Angus Dorbie (dorbie++at++bitch.reading.sgi.com)
Wed, 30 Aug 1995 09:22:26 -0600
This probably changes the light but it's already been bound. Re-binding the
light source here may affect the change but you shouldn't do this in mid-draw.
You have your viewing matrix applied + any model matrix so this should never
be done in the draw process.
>
> The apache model is a multigen model, and I would expect that the model
> would be dark as if with no light and then the rest of the terrain would
> appear with the light.
This wouldn't happen even if your callbacks worked because your light colour
is still set to time of day in pre and post callbacks (unless your model has
no diffuse or specular in it's materials).
>
> Also, is updating the apache DCS in the preDraw function a good or bad
> practice?
This is a bad idea, you should do this in the app. What would happen if your
original position was culled and the apache never got drawn even though it was
in the frustum? I've updated pfDCSs in post cull callbacks and this worked, but
I used the callback to billboard the node (modelled around origin), so the cull
was still valid.
>
> All +comments welcomed,
>
> Mario T.
>
>
>
>-- End of excerpt from Torres Mario 678-3280 AMSRL-BE-M
-- Angus Dorbie, Silicon Graphics Ltd, UK dorbie++at++reading.sgi.com
This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:51:51 PDT