Hi!
i've asked this before:
how do i draw a 3d dot on a 2d screen?
i know camera position and angles and i know the dots position.
how do i calc where this dot should be plotted?
Printable View
Hi!
i've asked this before:
how do i draw a 3d dot on a 2d screen?
i know camera position and angles and i know the dots position.
how do i calc where this dot should be plotted?
I asked for this in other 3D-expert-places and the simplest way to do this is to use these equations:Quote:
how do i draw a 3d dot on a 2d screen?
i know camera position and angles and i know the dots position.
how do i calc where this dot should be plotted?
Where D, choosen by you, is the distance between the center of the projection and the viewer.Code:Xscreen = (X3d * D) / (Z3d + D) + Xcenter
Yscreen = (Y3d * D) /( Z3d + D) + Ycenter
Xcenter and YCenter is the center of the screen, where Xcenter is 160 and Ycenter is 100 if you are 320*200 resolution, etc.
Bye
P.S.: I don't work with 3D, I just had this infos :)
thanks, but i've allready tried this. the problem here is that i dont have the camera angles in the equations...
Check this out:
http://members.lycos.co.uk/Reaper_66...ar/mike-1.html
thanks! i think that'll help me alot!
yeah! i've got all i need :D
thanks alot DiGiTaIErRoR :)