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.
|
|
//===== Copyright � 1996-2005, Valve Corporation, All rights reserved. ======//
//
// Purpose: These are declarations (functions, structs, enums) used in both
// SPU and PPU on PS/3, as well as potentially on different processor targets
// on future platforms
//===========================================================================//
#ifndef BASESHADER_SHARED_DECLARATIONS_HDR
#define BASESHADER_SHARED_DECLARATIONS_HDR
//-----------------------------------------------------------------------------
// Standard material vars
//-----------------------------------------------------------------------------
// Note: if you add to these, add to s_StandardParams in CBaseShader.cpp
enum ShaderMaterialVars_t { FLAGS = 0, FLAGS_DEFINED, // mask indicating if the flag was specified
FLAGS2, FLAGS_DEFINED2, COLOR, ALPHA, BASETEXTURE, FRAME, BASETEXTURETRANSFORM, FLASHLIGHTTEXTURE, FLASHLIGHTTEXTUREFRAME, COLOR2, SRGBTINT,
NUM_SHADER_MATERIAL_VARS };
// Alpha belnd mode enums. Moved from basevsshader
enum BlendType_t { // no alpha blending
BT_NONE = 0,
// src * srcAlpha + dst * (1-srcAlpha)
// two passes for HDR:
// pass 1:
// color: src * srcAlpha + dst * (1-srcAlpha)
// alpha: srcAlpha * zero + dstAlpha * (1-srcAlpha)
// pass 2:
// color: none
// alpha: srcAlpha * one + dstAlpha * one
//
BT_BLEND,
// src * one + dst * one
// one pass for HDR
BT_ADD,
// Why do we ever use this instead of using premultiplied alpha?
// src * srcAlpha + dst * one
// two passes for HDR
// pass 1:
// color: src * srcAlpha + dst * one
// alpha: srcAlpha * one + dstAlpha * one
// pass 2:
// color: none
// alpha: srcAlpha * one + dstAlpha * one
BT_BLENDADD };
#endif
|