Skip to content

Commit 4808609

Browse files
committed
add comments/todo
1 parent f8a7dc7 commit 4808609

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

com.unity.formats.fbx/Tests/FbxTests/ModelExporterTest.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -566,11 +566,13 @@ private string ExportSkinnedMesh(string fileToExport, out SkinnedMeshRenderer or
566566

567567
var importer = AssetImporter.GetAtPath(filename) as ModelImporter;
568568
#if UNITY_2019_1_OR_NEWER
569+
importer.importBlendShapes = true;
569570
importer.optimizeMeshPolygons = false;
570571
importer.optimizeMeshVertices = false;
571572
importer.meshCompression = ModelImporterMeshCompression.Off;
573+
// If blendshape normals are imported or weldVertices is turned off,
574+
// the vertex count between the original and exported meshes does not match.
572575
importer.importBlendShapeNormals = ModelImporterNormals.None;
573-
importer.importBlendShapes = true;
574576
importer.weldVertices = true;
575577
#else
576578
importer.optimizeMesh = false;
@@ -900,6 +902,8 @@ public void TestBlendShapeExport(string fbxPath)
900902
var hausdorffDistance = ComputeHausdorffDistance<Vector3>(worldVertices, exportedWorldVertices, (Vector3 a, Vector3 b) => Vector3.Distance(a, b));
901903
Assert.That(hausdorffDistance, Is.LessThan(epsilon), "Maximum distance between two vertices greater than epsilon");
902904

905+
// TODO: Investigate importing blendshape normals without discrepancy in vertex count between the original/exported meshes
906+
// and add test to compare blendshape normals and tangents.
903907
}
904908
}
905909
}

0 commit comments

Comments
 (0)