Opengl To Opengl Es Porting


Blue Ion

Member
Joined
Sep 19, 2008
Messages
177
Location
Madrid, Spain
Well, I want to port some games to the pandora that uses OpenGL. Since my experience with OpenGL is 0 and my code handling is limited at best, a proper Opengl translation is definitely off my limits.
So instead, I'd like to just wrap everything in the meantime while I learn some OpenGL.

What is the status on the OpenGL to OpenGL ES wrappers that so much got talked about some time ago?
Pickle uses NanoGL to do the job on the various Quakes, and Adventus has an other wrapper here, though he says it isn't ready for prime time yet, or so he said.
As for NanoGL, I haven't found the sources for it, and I'd like to ask them if they are free for use so I could try them and see if they are any good outside the quake games, (though after seeing the limited success for RTCW I have my doubts).

No hurries though, my Pandora broke down and I'm waiting to send it so the OPT team can have some really well tested units and avoid more of these problem nastiness.

I took a look to Neverball, since I like the game and could control well with the nubs or even the touchscreen.
So far, the biggest offender on the game is the use of display lists on much of its drawing, and the usual quads and probably matrix operations. If the wrappers are of no use, I'm going to try to target OpenGL ES 1.1 so it could be ported to other devices like the wiz, and avoid, for now, replicating a lot of the remaining fixed pipeline code in shaders.

OpenGL ES 1.1 can be considered a subset of OpenGL 2, right? I mean, perhaps with the exception of the fixed point numbers, everything in OGLES1 is in OGL2. I planned to get rid of such offenders first on normal OpenGL (ie: make everything use vertex arrays) before I tackled the pandora as it will be easier to work and debug.
 
Blue Ion said:
Well, I want to port some games to the pandora that uses OpenGL. Since my experience with OpenGL is 0 and my code handling is limited at best, a proper Opengl translation is definitely off my limits.
So instead, I'd like to just wrap everything in the meantime while I learn some OpenGL.

What is the status on the OpenGL to OpenGL ES wrappers that so much got talked about some time ago?
Pickle uses NanoGL to do the job on the various Quakes, and Adventus has an other wrapper here, though he says it isn't ready for prime time yet, or so he said.
As for NanoGL, I haven't found the sources for it, and I'd like to ask them if they are free for use so I could try them and see if they are any good outside the quake games, (though after seeing the limited success for RTCW I have my doubts).

No hurries though, my Pandora broke down and I'm waiting to send it so the OPT team can have some really well tested units and avoid more of these problem nastiness.

I took a look to Neverball, since I like the game and could control well with the nubs or even the touchscreen.
So far, the biggest offender on the game is the use of display lists on much of its drawing, and the usual quads and probably matrix operations. If the wrappers are of no use, I'm going to try to target OpenGL ES 1.1 so it could be ported to other devices like the wiz, and avoid, for now, replicating a lot of the remaining fixed pipeline code in shaders.

OpenGL ES 1.1 can be considered a subset of OpenGL 2, right? I mean, perhaps with the exception of the fixed point numbers, everything in OGLES1 is in OGL2. I planned to get rid of such offenders first on normal OpenGL (ie: make everything use vertex arrays) before I tackled the pandora as it will be easier to work and debug.

some things cant be wrapped or no one has wrapped them.
i came across a forum post a little while back about neverball and one problem was the server state i.e glPushAttrib. I havent found a way to handle this yet.
The nanogl author has gotten RTCW to run with nanogl, ive had limited success though.

From what i think i understand 1.X and 2.X are different, 1.X is a fixed API where 2.X is shader based.
I suggest you do something like i did pick something simple and go from there (i picked ken's labyrinth, then prboom)
 
Last edited by a moderator:
Converting OpenGL code to OpenGLES isn't too bad. Thanks to the iPhone's popularity you should be able to find some tutorials to help you out. Converting directly to OpenGLES gave me quite a speed boost when porting a game that used immediate mode OpenGL, versus using the NanoGL wrapper. You will get even bigger boosts if you refactor the code in clever ways to take advantage of the added efficiency of vertex/color arrays.

I don't know much about OpenGL 2.0 and haven't tried Adventus' wrapper. NanoGL is the other wrapper you are referring to and it is for older games using immediate mode. It is not very efficient and doesn't even support a lot of older OpenGL stuff and you can forget about any of the newer stuff. I wouldn't bother using it. Adventus's wrapper, if it only supports OpenGLES 2.0, would not work on the Wiz since it only supports OpenGLES 1.1
 
Anyone tried the to openGL 2.0 ES wrapper yet for stuff made in GLBasics 3D engine yet?
I guess it depends which OpenGL commands GLBasic creates from its code,
so the question is which 3D commands of OpenGL 2.0
can be realised with OpenGL ES´s command set.
I hope they are all somehow realisable with more or less OpenGL ES 2.0 commands...
 
Thanks for the answers.

No doubt a proper, even if hacky, port will probably get better perfomance than using a wrapper, but I wanted to get something running quickly and then start porting slowly from there.
That is why I also asked about the included feature set of OpenGL 2 and 1 ES. OpenGL 1 fixed pipeline is included in OpenGL 2 (and even in OpenGL 3) but I don't know how much of OpenGL ES 1 is included in standard OpenGL.
This way I can start removing unsupported stuff from the game and substitute them with supported parts and get instant feedback and a more comfortable environment that is the pc without emulators, once there, all I'll have to do is change how I startup the game, a couple of headers and that's it.

As for the wiz, it was a freebie if I had more time, or for someone else to port. I have none and debugging without the actual hardware is bound to be a pain in the ass.

Once I have my pandora back, I'll give Adventus' wrapper a shot, though I would like to hear from him what is the status. I wouldn't want to try it out, and spend hours debugging the application, when in reality the wrapper isn't still ready for anything other than a couple of triangles.

Out of curiosity, Who is the NanoGL author?
 
Back
Top