Can we make mirror in Irrlicht ?

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Guest

Can we make mirror in Irrlicht ?

Post by Guest »

I beginner for this engine .
I want to make mirror in game how can i do ?
can anyone help me? thank
puh
Posts: 356
Joined: Tue Aug 26, 2003 3:53 pm

Post by puh »

Domarius
Posts: 178
Joined: Thu Mar 11, 2004 9:51 am
Location: Brisbane, QLD, Australia

Post by Domarius »

If you look carefully at games that have mirrors in them, you'll see that it's just a trick, and not a true mirror that calculates what is visible in the mirror, and reflects it to the camera, which would be very costly to rendering time.

First trick, is to just duplicate the room behind the mirror, and make the 'glass' a semitransparent square.
This is usualy all a lot of games do, and you can tell because you can't see moving objects inside the mirror, but the feeling of a mirror is there and it works quite well.

But the second step is to duplicate all the moving objects in the real room, in the 'mirrored' room, and move them in exactly the opposite way.
Now, for all intents and purposes, you have a 'true' mirror, and the only cost is the polygon count.
Post Reply