Even though there's an implementation for textured rects, drawBitmap() is not hooked up yet as it will require a good texture cache. This method is implemented using FBOs. There's currently an issue either in the driver or in the Canvas renderer that forces the FBO to be fullscreen, which is extremely expensive and yields terrible performance. Change-Id: I148419195e12d45653c60186938aa78c23a68e2c
21 lines
381 B
GLSL
21 lines
381 B
GLSL
SHADER_SOURCE(gDrawTextureVertexShader,
|
|
|
|
attribute vec4 position;
|
|
attribute vec2 texCoords;
|
|
attribute vec4 color;
|
|
|
|
uniform mat4 projection;
|
|
uniform mat4 modelView;
|
|
uniform mat4 transform;
|
|
|
|
varying vec4 outColor;
|
|
varying vec2 outTexCoords;
|
|
|
|
void main(void) {
|
|
outColor = color;
|
|
outTexCoords = texCoords;
|
|
gl_Position = projection * transform * modelView * position;
|
|
}
|
|
|
|
);
|