瀏覽代碼

Fixed varrying binding in the lighting shader

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7898 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
rem..om 14 年之前
父節點
當前提交
e6c2653fe6
共有 1 個文件被更改,包括 4 次插入2 次删除
  1. 4 2
      engine/src/core-data/Common/MatDefs/Light/Lighting.frag

+ 4 - 2
engine/src/core-data/Common/MatDefs/Light/Lighting.frag

@@ -47,14 +47,16 @@ varying vec4 SpecularSum;
   uniform sampler2D m_ColorRamp;
   uniform sampler2D m_ColorRamp;
 #endif
 #endif
 uniform float m_AlphaDiscardThreshold;
 uniform float m_AlphaDiscardThreshold;
+
+varying vec4 lightVec;
+varying vec4 spotVec;
+
 #ifndef VERTEX_LIGHTING
 #ifndef VERTEX_LIGHTING
 uniform float m_Shininess;
 uniform float m_Shininess;
 
 
 #ifdef HQ_ATTENUATION
 #ifdef HQ_ATTENUATION
 uniform vec4 g_LightPosition;
 uniform vec4 g_LightPosition;
 #endif
 #endif
-varying vec4 lightVec;
-varying vec4 spotVec;
 
 
 #ifdef USE_REFLECTION 
 #ifdef USE_REFLECTION 
     uniform float m_ReflectionPower;
     uniform float m_ReflectionPower;