Opengl es2 render error when rendering 3D Model


I tried ofxAssimpModelLoader Example with opengl es1 without errors. When using opengl es2 as renderer the models look noisy (meaning some triangles pop out not as expected), especially the AstroBoy.
When I use my own models I have this noise problem in an even bigger scale.

Someone has any idea on how to solve this. I did not make any change just using the example as it is. Could it perhaps be a render setting I need to change?



Hi, I think it would be better if you can share an image of the problem.

Yes, of course. Here is an image that shows the problem (opengl es1 compared with opengl es2).

oh, i see this post now, 5 days later… sorry for a late reply.

the first one looks like having a diffuse light and the second one looks like having an ambient light. Are the lights same in 2 renders?

It would be helpful if you can share 2 renders with same lights.

I assume that the lights are the same, since I only changed


in, when using the es2 renderer.

I don’t know why the shading is so different, since it shouldn’t be. Do you have to use a custom shader when using opengl es2?

In 0.8.3 there’s still no lighting when using ES2 that’s why it looks so different.

not sure about the glitches but it seems something else. can you try increasing the float precission of the default shaders? In libs/openFrameworks/gl/ofGLProgrammableRenderer.cpp

search for all occurrences of precision low float; and change low to medium or high

Changing to precision from low to high solved the problem and eleminated the glitches. Thank you arturo and thank you Rancs!

can you check what happens if you use medium? i changed medium to be the default in next version but will change it to high if it still creates glitches

Medium still produces glitches. So high should be the best option.

I still use es1 :smiley: