ArcRotateCamera automatically adjusts the field of viewbased on the imported model

hello everyone, I want to implement the function of character skinning. The basic character model is uploaded by the user. How to automatically adjust the camera adaptation according to the character model in the imported scene so that the character model is in the center of the camera’s field of view

This is the expected result
This is not the expected result

There’s been a number of topics around this. First thing you can try with the arcRotateCamera is to use framingBehavior
Else you can make a search for center +mesh +view or +fit screen. Something around that.
Solutions are around getting the boundingBox information and targetting on this. But I think an ez start would be to try use the above (framing behavior).
Meanwhile, have a great day :sunglasses:

1 Like

Thank you very much for your answer, it helped me a lot

1 Like