Calculate boundingBox on first and last frame on animationGroup

Hi guys,

I’m new here :smile:

I’m currently building a product configurator and I’m importing a GLTF file in my scene.

This GLTF file contains an animation (i see it as a animationGroup in my scene) and when I load it with my assetsManager I need to know the boundingBox of all active meshes when they are on animation frame 0 and when they are on the latest frame.

I’m trying to do that inside the assetsManager.onFinish callback, but I can’t understand how to bring the animation to frame 0 and then calculate the current boundingBox (no problem here with this calculation), then bring the animation to latest frame and then calculate again the boundingBox (again, no problem with boundingBox calc). My problem is to move instantly between the frames of the animation, how can I achive this?

Thank you in advance

Hey @ste, welcome to the community! For an animation group, I believe that you can use goToFrame to go directly to a specific frame.

Hello @ste just checking in, was your question answered? :slight_smile: