I thought
varying mediump vec4 position;
would give me the position of the sprite, but apparently not.
It give me warning, error, and, stopped dmengine instead.
WARNING:GRAPHICS: The fragment shader uses varying position, but previous shader does not write to it.
Out of resource error.
ERROR:GRAPHICS: gl error 1281: invalid value
Assertion failed: 0, file ..\src\opengl\graphics_opengl.cpp, line 1091
Do I need to pass the position via constant?