Basic render 3D perspective projection onto 2D screen with camera (without opengl)
Let's say I have a data structure like the following: Camera { double x, y, z /** ideally the camera angle is positioned to aim at the 0,0,0 point */ double angleX, angleY, angleZ; } SomePointIn3DSpace { double x, y, z } ScreenData { /** Convert from some point 3d space to 2d space, end up with x, y */ int x_screenPositionOfPt, y_screenPositionOfPt double zFar = 100; int width=640, height=480 } ... Without screen clipping or much of anything else, how would I calculate the screen x,y position of some point given some 3d point in space. I want to project that 3d point onto the 2d screen. Camera