Bonzai Engine Forum

Bonzai Engine & Tools => Bonzai Engine => Topic started by: refuzee on October 19, 2013, 05:46:52 PM

Title: Lighting relative to model
Post by: refuzee on October 19, 2013, 05:46:52 PM
Hi,

in your tutorial you state how to set light positions and bind them relative to the model or relative to the camera.

http://bonzaiengine.com/tutorials.php?admin=../tutorials.php&id=1





Now we have our own pipeline and use bonzai just for the model loading and details for now. Is it possible to somehow bind the lights in our pipeline to be relative to the model and not to the camera ?
here is our code:

          
maybe someone sees an easy solution ?
Title: Re: Lighting relative to model
Post by: jerome_j on October 19, 2013, 06:31:02 PM
Yes, bind your lights after the camera lookThough (which I assume set the opengl modelview matrix ?)