Skip to content

Commit 2d855f0

Browse files
committed
Fix #3128 Currently selected frame in the animated texture breaks gltf export
1 parent 310a976 commit 2d855f0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

js/io/formats/gltf.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -453,6 +453,10 @@ var codec = new Codec('gltf', {
453453
if (!Modes.edit) {
454454
Animator.showDefaultPose();
455455
}
456+
let animated_textures = Texture.all.filter(tex => tex.frameCount > 1);
457+
Texture.all.forEach(tex => tex.currentFrame = 0);
458+
TextureAnimator.update(animated_textures);
459+
456460
Outliner.root.forEach(node => {
457461
if (node instanceof Group && options.armature) {
458462
let skinned_mesh = buildSkinnedMeshFromGroup(node, options.scale);

0 commit comments

Comments
 (0)