Using cv.jit.faces to control camera

Oct 8, 2011 at 5:08am

Using cv.jit.faces to control camera

i’m trying to combine zachary seldess’ version of faces and 3d rotation (patch at the bottom-http://cycling74.com/forums/topic.php?id=33029 ) with camera controls…

i’m a bit stuck…..how should i link them?

[attachment=172225,2702]

Attachments:
#59207
Oct 8, 2011 at 6:34pm

Hi synthaswinger,

What are you trying to do? That patch already had “camera controls” of a sort, so if you could be a bit more specific I might be able to help.

best,
Zachary

#212655
Oct 8, 2011 at 8:20pm

I am trying to have the camera move the same way for using 3d objects but with image plane/depth map…i’m also trying to find a way to be able to set the camera axis at 0 at any given angle to use different angles for rotating.

i just threw your patch into this one without even taking any stupid leaps. i’d like to do it right. do i need to convert to char to use faces?
thankyou very much,

– Pasted Max Patch, click to expand. –
#212656
Oct 8, 2011 at 8:35pm

If you want to use the depth matrix from the kinect in tandem with cv.jit.faces for what you describe, I’d recommend grabbing the center coordinate of the face (see [p getCenterCoords]) and looking up the depth value for that coordinate in the depth matrix (see the tutorials on how to look up cell values in a jit.matrix). You can use that depth value in the right inlet of [p z.3Dportocar].

Setting the camera axis at 0 at any given angle is just a matter of modifying the azimuth and elevation values going into the 1st two inlets of [p z.3Dpoltocar] (translation via addition or subtraction, etc.). This assumes you want an up vector of 0. 1. 0. (the default). If not, you shouldn’t use my poltocar solution.

best,
Zachary

#212657
Oct 11, 2011 at 3:09pm

From your screen shot it looks like your Quat objects aren’t installed properly. Do you have the cosm objects installed?

#212658

You must be logged in to reply to this topic.