Horde3D http://horde3d.org/forums/ |
|
Ambient Lighting http://horde3d.org/forums/viewtopic.php?f=2&t=89 |
Page 1 of 1 |
Author: | SpOOky [ 14.05.2007, 15:53 ] |
Post subject: | Ambient Lighting |
I`m heaving real trouble converting the spotlight provided in the chicago demo app into an ambient light. light.material.xml and lighting.shader.xml gave no answer. same story with the api. am i missing something? i am clueless onto what happens in deferredutils_frag.txt and lightingutils_frag.txt but i am sure the latter pixel shader holds the answer. the removal of realtime computed shadows holds great promise to me, as it will cause a great performance boost. (same story on any rendering engine ) can you help me with this? paul |
Author: | marciano [ 14.05.2007, 22:30 ] |
Post subject: | |
I really need to write a comprehensive usage guide which shows how to solve some standard issues. Most things are possible with Horde but they are not always directly obvious for beginners. Currently I'm still busy with adding features so I hardly have the time for that Anyways, back to the subject. There are several ways to do ambient lighting. The Chicago pipeline.xml defines an ambient pass which uses the shader context "AMBIENT". Currently these contexts just set the color to black. You could use a brighter value or the texture modulated with some factor and get your ambient lighting. Another way would be to define a lightsource which affects the whole scene and to apply a special shader to it. But I think the first way is easier to do. |
Author: | SpOOky [ 15.05.2007, 12:07 ] |
Post subject: | |
at the moment with my level of knowledge the modifying the shader context seems to be the easiest way, but how to change the parameters in other to achieve ambient lighting? paul |
Author: | marciano [ 16.05.2007, 12:14 ] |
Post subject: | |
You could just copy the LIGHTING context from the skybox shader and rename it to AMBIENT. I think that should work. Then you can multiply a factor smaller than one with the albedo (texture) color to reduce the intensity of the ambient lighting. |
Author: | SpOOky [ 16.05.2007, 12:47 ] |
Post subject: | |
thanks for pointing me to the skybox shader. i`ve actually used this one in the stones material. now i`ve got my ambient lighting i am now getting up to 70 fps with the folowing setings TrilinearFiltering 1 TexCompression 1 AnisotropyFactor 4 Resolution 960*600 and got 90+ with all on low. The important thing is that i can boost the geometry now i have all i needed to get me on my way, now i`m going to start a wip devblog in showcase regarding the evolution of my first Horde3D app paul |
Page 1 of 1 | All times are UTC + 1 hour |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |