change math library
fixed bug
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using SharpDX;
|
||||
|
||||
namespace AssetStudio
|
||||
{
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using SharpDX;
|
||||
|
||||
namespace AssetStudio
|
||||
{
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using SharpDX;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace AssetStudio
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
using SharpDX;
|
||||
|
||||
namespace AssetStudio
|
||||
{
|
||||
@@ -21,7 +20,7 @@ namespace AssetStudio
|
||||
{
|
||||
public KeyValuePair<string, UnityTexEnv>[] m_TexEnvs;
|
||||
public KeyValuePair<string, float>[] m_Floats;
|
||||
public KeyValuePair<string, Color4>[] m_Colors;
|
||||
public KeyValuePair<string, Color>[] m_Colors;
|
||||
|
||||
public UnityPropertySheet(ObjectReader reader)
|
||||
{
|
||||
@@ -40,10 +39,10 @@ namespace AssetStudio
|
||||
}
|
||||
|
||||
int m_ColorsSize = reader.ReadInt32();
|
||||
m_Colors = new KeyValuePair<string, Color4>[m_ColorsSize];
|
||||
m_Colors = new KeyValuePair<string, Color>[m_ColorsSize];
|
||||
for (int i = 0; i < m_ColorsSize; i++)
|
||||
{
|
||||
m_Colors[i] = new KeyValuePair<string, Color4>(reader.ReadAlignedString(), reader.ReadColor4());
|
||||
m_Colors[i] = new KeyValuePair<string, Color>(reader.ReadAlignedString(), reader.ReadColor4());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using SharpDX;
|
||||
|
||||
namespace AssetStudio
|
||||
{
|
||||
@@ -428,7 +427,7 @@ namespace AssetStudio
|
||||
public SubMesh[] m_SubMeshes;
|
||||
private uint[] m_IndexBuffer;
|
||||
public BlendShapeData m_Shapes;
|
||||
public Matrix[] m_BindPose;
|
||||
public Matrix4x4[] m_BindPose;
|
||||
public uint[] m_BoneNameHashes;
|
||||
public int m_VertexCount;
|
||||
public float[] m_Vertices;
|
||||
@@ -845,13 +844,13 @@ namespace AssetStudio
|
||||
{
|
||||
if (m_CompressedMesh.m_BindPoses.m_NumItems > 0)
|
||||
{
|
||||
m_BindPose = new Matrix[m_CompressedMesh.m_BindPoses.m_NumItems / 16];
|
||||
m_BindPose = new Matrix4x4[m_CompressedMesh.m_BindPoses.m_NumItems / 16];
|
||||
var m_BindPoses_Unpacked = m_CompressedMesh.m_BindPoses.UnpackFloats(16, 4 * 16);
|
||||
var buffer = new float[16];
|
||||
for (int i = 0; i < m_BindPose.Length; i++)
|
||||
{
|
||||
Array.Copy(m_BindPoses_Unpacked, i * 16, buffer, 0, 16);
|
||||
m_BindPose[i] = new Matrix(buffer);
|
||||
m_BindPose[i] = new Matrix4x4(buffer);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1082,7 +1081,7 @@ namespace AssetStudio
|
||||
value = inputBytes[i] / 255.0f;
|
||||
break;
|
||||
case 2:
|
||||
value = System.Half.ToHalf(inputBytes, i * 2);
|
||||
value = Half.ToHalf(inputBytes, i * 2);
|
||||
break;
|
||||
case 4:
|
||||
value = BitConverter.ToSingle(inputBytes, i * 4);
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using SharpDX;
|
||||
using RectangleF = System.Drawing.RectangleF;
|
||||
using System.Drawing;
|
||||
|
||||
namespace AssetStudio
|
||||
{
|
||||
@@ -67,7 +66,7 @@ namespace AssetStudio
|
||||
public VertexData m_VertexData;
|
||||
public SpriteVertex[] vertices;
|
||||
public ushort[] indices;
|
||||
public Matrix[] m_Bindpose;
|
||||
public Matrix4x4[] m_Bindpose;
|
||||
public BoneWeights4[] m_SourceSkin;
|
||||
public RectangleF textureRect;
|
||||
public Vector2 textureRectOffset;
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using SharpDX;
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace AssetStudio
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using SharpDX;
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
Reference in New Issue
Block a user