Hi everybody,
Every now and again I update the current MAME build (which uses SDL) for AOS4. The major slowdown is by far the graphics.
Obviously there is a lot of overhead using the SDL library... hence I'm wondering what are the plans for OpenGL support in SDL? Is support planned for OS 4.2?
I realise that the maintainers of the SDL have a few (thousand!) other things to worry about, but OpenGL support in SDL could be useful for all sorts of other programs, and would speed things up massively because 2D scaled graphics are such a bottleneck at the moment. With OpenGL we'd have properly scaled graphics at practically no cost to the processor, and even the lowliest Sam440 would be able to do full screen renders quickly on SDL programs like MAME.
Anybody have any input?
Thanks!
SDL and OpenGL
Re: SDL and OpenGL
We are working on Gallium3D for AmigaOS. This enables access to many hardware drivers and will provide you with the speed you need.
On top of Gallium3D is a port of Mesa which is an OpenGL implementation. Remember, OpenGL is only a specification and doesn't actually do anything.
As previously reported, the software rendering has been working for some time via Mesa. The focus now is on the Gallium3D hardware drivers.
Once we ship both Gallium3D and Mesa then the SDL maintainers can then utilize our Mesa port which will then give you access to the hardware acceleration via Gallium3D.
Sorry but we cannot provide a timeline for anything. All I can say is that work is continuing.
On top of Gallium3D is a port of Mesa which is an OpenGL implementation. Remember, OpenGL is only a specification and doesn't actually do anything.

As previously reported, the software rendering has been working for some time via Mesa. The focus now is on the Gallium3D hardware drivers.
Once we ship both Gallium3D and Mesa then the SDL maintainers can then utilize our Mesa port which will then give you access to the hardware acceleration via Gallium3D.
Sorry but we cannot provide a timeline for anything. All I can say is that work is continuing.
ExecSG Team Lead
Re: SDL and OpenGL
Hi Steven,
Don't worry - I'm a developer so I know about timelines (and lack thereof
). I just really want to know that it's going to be likely in the nearish future, as I don't want to write an OS4 graphics layer if within a few months I could just uncomment the line that says "disable OpenGL" in the makefile. 
Don't worry - I'm a developer so I know about timelines (and lack thereof


Re: SDL and OpenGL
I actually managed to compile MAME with SDL support including OpenGL today.
It doesn't work.
Now, that's not terribly surprising, given we're using just minigl at the moment.
The symptom is this: all font rendering comes out as a white square. When the game starts up, the entire screen turns white. Strikes me that it may be trying to render a texture but the data is in the wrong memory (system memory instead of video memory?)
Is there anything I need to know that may be causing this? I presume usage of MiniGL is almost deprecated because we'll be getting a proper OpenGL implementation soon, but nonetheless I did see an encouraging speed-up, so if I can get it to work I will do!
Can anybody give any advice?
Thanks!
Edit: For reference, this is on my Sam440ep, with its onboard graphics. I checked GLExcess and the cube demos on os4depot and both work fine.
It doesn't work.
Now, that's not terribly surprising, given we're using just minigl at the moment.
The symptom is this: all font rendering comes out as a white square. When the game starts up, the entire screen turns white. Strikes me that it may be trying to render a texture but the data is in the wrong memory (system memory instead of video memory?)
Is there anything I need to know that may be causing this? I presume usage of MiniGL is almost deprecated because we'll be getting a proper OpenGL implementation soon, but nonetheless I did see an encouraging speed-up, so if I can get it to work I will do!
Can anybody give any advice?
Thanks!
Edit: For reference, this is on my Sam440ep, with its onboard graphics. I checked GLExcess and the cube demos on os4depot and both work fine.
Re: SDL and OpenGL
Sorry to reply to my own post, but it may be of use. Turns out the GL_BGRA is supported by GL_UNSIGNED_INT_8_8_8_8_REV isn't supported by MiniGL. I have to manually bit shift the texture before uploading and use GL_UNSIGNED_BYTE.