bgfx/examples/runtime/shaders/gles/vs_instancing.bin

28 lines
558 B
Text
Raw Normal View History

2012-10-09 02:24:10 -04:00
#ifdef GL_ES
precision highp float;
#endif // GL_ES
uniform mat4 u_viewProj;
varying vec4 v_color0;
attribute vec4 i_data4;
attribute vec4 i_data3;
attribute vec4 i_data2;
attribute vec4 i_data1;
attribute vec4 i_data0;
2012-10-28 00:34:41 -04:00
attribute vec4 a_color0;
2012-10-09 02:24:10 -04:00
attribute vec3 a_position;
void main ()
{
mat4 model_1;
model_1[0] = i_data0;
model_1[1] = i_data1;
model_1[2] = i_data2;
model_1[3] = i_data3;
vec4 tmpvar_2;
tmpvar_2.w = 1.0;
tmpvar_2.xyz = a_position;
gl_Position = (u_viewProj * (model_1 * tmpvar_2));
2012-10-28 00:34:41 -04:00
v_color0 = (a_color0 * i_data4);
2012-10-09 02:24:10 -04:00
}