Hash :
bd4e756a
Author :
Date :
2020-02-17T09:49:45
Const-ify the validation layer. Enforces that the validation layers should be working pretty much read- only with the exeption of updating caches. Requires a few tricks: - updates EP code generation to add 'const' to pointer parameters - enables a kludge const_cast to enable the robust query extension - makes some members of Framebuffer mutable to work around syncState - makes 'is' queries and other methods in Context/State const Will allow us to more safely expose the no_error extension. Bug: angleproject:1280 Change-Id: Id9756757854c9e68fc096ecec8d93759fbe6b3a4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2060689 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
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 246 247 248
// GENERATED FILE - DO NOT EDIT.
// Generated by generate_entry_points.py using data from gl.xml and gl_angle_ext.xml.
//
// Copyright 2020 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.
//
// validationES1_autogen.h:
// Validation functions for the OpenGL ES 1.0 entry points.
#ifndef LIBANGLE_VALIDATION_ES1_AUTOGEN_H_
#define LIBANGLE_VALIDATION_ES1_AUTOGEN_H_
#include "common/PackedEnums.h"
namespace gl
{
class Context;
bool ValidateAlphaFunc(const Context *context, AlphaTestFunc funcPacked, GLfloat ref);
bool ValidateAlphaFuncx(const Context *context, AlphaTestFunc funcPacked, GLfixed ref);
bool ValidateClearColorx(const Context *context,
GLfixed red,
GLfixed green,
GLfixed blue,
GLfixed alpha);
bool ValidateClearDepthx(const Context *context, GLfixed depth);
bool ValidateClientActiveTexture(const Context *context, GLenum texture);
bool ValidateClipPlanef(const Context *context, GLenum p, const GLfloat *eqn);
bool ValidateClipPlanex(const Context *context, GLenum plane, const GLfixed *equation);
bool ValidateColor4f(const Context *context,
GLfloat red,
GLfloat green,
GLfloat blue,
GLfloat alpha);
bool ValidateColor4ub(const Context *context,
GLubyte red,
GLubyte green,
GLubyte blue,
GLubyte alpha);
bool ValidateColor4x(const Context *context,
GLfixed red,
GLfixed green,
GLfixed blue,
GLfixed alpha);
bool ValidateColorPointer(const Context *context,
GLint size,
VertexAttribType typePacked,
GLsizei stride,
const void *pointer);
bool ValidateDepthRangex(const Context *context, GLfixed n, GLfixed f);
bool ValidateDisableClientState(const Context *context, ClientVertexArrayType arrayPacked);
bool ValidateEnableClientState(const Context *context, ClientVertexArrayType arrayPacked);
bool ValidateFogf(const Context *context, GLenum pname, GLfloat param);
bool ValidateFogfv(const Context *context, GLenum pname, const GLfloat *params);
bool ValidateFogx(const Context *context, GLenum pname, GLfixed param);
bool ValidateFogxv(const Context *context, GLenum pname, const GLfixed *param);
bool ValidateFrustumf(const Context *context,
GLfloat l,
GLfloat r,
GLfloat b,
GLfloat t,
GLfloat n,
GLfloat f);
bool ValidateFrustumx(const Context *context,
GLfixed l,
GLfixed r,
GLfixed b,
GLfixed t,
GLfixed n,
GLfixed f);
bool ValidateGetClipPlanef(const Context *context, GLenum plane, const GLfloat *equation);
bool ValidateGetClipPlanex(const Context *context, GLenum plane, const GLfixed *equation);
bool ValidateGetFixedv(const Context *context, GLenum pname, const GLfixed *params);
bool ValidateGetLightfv(const Context *context,
GLenum light,
LightParameter pnamePacked,
const GLfloat *params);
bool ValidateGetLightxv(const Context *context,
GLenum light,
LightParameter pnamePacked,
const GLfixed *params);
bool ValidateGetMaterialfv(const Context *context,
GLenum face,
MaterialParameter pnamePacked,
const GLfloat *params);
bool ValidateGetMaterialxv(const Context *context,
GLenum face,
MaterialParameter pnamePacked,
const GLfixed *params);
bool ValidateGetTexEnvfv(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
const GLfloat *params);
bool ValidateGetTexEnviv(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
const GLint *params);
bool ValidateGetTexEnvxv(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
const GLfixed *params);
bool ValidateGetTexParameterxv(const Context *context,
TextureType targetPacked,
GLenum pname,
const GLfixed *params);
bool ValidateLightModelf(const Context *context, GLenum pname, GLfloat param);
bool ValidateLightModelfv(const Context *context, GLenum pname, const GLfloat *params);
bool ValidateLightModelx(const Context *context, GLenum pname, GLfixed param);
bool ValidateLightModelxv(const Context *context, GLenum pname, const GLfixed *param);
bool ValidateLightf(const Context *context,
GLenum light,
LightParameter pnamePacked,
GLfloat param);
bool ValidateLightfv(const Context *context,
GLenum light,
LightParameter pnamePacked,
const GLfloat *params);
bool ValidateLightx(const Context *context,
GLenum light,
LightParameter pnamePacked,
GLfixed param);
bool ValidateLightxv(const Context *context,
GLenum light,
LightParameter pnamePacked,
const GLfixed *params);
bool ValidateLineWidthx(const Context *context, GLfixed width);
bool ValidateLoadIdentity(const Context *context);
bool ValidateLoadMatrixf(const Context *context, const GLfloat *m);
bool ValidateLoadMatrixx(const Context *context, const GLfixed *m);
bool ValidateLogicOp(const Context *context, LogicalOperation opcodePacked);
bool ValidateMaterialf(const Context *context,
GLenum face,
MaterialParameter pnamePacked,
GLfloat param);
bool ValidateMaterialfv(const Context *context,
GLenum face,
MaterialParameter pnamePacked,
const GLfloat *params);
bool ValidateMaterialx(const Context *context,
GLenum face,
MaterialParameter pnamePacked,
GLfixed param);
bool ValidateMaterialxv(const Context *context,
GLenum face,
MaterialParameter pnamePacked,
const GLfixed *param);
bool ValidateMatrixMode(const Context *context, MatrixType modePacked);
bool ValidateMultMatrixf(const Context *context, const GLfloat *m);
bool ValidateMultMatrixx(const Context *context, const GLfixed *m);
bool ValidateMultiTexCoord4f(const Context *context,
GLenum target,
GLfloat s,
GLfloat t,
GLfloat r,
GLfloat q);
bool ValidateMultiTexCoord4x(const Context *context,
GLenum texture,
GLfixed s,
GLfixed t,
GLfixed r,
GLfixed q);
bool ValidateNormal3f(const Context *context, GLfloat nx, GLfloat ny, GLfloat nz);
bool ValidateNormal3x(const Context *context, GLfixed nx, GLfixed ny, GLfixed nz);
bool ValidateNormalPointer(const Context *context,
VertexAttribType typePacked,
GLsizei stride,
const void *pointer);
bool ValidateOrthof(const Context *context,
GLfloat l,
GLfloat r,
GLfloat b,
GLfloat t,
GLfloat n,
GLfloat f);
bool ValidateOrthox(const Context *context,
GLfixed l,
GLfixed r,
GLfixed b,
GLfixed t,
GLfixed n,
GLfixed f);
bool ValidatePointParameterf(const Context *context, PointParameter pnamePacked, GLfloat param);
bool ValidatePointParameterfv(const Context *context,
PointParameter pnamePacked,
const GLfloat *params);
bool ValidatePointParameterx(const Context *context, PointParameter pnamePacked, GLfixed param);
bool ValidatePointParameterxv(const Context *context,
PointParameter pnamePacked,
const GLfixed *params);
bool ValidatePointSize(const Context *context, GLfloat size);
bool ValidatePointSizex(const Context *context, GLfixed size);
bool ValidatePolygonOffsetx(const Context *context, GLfixed factor, GLfixed units);
bool ValidatePopMatrix(const Context *context);
bool ValidatePushMatrix(const Context *context);
bool ValidateRotatef(const Context *context, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
bool ValidateRotatex(const Context *context, GLfixed angle, GLfixed x, GLfixed y, GLfixed z);
bool ValidateSampleCoveragex(const Context *context, GLclampx value, GLboolean invert);
bool ValidateScalef(const Context *context, GLfloat x, GLfloat y, GLfloat z);
bool ValidateScalex(const Context *context, GLfixed x, GLfixed y, GLfixed z);
bool ValidateShadeModel(const Context *context, ShadingModel modePacked);
bool ValidateTexCoordPointer(const Context *context,
GLint size,
VertexAttribType typePacked,
GLsizei stride,
const void *pointer);
bool ValidateTexEnvf(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
GLfloat param);
bool ValidateTexEnvfv(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
const GLfloat *params);
bool ValidateTexEnvi(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
GLint param);
bool ValidateTexEnviv(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
const GLint *params);
bool ValidateTexEnvx(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
GLfixed param);
bool ValidateTexEnvxv(const Context *context,
TextureEnvTarget targetPacked,
TextureEnvParameter pnamePacked,
const GLfixed *params);
bool ValidateTexParameterx(const Context *context,
TextureType targetPacked,
GLenum pname,
GLfixed param);
bool ValidateTexParameterxv(const Context *context,
TextureType targetPacked,
GLenum pname,
const GLfixed *params);
bool ValidateTranslatef(const Context *context, GLfloat x, GLfloat y, GLfloat z);
bool ValidateTranslatex(const Context *context, GLfixed x, GLfixed y, GLfixed z);
bool ValidateVertexPointer(const Context *context,
GLint size,
VertexAttribType typePacked,
GLsizei stride,
const void *pointer);
} // namespace gl
#endif // LIBANGLE_VALIDATION_ES1_AUTOGEN_H_