þ:    E   	            POINT   SHADOWS_CUBE   SHADOWS_SOFTV  !!GLES3#version 300 es


#ifdef VERTEX


in vec4 _glesVertex;
in vec3 _glesNormal;
uniform highp vec4 _ProjectionParams;
uniform highp mat4 glstate_matrix_mvp;
uniform highp mat4 glstate_matrix_modelview0;
uniform highp float _LightAsQuad;
out highp vec4 xlv_TEXCOORD0;
out highp vec3 xlv_TEXCOORD1;
void main ()
{
  highp vec4 tmpvar_1;
  tmpvar_1 = (glstate_matrix_mvp * _glesVertex);
  highp vec4 o_2;
  highp vec4 tmpvar_3;
  tmpvar_3 = (tmpvar_1 * 0.5);
  highp vec2 tmpvar_4;
  tmpvar_4.x = tmpvar_3.x;
  tmpvar_4.y = (tmpvar_3.y * _ProjectionParams.x);
  o_2.xy = (tmpvar_4 + tmpvar_3.w);
  o_2.zw = tmpvar_1.zw;
  gl_Position = tmpvar_1;
  xlv_TEXCOORD0 = o_2;
  xlv_TEXCOORD1 = mix (((glstate_matrix_modelview0 * _glesVertex).xyz * vec3(-1.0, -1.0, 1.0)), _glesNormal, vec3(_LightAsQuad));
}



#endif
#ifdef FRAGMENT


