How to divide multislider in UNequal, non-integer increments

    Jan 05 2010 | 12:31 am
    I want to use multislider to control a simple frequency sequencer. I prefer multislider for this so I can make a bunch of presets.
    Anyway, I want there to be 12 sliders, ranging from 1 to 2. I also want each slider to have only 12 possible positions, which I'd like to define manually. Is this possible to do? Check this out...this shows a 12-slider multislider with a message sending it the 12 increments I would like. Please, if there is a way to make it so moving the sliders up and down will just move between these increments, please let me know!
    Thanks, Jeremy

    • Jan 05 2010 | 1:20 am
      If you don't mind the visual effect of the [multislider] not quite matching up to the real values you could try setting them to integer values and using [vexpr] to do the conversion. Perhaps something like this example.
    • Jan 06 2010 | 7:04 pm
      Awesome that is a start. So I want to use the output of the multislider as a multiplier for another number (carrier freq) which will be in another number box...
      The intervals contained in the message boxes there represent the intervals between notes in an equal tempered octave. Basically I want to make a little note sequencer/arppegiator with controls of carrier frequency (for FM), and tempo. I already have the rest of the machine built. I just want to be able to basically make any 12-note sequence I want, and have the output of the multislider be one of the interval ratios listed in the message box (that way it can be multiplied with the carrier frequency and the note arrangements will be "in key" regardless of what originating frequency the user chooses.
      Thanks for any help!
      so if you look here, i want the interval multiplier box to be receiving the numbers in the 1, 1.059...etc series.
    • Jan 06 2010 | 7:11 pm
      Use the equation in an [expr] rather than a [vexpr] so [expr (pow(2.,(($f1-1.)/12.)))] instead.
    • Jan 06 2010 | 7:32 pm
      Ok...but taking the output of the exp object and inputting it to a flonum doesn't do anything...
    • Jan 06 2010 | 8:08 pm
      Try this.
    • Jan 06 2010 | 9:51 pm
      That is better, thank you. So now the flonum moves with the numbers, but the multiplier isn't really doing anything...see? basically the number on the right input of the multiplier just goes through.
    • Jan 07 2010 | 4:38 am
      Really can't figure out why the multiplier isn't doing anything. Sorry to be such a goon but this is my last question.
    • Jan 07 2010 | 4:48 am
      You need to give the [* ] object a float argument otherwise it will truncate everything it receives to an integer, basically ignoring everything after the decimal point. Try replacing it with [* 1.] and remember to use a [flonum] instead of a [number] afterwards.
    • Jan 07 2010 | 4:59 am
      Luke Hall, I owe thee a beverage. Many thanks.
    • Feb 10 2010 | 4:05 am
      Hey Luke Hall! Got another quick question about this thing when you have a sec! I'm trying to increase the range to two octaves, so now i have a total of 25 notes instead of 12. Do I need to change anything with the code you gave me? I only ask because I tried just changing the message box to contain all 25 intervals, but it's not coming out right. It's basically just playing each interval twice in a row.
      The new intervals I want are:
      Thanks again!
    • Feb 10 2010 | 9:30 am
      In the [vexpr] objects you need to change the equation back to this: [vexpr (((log10($f1))/(log10(2.)))*12.)+1.] and [vexpr (pow(2.,(($f1-1.)/12.)))]. You had changed the "2" to a "3" which was causing problems. You probably also want to change your multislider back to integer mode.
    • Feb 10 2010 | 10:26 pm
      My man, thanks!