Skip to content

Commit 49f95dc

Browse files
authored
Merge pull request #496 from impossible-dev/fix-blendshapes-naming
Fix FBX shape naming for blendshapes
2 parents 02596c1 + 1cb7e24 commit 49f95dc

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

com.unity.formats.fbx/Editor/FbxExporter.cs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,14 @@ private bool ExportBlendShapes(MeshInfo mesh, FbxMesh fbxMesh, FbxScene fbxScene
498498
var weight = umesh.GetBlendShapeFrameWeight(bi, fi);
499499
umesh.GetBlendShapeFrameVertices(bi, fi, deltaPoints, deltaNormals, deltaTangents);
500500

501-
var fbxShape = FbxShape.Create(fbxScene, "");
501+
var fbxShapeName = bsName;
502+
503+
if (numFrames > 1)
504+
{
505+
fbxShapeName += "_" + fi;
506+
}
507+
508+
var fbxShape = FbxShape.Create(fbxScene, fbxShapeName);
502509
fbxChannel.AddTargetShape(fbxShape, weight);
503510

504511
// control points

0 commit comments

Comments
 (0)