Vidvox / oscqueryhtml

MIT License
14 stars 1 forks source link

Sliders fire OSC messages when the value gets updated from the server #63

Open SolfaMode opened 2 years ago

SolfaMode commented 2 years ago

Steps to reproduce: Given a slider with OSC address X. Update the float value of X in the OSC Query server and send it using Web Socket.

Expected result: Javascript updates the slider and done

What happens: oscqueryhtml additionally sends a new value for X back to the server. This can produce an infinite update-cycle.

Workaround: In index.js applyOSCMessageValue() set a global flag before targetElem.rangeSlider.update({value: value}, false); Clean that flag after the call. In userinput.js controlEvent(e) avoid sending value if flag is set.