From: Florian Berger (florian.berger++at++aec.at)
Date: 04/15/2003 04:25:28
>
> ...And the most important questions, anyone has tried to merge
> some Performer code with OpenGL calls in order to implement per pixel
> lighting?
>
well, one way is to use pre and post callbacks of pfGeoState to set certain
opengl features (load/unload fragment programs, set/unset parameters, etc.)
the definitions are a bit misleading - its not pre/post-GeoState funtions but
rather something like pre/post-draw funtions.
the post-funtion of the actual GeoState is called just before the the next
GeoState is processed.
so you make your opengl calls in the pre-function and tidy up in the
post-func.
another less flexible way is to generally use preDraw and postDraw callbacks
of the pfChannel.
or you can even make your own draw-traversal with
"pfChannel::setTravFunc(PFTRAV_DRAW, drawFunc)" and manage everything "by
hand".
hope this helps,
floh
------------------------------------------------------------
Dipl.-Ing. Florian Berger
Email: florian.berger++at++aec.at
Homepage: http://www.geocities.com/harpin_floh
This archive was generated by hypermail 2b29 : Tue Apr 15 2003 - 04:27:17 PDT