You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there any easy way to see which variables have changed during a call to solver.updateVariables? The api doesn't seem to give me a convenient way to incrementally update anything depending on the kiwi solver's state (such as UI), without checking each variable individually.
2 possible approaches for the API that spring to mind are:
Thanks for the ideation! Sounds like a good idea in general to be able to react to changes of (derive from) certain variables.
Thoughts?
I think the callback approach is good because it will cost initial memory for the callbacks, and after that will only be calling the callbacks upon updates if the callbacks exist, whereas if the updateVariables method returns a new array of modified variables on each call, that could add higher runtime cost for every calculation in creating the new arrays (imagining it running during animation). I think that the subscription is also more common of a pattern people will be familiar with.
Is there any easy way to see which variables have changed during a call to
solver.updateVariables
? The api doesn't seem to give me a convenient way to incrementally update anything depending on the kiwi solver's state (such as UI), without checking each variable individually.2 possible approaches for the API that spring to mind are:
solver.updateVariables
Thoughts?
The text was updated successfully, but these errors were encountered: