0
105 May 17, 2013 at 11:14

As of late I support the c++11 standards in my project. To get full c++11 support I’ve switched my MinGW environment from 32bit to 64bit. Now I use the MinGW-build environment with GCC 4.8. I could build and compile anything of my sources. But since few days I’m fighting with GLES2 emulation support.

I’ve downloaded and integrated the latest PVRFrame GLES2 x64 libraries to my MinGW64 environment. I could compile my GLES2 sources without any failure. But on runtime my application crashes if I try to crate a VBO:

(Host: (null))
Fri May 17 11:09:15 2013: OpenGL version: OpenGL ES 2.0 (Host: (null))
Fri May 17 11:09:15 2013: Graphics card : PVRVFrame 9.4 - Host (OpenGL) (Host: (null)) (SDK Build: 3.0@2224087)
Fri May 17 11:09:15 2013: Supported OpenGL ES extensions :
-GL_OES_byte_coordinates
-GL_OES_fixed_point
-GL_OES_query_matrix
-GL_OES_single_precision
-GL_OES_matrix_get
-GL_OES_point_sprite
-GL_OES_query_matrix
-GL_OES_texture_env_crossbar
-GL_OES_texture_mirrored_repeat
-GL_OES_blend_subtract
-GL_OES_blend_func_separate
-GL_OES_blend_equation_separate
-GL_OES_stencil_wrap
-GL_OES_extended_matrix_palette
-GL_OES_compressed_ETC1_RGB8_texture
-GL_OES_compressed_paletted_texture
-GL_OES_depth_texture
-GL_OES_required_internalformat
-GL_OES_texture_cube_map
-GL_OES_fragment_precision_high
-GL_OES_element_index_uint
-GL_IMG_texture_compression_pvrtc
-GL_OES_mapbuffer
-GL_EXT_multi_draw_arrays
-GL_OES_standard_drivatives

Try to generate buffer.
(Error) The following error occurred in glGenBuffers: (502) GL_INVALID_OPERATION
Buffer generated

I simple call:

GLuint vertexBuffer;
glGenBuffers (1, &vertexBuffer);


As you can see, the OpenGLES2 environment is set up correctly. I could check the GLES2 extensions and successfully initialize and create the required EGL objects (Display, Window, RenderContext). But if I call a standard OpenGL Extensions, this call fails (same also on GLSL shader object creation). My GLES2 sources are correctly, I use the same sources on Android ADT platform, without any issue.

Has someone experience with MinWG64 and GLES2 set up?
Thanks for any hint or help.

2 Replies

0
151 May 18, 2013 at 08:53

VBO’s are not supported by default in OpenglES 2.

It’s really frustrating, on some devices you HAVE to use VBO’s, on others they are not available.

Khronos really screwed up on the spec for ES2, I think they have done a better job on ES3, but I don’t have any devices that support it yet. :(

From talking to people, it seems that Khronos were scared that none of the manufacturers would support it if they put too many things in the spec, but the result is that ES2 is crippled.

I have a compiler flag USE_VBO and have two versions of my rendering code.

0
105 May 18, 2013 at 15:19

Thanks for the hint with VBO. I’ve to regard this and should use ES Arrays in that case. Your Compiler flag is a good idea.

But I think this is not the problem. Same code runs with PVRFrame on 32bit MinGW with VBO’s (a version I’ve implemented last year before I’ve start with c++11 support).

I’ve found the Angle library as ES2 emulator and will give it also a try. Also I will check out ES3, I’ve seen PVRFrame also offers libs for it…