Forums > Jitter

[sharing] 3D Camera Movements in Max 6

December 16, 2011 | 9:50 pm

I came up with this really simple patch that shows how to use jit.anim.drive to make really smooth, totally nice-looking 3D camera movements in Jitter, with easing and everything. As a bonus, I also included a little subpatch that connects to a Space Navigator mouse. Now, go create some galaxies to explore!

– Pasted Max Patch, click to expand. –

December 18, 2011 | 2:29 am

nice, can’t wait for your gen recipes :)



t
December 18, 2011 | 8:38 pm

thank you Andrew!!!


December 25, 2011 | 4:28 pm

Hello Andrew,

First i want to thank for this wonderfull example !

But i have a litte problem:
I am trying to stare and recall different views of the camera.
I am grabbing the position and the rotatxyz attributes.

But the stored and the recalled views are not the same.

Is there an other attribute as position and rotatxyz, which
is set, when moving the camera with "move" and "turn" ?

Thanks for any help,
TT

here is my example patch:

– Pasted Max Patch, click to expand. –

December 27, 2011 | 6:23 pm

hi timtom. the views are the same. it’s just that every time you bang your preset, it is causing the scene to be randomly regenerated, because your preset is including the main toggle that triggers the scene randomization.


December 28, 2011 | 6:24 pm

thank you very much for looking into the patch robert.
now it works !

one little thing is not clear from my point of view.

the pattr oblect, which is bind to the rotatexyz attribute of the camera
is not outputting the attribute if you change it with the mouse
(using the jit.anim.drive)

also the cameras attrui object does not update.

here is a smal example:

– Pasted Max Patch, click to expand. –

December 31, 2011 | 9:50 am

hi andrew – is there any way to set limits on an axis of camera rotation? – I’d like to be able stop the camera from looking too far up or down.


December 31, 2011 | 6:02 pm

i am considering adding limits as a feature to jit.anim.node, so your request is registered.

in the meantime, you can to this yourself simply by keeping track for the current camera x and y rotation, and not allowing additional rotations when you’ve reached your limits.

the example patch Max6/examples/jitter-examples/render/anim/anim.camera.advanced.maxpat
give one way to do this in the "limit-orient" sub-patch.


December 31, 2011 | 11:50 pm

Robert – thanks, but unfortunately the anim.camera.advanced.maxpat example you gave uses mouse movement as input, unlike Andrew’s example, which uses jit.anim.drive, and so it’s not at all obvious how the ‘limit-orient’ sub-patch could be repurposed for jit.anim.drive — since jit.anim.drive has to be connected directly to the object/node that it’s controlling.


January 4, 2012 | 5:55 pm

actually, jit.anim.drive does not need to be directly connected.
it simply outputs animation messages (anim_turn, anim_move, anim_grow).

however, note that the fourth argument to the animation message is speed, and needs to be multiplied with the first three args for proper scaling of the animation.

you can set the @targetname attribute manually, and bypass the need for direct connections.

but yes, i agree limit attributes would be useful.


January 4, 2012 | 6:45 pm

by god – it actually works – a bit of a hiccup now and then, but it works!

thanks Robert!

– Pasted Max Patch, click to expand. –

January 4, 2012 | 8:03 pm

although I just realized I left out the fourth speed argument, and when I put it back in, the limits don’t work correctly any more – what am I doing wrong?

– Pasted Max Patch, click to expand. –

February 3, 2012 | 1:17 am

okay, so I tried this and it worked alright, but for some reason my SpaceNavigator setup is vastly different – "hi" reports different indexes for the values, and even the device name is different on mine.

If others are having the same problem, here’s my edit of the innards of the space navigator subpatch:

– Pasted Max Patch, click to expand. –

Also worth noting: I’ve added change filtering and switched some polarities on the controls, so navigation is very different – and to me a bit more intuitive. I had the same issues with the original aka.spacenavigator and the jit.gl.handle version of it, too.


July 11, 2014 | 10:00 am

Andrew,
I am trying to apply this patch to an object as opposed to a camera.
Picture this: A model of a Camera on a Dolly travelling on a Dolly Track. I am rotating it around an anchor point at the proper radius.
I want to define ~10 positions along that track and be able to save them. I am looking for Hold time, Position, Ease Out and Speed.
After the "Scenes" are saved, I would like to hit a Go button and have the 3dD Camera perform the defined motions.

I’ve copied your Patch into mine and routed the output to the Camera Rotation. Several things became clear right away. One is the fog. I got rid of it and now my scene renders without all the crazy things it was doing.
Another question is – what does the noise stuff do? Is it applicable to an object vs a camera?

My request is – an annotated patch that explains the struct and the usage in detail.
You sure would be helping us Animators out in Jitter.

I am somewhat new to Jitter, so anything you could do along these lines would be greatly appreciated.
I know I’m asking a lot.
Thanks for what you’ve already done – it’s given me the inspiration to take it to the next level.

– Pasted Max Patch, click to expand. –

The working Patch:

– Pasted Max Patch, click to expand. –

Richard


July 11, 2014 | 11:20 am

Andrew,
Here are the files I’m working with…
Richard


July 13, 2014 | 2:41 am

Andrew,
We decided to go another route. Thanks for your patch. I’ll be using it for other things I’m sure.

Richard


July 18, 2014 | 10:18 pm

This in fascinating – thanks Andrew.


Viewing 17 posts - 1 through 17 (of 17 total)