mirror of
https://github.com/AssetRipper/AssetRipper.git
synced 2025-12-11 20:15:29 +01:00
* Fix bug where there were extra skin weights extracted. The extra values were all 0 because there was never any data to fill them. * Make compiler warn for incorrect use of Pure methods * Refactor BoneWeight4 to use InlineArray * Support bit packing ReadOnlySpan<int> * Support setting the compressed mesh weights
19 lines
487 B
C#
19 lines
487 B
C#
namespace AssetRipper.Numerics.Tests;
|
|
|
|
public class BoneWeight4Tests
|
|
{
|
|
[Test]
|
|
public void DefaultCanBeNormalized()
|
|
{
|
|
BoneWeight4 boneWeight = new BoneWeight4().NormalizeWeights();
|
|
Assert.Multiple(() =>
|
|
{
|
|
Assert.That(boneWeight.Weight0, Is.EqualTo(0.25f));
|
|
Assert.That(boneWeight.Weight1, Is.EqualTo(0.25f));
|
|
Assert.That(boneWeight.Weight2, Is.EqualTo(0.25f));
|
|
Assert.That(boneWeight.Weight3, Is.EqualTo(0.25f));
|
|
Assert.That(boneWeight.Normalized);
|
|
});
|
|
}
|
|
}
|