I am trying to live stream an animation (for a gltf model) frame by frame from a server (via a WebSocket) by sending transform data (i.e. bone position, rotation, ...) from server to client. The data is for the same model so animation re-targeting is not an issue here.
I would like some advice on how I should use the frames I receive and whether I should update the model in the render loop or not.
My idea is to buffer the frames in an array as I receive them. Then I have update functions in my render loop where I take the first element from the array (if available) and apply the transforms to my model, taking deltaTime (time between current and previous frame) into account.
For live streaming transform data like this and updating the model dynamically, should the updates happen inside the render loop or outside of it ?