forked from sears2424/Source-PlusPlus
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathshareddefs.h
111 lines (94 loc) · 2.76 KB
/
shareddefs.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose: NOTE: This file is for backward compat!
// We'll get rid of it soon. Most of the contents of this file were moved
// into shaderpi/ishadershadow.h, shaderapi/ishaderdynamic.h, or
// shaderapi/shareddefs.h
//
// $NoKeywords: $
//
//===========================================================================//
#ifndef SHADERAPI_SHAREDDEFS_H
#define SHADERAPI_SHAREDDEFS_H
#ifdef _WIN32
#pragma once
#endif
//-----------------------------------------------------------------------------
// Important enumerations
//-----------------------------------------------------------------------------
enum ShaderShadeMode_t
{
SHADER_FLAT = 0,
SHADER_SMOOTH
};
enum ShaderTexCoordComponent_t
{
SHADER_TEXCOORD_S = 0,
SHADER_TEXCOORD_T,
SHADER_TEXCOORD_U
};
enum ShaderTexFilterMode_t
{
SHADER_TEXFILTERMODE_NEAREST,
SHADER_TEXFILTERMODE_LINEAR,
SHADER_TEXFILTERMODE_NEAREST_MIPMAP_NEAREST,
SHADER_TEXFILTERMODE_LINEAR_MIPMAP_NEAREST,
SHADER_TEXFILTERMODE_NEAREST_MIPMAP_LINEAR,
SHADER_TEXFILTERMODE_LINEAR_MIPMAP_LINEAR,
SHADER_TEXFILTERMODE_ANISOTROPIC
};
enum ShaderTexWrapMode_t
{
SHADER_TEXWRAPMODE_CLAMP,
SHADER_TEXWRAPMODE_REPEAT,
SHADER_TEXWRAPMODE_BORDER
// MIRROR? - probably don't need it.
};
//-----------------------------------------------------------------------------
// Sampler + texture stage identifiers
// NOTE: Texture stages are used only by fixed function shading algorithms
// Samplers are used to enable and bind textures + by programmable shading algorithms
//-----------------------------------------------------------------------------
enum TextureStage_t
{
SHADER_TEXTURE_STAGE0 = 0,
SHADER_TEXTURE_STAGE1,
};
enum Sampler_t
{
SHADER_SAMPLER0 = 0,
SHADER_SAMPLER1,
SHADER_SAMPLER2,
SHADER_SAMPLER3,
SHADER_SAMPLER4,
SHADER_SAMPLER5,
SHADER_SAMPLER6,
SHADER_SAMPLER7,
SHADER_SAMPLER8,
SHADER_SAMPLER9,
SHADER_SAMPLER10,
SHADER_SAMPLER11,
SHADER_SAMPLER12,
SHADER_SAMPLER13,
SHADER_SAMPLER14,
SHADER_SAMPLER15,
};
//-----------------------------------------------------------------------------
// Vertex texture sampler identifiers
//-----------------------------------------------------------------------------
enum VertexTextureSampler_t
{
SHADER_VERTEXTEXTURE_SAMPLER0 = 0,
SHADER_VERTEXTEXTURE_SAMPLER1,
SHADER_VERTEXTEXTURE_SAMPLER2,
SHADER_VERTEXTEXTURE_SAMPLER3,
};
#if defined( _X360 )
#define REVERSE_DEPTH_ON_X360 //uncomment to use D3DFMT_D24FS8 with an inverted depth viewport for better performance. Keep this in sync with the same named #define in materialsystem/stdshaders/common_fxc.h
#endif
#if defined( REVERSE_DEPTH_ON_X360 )
#define ReverseDepthOnX360() true
#else
#define ReverseDepthOnX360() false
#endif
#endif // SHADERAPI_SHAREDDEFS_H