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.

78 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. // defined $PIXELFOGTYPE && defined $WRITEWATERFOGTODESTALPHA && ( $PIXELFOGTYPE != 1 ) && $WRITEWATERFOGTODESTALPHA
  13. // defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPTINT && $LIGHTING_PREVIEW && $FASTPATHENVMAPTINT
  14. // defined $LIGHTING_PREVIEW && defined $FASTPATHENVMAPCONTRAST && $LIGHTING_PREVIEW && $FASTPATHENVMAPCONTRAST
  15. // defined $LIGHTING_PREVIEW && defined $FASTPATH && $LIGHTING_PREVIEW && $FASTPATH
  16. // ($FLASHLIGHT || $FLASHLIGHTSHADOWS) && $LIGHTING_PREVIEW
  17. #include "shaderlib/cshader.h"
  18. class deferred_global_light_ps20b_Static_Index
  19. {
  20. private:
  21. int m_nFLASHLIGHTDEPTHFILTERMODE;
  22. #ifdef _DEBUG
  23. bool m_bFLASHLIGHTDEPTHFILTERMODE;
  24. #endif
  25. public:
  26. void SetFLASHLIGHTDEPTHFILTERMODE( int i )
  27. {
  28. Assert( i >= 0 && i <= 2 );
  29. m_nFLASHLIGHTDEPTHFILTERMODE = i;
  30. #ifdef _DEBUG
  31. m_bFLASHLIGHTDEPTHFILTERMODE = true;
  32. #endif
  33. }
  34. void SetFLASHLIGHTDEPTHFILTERMODE( bool i )
  35. {
  36. m_nFLASHLIGHTDEPTHFILTERMODE = i ? 1 : 0;
  37. #ifdef _DEBUG
  38. m_bFLASHLIGHTDEPTHFILTERMODE = true;
  39. #endif
  40. }
  41. public:
  42. // CONSTRUCTOR
  43. deferred_global_light_ps20b_Static_Index( IShaderShadow *pShaderShadow, IMaterialVar **params )
  44. {
  45. #ifdef _DEBUG
  46. m_bFLASHLIGHTDEPTHFILTERMODE = false;
  47. #endif // _DEBUG
  48. m_nFLASHLIGHTDEPTHFILTERMODE = 0;
  49. }
  50. int GetIndex()
  51. {
  52. // Asserts to make sure that we aren't using any skipped combinations.
  53. // Asserts to make sure that we are setting all of the combination vars.
  54. #ifdef _DEBUG
  55. bool bAllStaticVarsDefined = m_bFLASHLIGHTDEPTHFILTERMODE;
  56. Assert( bAllStaticVarsDefined );
  57. #endif // _DEBUG
  58. return ( 1 * m_nFLASHLIGHTDEPTHFILTERMODE ) + 0;
  59. }
  60. };
  61. #define shaderStaticTest_deferred_global_light_ps20b psh_forgot_to_set_static_FLASHLIGHTDEPTHFILTERMODE + 0
  62. class deferred_global_light_ps20b_Dynamic_Index
  63. {
  64. public:
  65. // CONSTRUCTOR
  66. deferred_global_light_ps20b_Dynamic_Index( IShaderDynamicAPI *pShaderAPI )
  67. {
  68. }
  69. int GetIndex()
  70. {
  71. // Asserts to make sure that we aren't using any skipped combinations.
  72. // Asserts to make sure that we are setting all of the combination vars.
  73. #ifdef _DEBUG
  74. #endif // _DEBUG
  75. return 0;
  76. }
  77. };
  78. #define shaderDynamicTest_deferred_global_light_ps20b 0