I have been working with a Blender file that contains multiple shape keys. By adjusting the slider in Blender, I am able to manipulate these shape keys.
(screenshot):
Currently, I am exporting the GLTF and then importing it into Three.js.
Upon console.log
ing the mesh from the GLTF, I noticed that the shape keys from Blender are present in the morphTargetDictionary
. I have also set up a GUI to adjust the morphTargetInfluences
for each shape key:
folder
.add(params, "influence2", 0, 1)
.step(0.01)
.onChange(function (value) {
console.log(dodec.morphTargetInfluences[1]);
dodec.morphTargetInfluences[1] = value;
//dodec.updateMorphTargets();
});
Despite my efforts, updating these morphTargetInfluences does not seem to produce any changes. How can I configure this setup so that I can replicate the same effects in Three.js as I achieve in Blender by adjusting the sliders for each shape key?
update
For reference, here is a codepen showcasing my current progress: