I want to have the same shader source for OpenGL ES and OpenGL (Windows). For this, I want to define custom data types and use only the OpenGL ES features.
One approach is to determine:
#define highp
#define mediump
#define lowp
for the Windows shader and burn the shader, as for OpenGL ES.
Another approach is to define custom data types like this for OpenGL ES:
#define hvec2 highp vec2
and how is it for windows
#define hvec2 vec2
What do you think is better? Do you have other solutions to this problem?
source
share