summaryrefslogtreecommitdiffstats
path: root/gfx/angle/checkout/src/libANGLE/validationES31.h
blob: 0f9d4eee7ca90bce9f79e6d465f6285fd4848836 (plain)
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
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
//
// Copyright 2018 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// validationES31.h:
//  Inlined validation functions for OpenGL ES 3.1 entry points.

#ifndef LIBANGLE_VALIDATION_ES31_H_
#define LIBANGLE_VALIDATION_ES31_H_

#include "libANGLE/ErrorStrings.h"
#include "libANGLE/validationES31_autogen.h"

namespace gl
{

bool ValidateTexBufferBase(const Context *context,
                           TextureType target,
                           GLenum internalformat,
                           BufferID bufferPacked);
bool ValidateTexBufferRangeBase(const Context *context,
                                TextureType target,
                                GLenum internalformat,
                                BufferID bufferPacked,
                                GLintptr offset,
                                GLsizeiptr size);

// GL_EXT_separate_shader_objects
bool ValidateActiveShaderProgramBase(const Context *context,
                                     ProgramPipelineID pipelinePacked,
                                     ShaderProgramID programPacked);
bool ValidateBindProgramPipelineBase(const Context *context, ProgramPipelineID pipelinePacked);
bool ValidateCreateShaderProgramvBase(const Context *context,
                                      ShaderType typePacked,
                                      GLsizei count,
                                      const GLchar **strings);
bool ValidateDeleteProgramPipelinesBase(const Context *context,
                                        GLsizei n,
                                        const ProgramPipelineID *pipelinesPacked);
bool ValidateGenProgramPipelinesBase(const Context *context,
                                     GLsizei n,
                                     const ProgramPipelineID *pipelinesPacked);
bool ValidateGetProgramPipelineInfoLogBase(const Context *context,
                                           ProgramPipelineID pipelinePacked,
                                           GLsizei bufSize,
                                           const GLsizei *length,
                                           const GLchar *infoLog);
bool ValidateGetProgramPipelineivBase(const Context *context,
                                      ProgramPipelineID pipelinePacked,
                                      GLenum pname,
                                      const GLint *params);
bool ValidateIsProgramPipelineBase(const Context *context, ProgramPipelineID pipelinePacked);
bool ValidateProgramParameteriBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   GLenum pname,
                                   GLint value);
bool ValidateProgramUniform1fBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLfloat v0);
bool ValidateProgramUniform1fvBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLfloat *value);
bool ValidateProgramUniform1iBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLint v0);
bool ValidateProgramUniform1ivBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLint *value);
bool ValidateProgramUniform1uiBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLuint v0);
bool ValidateProgramUniform1uivBase(const Context *context,
                                    ShaderProgramID programPacked,
                                    UniformLocation locationPacked,
                                    GLsizei count,
                                    const GLuint *value);
bool ValidateProgramUniform2fBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLfloat v0,
                                  GLfloat v1);
bool ValidateProgramUniform2fvBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLfloat *value);
bool ValidateProgramUniform2iBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLint v0,
                                  GLint v1);
bool ValidateProgramUniform2ivBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLint *value);
bool ValidateProgramUniform2uiBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLuint v0,
                                   GLuint v1);
bool ValidateProgramUniform2uivBase(const Context *context,
                                    ShaderProgramID programPacked,
                                    UniformLocation locationPacked,
                                    GLsizei count,
                                    const GLuint *value);
bool ValidateProgramUniform3fBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLfloat v0,
                                  GLfloat v1,
                                  GLfloat v2);
bool ValidateProgramUniform3fvBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLfloat *value);
bool ValidateProgramUniform3iBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLint v0,
                                  GLint v1,
                                  GLint v2);
bool ValidateProgramUniform3ivBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLint *value);
bool ValidateProgramUniform3uiBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLuint v0,
                                   GLuint v1,
                                   GLuint v2);
