how to use reflectionhelper?

Started by Disastorm, July 03, 2011, 07:03:45 AM

Previous topic - Next topic

Disastorm

Hello I was just wondering how to use ReflectionHelper class (to make a mirror)?  I made a mirror myself which work kind of OK but they aren't as accurate as they should be so I wanna try out this class but Im not sure how to use it.

Do I just call the ReflectionHelper's drawScene method in my main loop, because that didn't seem to work for me.

EgonOlsen

The ReflectionHelper is only useful for planar reflections on a floor with an untilted camera. Is that, what you have in mind?

Disastorm

ah i thoughtit was just planar in general.  so what you are saying is i cant make a plane on a wall and have the player look at it like a mirror using the ReflectionHelper?

EgonOlsen

No, that's not what it's meant for.

Disastorm

oh ok, whats the best way to make a mirror.  the way i used works alright except if i make the mirror really wide the image gets distorted to be wide.  I use a camera inside the mirror that renders to the mirror texture.

EgonOlsen

Sounds reasonable to me. I don't have a better idea right now.

Disastorm

I managed to make it look not distorted by changing the FOV and the YFOV of the mirror's camera.