Hi Alok,

On Wed, Dec 2, 2009 at 6:29 AM, Alok Priyadarshi <[email protected]> wrote:
> I am a software engineer at Google. We are evaluating using osg with
> OpenGL ES 2.0 backend in an internal project. Thanks for adding the
> support for ES.

Welcome to the OSG :-)

> My first task is to compile and run the examples on ES 2.0 emulator
> (imagination technologies on windows). I have been able to compile all
> core libraries by tweaking cmake options:
> 1. OPENGL_egl_LIBRARY: libEGL
> 2. OPENGL_gl_LIBRARY: libGLESv2
> 3. OPENGL_glu_LIBRARY:
> 4. Check OSG_GLES2_AVAILABLE; uncheck everything else
> Is this the recommended way to customize build for ES?

A present it is, my plan is to use Cmake to automatically set the
appropriate options ON/OFF for each OpenGL/OpenGL ES target so it'll
make the process a bit more straight forward.  OpenGL ES support in
the OSG is still very much bleeding edge so you'll need to jump
through a few hoops till we settle everything down :-)

> I am getting link errors in osgViewer because it includes wgl
> functions. Has anyone tried implementing osgViewer using EGL? Is that
> the preferred long-term solution? Is there any short-term trick to
> make it work?

I've only written EGL support for GraphicsWindowX11.cpp, and don't
have any access to a Windows or OSX system so can't directly help
there.  Members of the community will have to dive in and add EGL
support to src/osgViewer/GraphicsWindowWin32.cpp to enable OpenGL ES
under Windows.

If you want to get started right away then you can just boot into
32bit Linux as the ImgTech GLES emulator drivers work pretty well - if
fact I've had feedback that the Linux drivers are actually working
better.

Another option is to just work against OpenGL and just disable the
fixed function pipeline features via the OSG_*_AVAILABLE Cmake
options.  This gives you the same GL features that you'll see with
GLES 1.1 or 2.0 (depending upon the options you choose.) When I did
the initial groundwork for the GLES port I did it all against standard
OpenGL using Cmake to give me a first pass approximation at GLES
support, and it certainly helped make the port go smoothly as I was
able to change one thing at a time and gradually shift across rather
than be faced with a massive porting effort all at once.

Cheers,
Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to