mirror of
https://github.com/scratchfoundation/bgfx.git
synced 2024-12-11 00:31:28 -05:00
163 lines
5.1 KiB
Text
163 lines
5.1 KiB
Text
attribute vec4 _glesVertex;
|
|
uniform highp mat4 glstate_matrix_mvp;
|
|
uniform highp mat4 _Object2World;
|
|
uniform mediump vec2 _DynLampInfo_bufferSize;
|
|
uniform sampler2D _DynLampInfo;
|
|
varying mediump vec3 xlv_TEXCOORD2;
|
|
void main ()
|
|
{
|
|
mediump vec3 tmpvar_1;
|
|
highp vec3 tmpvar_2;
|
|
tmpvar_2 = (_Object2World * _glesVertex).xyz;
|
|
highp vec3 tmpvar_3;
|
|
mediump vec3 hybridCol_4;
|
|
highp ivec4 tmpvar_5;
|
|
tmpvar_5.xyz = ivec3(tmpvar_2);
|
|
tmpvar_5.w = int(-(tmpvar_2.x));
|
|
highp vec2 tmpvar_6;
|
|
tmpvar_6.y = 1.0;
|
|
tmpvar_6.x = float(tmpvar_5.x);
|
|
mediump vec2 coord_7;
|
|
coord_7 = tmpvar_6;
|
|
mediump vec4 tmpvar_8;
|
|
tmpvar_8.zw = vec2(0.0, 0.0);
|
|
tmpvar_8.xy = (coord_7 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_9;
|
|
lowp vec4 tmpvar_10;
|
|
tmpvar_10 = texture2DLod (_DynLampInfo, tmpvar_8.xy, 0.0);
|
|
tmpvar_9 = tmpvar_10;
|
|
highp vec2 tmpvar_11;
|
|
tmpvar_11.y = 2.0;
|
|
tmpvar_11.x = float(tmpvar_5.x);
|
|
mediump vec2 coord_12;
|
|
coord_12 = tmpvar_11;
|
|
mediump vec4 tmpvar_13;
|
|
tmpvar_13.zw = vec2(0.0, 0.0);
|
|
tmpvar_13.xy = (coord_12 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_14;
|
|
lowp vec4 tmpvar_15;
|
|
tmpvar_15 = texture2DLod (_DynLampInfo, tmpvar_13.xy, 0.0);
|
|
tmpvar_14 = tmpvar_15;
|
|
highp vec2 tmpvar_16;
|
|
tmpvar_16.y = 1.0;
|
|
tmpvar_16.x = float(tmpvar_5.y);
|
|
mediump vec2 coord_17;
|
|
coord_17 = tmpvar_16;
|
|
mediump vec4 tmpvar_18;
|
|
tmpvar_18.zw = vec2(0.0, 0.0);
|
|
tmpvar_18.xy = (coord_17 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_19;
|
|
lowp vec4 tmpvar_20;
|
|
tmpvar_20 = texture2DLod (_DynLampInfo, tmpvar_18.xy, 0.0);
|
|
tmpvar_19 = tmpvar_20;
|
|
highp vec2 tmpvar_21;
|
|
tmpvar_21.y = 2.0;
|
|
tmpvar_21.x = float(tmpvar_5.y);
|
|
mediump vec2 coord_22;
|
|
coord_22 = tmpvar_21;
|
|
mediump vec4 tmpvar_23;
|
|
tmpvar_23.zw = vec2(0.0, 0.0);
|
|
tmpvar_23.xy = (coord_22 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_24;
|
|
lowp vec4 tmpvar_25;
|
|
tmpvar_25 = texture2DLod (_DynLampInfo, tmpvar_23.xy, 0.0);
|
|
tmpvar_24 = tmpvar_25;
|
|
highp vec2 tmpvar_26;
|
|
tmpvar_26.y = 1.0;
|
|
tmpvar_26.x = float(tmpvar_5.z);
|
|
mediump vec2 coord_27;
|
|
coord_27 = tmpvar_26;
|
|
mediump vec4 tmpvar_28;
|
|
tmpvar_28.zw = vec2(0.0, 0.0);
|
|
tmpvar_28.xy = (coord_27 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_29;
|
|
lowp vec4 tmpvar_30;
|
|
tmpvar_30 = texture2DLod (_DynLampInfo, tmpvar_28.xy, 0.0);
|
|
tmpvar_29 = tmpvar_30;
|
|
highp vec2 tmpvar_31;
|
|
tmpvar_31.y = 2.0;
|
|
tmpvar_31.x = float(tmpvar_5.z);
|
|
mediump vec2 coord_32;
|
|
coord_32 = tmpvar_31;
|
|
mediump vec4 tmpvar_33;
|
|
tmpvar_33.zw = vec2(0.0, 0.0);
|
|
tmpvar_33.xy = (coord_32 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_34;
|
|
lowp vec4 tmpvar_35;
|
|
tmpvar_35 = texture2DLod (_DynLampInfo, tmpvar_33.xy, 0.0);
|
|
tmpvar_34 = tmpvar_35;
|
|
highp vec2 tmpvar_36;
|
|
tmpvar_36.y = 1.0;
|
|
tmpvar_36.x = float(tmpvar_5.w);
|
|
mediump vec2 coord_37;
|
|
coord_37 = tmpvar_36;
|
|
mediump vec4 tmpvar_38;
|
|
tmpvar_38.zw = vec2(0.0, 0.0);
|
|
tmpvar_38.xy = (coord_37 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_39;
|
|
lowp vec4 tmpvar_40;
|
|
tmpvar_40 = texture2DLod (_DynLampInfo, tmpvar_38.xy, 0.0);
|
|
tmpvar_39 = tmpvar_40;
|
|
highp vec2 tmpvar_41;
|
|
tmpvar_41.y = 2.0;
|
|
tmpvar_41.x = float(tmpvar_5.w);
|
|
mediump vec2 coord_42;
|
|
coord_42 = tmpvar_41;
|
|
mediump vec4 tmpvar_43;
|
|
tmpvar_43.zw = vec2(0.0, 0.0);
|
|
tmpvar_43.xy = (coord_42 / _DynLampInfo_bufferSize);
|
|
mediump vec4 tmpvar_44;
|
|
lowp vec4 tmpvar_45;
|
|
tmpvar_45 = texture2DLod (_DynLampInfo, tmpvar_43.xy, 0.0);
|
|
tmpvar_44 = tmpvar_45;
|
|
mediump vec3 hybridCol_46;
|
|
mediump vec4 atten_47;
|
|
highp vec3 tmpvar_48;
|
|
tmpvar_48 = (tmpvar_9.xyz - tmpvar_2);
|
|
highp float tmpvar_49;
|
|
tmpvar_49 = dot (tmpvar_48, tmpvar_48);
|
|
mediump vec4 tmpvar_50;
|
|
tmpvar_50.yzw = atten_47.yzw;
|
|
tmpvar_50.x = (tmpvar_49 * tmpvar_9.w);
|
|
highp vec3 tmpvar_51;
|
|
tmpvar_51 = (tmpvar_19.xyz - tmpvar_2);
|
|
highp float tmpvar_52;
|
|
tmpvar_52 = dot (tmpvar_51, tmpvar_51);
|
|
mediump vec4 tmpvar_53;
|
|
tmpvar_53.xzw = tmpvar_50.xzw;
|
|
tmpvar_53.y = (tmpvar_52 * tmpvar_19.w);
|
|
highp vec3 tmpvar_54;
|
|
tmpvar_54 = (tmpvar_29.xyz - tmpvar_2);
|
|
highp float tmpvar_55;
|
|
tmpvar_55 = dot (tmpvar_54, tmpvar_54);
|
|
mediump vec4 tmpvar_56;
|
|
tmpvar_56.xyw = tmpvar_53.xyw;
|
|
tmpvar_56.z = (tmpvar_55 * tmpvar_29.w);
|
|
highp vec3 tmpvar_57;
|
|
tmpvar_57 = (tmpvar_39.xyz - tmpvar_2);
|
|
highp float tmpvar_58;
|
|
tmpvar_58 = dot (tmpvar_57, tmpvar_57);
|
|
mediump vec4 tmpvar_59;
|
|
tmpvar_59.xyz = tmpvar_56.xyz;
|
|
tmpvar_59.w = (tmpvar_58 * tmpvar_39.w);
|
|
atten_47 = tmpvar_59;
|
|
hybridCol_46 = (hybridCol_4 + (tmpvar_14.xyz * tmpvar_50.x));
|
|
hybridCol_46 = (hybridCol_46 + (tmpvar_24.xyz * tmpvar_53.y));
|
|
hybridCol_46 = (hybridCol_46 + (tmpvar_34.xyz * tmpvar_56.z));
|
|
hybridCol_46 = (hybridCol_46 + (tmpvar_44.xyz * tmpvar_59.w));
|
|
tmpvar_3 = hybridCol_46;
|
|
tmpvar_1 = tmpvar_3;
|
|
gl_Position = (glstate_matrix_mvp * _glesVertex);
|
|
xlv_TEXCOORD2 = tmpvar_1;
|
|
}
|
|
|
|
|
|
// stats: 57 alu 8 tex 0 flow
|
|
// inputs: 1
|
|
// #0: _glesVertex (high float) 4x1 [-1]
|
|
// uniforms: 3 (total size: 0)
|
|
// #0: glstate_matrix_mvp (high float) 4x4 [-1]
|
|
// #1: _Object2World (high float) 4x4 [-1]
|
|
// #2: _DynLampInfo_bufferSize (medium float) 2x1 [-1]
|
|
// textures: 1
|
|
// #0: _DynLampInfo (low 2d) 0x0 [-1]
|