bool ValidateProgramUniform3uivBase(const Context *context,
                                    ShaderProgramID programPacked,
                                    UniformLocation locationPacked,
                                    GLsizei count,
                                    const GLuint *value);
bool ValidateProgramUniform4fBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLfloat v0,
                                  GLfloat v1,
                                  GLfloat v2,
                                  GLfloat v3);
bool ValidateProgramUniform4fvBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLfloat *value);
bool ValidateProgramUniform4iBase(const Context *context,
                                  ShaderProgramID programPacked,
                                  UniformLocation locationPacked,
                                  GLint v0,
                                  GLint v1,
                                  GLint v2,
                                  GLint v3);
bool ValidateProgramUniform4ivBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLsizei count,
                                   const GLint *value);
bool ValidateProgramUniform4uiBase(const Context *context,
                                   ShaderProgramID programPacked,
                                   UniformLocation locationPacked,
                                   GLuint v0,
                                   GLuint v1,
                                   GLuint v2,
                                   GLuint v3);
bool ValidateProgramUniform4uivBase(const Context *context,
                                    ShaderProgramID programPacked,
                                    UniformLocation locationPacked,
                                    GLsizei count,
                                    const GLuint *value);
bool ValidateProgramUniformMatrix2fvBase(const Context *context,
                                         ShaderProgramID programPacked,
                                         UniformLocation locationPacked,
                                         GLsizei count,
                                         GLboolean transpose,
                                         const GLfloat *value);
bool ValidateProgramUniformMatrix2x3fvBase(const Context *context,
                                           ShaderProgramID programPacked,
                                           UniformLocation locationPacked,
                                           GLsizei count,
                                           GLboolean transpose,
                                           const GLfloat *value);
bool ValidateProgramUniformMatrix2x4fvBase(const Context *context,
                                           ShaderProgramID programPacked,
                                           UniformLocation locationPacked,
                                           GLsizei count,
                                           GLboolean transpose,
                                           const GLfloat *value);
bool ValidateProgramUniformMatrix3fvBase(const Context *context,
                                         ShaderProgramID programPacked,
                                         UniformLocation locationPacked,
                                         GLsizei count,
                                         GLboolean transpose,
                                         const GLfloat *value);
bool ValidateProgramUniformMatrix3x2fvBase(const Context *context,
                                           ShaderProgramID programPacked,
                                           UniformLocation locationPacked,
                                           GLsizei count,
                                           GLboolean transpose,
                                           const GLfloat *value);
bool ValidateProgramUniformMatrix3x4fvBase(const Context *context,
                                           ShaderProgramID programPacked,
                                           UniformLocation locationPacked,
                                           GLsizei count,
                                           GLboolean transpose,
                                           const GLfloat *value);
bool ValidateProgramUniformMatrix4fvBase(const Context *context,
                                         ShaderProgramID programPacked,
                                         UniformLocation locationPacked,
                                         GLsizei count,
                                         GLboolean transpose,
                                         const GLfloat *value);
bool ValidateProgramUniformMatrix4x2fvBase(const Context *context,
                                           ShaderProgramID programPacked,
                                           UniformLocation locationPacked,
                                           GLsizei count,
                                           GLboolean transpose,
                                           const GLfloat *value);
bool ValidateProgramUniformMatrix4x3fvBase(const Context *context,
                                           ShaderProgramID programPacked,
                                           UniformLocation locationPacked,
                                           GLsizei count,
                                           GLboolean transpose,
                                           const GLfloat *value);
bool ValidateUseProgramStagesBase(const Context *context,
                                  ProgramPipelineID pipelinePacked,
                                  GLbitfield stages,
                                  ShaderProgramID programPacked);
bool ValidateValidateProgramPipelineBase(const Context *context, ProgramPipelineID pipelinePacked);
}  // namespace gl

#endif  // LIBANGLE_VALIDATION_ES31_H_