jit.gl.render 'z' question

    Oct 06 2015 | 2:10 pm
    I'm sorry, I'm very new to jitter. I try to have an interface which shows me x,y,z values. So I'm taking a circle and when the z value increases, the circle should become bigger and visa versa. I made a patcher, using 'jit.gl.render PLUS jit.window PLUS jit.gl.gridshape'. Everything works fine but because it is 3D, my circle not only increases but 'comes closer' when raising the z value. Is there a possibility that the size of the circle increases WITHOUT changing its position in space? The problem is: when I'm at the corner of my jit.window and I increase z, the circle comes closer and 'disappears' out of the jit.window. There are so many commands and I don't know which one to use to prevent that. Thanx for helping.

    • Oct 06 2015 | 5:04 pm
      if you want to fix the "disappearing" circle, adjust the @near_clip attribute of jit.gl.render or jit.gl.camera, otherwise make your circle bigger using the @scale attribute.
    • Oct 06 2015 | 5:08 pm
      Hey Rob, thanx a lot...there is not much comment about the 'near-clip' in the references. I try to figure it out. Super... Peer
    • Oct 06 2015 | 5:42 pm
      Hey Rob, could you please send me a little example-patcher ? i don't get it. the @scale attribute is no option because the dimensions are changing proportional with that.
      Thanx Peer
    • Oct 07 2015 | 1:35 pm
      Helllo Jazzifaction,
      If you right click on the object's left most inlet , you'll that all the object's attributes are there.
      to control an OB3D object ( you'll want to talk to what we call a transform.
      a transform : position / scale / rotatexyz / if you choose and attrui object , you'l see the state of these params update automatically, Next , you'll most likely write back here saying I can there it a workaround using the pattrstorage but it's ugly and more pain that it's worth.
      back to your topic; again, right clicking on the left most inlet will give all the info about the object you need.
      Consider the near clip and far clip as the buffer size for the 3d scene to draw
      phiol hope this helps
      Max Patcher
      In Max, select New From Clipboard.
      here is a basic setup
    • Oct 07 2015 | 3:34 pm
      Hey Phiol, thanx a lot. Honestly, I knew all that and it is not I was searching for BUT that's not at all your fault cause I just asked a stupid question for which there is no answer. I was trying to have a 2D object in which I can change the size of the circle I'm using. So I thought that I can use jit.gl. for a 2D graphic with a so called 'z' which changes the size of my circle without changing the position of it. Intelligent, isn't it ?
      Briefly I wanted to pay with Dollars although I only had Euros in my pocket if you understand. It took me 10 hours to come to this point, but well, that's how life is ;-) Thanx anyway.
      Cheers Peer
    • Oct 07 2015 | 4:30 pm
      use the @ortho attribute for jit.gl.render, you can change it to orthographic and use the lens angle instead of the "z" parameter which is now unusable. In this way you should achieve what you're looking for, but obviously you're gonna lost the "real" perspective.
    • Oct 07 2015 | 10:51 pm
      Hey Franz, if I use @ortho 1 for jit.gl.render my z axis is 'switched off'. But then I have to @lense_angle -or so to say a message box lense_angle $1- to the jit.gl.render object...and the result: it doesn't solve the problem. Did I do sth wrong? -> see patcher
      Max Patcher
      In Max, select New From Clipboard.
      Thanx so much Peer
    • Oct 08 2015 | 4:54 pm
      I really can't figure out what you're trying to achive. Your last patch works good, except for the "lense" typo.
    • Oct 08 2015 | 11:12 pm
      Hey Franz, sorry, you are right...now it works :-) Fantastic !! Thanx so much
      Cheers Peer
    • Oct 09 2015 | 7:29 am
      This is finally the patcher which does exactly what I want. No lens_angle needed - @ortho 1 is just fine to solve the problem. Thanx to all of you.
      Max Patcher
      In Max, select New From Clipboard.
      Cheers Peer
    • Oct 09 2015 | 6:11 pm
      Great! Glad to be useful :) I think you can mark the topic as [SOLVED]
    • Oct 09 2015 | 6:21 pm
      indeed :-)