Eyes behind my head

Started by
0 comments, last by VBSmiles 19 years, 11 months ago
dx8 vb6 ... but can understand in c++ Been struggling with this one for a while now. It is understood that I am able to place 2d on top of 3d. But how do you go about putting 3d on top of 3d as in a mirror? Or as a window within a window. I seen info in the sdk refering to stencils but it did not really say how to go about it. Help
Advertisement
Well, this may not be Alot of help, but in Opengl you can set your "ViewPort" which is th escreen rectangle that gets drawn to. Usually it is set to be the whole screen, but for amirror effect, try this:

1) Draw scene normally
2) Set the viewport to the screen coordinates that you want the "mirror" drawn to.
3) Move the camera so that it sees what the mirror sees, and draw the scene again.

This is a high-level overview of what needs to be done, and I don not know the DX semantics for Viewports, but thats the idea.



Waramp.

"Before you insult a man, walk a mile in his shoes.
That way, when you do insult him, you''ll be a mile away, and you''ll have his shoes."
Waramp.Before you insult a man, walk a mile in his shoes.That way, when you do insult him, you'll be a mile away, and you'll have his shoes.

This topic is closed to new replies.

Advertisement