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
If the value_per_step is smaller then 0.5 it will never increase or decrease because of the Math.round function.
This creates a one step of change after the transition_time timeout.
maybe use the Math.round function in the sendDMX function instead of in the fadeToValue function.
Also this is in the way
if (diff <= steps) {
steps = 1;
}
The text was updated successfully, but these errors were encountered:
function sendDMX(values) {
var DMXvalues = []
for (var i = 0; i < values.length; i++) DMXvalues[i] = Math.round(values[i]);
var post_data = querystring.stringify({
u: node.universe,
d: DMXvalues.join(',')
});
// if (diff <= steps) { // cannot be completed in the amount of steps, so reduce to just one step
// steps = 1;
// }
if (direction === true) {
var value = node.addresses[channel - 1] + value_per_step;
} else {
var value = node.addresses[channel - 1] - value_per_step;
}
If the value_per_step is smaller then 0.5 it will never increase or decrease because of the Math.round function.
This creates a one step of change after the transition_time timeout.
maybe use the Math.round function in the sendDMX function instead of in the fadeToValue function.
Also this is in the way
if (diff <= steps) {
steps = 1;
}
The text was updated successfully, but these errors were encountered: