Using rslider as frequency range selector

Jan 27, 2010 at 9:56pm

Using rslider as frequency range selector

Ever wake up saying to yourself, I’m going to code a simple little Max patch this morning in about ten minutes, only to surface 4-5 hours later?

I thought to make a log frequency range selector using rslider and two number boxes, but when you mouse the number boxes directly, you get a negative range, blech. Want I wanted was for the two numbers (lo + hi) to behave like beads on an abacus, i.e., respect each other’s boundaries.

Anyway, thought I’d post the result as it contains an interesting Max trick (or, perhaps someone can suggest a simpler approach?).

– Pasted Max Patch, click to expand. –
#48073
Jan 27, 2010 at 11:36pm

Not sure if this will help, but thought I’d post it. I like what you did with [pvar] which is something I never use, but probably should…

You can also make use of [waveform~] instead of the [rslider] for a range selector, it takes a little more work to set up (not much) and gives you some more possibilities like the grid and snapping features, and the “loop” tool behaves slightly differently (expand/contract the range with the mouse more easily than the “select” a la rslider). Just set the buffer~ size to the range you want, like 155 as you have with your [rslider]. You don’t need any audio in the buffer~, but you do need to initialize it with a length for it to become interactive.

– Pasted Max Patch, click to expand. –
#172917

You must be logged in to reply to this topic.