creating a trigger at running cursor position

Home Forums Scripts creating a trigger at running cursor position

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #2278 Reply
    Anonymous
    Inactive

    HI!
    Can someone give me an example of a script to create a trigger, when pressing a key on a controller, in the actual position of the running cursor.

    Here is my script:
    I put in BOLD the line than doesn´t work.

    function onConfigure() {
    //title(“enter title here”);
    //ask(“prompt”, “groupName”, “variableName”, defaultValue);
    }

    function onCreate() {
    run (” add curve 1 “)

    run (” setpos current 0 0 0 “)
    run (” setpointsellipse current 5 5 “)
    run (” add cursor 2 “)
    run (” setcurve current lastCurve “)
    run (” setspeed current 50 “)
    run (” setPattern current 0 0 1 “)
    run (” add trigger 23 “)
    run (” setpos current 4 3 0 “)

    run (” add trigger 25 “)
    run (” setpos current -4 -3 0 “)
    }

    function onMessage(protocol, host, port, destination, values) {
    if((protocol == “midi”) && (destination == “cc”) && (values.length > 2)) {
    var channel = parseInt(values[0]);
    var cc = parseInt(values[1]);
    var val = parseInt(values[2]);

    if (cc == 32) {

    run (” add trigger auto “)
    run(“setPos current ” + cursor_value_x + ” ” + cursor_value_y + ” 0″);

    }

    }
    }

    Thank´s

    Andrés

    #2832 Reply
    Anonymous
    Inactive

    Hi!

    In the current version, it is not possible to that directly in IanniX. We make tests with new features that allows to do that for the next release. The only possibility is to use Pd or Max (cursor outputs its coordinates and pd send the information to create a trigger).

    Thanks!

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: creating a trigger at running cursor position
Your information:





© IanniX Association

What is IanniX? | Download | Showcase | Forums | Research | About