uniform sampler2D unity_LightmapInd;
uniform sampler2D unity_Lightmap;
uniform sampler2D _MainTex;
uniform sampler2D _LightBuffer;
void main ()
{
  vec3 tmpvar_1;
  tmpvar_1 = gl_TexCoord[1].xyz;
  vec4 tmpvar_2;
  tmpvar_2 = gl_TexCoord[2];
  vec3 tmpvar_3;
  tmpvar_3 = gl_TexCoord[3].xyz;
  vec4 light;
  vec2 tmpvar_4;
  tmpvar_4 = gl_TexCoord[0].xy;
  float x;
  x = (fract (((tmpvar_1.y + (tmpvar_1.z * 0.1)) * 5.0)) - 0.5);
  if ((x < 0.0)) {
    discard;
  };
  vec4 tmpvar_5;
  tmpvar_5 = -(log2 (texture2DProj (_LightBuffer, tmpvar_2)));
  light = tmpvar_5;
  light.xyz = (tmpvar_5.xyz + mix ((2.0 * texture2D (unity_LightmapInd, tmpvar_3.xy).xyz), (2.0 * texture2D (unity_Lightmap, tmpvar_3.xy).xyz), vec3(clamp (tmpvar_3.z, 0.0, 1.0))));
  vec4 c;
  c.xyz = (texture2D (_MainTex, tmpvar_4).xyz * light.xyz);
  c.w = 0.0;
  gl_FragData[0] = c;
}

