Dear all,
I want to compare the performance of online shader compiler and offline shader compiler.
I compiled shader source with mali offline shader compiler and the output are two files named *.out.non-prerotate and *.out.prerotate.
However I have difficulties in how to use these two binary file in my opengl es program. I searched examples in mali SDK but there's no example case found.
Is there anyone who has successfully use binary shader in opengl es program? Is there any other references?
You're calling "free(fileContent);" before uploading to glShaderBinary so you've at least got a use-after-free bug there. Move the free after the GL call to avoid that one.
I suspect one issue is that the driver version on your platform may be different to the version you are compiling for (the shader binary format has changed over time); the offline compiler lets you specify the DDK version in addition to the hardware version - can you check that?
Cheers, Pete