Hi

gles 2 dont support fixed pipeline lighting stuff like GL_LIGHT# and such, 
which osg uses to manage lighting. To calculate proper lighting you should 
supply shaders with light source parameters(position\direction, color etc) 
through uniforms and use those.

Cheers,
Sergey.

06.06.2012, 03:52, "Preet" <prismatic.proj...@gmail.com>:
> After playing around with a couple of things, it seems like it still
> only partially works. I can draw the cube, but I don't see any
> lighting even though I see some "DirectionalLight" stuff in the vertex
> shader, and I do see proper lighting if I run the example on my
> desktop. But I'm seeing an object on the device which is a good sign
> :)
>
> I've attached CMakeCache files for both the device and the simulator
> included with BlackBerry NDK 2.0.1 in case anyone else wants to port
> OSG to the Playbook (you'll have to adjust the paths for your own
> system). Also:
>
> Build notes:
> * get openscenegraph from git
> * edit CMakeModules/CheckAtomicOps.cmake to default to using mutexes
> without testing
> * edit line 110 of src/OpenThreads/CMakeLists.txt and replace the
> "MESSAGE(Sorry...)" line with "SUBDIRS(pthreads)" to force pthreads
> usage
>
> Compile (your application) notes:
> * I get an error in include/osg/Array (in the install dir), lines 409
> and 446, since I think GLdoubles are typedef'd to GLfloats with GL ES
> 1.1/2. Comment out those lines when building with osg.
>
> I'll update the list with an example project if I can get things
> working correctly.
>
> Regards,
>
> Preet
>
> _______________________________________________
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to