Samsung S3C6410 processor supports OpenGL ES 1.1 and 2.0, but for some reason Samsung didn't include any proper OpenGL ES 1.0 implementation on our devices.
This is the project of creating a libgles_cm.dll library which compensates this.
So, here is the release of the OpenGL ES 3D v1 (and HTC) compatibility layer for Samsung Omnia II, Pro (Qwerty) and Giorgio Armani 2 (and M900 and...):
Installation:
ZIP download (current version):
(original GinKage material) Download it by clicking on this link.
The zip contains libgles_cm.dll, put this in your \Windows folder for activation across the entire device, or in the same folder as the EXE of the program you want to try this with.
CAB download (version 0.26):
(some additions by Chainfire) Attached!
This CAB will place the libgles_cm.dll file in your \Windows folder (unsigned). This means it will be used by all (capable) programs. I have also included libgles_cl.dll (an adaption from NuShrike's CL), which may add some compatibility for some games, but is untested in combination with GinKage's CM library.
Note:
Don't forget to switch your device to HIGH performance mode or plug a charge adapter otherwise you won't get any decent performance.
Compatibility:
What works:
- Xtrakt
- Experiment 13
- HTC TouchFlo3D v1.3, v2.0, HTC Sense v2.5
- Tower Defense
- Flight Commander
- 10 Games for Betting
- S2P 0.80
- Opera Mobile 9.7
- glBenchmark 1.0/1.1
- TestOpenGL
- HG Engine (Hologram App) and HG Proton [reported by daskalos]
- glBenchmark hangs after 10-13 tests, don't know why. So, if you want to benchmark, do it in 3-4 runs, few tests at a time. Also, 'Flat' shading mode doesn't work, everything renders as 'Smooth'.
- Xtrakt has some minor texturing issues (as you may see on fonts) due to the unsupported 1024x1024 texture resolution. Although it's perfectly playable.
- Some alpha-blensing issues with Spb Mobile Shell 3.5.2 and earlier, NFS: Undercover, 10 Games for Betting and Call of Duty 2.
- Spb Mobile Shell 3.5.2 and earlier. Although you may switch acceleration on by registry at [HKLM\Software\Spb Software House 2\Spb Mobile Shell\Gl\], setting GlEnabed to 1, but it is really unusable: you can't tap on a panel or a message to select it, you can only swipe to rotate carousel. I don't really care, because Spb already added GL2 support in the later releases.
- NFS: Undercover. Almost worked for some time, but used to hang or crash randomly, and now it won't start at all. Again, I don't really care, as there is NFS in Samsung's AppStore.
- Tons of GL apps.

What I DO want to know about, is if anything else apart from
the list above work. That would really be a surprise!
Source code
The project is open-sourced. There are three main reasons for this:
- I want the project to evolve, even when I don't have enough time for it.
- I want to see more GL2 applications for Omnia 2 created by third-party developers (waiting for a Samsung's GL2 SDK is some pain).
- I want Samsung to finally fix their own GL2 driver (and I hope that maybe this lib's sources will help).
Project source is available at SourceForge here: http://sourceforge.n...jects/omnia2gl/
To build the source code you'll need Visual Studio 2008, Windows Mobile 6 SDK and GL2_SDK.zip from the Files section of the SourceForge project.
At the moment, only me (GinKage) and Chainfire are the project admins, so if you have something to commit you'll need to contact us.
You may also find Screentex source there. Simple app it is, but it may be compiled in both GL1 and GL2 modes (some time earlier, it was also D3DM-compliant, not sure about it now).
I kindly ask you not to criticize the code too much, as I haven't even tried to make it look like industrial-standard.
It was created as a hobby, a brain siesta. If you want to prettify it, do it (and send us a patch, so it would find its way to SVN).
Also, if you use some parts of the code, please do mention us (GinKage, Chainfire, NuShrike) in credits. That's all I ask in return.
Bonus (for Samsung representatives if any):
A short list of some stupid bugs found in Samsung's driver during my work on this project:
- eglGetDisplay(0) fails. It should work with a zero argument, by standard, but it fails.
- Calling glGetString() before eglInitialize(), crashes.
- eglGetConfigs with config_size = 4096 crashes.
- glBindBuffer generates GL_OUT_OF_MEMORY if buffer number is above 100 (it is an actual limit hard-wired into libGLESv2, I had to re-implement the whole buffer management by myself). And, Xtrakt needs 102 buffers...
- glGetIntegerv(GL_MAX_TEXTURE_UNITS) returns 0 instead of 2. This one totally breaks NFS.
- glGetIntegerv(GL_MAX_TEXTURE_SIZE) returns 2048. In reality, every texture larger than 512x512 is going to be ignored at all, with some allocaton errors in debugger output. It may be used with S3TC, but it's DXT1 only, not even DXT5. And, somehow, with a GL_RGBA_S3TC_OES format, an alpha bit is ignored at all.
- And don't forget to create mipmaps, or GL_*_MIPMAP_* won't draw anything at all (it should just use the only level available)!
- glAlphaFuncEXP is not iplemented in libGLESv2 (though the hardware DOES have this available), had to do a hack for this to work.
- glViewport works wrong after all. If the parameters, e.g. X and Width have a larger sum than the width of the window surface, then the resulting width is clamped, which results in scaled down rendering.
- eglCreateWindowSurface is a fail: it doesn't track window size change at all, so if you create a surface and change window size, your output will be of an inadequate size (e.g., in Opera 9.7 going from Widowed mode to Fullscreen, or in anything else when going from Landscape to Portrait mode).
- eglSwapBuffers is slow as hell (probably because of plain BitBlt it uses), it takes about 10 ms, which limits fps to about 100 and reduces the speed of everything else (e.g., you'll get 16 fps where you could have 20, only because of this functon).
- All textures have an offset by half-texel. This is probably done for mapping to the nearest texel (like, round(u + 0.5)), but it breaks everything that is drawn, for example, with glOrtho (like Opera 9.7). Well, not exactly breaks, but akes everything look "smoothed out".
Release history:
Version 0.2, pre-alpha (Sep 24, 2009)
- Initial release (proof-of-concept)
One of the nicest updates. Faster, smaller, better. That is:
- It does QTC texture decompression more quickly, so Xtrakt loads a tad faster, and lags in TF3D were reduced (though haven't gone completely).
- It has a smaller footprint, so Acer M900 users should be able to run Xtrakt now.
- It allows to run an original unmodified TouchFLO 3D 1.3 (fixes yet another Samsung's bug, this time in glViewport). Maybe it can do even more, but that was not tested. smile.gif
- CFC 0.60 fully supported.
Version 0.256 (Nov 14, 2009)
A minor yet highly recommended update!
- Introduced a minus half-texel offset for every texture coordinate that libgles renders (yet another Samsung's bug).
- The difference, now, is huge. First thing you'll probably notice, is a perfect (pixel-wise) Opera 9.7 rendering.
- Second, some of the irritating lines in Xtrakt are gone as well.
- Third, Tower Defense gets a tiny bit more clear and sharp look.
Following games are now supported:
- Flight Commander
- Experiment 13
Yet another minor update:
- adds PVRTC support (not sure if it gives anything useful, but let it be: maybe some game for Dell Axim will finally work, maybe not);
- fixes minor ambient lighting issue (as seen in TestOpenGL's donut test;
- removes matrix palette from extensions list (so that glBenchmark 1.1 wouldn't hang);
- and fixes a crash on MindPol's Coin game from their 10 Games for Betting.
Congratulations to MindPol on getting Bronze medal in App Contest with this one!
Version 0.26 (Feb 23, 2010)
Back to the two-digit version numbers! ![]()
- S2P 0.80 crash fixed;
- HTC Sense 2.5 texturing and crashes fixed.
Attached Files
Edited by tacchan23, 28 February 2010 - 09:36 AM.







Sign In
Create Account



Back to top










