snapping slider or dial or number box

Louis Dufort's icon

Hi,

I would like to have a snapping option on i.e a slider . Let say that my slider goes from 0 to 100 and I want my mouse to snap on 20 , 40, 80, and 92. I still want to be able to access all the value in between, but when I'm near a specify number (20, 40 80 and 92) I want it to snap.

Any ideas on how to achieve this?

The use I want to make of this is to control a loop and I want it to lock to a specific multiple of a bpm value or note value while I can still in real time make some accelerando or decelerando between each specific note value...

Thanks

Louis

LiamCormacGould's icon

Why not use split and scale or something like that on the output. Then you can create a wider area of the slider that corresponds to those values. Not exactly what you mean but it would do a similar job.

seejayjames's icon

yep, I would use a slider with just the points you need (the BPM divisions), then have a "fine-tuner" dial afterwards which adds or subtracts some given amount.

The "snapping" would be doable, but kind of tricky I think, and there's the issue of: how do you make fine adjustments once you're snapped to a value, when it snaps automatically if you get close to that number? ... you could gate the snapping behavior I suppose...

It sounds off-topic, but [waveform~] has some interesting snapping features, maybe there's a way to hack into those...using them as a control for tempo, not for buffer~ selection.

Roman Thilenius's icon

you must start off a metro object, which regulary bangs the slider with the desired snap values.
the rest should be easy to find out.

goingdeaf's icon

Try using the [if] object combined with [line]?

: )