1
0
mirror of synced 2024-11-12 02:00:50 +01:00

Ignore rigid indices for now to fix transform issues

This commit is contained in:
KillzXGaming 2019-06-14 21:35:09 -04:00
parent b8cb80727a
commit ad3cd6654b
9 changed files with 3 additions and 14 deletions

Binary file not shown.

View File

@ -1273,9 +1273,9 @@ namespace Bfres.Structs
Matrix4 trans = Matrix4.Identity;
if (IsSingleBind)
{
bool IsRigidIndex = skel.IsIndexRigid(BoneIndex);
if (!IsRigidIndex)
return position;
// bool IsRigidIndex = skel.IsIndexRigid(BoneIndex);
// if (!IsRigidIndex)
// return position;
if (BoneIndex >= skel.Node_Array.Length || BoneIndex == -1)
{

View File

@ -336,10 +336,6 @@ namespace FirstPlugin
{
int boneIndex = fshp.BoneIndex;
//Not often but some models use a bone index list instead
if (fshp.BoneIndices.Count > 0)
boneIndex = fshp.BoneIndices[0];
Matrix4 NoBindFix = model.Skeleton.bones[boneIndex].Transform;
v.pos = Vector3.TransformPosition(v.pos, NoBindFix);
v.nrm = Vector3.TransformNormal(v.nrm, NoBindFix);

View File

@ -289,10 +289,6 @@ namespace FirstPlugin
if (model.Skeleton.bones.Count > 0) {
int boneIndex = fshp.BoneIndex;
//Not often but some models use a bone index list instead
if (fshp.BoneIndices.Count > 0)
boneIndex = fshp.BoneIndices[0];
Matrix4 NoBindFix = model.Skeleton.bones[boneIndex].Transform;
v.pos = Vector3.TransformPosition(v.pos, NoBindFix);
v.nrm = Vector3.TransformNormal(v.nrm, NoBindFix);

View File

@ -773,8 +773,6 @@ namespace Switch_Toolbox.Library
dataOffset += ArrayImageize;
mipDataOffset += ArrayMipImageize;
break;
}
return result;
@ -1160,7 +1158,6 @@ namespace Switch_Toolbox.Library
private static ulong computeSurfaceAddrFromCoordMacroTiled(uint x, uint y, uint bpp, uint pitch, uint height,
AddrTileMode tileMode, uint pipeSwizzle, uint bankSwizzle)
{
uint sampleSlice, numSamples, samplesPerSlice;
uint numSampleSplits, bankSwapWidth, swapIndex;