浏览代码

Merge pull request #1164 from BeamNG/remove_gl_shadegen_dead_code

Remove some dead code from OpenGL shadergen.
Luis Anton Rebollo 10 年之前
父节点
当前提交
b1ad72692c
共有 1 个文件被更改,包括 1 次插入17 次删除
  1. 1 17
      Engine/source/shaderGen/GLSL/shaderCompGLSL.cpp

+ 1 - 17
Engine/source/shaderGen/GLSL/shaderCompGLSL.cpp

@@ -373,17 +373,7 @@ Vector<String> initDeprecadedDefines()
 
 void VertPixelConnectorGLSL::printStructDefines( Stream &stream, bool in )
 {
-   const char* connectionDir;
-
-   if(in)
-   {       
-      connectionDir = "IN";
-   }
-   else
-   {
-     
-      connectionDir = "OUT";
-   }
+   const char* connectionDir = in ? "IN" : "OUT";
 
    static Vector<String> deprecatedDefines = initDeprecadedDefines();
 
@@ -407,12 +397,6 @@ void VertPixelConnectorGLSL::printStructDefines( Stream &stream, bool in )
          stream.write( dStrlen((char*)output), output );
          continue;
       }
-
-      if( deprecatedDefines.contains((char*)var->name))
-         continue;
-
-      dSprintf((char*)output, sizeof(output), "#define %s %s_%s\r\n", var->name, connectionDir, var->name);
-      stream.write( dStrlen((char*)output), output );
    }
 
    stream.write( dStrlen((char*)newLine), newLine );