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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
|
/**************************************************************************
*
* Copyright 2012-2021 VMware, Inc.
* All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sub license, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
* THE COPYRIGHT HOLDERS, AUTHORS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM,
* DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
* OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
* USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* The above copyright notice and this permission notice (including the
* next paragraph) shall be included in all copies or substantial portions
* of the Software.
*
**************************************************************************/
/*
* Shader.h --
* Functions that manipulate shader resources.
*/
#ifndef SHADER_H
#define SHADER_H
#include "DriverIncludes.h"
struct Device;
struct Shader;
void *
CreateEmptyShader(Device *pDevice,
enum pipe_shader_type processor);
void
DeleteEmptyShader(Device *pDevice,
enum pipe_shader_type processor, void *handle);
unsigned
ShaderFindOutputMapping(Shader *shader, unsigned registerIndex);
SIZE_T APIENTRY
CalcPrivateShaderSize(D3D10DDI_HDEVICE hDevice,
__in_ecount (pShaderCode[1]) const UINT *pShaderCode,
__in const D3D10DDIARG_STAGE_IO_SIGNATURES *pSignatures);
void APIENTRY
DestroyShader(D3D10DDI_HDEVICE hDevice, D3D10DDI_HSHADER hShader);
SIZE_T APIENTRY
CalcPrivateSamplerSize(D3D10DDI_HDEVICE hDevice,
__in const D3D10_DDI_SAMPLER_DESC *pSamplerDesc);
void APIENTRY CreateSampler(D3D10DDI_HDEVICE hDevice,
__in const D3D10_DDI_SAMPLER_DESC *pSamplerDesc,
D3D10DDI_HSAMPLER hSampler, D3D10DDI_HRTSAMPLER hRTSampler);
void APIENTRY DestroySampler(D3D10DDI_HDEVICE hDevice, D3D10DDI_HSAMPLER hSampler);
void APIENTRY CreateVertexShader(D3D10DDI_HDEVICE hDevice,
__in_ecount (pShaderCode[1]) const UINT *pCode,
D3D10DDI_HSHADER hShader, D3D10DDI_HRTSHADER hRTShader,
__in const D3D10DDIARG_STAGE_IO_SIGNATURES *pSignatures);
void APIENTRY VsSetShader(D3D10DDI_HDEVICE hDevice, D3D10DDI_HSHADER hShader);
void APIENTRY VsSetShaderResources(
D3D10DDI_HDEVICE hDevice, UINT Offset, UINT NumViews,
__in_ecount (NumViews) const D3D10DDI_HSHADERRESOURCEVIEW *phShaderResourceViews);
void APIENTRY VsSetConstantBuffers(D3D10DDI_HDEVICE hDevice, UINT StartBuffer, UINT NumBuffers,
__in_ecount (NumBuffers) const D3D10DDI_HRESOURCE *phBuffers);
void APIENTRY VsSetSamplers(D3D10DDI_HDEVICE hDevice, UINT Offset, UINT NumSamplers,
__in_ecount (NumSamplers) const D3D10DDI_HSAMPLER *phSamplers);
void APIENTRY CreateGeometryShader(D3D10DDI_HDEVICE hDevice,
__in_ecount (pShaderCode[1]) const UINT *pCode,
D3D10DDI_HSHADER hShader, D3D10DDI_HRTSHADER hRTShader,
__in const D3D10DDIARG_STAGE_IO_SIGNATURES *pSignatures);
void APIENTRY GsSetShader(D3D10DDI_HDEVICE hDevice, D3D10DDI_HSHADER hShader);
void APIENTRY GsSetShaderResources(
D3D10DDI_HDEVICE hDevice, UINT Offset, UINT NumViews,
__in_ecount (NumViews) const D3D10DDI_HSHADERRESOURCEVIEW *phShaderResourceViews);
void APIENTRY GsSetConstantBuffers(D3D10DDI_HDEVICE hDevice, UINT StartBuffer, UINT NumBuffers,
__in_ecount (NumBuffers) const D3D10DDI_HRESOURCE *phBuffers);
void APIENTRY GsSetSamplers(D3D10DDI_HDEVICE hDevice, UINT Offset, UINT NumSamplers,
__in_ecount (NumSamplers) const D3D10DDI_HSAMPLER *phSamplers);
SIZE_T APIENTRY CalcPrivateGeometryShaderWithStreamOutput(
D3D10DDI_HDEVICE hDevice,
__in const D3D10DDIARG_CREATEGEOMETRYSHADERWITHSTREAMOUTPUT *pCreateGeometryShaderWithStreamOutput,
__in const D3D10DDIARG_STAGE_IO_SIGNATURES *pSignatures);
void APIENTRY CreateGeometryShaderWithStreamOutput(
D3D10DDI_HDEVICE hDevice,
__in const D3D10DDIARG_CREATEGEOMETRYSHADERWITHSTREAMOUTPUT *pCreateGeometryShaderWithStreamOutput,
D3D10DDI_HSHADER hShader, D3D10DDI_HRTSHADER hRTShader,
__in const D3D10DDIARG_STAGE_IO_SIGNATURES *pSignatures);
void APIENTRY SoSetTargets(D3D10DDI_HDEVICE hDevice, UINT SOTargets, UINT ClearTargets,
__in_ecount (SOTargets) const D3D10DDI_HRESOURCE *phResource,
__in_ecount (SOTargets) const UINT *pOffsets);
void APIENTRY CreatePixelShader(D3D10DDI_HDEVICE hDevice,
__in_ecount (pShaderCode[1]) const UINT *pCode,
D3D10DDI_HSHADER hShader, D3D10DDI_HRTSHADER hRTShader,
__in const D3D10DDIARG_STAGE_IO_SIGNATURES *pSignatures);
void APIENTRY PsSetShader(D3D10DDI_HDEVICE hDevice, D3D10DDI_HSHADER hShader);
void APIENTRY PsSetShaderResources(
D3D10DDI_HDEVICE hDevice, UINT Offset, UINT NumViews,
__in_ecount (NumViews) const D3D10DDI_HSHADERRESOURCEVIEW *phShaderResourceViews);
void APIENTRY PsSetConstantBuffers(D3D10DDI_HDEVICE hDevice, UINT StartBuffer, UINT NumBuffers,
__in_ecount (NumBuffers) const D3D10DDI_HRESOURCE *phBuffers);
void APIENTRY PsSetSamplers(D3D10DDI_HDEVICE hDevice, UINT Offset, UINT NumSamplers,
__in_ecount (NumSamplers) const D3D10DDI_HSAMPLER *phSamplers);
void APIENTRY ShaderResourceViewReadAfterWriteHazard(
D3D10DDI_HDEVICE hDevice, D3D10DDI_HSHADERRESOURCEVIEW hShaderResourceView,
D3D10DDI_HRESOURCE hResource);
SIZE_T APIENTRY CalcPrivateShaderResourceViewSize(
D3D10DDI_HDEVICE hDevice,
__in const D3D10DDIARG_CREATESHADERRESOURCEVIEW *pCreateShaderResourceView);
void APIENTRY CreateShaderResourceView(
D3D10DDI_HDEVICE hDevice,
__in const D3D10DDIARG_CREATESHADERRESOURCEVIEW *pCreateShaderResourceView,
D3D10DDI_HSHADERRESOURCEVIEW hShaderResourceView,
D3D10DDI_HRTSHADERRESOURCEVIEW hRTShaderResourceView);
SIZE_T APIENTRY CalcPrivateShaderResourceViewSize1(
D3D10DDI_HDEVICE hDevice,
__in const D3D10_1DDIARG_CREATESHADERRESOURCEVIEW *pCreateShaderResourceView);
void APIENTRY CreateShaderResourceView1(
D3D10DDI_HDEVICE hDevice,
__in const D3D10_1DDIARG_CREATESHADERRESOURCEVIEW *pCreateShaderResourceView,
D3D10DDI_HSHADERRESOURCEVIEW hShaderResourceView,
D3D10DDI_HRTSHADERRESOURCEVIEW hRTShaderResourceView);
void APIENTRY DestroyShaderResourceView(D3D10DDI_HDEVICE hDevice,
D3D10DDI_HSHADERRESOURCEVIEW hShaderResourceView);
void APIENTRY GenMips(D3D10DDI_HDEVICE hDevice,
D3D10DDI_HSHADERRESOURCEVIEW hShaderResourceView);
#endif /* SHADER_H */
|