Skip to content

Commit

Permalink
Merge pull request #1283 from notargs/feature/fix_exporting_bug
Browse files Browse the repository at this point in the history
Ignore meshFilter if it hided or hasn't vertex
  • Loading branch information
ousttrue authored Oct 8, 2021
2 parents 97ff3ba + 75afd54 commit 4a19a4e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Assets/UniGLTF/Runtime/UniGLTF/IO/MeshIO/MeshExportInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ public MeshExportInfo(Renderer renderer, GltfExportSettings settings)
else if (renderer is MeshRenderer mr)
{
var filter = mr.GetComponent<MeshFilter>();
if (filter != null)
if (filter.hideFlags == HideFlags.None && Mesh.vertexCount > 0 && filter != null)
{
Mesh = filter.sharedMesh;
}
Expand Down

0 comments on commit 4a19a4e

Please sign in to comment.