Volumes Of Fun http://www.volumesoffun.com/phpBB3/ |
|
Light issue http://www.volumesoffun.com/phpBB3/viewtopic.php?f=14&t=399 |
Page 1 of 1 |
Author: | Abyssos [ Sun Jun 03, 2012 10:11 am ] | |||
Post subject: | Light issue | |||
Hello again. I have tried to solve a problem with lighting on the Ogre manual object built from ker's example "GLSL + Ogre for triplanar texturing and multiple textures" in the wiki. My issue if I use the shader program to smoothly merge textures, the terrain is not affected by light (you can see the tree is affected by light). If I remove disable the shader programs, the light seems to work fine on the terrain/manual object. Here are some images.
|
Author: | David Williams [ Mon Jun 04, 2012 9:51 am ] |
Post subject: | Re: Light issue |
Abyssos wrote: My issue if I use the shader program to smoothly merge textures, the terrain is not affected by light (you can see the tree is affected by light). If I remove disable the shader programs, the light seems to work fine on the terrain/manual object. I believe this is expected - ker's shader code is only meant to demonstrate how texturing can be performed, and it does not include any lighting code. You need to implement the lighting yourself in the shader. When shaders are turned off Ogre is simply making use of the fixed-function lighting but you cannot combine this with shaders (this is a hardware limitation I think). |
Page 1 of 1 | All times are UTC |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |