I have made a program to take a set 3D coordinates and project them onto a 2D space. In order to do this, the program needs to know the position of the camera relative to the world space, the position of the viewer relative to the camera space, and the orientation of the camera space in the world space expressed as extrinsic Tait-Bryan angles.

I plan on using this program to facilitate a variety of 3D graphing tools.

Sample output:

The program uses a transformation matrix to first transform a point in the world space into the camera space, and then uses some other formulae to transform the points from camera space into a 2-dimensional projection.

In order to simplify the user settings, the camera orientation angles are calculated from a point that the camera is looking to in the world space. By subtracting this point from C, the program obtains a vector parallel to the camera z-axis. Because the camera orientation is represented by extrinsic rotations, the camera can be properly oriented with only two calculations if the camera x-axis is assumed to be parallel to the world space xy-plane.

More information to come later when I find my notes Smile
Looks nice! What language is this programmed in?
As a side note, this is technically a 3D to 2D projection Wink
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum