1 #ifndef SIMPLESHADERS_H_
2 #define SIMPLESHADERS_H_
10 "attribute vec4 position; \n"
11 "attribute vec2 textureCoordinates; \n"
12 "uniform mat4 projectionMatrix;\n"
13 "uniform mat4 modelMatrix; \n"
14 "uniform mat4 viewMatrix; \n"
15 "varying vec2 v_textureCoordinates; \n"
18 " gl_Position = projectionMatrix*(modelMatrix*(viewMatrix*position)); \n"
19 " v_textureCoordinates = textureCoordinates; \n"
24 "precision mediump float; \n"
25 "varying vec2 v_textureCoordinates; \n"
26 "uniform sampler2D s_texture; \n"
29 " gl_FragColor = texture2D(s_texture, v_textureCoordinates); \n"
34 "attribute vec4 position; \n"
35 "uniform mat4 projectionMatrix;\n"
36 "uniform mat4 modelViewMatrix; \n"
37 "uniform vec4 color; \n"
38 "varying vec4 v_color; \n"
41 " gl_Position = projectionMatrix*(modelViewMatrix*position); \n"
42 " v_color = color; \n"
46 "precision mediump float; \n"
47 "varying vec4 v_color; \n"
50 " gl_FragColor = v_color; \n"
54 "attribute vec4 vPosition;\n"
55 "uniform mat4 projectionMatrix;\n"
58 "gl_Position = position; \n"
63 "precision mediump float;\n"
66 " gl_FragColor = vec4(1.0, 0.0, 0.0, 1.0); \n"
71 { 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
72 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
73 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
74 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
75 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
76 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
77 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
78 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
79 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
80 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
81 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
82 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
83 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
84 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
85 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128,
86 128, 0, 0, 128, 0, 128, 0, 128, 0, 0, 128, 128, 128, 128, 0, 128