Hi!
I wonder if there is a possibility to calculate the 3d coordinates of 2d point on my screen. I know that there is a infinite number of solutions when transforming a 2d point to 3d-space, so i’d like to do it on a plane with y=0.
Any suggestions?
Calculate 3D Coordinates of 2D PointSoftware: Away3D 4.x |
||
|
RIPI, Jr. Member
Posted: 13 June 2012 01:34 PM Total Posts: 33 Hi! I wonder if there is a possibility to calculate the 3d coordinates of 2d point on my screen. I know that there is a infinite number of solutions when transforming a 2d point to 3d-space, so i’d like to do it on a plane with y=0. Any suggestions? |
||
|
|
||
|
RIPI, Jr. Member
Posted: 13 June 2012 02:11 PM Total Posts: 33 [ # 2 ] Could you be a little more specific? I found these two methods but aren’t really sure how to use them. Example: I have a camera, a Plane and a Sphere. The plane is used as a floor, where i want to position the sphere on it. But: i want the sphere to be on the left side of the 2d-screen (x=0) depending on a varying z-position in the scene. I thought about transforming the 3d z-position to a 2d y-position and then transforming this 2d Point (0,y) into 3d space with (x,0,z). also i’d like to find the “right edge” of my screen, with x=1920 (2d space) what must be the x position of my sphere in 3d-space with a given z and y=0? Thank you in advance, i hope my description is not too much confusing you
|
||
|
|
||
|
RIPI, Jr. Member
Posted: 13 June 2012 03:09 PM Total Posts: 33 [ # 4 ] Ok, i’ll try – it’s not my mothertounge either.. I’ve attached an image to describe the problem better. i am looking into a 3d-scene. On my Screen i imagine a Point P, this Point is in 2d-space. Now, in the 3D-space, i would like to position a Object at the exact Position of Point P, but in 3D-Space. I already know the z Value (it’s z1 like in the image) and i know the y-value (its 0, because it is on a flat plane). what i need is the x-value. So to say it short: i want to transform a 2d-x-value into the 3d-space. Do you have any further ideas or explanations how to achieve this with project/unproject? Or anything else? like the FOV of the camera? Thank you!
|
||
|
|