rotating cartesian points (on Z axis) at audio signal rate?

meeble's icon

Hello,

I am currently building a custom laser control patch in Max/Jitter and have the basics working. The X and Y coordinates are sent as audio signals, which creates the various shapes via analog voltages. Let's say I have a simple 4 point square being created with my X/Y signals - how would I go about rotating the square on the Z axis while still remaining in the audio signal realm? The laser projector requires very exact timing to create smooth shapes, and Max's control/bang/metro/scheduler messages are far to unpredictable to work in this application.

I am currently using a scope~ object to visualize the X/Y shapes - ideally, I could see the rotation from there.

Thanks!

seejayjames's icon

Not really sure about a few things in your setup. How are you sending the X, Y, Z audio data? Do the projectors respond to the Z data somehow? I'm assuming they must, if you want to rotate it...or are you just "rotating" it in 2D, so it *looks* like it's using Z but really isn't?

To monitor things, you might try jit.plot instead of scope~, it's set in a 3D environment. Not sure how the Z data will fit in though, except just for monitoring...

meeble's icon

Hi seejayjames,

The laser projector only accepts X and Y voltages, and they are being sent as audio signals. I want the 2D image or coordinates to rotate on the Z access, but you are exactly correct - it is merely 2D. I'm not sure if a Z axis is needed or not?

Thanks!

spectro's icon

Cartopol~ & poltocar~ is what you could use for 'rotations' in the audio domain (but, assuming an origin of zero, all you really need to do is scale your x co-ords by an oscillating value for horizontal rotation and y for vertical) With that said, there's probably no good reason you couldn't use scheduler based processes to create and rotate your geometry etc (via jitter) and then convert the laser co-ordinates to audio signals (with a little smoothing perhaps) as a final step.

spectro's icon

Ok. Just realized that what I suggested re scaling the x and y values is really just rotating around the x and/or y axes(!) and can't previous post now. Cartopol~ and poltocar~ are still applicable though.

meeble's icon

Thanks a lot - the cartopol~ and poltocar~ objects work perfectly. :)

An a side note - how would I enter a mathematical expression to be calculated on the signals like this one:

r(theta) = a+b(theta)

which supposedly makes a spiral shape when graphed/scoped.

dtr's icon

Hey Meeble, did you get any further with this?

Layne Harris's icon

I'm working on a laser patch also. Is there any chance you would mind sharing your patch? Thanks!