Open hamza-hajji opened 1 month ago
Hi @hamza-hajji , Michał from Creoox here. Thank you for your feature request, we'd like to understand the motivation better. What would be a use-case for this user-initiated state change broadcast?
Hi Michał, thanks for your response, about the motivation: based on your linkedin post (https://www.linkedin.com/posts/xeolabs_testing-xeokits-upcoming-dynamic-model-realign[…]tm_content=feedcontent&utm_medium=g_dt_web&utm_campaign=copy) we would like to listen the event when a user moves a model to align it in order to display for example arrow the direction the user move the model
If we align the models every time we move a model with model.position = [...]
, we have to copy paste it all over the codebase, it's better to listen to that change once, and align all the time
model.on('position', (newPos) => {
alignedModel.position = newPos;
})
Is your feature request related to a problem? Please describe. I often want to listen to transform (position, rotation...) change for a model, but I don't find a triggered event for that
Describe the solution you'd like Maybe an event, like
eye
for camera that listens to eye property change, for exampleDescribe alternatives you've considered I make it work currentyl with
rendered
eventBut it causes a lot of lagging even after debounce
Thank you