layout(location=0) out mediump vec4 _glesFragData[4];
uniform highp vec3 _WorldSpaceCameraPos;
uniform highp vec4 _ProjectionParams;
uniform highp vec4 _ZBufferParams;
uniform highp vec4 _LightPositionRange;
uniform mediump vec4 _LightShadowData;
uniform highp sampler2D _CameraDepthTexture;
uniform highp vec4 _LightPos;
uniform highp vec4 _LightColor;
uniform highp mat4 _CameraToWorld;
uniform sampler2D _LightTextureB0;
uniform highp samplerCube _ShadowMapTexture;
uniform mediump vec4 unity_LightGammaCorrectionConsts;
uniform sampler2D _CameraGBufferTexture0;
uniform sampler2D _CameraGBufferTexture1;
uniform sampler2D _CameraGBufferTexture2;
in highp vec4 xlv_TEXCOORD0;
in highp vec3 xlv_TEXCOORD1;
void main ()
{
  lowp vec4 tmpvar_1;
  mediump vec4 gbuffer2_2;
  mediump vec4 gbuffer1_3;
  mediump vec4 gbuffer0_4;
  mediump vec3 tmpvar_5;
  highp float atten_6;
  mediump vec3 lightDir_7;
  highp vec2 tmpvar_8;
  tmpvar_8 = (xlv_TEXCOORD0.xy / xlv_TEXCOORD0.w);
  highp vec4 tmpvar_9;
  tmpvar_9 = texture (_CameraDepthTexture, tmpvar_8);
  highp vec4 tmpvar_10;
  tmpvar_10.w = 1.0;
  tmpvar_10.xyz = ((xlv_TEXCOORD1 * (_ProjectionParams.z / xlv_TEXCOORD1.z)) * (1.0/((
    (_ZBufferParams.x * tmpvar_9.x)
   + _ZBufferParams.y))));
  highp vec3 tmpvar_11;
  tmpvar_11 = (_CameraToWorld * tmpvar_10).xyz;
  highp vec3 tmpvar_12;
  tmpvar_12 = (tmpvar_11 - _LightPos.xyz);
  highp vec3 tmpvar_13;
  tmpvar_13 = -(normalize(tmpvar_12));
  lightDir_7 = tmpvar_13;
  highp float tmpvar_14;
  tmpvar_14 = (dot (tmpvar_12, tmpvar_12) * _LightPos.w);
  lowp float tmpvar_15;
  tmpvar_15 = texture (_LightTextureB0, vec2(tmpvar_14)).w;
  atten_6 = tmpvar_15;
  highp vec4 shadowVals_16;
  highp float tmpvar_17;
  tmpvar_17 = ((sqrt(
    dot (tmpvar_12, tmpvar_12)
  ) * _LightPositionRange.w) * 0.97);
  highp vec4 tmpvar_18;
  tmpvar_18 = texture (_ShadowMapTexture, (tmpvar_12 + vec3(0.0078125, 0.0078125, 0.0078125)));
  shadowVals_16.x = tmpvar_18.x;
  highp vec4 tmpvar_19;
  tmpvar_19 = texture (_ShadowMapTexture, (tmpvar_12 + vec3(-0.0078125, -0.0078125, 0.0078125)));
  shadowVals_16.y = tmpvar_19.x;
  highp vec4 tmpvar_20;
  tmpvar_20 = texture (_ShadowMapTexture, (tmpvar_12 + vec3(-0.0078125, 0.0078125, -0.0078125)));
  shadowVals_16.z = tmpvar_20.x;
  highp vec4 tmpvar_21;
  tmpvar_21 = texture (_ShadowMapTexture, (tmpvar_12 + vec3(0.0078125, -0.0078125, -0.0078125)));
  shadowVals_16.w = tmpvar_21.x;
  bvec4 tmpvar_22;
  tmpvar_22 = lessThan (shadowVals_16, vec4(tmpvar_17));
  mediump vec4 tmpvar_23;
  tmpvar_23 = _LightShadowData.xxxx;
  mediump float tmpvar_24;
  if (tmpvar_22.x) {
    tmpvar_24 = tmpvar_23.x;
  } else {
    tmpvar_24 = 1.0;
  };
  mediump float tmpvar_25;
  if (tmpvar_22.y) {
    tmpvar_25 = tmpvar_23.y;
  } else {
    tmpvar_25 = 1.0;
  };
  mediump float tmpvar_26;
  if (tmpvar_22.z) {
    tmpvar_26 = tmpvar_23.z;
  } else {
    tmpvar_26 = 1.0;
  };
  mediump float tmpvar_27;
  if (tmpvar_22.w) {
    tmpvar_27 = tmpvar_23.w;
  } else {
    tmpvar_27 = 1.0;
  };
  mediump vec4 tmpvar_28;
  tmpvar_28.x = tmpvar_24;
  tmpvar_28.y = tmpvar_25;
  tmpvar_28.z = tmpvar_26;
  tmpvar_28.w = tmpvar_27;
  mediump float tmpvar_29;
  tmpvar_29 = dot (tmpvar_28, vec4(0.25, 0.25, 0.25, 0.25));
  highp float tmpvar_30;
  tmpvar_30 = (atten_6 * tmpvar_29);
  atten_6 = tmpvar_30;
  lowp vec4 tmpvar_31;
  tmpvar_31 = texture (_CameraGBufferTexture0, tmpvar_8);
  gbuffer0_4 = tmpvar_31;
  lowp vec4 tmpvar_32;
  tmpvar_32 = texture (_CameraGBufferTexture1, tmpvar_8);
  gbuffer1_3 = tmpvar_32;
  lowp vec4 tmpvar_33;
  tmpvar_33 = texture (_CameraGBufferTexture2, tmpvar_8);
  gbuffer2_2 = tmpvar_33;
  highp vec3 tmpvar_34;
  tmpvar_34 = (_LightColor.xyz * tmpvar_30);
  tmpvar_5 = tmpvar_34;
  mediump vec3 tmpvar_35;
  tmpvar_35 = normalize(((gbuffer2_2.xyz * 2.0) - 1.0));
  highp vec3 tmpvar_36;
  tmpvar_36 = normalize((tmpvar_11 - _WorldSpaceCameraPos));
  mediump vec3 viewDir_37;
  viewDir_37 = -(tmpvar_36);
  mediump vec3 tmpvar_38;
  tmpvar_38 = normalize((lightDir_7 + viewDir_37));
  mediump float tmpvar_39;
  tmpvar_39 = max (0.0, dot (lightDir_7, tmpvar_38));
  mediump float tmpvar_40;
  tmpvar_40 = (1.0 - gbuffer1_3.w);
  mediump float tmpvar_41;
  mediump float tmpvar_42;
  tmpvar_42 = (10.0 / log2((
    ((1.0 - tmpvar_40) * 0.968)
   + 0.03)));
  tmpvar_41 = (tmpvar_42 * tmpvar_42);
  mediump vec4 tmpvar_43;
  tmpvar_43.w = 1.0;
  tmpvar_43.xyz = (((gbuffer0_4.xyz + 
    ((((tmpvar_41 + 1.0) * pow (
      max (0.0, dot (tmpvar_35, tmpvar_38))
    , tmpvar_41)) / ((
      (unity_LightGammaCorrectionConsts.z * (((tmpvar_39 * tmpvar_39) * gbuffer1_3.w) + (tmpvar_40 * tmpvar_40)))
     * tmpvar_39) + 0.0001)) * gbuffer1_3.xyz)
  ) * tmpvar_5) * max (0.0, dot (tmpvar_35, lightDir_7)));
  mediump vec4 tmpvar_44;
  tmpvar_44 = exp2(-(tmpvar_43));
  tmpvar_1 = tmpvar_44;
  _glesFragData[0] = tmpvar_1;
}



#endif                          