Basic Render-Target Example
// The 4x4 world view projection matrix. uniform mat4 worldViewProjection; attribute vec4 position; attribute vec2 texCoord0; varying vec2 texcoord; /** * Vertex Shader performing basic viewing transformation. */ void main() { /** * We transform each vertex by the view projection matrix to bring * it from world space to projection space. * * We return its color unchanged. */ gl_Position = worldViewProjection * position; texcoord = texCoord0; } // #o3d SplitMarker uniform sampler2D texSampler0; varying vec2 texcoord; /** * Pixel Shader */ void main() { gl_FragColor = texture2D(texSampler0, texcoord * 5.0) + vec4(0.2, 0.2, 0.0, 1.0); } // #o3d MatrixLoadOrder RowMajor