Hi
I am a beginner inOpenGL ES 2.0,and get a problem,
After decompress Mali_OpenGL_ES_2.0_SDK_for_Linux_On_ARM_v1.2.0.9310_Linux.tar.gz
and install Sourcery CodeBench Lite Edition for ARM (arm-2013.05-24-arm-none-linux-gnueabi.bin),
build the sample (Cube)
bash build-x86-linux.sh Cube succeed
cd build/x86/Cube
ls
assets Cube
./Cube
Error: eglGetError() = 12291 (0x00003003) at /home/pass2014/Software/Mali_OpenGL_ES_2.0_SDK_for_Linux_On_ARM_v1.2.0/samples/linux/Cube/Cube.cpp:177
code
int main(void)
{
/* Intialize the Platform object for platform specific functions. */
Platform* platform = Platform::getInstance();
/* Initialize windowing system. */
platform->createWindow(WINDOW_W, WINDOW_H);
/* Initialize EGL. */
EGLRuntime::initializeEGL(EGLRuntime::OPENGLES2);
EGL_CHECK(eglMakeCurrent(EGLRuntime::display, EGLRuntime::surface, EGLRuntime::surface, EGLRuntime::context)); //line 177
/* Initialize OpenGL ES graphics subsystem. */
setupGraphics(WINDOW_W, WINDOW_H);
/* Timer variable to calculate FPS. */
Timer fpsTimer;
fpsTimer.reset();
bool end = false;
/* The rendering loop to draw the scene. */
while(!end)
/* If something has happened to the window, end the sample. */
if(platform->checkWindow() != Platform::WINDOW_IDLE)
end = true;
}
/* Calculate FPS. */
float fFPS = fpsTimer.getFPS();
if(fpsTimer.isTimePassed(1.0f))
LOGI("FPS:\t%.1f\n", fFPS);
/* Render a single frame */
renderFrame();
/*
* Push the EGL surface color buffer to the native window.
* Causes the rendered graphics to be displayed on screen.
*/
eglSwapBuffers(EGLRuntime::display, EGLRuntime::surface);
/* Shut down OpenGL ES. */
/* Shut down Text. */
delete text;
/* Shut down EGL. */
EGLRuntime::terminateEGL();
/* Shut down windowing system. */
platform->destroyWindow();
/* Shut down the Platform object. */
delete platform;
return 0;
What should I do to fix the problem?
Thanks
Hi Chris ,
I have updated the SDK to v2.4.4 , and got the same result when i ran the sample.
Could you please tell me the different usage between the mali kernel and userspace drivers in detail?
The mali and ump kernel driver include in the BSP supplied by the Allwiner.but i have no idea about the userspace drivers,seems it could be fetched from the link below:
http://linux-sunxi.org/Mali_binary_driver
Hi jackfeng,
Generally speaking, it is highly advised to use a matching driver version for both the User side and Kernel side Mali driver. This ensures maximum compatibility.
Ideally also you should obtain both components from the same source, the OEM or Silicon manufacturer, as they may have modified either/both parts to include further optimisations or features that the vanilla driver that we provide may not have.
It is also worth mentioning that the kernel side is GPL and you should be entitled access to this. We provide the vanilla code on our website: Open Source Mali Midgard GPU Kernel Drivers - Mali Developer Center and Open Source Mali Utgard GPU Linux Kernel Drivers - Mali Developer Center depending on your Mali architecture. You should also be allowed access to the integrated/modified version from your OEM/Silicon Manufacturer.
However the user side driver is proprietary so you will need to get a binary version from 'somewhere'. As I mentioned above, for best results, you should get this from the OEM. We do provide a vanilla version on our website but it is device dependent and we do not have any Allwinner versions up. (For reference, ARM Mali Midgard GPU User Space Drivers - Mali Developer Center and ARM Mali Utgard GPU series User Space Drivers )
I hope that helps explain the situation a little better.
Kind Regards,
Michael McGeagh
Hi mcgeagh,
It is appreciated for your detailed explanation. I am going to apply for the drivers from my distributor of the board .
Thanks,