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.
|
|
//
// - This is the fog header to include for vertex shaders if the shader doesn't support pixel-shader-blended vertex fog.
//
// -- DOWATERFOG is 0 for RANGE FOG, 1 for WATER/HEIGHT FOG --
// DYNAMIC: "DOWATERFOG" "0..1" [ = ( pShaderAPI->GetSceneFogMode() == MATERIAL_FOG_LINEAR_BELOW_FOG_Z ) ]
// -- DOPIXELFOG is 1 if the material has $pixelfog 1, or if the material forces pixel fog by default (lightmappedgeneric for instance.) --
// FIXME! Will need to revisit this once we are doing water/height fog again. Needs to be pixel for in the water case.
// STATIC: "DOPIXELFOG" "0..1" [ = g_pHardwareConfig->SupportsPixelShaders_2_b() ]
// STATIC: "HARDWAREFOGBLEND" "0..0" [XBOX] [ = 0 ]
// STATIC: "HARDWAREFOGBLEND" "0..1" [PC] [vs20] [ = !g_pHardwareConfig->SupportsPixelShaders_2_b() ]
// STATIC: "HARDWAREFOGBLEND" "0..0" [PC] [vs30] [ = 0 ]
// Can't do fixed-function fog and pixelfog at the same time, but only if we aren't doing water since HARDWAREFOGBLEND and DOPIXELFOG get redefined below.
// SKIP: ( $DOWATERFOG == 0 ) && ( $DOPIXELFOG && $HARDWAREFOGBLEND )
// Support either pixel fog or fixed-function fog, skip everything else.
// SKIP: ( $DOWATERFOG == 0 ) && ( $HARDWAREFOGBLEND == 0 ) && ( $DOPIXELFOG == 0 )
#if DOWATERFOG == 1
#undef HARDWAREFOGBLEND
#define HARDWAREFOGBLEND 0
#undef DOPIXELFOG
#define DOPIXELFOG 1
#endif
|