World Coordinates to Screen

Started by
1 comment, last by themush 14 years, 11 months ago
Hey there. Im trying to gather some synthetic data, basically i want the world coordinates of a scene in screen coordinates as the camera or the objects move. I want to have as realistic geometry as possible, so I was thinking of taking an existing game engine and using that to get my data. http://www.loria.fr/~berger/lepetit/images/reconstruction.gif The image in the link kind of explains what i want to do. Given a point in the world, I want to know where it maps to in the screen for successive frames. This doesnt have to be real time. I have been looking into some engines like Cyrengine and the half life 2 but not sure which would be appropriate. It would be great to get some pointers so i can check this out. hanks for your help.
Advertisement
Unless I misunderstand you, this is pretty trivial.

You have a point in world space, and you presumably know enough about the state of the simulation to compute where that point will be in world space for the next n successive frames as well (otherwise you wouldn't be able to generate those n successive frames). So compute those points, and then transform the lot of them to screen space. This is done by applying the view and projection transforms, which places you in clip space. You then perform the perspective divide (by W) which brings you to normalized device coordinate space (-1, 1 on the X and Y axis). You can then transform this to a (0,1) range or pixel/window-coordinate based ranged, as needed.
Exactly, but I dont want to build the engine myself. I want to have a scene with as realistic geometry and lighting as possible. Thats what I thought about using some existing environment, but Im just not sure how customizable they are.

This topic is closed to new replies.

Advertisement