Projecting 3D points to 2D plane

Lighthink

Let A be a point for which I have the 3D coordinates x, y, z and I want to transform them into 2D coordinates: x, y. The projection shall be orthogonal on a plane defined by a given normal. The trivial case, where the normal is actually one of the axes, it's easy to solve, simply eliminating a coordinate, but how about the other cases, which are more likely to happen?

John Alexiou

If you have your target point P with coordinates r_P = (x,y,z) and a plane with normal n=(nx,ny,nz) you need to define an origin on the plane, as well as two orthogonal directions for x and y. For example if your origin is at r_O = (ox, oy, oz) and your two coordinate axis in the plane are defined by e_1 = (ex_1,ey_1,ez_1), e_2 = (ex_2,ey_2,ez_2) then orthogonality has that Dot(n,e_1)=0, Dot(n,e_2)=0, Dot(e_1,e_2)=0 (vector dot product). Note that all the direction vectors should be normalized (magnitude should be one).

Your target point P must obey the equation:

r_P = r_O + t_1*e_1 + t_2*e_2 + s*n

where t_1 and t_2 are your 2D coordinates along e_1 and e_2 and s the normal separation (distance) between the plane and the point.

There scalars are found by projections:

s = Dot(n, r_P-r_O)
t_1 = Dot(e_1, r_P-r_O)    
t_2 = Dot(e_2, r_P-r_O)

Example with a plane origin r_O = (-1,3,1) and normal:

n = r_O/|r_O| = (-1/√11, 3/√11, 1/√11)

You have to pick orthogonal directions for the 2D coordinates, for example:

e_1 = (1/√2, 0 ,1/√2)
e_2 = (-3/√22, -2/√22, 3/√22)

such that Dot(n,e_1) = 0 and Dot(n,e_2) = 0 and Dot(e_1, e_2) = 0.

The 2D coordinates of a point P r_P=(1,7,-3) are:

t_1 = Dot(e_1, r_P-r_O) = ( 1/√2,0,1/√2)·( (1,7,-3)-(-1,3,1) ) =  -√2
t_2 = Dot(e_2, r_P-r_O) = (-3/√22, -2/√22, 3/√22)·( (1,7,-3)-(-1,3,1) ) = -26/√22

and the out of plane separation:

s = Dot(n, r_P-r_O) = 6/√11

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Projecting 3D Model onto 2d plane

From Dev

fitting a plane into a cloud of points (3d)

From Dev

projecting points onto a plane given by a normal and a point

From Dev

orientate a 3d plane from 3 given points

From Dev

Matplotlib - Plot a plane and points in 3D simultaneously

From Dev

How to estimate local tangent plane for 3d points?

From Dev

Find shortest path through points in 2D plane

From Dev

Check connection between two points on 2D plane

From Dev

Scale 3D-Points in Plane

From Dev

project 3D plot to 2D screen plane

From Dev

2D overlay on top of 3D plane with texture

From Dev

Rotate 3D vectors on 2D plane

From Dev

Given n points on a 2D plane, find the maximum number of points that lie on the same straight line

From Dev

Given n points on a 2D plane, find the maximum number of points that lie on the same straight line

From Dev

Projecting a 2D point into 3D space using camera calibration parameters in OpenCV

From Dev

Projecting a 2D point into 3D space using camera calibration parameters in OpenCV

From Dev

Homography from 3D plane to plane parallel to image plane

From Dev

How to extract a plane from a 3D variable in FiPy (3D to 2D)

From Dev

How to extract a plane from a 3D variable in FiPy (3D to 2D)

From Dev

Fit plane to a set of points in 3D: scipy.optimize.minimize vs scipy.linalg.lstsq

From Dev

How to calculate the distance from all points in a 3d matrix to a plane in matlab?

From Dev

Best way to get the bounding rectangle of a set of 3D points on a plane in Matlab

From Dev

Test if points lie on a 2D fitted plane in 4D

From Dev

Finding the point in 2d plane such that maximum distance from a set of points is minimum

From Dev

Troubles in 3D points correpondance to 2D

From Dev

Troubles in 3D points correpondance to 2D

From Dev

How to find the plane of intersection betweeen a plane and a 3d matrix

From Dev

Plane fitting in a 3d point cloud

From Dev

3D Plane fitting algorithms

Related Related

  1. 1

    Projecting 3D Model onto 2d plane

  2. 2

    fitting a plane into a cloud of points (3d)

  3. 3

    projecting points onto a plane given by a normal and a point

  4. 4

    orientate a 3d plane from 3 given points

  5. 5

    Matplotlib - Plot a plane and points in 3D simultaneously

  6. 6

    How to estimate local tangent plane for 3d points?

  7. 7

    Find shortest path through points in 2D plane

  8. 8

    Check connection between two points on 2D plane

  9. 9

    Scale 3D-Points in Plane

  10. 10

    project 3D plot to 2D screen plane

  11. 11

    2D overlay on top of 3D plane with texture

  12. 12

    Rotate 3D vectors on 2D plane

  13. 13

    Given n points on a 2D plane, find the maximum number of points that lie on the same straight line

  14. 14

    Given n points on a 2D plane, find the maximum number of points that lie on the same straight line

  15. 15

    Projecting a 2D point into 3D space using camera calibration parameters in OpenCV

  16. 16

    Projecting a 2D point into 3D space using camera calibration parameters in OpenCV

  17. 17

    Homography from 3D plane to plane parallel to image plane

  18. 18

    How to extract a plane from a 3D variable in FiPy (3D to 2D)

  19. 19

    How to extract a plane from a 3D variable in FiPy (3D to 2D)

  20. 20

    Fit plane to a set of points in 3D: scipy.optimize.minimize vs scipy.linalg.lstsq

  21. 21

    How to calculate the distance from all points in a 3d matrix to a plane in matlab?

  22. 22

    Best way to get the bounding rectangle of a set of 3D points on a plane in Matlab

  23. 23

    Test if points lie on a 2D fitted plane in 4D

  24. 24

    Finding the point in 2d plane such that maximum distance from a set of points is minimum

  25. 25

    Troubles in 3D points correpondance to 2D

  26. 26

    Troubles in 3D points correpondance to 2D

  27. 27

    How to find the plane of intersection betweeen a plane and a 3d matrix

  28. 28

    Plane fitting in a 3d point cloud

  29. 29

    3D Plane fitting algorithms

HotTag

Archive