
|
Camera look at not working?
Hey, I'm making a new post cause it seems some how my old one got messed up. Any ways, i keep trying the camera lookAt() method and it doesn't seem to be working for me, camera.lookAt( DisplayObject3D.ZERO ); doesn't not do the desire effect.
Old post...
Default papervision set up...
/\ camera at z -10
\_/ Flat plane culling so that visible for the camera
+x_____0 Left hand rule
|
|
|+z
I basically want to achieve...
/\ camera at z 10
|+z
\_/ |
+x_____| Righ hand rule
0
In order to achieve this, with out applying a yaw of 180 to the camera, because i want rotation on the camera to stay intact, i would need to change the look at of the camera from 0, 0, 1, to 0, 0, -1 so that its looking straight down at the +z plane. Also because of the default culling order of the objects in papervision i would be looking at the back of plane and see nothing, unless i turn on backside, but i don't want to do that, i want to change the direction of the culling, so that i can see it on the other side.
I hope I'm making more sence now, let me know if still not understanding what I want to achieve.
I'm not sure if doing, camera.lookAt( DisplayObject3D.ZERO ); (which I tried but did not work for me) would give me what i need, and by that I mean, if i was to move the camera in the x, would the camera then yaw itself to look at the origin? My one idea, which i'm not sure how to achieve, would be to have the camera inside another scene node, so that maybe i can just yaw 180 the camera, and then use the camera's parent node to position it and rotate it as need it.
Any ways, I appretiate the help on this, let me know what you think.
Tim Knip-2 wrote:
Hi,
Uh: you're in a right-handed system, your camera sits at 0, 0, -10...
looking at the origin...
Then an object at 0, 0, 1 would indeed appear on the left.
* camera (0, 0, -10)
o______ +x
|
|
|+z
Can't you simply set camera.z = 10 and do a camera.lookAt(
DisplayObject3D.ZERO );
Just not sure exactly what you mean, maybe I'm missing something.
Tim
|