jit.noise to jit.gl.mesh, staying centered

    Jan 23 2014 | 7:42 am
    This is surely a stupid problem, but I've been dying to get a handle on processing 3D geometry and keep running into this issue. I want to play with jit.gl.mesh by feeding it generative matrices. It likes float32 3 plane matrices as input for its vertex array so I've been trying to create those and then run them through jit.ops. Very important is also to interpolate the values via something like jit.slide, but when I do a slide and crank up slide_down, the whole thing becomes tiny and recedes to the upper right corner of the screen, and slide_up to the lower left. Does anybody know the best way to avoid this? Ideally, when you crank up slide_down, the noisey mass would stay roughly the same size but just kind of undulate softly instead of explodish-ly.
    [mod - removed uncompressed patch]

    • Jan 28 2014 | 2:46 pm
      hi, Yo should use copy compressed, to post patches here...
    • Feb 03 2014 | 8:57 pm
      jit.noise creates random values between 0 and 1. if you want to keep that centered using gl.mesh and the default gl.render view, simply pass through a jit.expr or jit.op chain. eg: jit.expr @expr in[0]*2-1, which scales the values to -1 to 1