Re: [Mirror]

New Message Reply Date view Thread view Subject view Author view

Yuichi Sasaki (t96443ys++at++sfc.keio.ac.jp)
Sat, 19 Dec 1998 12:00:53 +0900


Svend Tang-Peterson ,thank you for advicing.
I finish making Mirror in method "b"!

<Svend Tang-Petersen, MSc (svend++at++copen.sgi.com) wrote to me>
>I can think of two ways:
>
> a) let the mirror be a semi transparent polygon and keep a mirror
> reflected copy of your geometry behind that.>
>
> b) Render a seperate channel in the backbuffer using the mirrored eye
> position as the viewpoint. Then texturemap the mirror with this
>
>What you do is to register a DrawCallBack with your mirror channel.
>Then specify that the channel gets drawn in the backbuffer and do the
>subload after pfDraw().
>
>Only thing you have to remember is to define the mirror channel before
>your main channel to have the mirror drawn first in the backbuffer.
>Otherwise the mirrorchannel will still be displayed when swapping
>back to front.
>

1) Make MirrorGeometry in MultiGen.
   In MultiGen, define MirrorSurface to be BothSidesVisible.
   In Performer, get the texture(pfTexture) which is maped on MirrorSurface.

2) Set MirrorChannel to PipeWindow before MainChannel,
because pfFrame() calls MirrorChannel's pfDraw() before calling
MainChannel's pfDraw().

3) Set (pfTextre *)mirrorTexture->subload() in MirrorChannelDrawCallback.

4) Look at the back side of MirrorSurface. It's a mirror!

    YUICHI SASAKI KEIO University :student-ID 79654430
                             Faculty of Environment Information
                             E-mail address "t96443ys++at++sfc.keio.ac.jp"
                             WWW URL "http://www.sfc.keio.ac.jp/~t96443ys"


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Fri Dec 18 1998 - 19:04:07 PST

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.