Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

94 lines
3.0 KiB

  1. // ALL SKIP STATEMENTS THAT AFFECT THIS SHADER!!!
  2. // defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA
  3. // defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT
  4. // defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST
  5. // defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH
  6. // ($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW
  7. // defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA
  8. // defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT
  9. // defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST
  10. // defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH
  11. // ($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW
  12. #include "shaderlib/cshader.h"
  13. class windowimposter_ps20b_Static_Index
  14. {
  15. public:
  16. // CONSTRUCTOR
  17. windowimposter_ps20b_Static_Index( IShaderShadow *pShaderShadow, IMaterialVar **params )
  18. {
  19. }
  20. int GetIndex()
  21. {
  22. // Asserts to make sure that we aren't using any skipped combinations.
  23. // Asserts to make sure that we are setting all of the combination vars.
  24. #ifdef _DEBUG
  25. #endif // _DEBUG
  26. return 0;
  27. }
  28. };
  29. #define shaderStaticTest_windowimposter_ps20b 0
  30. class windowimposter_ps20b_Dynamic_Index
  31. {
  32. private:
  33. int m_nPIXELFOGTYPE;
  34. #ifdef _DEBUG
  35. bool m_bPIXELFOGTYPE;
  36. #endif
  37. public:
  38. void SetPIXELFOGTYPE( int i )
  39. {
  40. Assert( i >= 0 && i <= 1 );
  41. m_nPIXELFOGTYPE = i;
  42. #ifdef _DEBUG
  43. m_bPIXELFOGTYPE = true;
  44. #endif
  45. }
  46. void SetPIXELFOGTYPE( bool i )
  47. {
  48. Assert( ( i ? 1 : 0 ) >= 0 && ( i ? 1 : 0 ) <= 1 );
  49. m_nPIXELFOGTYPE = i ? 1 : 0;
  50. #ifdef _DEBUG
  51. m_bPIXELFOGTYPE = true;
  52. #endif
  53. }
  54. public:
  55. // CONSTRUCTOR
  56. windowimposter_ps20b_Dynamic_Index( IShaderDynamicAPI *pShaderAPI )
  57. {
  58. #ifdef _DEBUG
  59. m_bPIXELFOGTYPE = true;
  60. #endif // _DEBUG
  61. m_nPIXELFOGTYPE = ( pShaderAPI->GetSceneFogMode() == MATERIAL_FOG_LINEAR_BELOW_FOG_Z ) ;
  62. }
  63. int GetIndex()
  64. {
  65. // Asserts to make sure that we aren't using any skipped combinations.
  66. // Asserts to make sure that we are setting all of the combination vars.
  67. #ifdef _DEBUG
  68. bool bAllDynamicVarsDefined = m_bPIXELFOGTYPE;
  69. Assert( bAllDynamicVarsDefined );
  70. #endif // _DEBUG
  71. return ( 1 * m_nPIXELFOGTYPE ) + 0;
  72. }
  73. };
  74. #define shaderDynamicTest_windowimposter_ps20b 0
  75. static const ShaderComboInformation_t s_DynamicComboArray_windowimposter_ps20b[1] =
  76. {
  77. { "PIXELFOGTYPE", 0, 1 },
  78. };
  79. static const ShaderComboSemantics_t windowimposter_ps20b_combos =
  80. {
  81. "windowimposter_ps20b", s_DynamicComboArray_windowimposter_ps20b, 1, NULL, 0
  82. };
  83. class ConstructMe_windowimposter_ps20b
  84. {
  85. public:
  86. ConstructMe_windowimposter_ps20b()
  87. {
  88. GetShaderDLL()->AddShaderComboInformation( &windowimposter_ps20b_combos );
  89. }
  90. };
  91. static ConstructMe_windowimposter_ps20b s_ConstructMe_windowimposter_ps20b;