// 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.
//
// validationES32_autogen.h:
//   Validation functions for the OpenGL ES 3.2 entry points.

#ifndef LIBANGLE_VALIDATION_ES32_AUTOGEN_H_
#define LIBANGLE_VALIDATION_ES32_AUTOGEN_H_

#include "common/PackedEnums.h"

namespace gl
{
class Context;

bool ValidateBlendBarrier(const Context *context);
bool ValidateBlendEquationSeparatei(const Context *context,
                                    GLuint buf,
                                    GLenum modeRGB,
                                    GLenum modeAlpha);
bool ValidateBlendEquationi(const Context *context, GLuint buf, GLenum mode);
bool ValidateBlendFuncSeparatei(const Context *context,
                                GLuint buf,
                                GLenum srcRGB,
                                GLenum dstRGB,
                                GLenum srcAlpha,
                                GLenum dstAlpha);
bool ValidateBlendFunci(const Context *context, GLuint buf, GLenum src, GLenum dst);
bool ValidateColorMaski(const Context *context,
                        GLuint index,
                        GLboolean r,
                        GLboolean g,
                        GLboolean b,
                        GLboolean a);
bool ValidateCopyImageSubData(const Context *context,
                              GLuint srcName,
                              GLenum srcTarget,
                              GLint srcLevel,
                              GLint srcX,
                              GLint srcY,
                              GLint srcZ,
                              GLuint dstName,
                              GLenum dstTarget,
                              GLint dstLevel,
                              GLint dstX,
                              GLint dstY,
                              GLint dstZ,
                              GLsizei srcWidth,
                              GLsizei srcHeight,
                              GLsizei srcDepth);
bool ValidateDebugMessageCallback(const Context *context,
                                  GLDEBUGPROC callback,
                                  const void *userParam);
bool ValidateDebugMessageControl(const Context *context,
                                 GLenum source,
                                 GLenum type,
                                 GLenum severity,
                                 GLsizei count,
                                 const GLuint *ids,
                                 GLboolean enabled);
bool ValidateDebugMessageInsert(const Context *context,
                                GLenum source,
                                GLenum type,
                                GLuint id,
                                GLenum severity,
                                GLsizei length,
                                const GLchar *buf);
bool ValidateDisablei(const Context *context, GLenum target, GLuint index);
bool ValidateDrawElementsBaseVertex(const Context *context,
                                    PrimitiveMode modePacked,
                                    GLsizei count,
                                    DrawElementsType typePacked,
                                    const void *indices,
                                    GLint basevertex);
bool ValidateDrawElementsInstancedBaseVertex(const Context *context,
                                             PrimitiveMode modePacked,
                                             GLsizei count,
                                             DrawElementsType typePacked,
                                             const void *indices,
                                             GLsizei instancecount,
                                             GLint basevertex);
bool ValidateDrawRangeElementsBaseVertex(const Context *context,
                                         PrimitiveMode modePacked,
                                         GLuint start,
                                         GLuint end,
                                         GLsizei count,
                                         DrawElementsType typePacked,
                                         const void *indices,
                                         GLint basevertex);
bool ValidateEnablei(const Context *context, GLenum target, GLuint index);
bool ValidateFramebufferTexture(const Context *context,
                                GLenum target,
                                GLenum attachment,
                                TextureID texturePacked,
                                GLint level);
bool ValidateGetDebugMessageLog(const Context *context,
                                GLuint count,
                                GLsizei bufSize,
                                const GLenum *sources,
                                const GLenum *types,
                                const GLuint *ids,
                                const GLenum *severities,
                                const GLsizei *lengths,
                                const GLchar *messageLog);
bool ValidateGetGraphicsResetStatus(const Context *context);
bool ValidateGetObjectLabel(const Context *context,
                            GLenum identifier,
                            GLuint name,
                            GLsizei bufSize,
                            const GLsizei *length,
                            const GLchar *label);
bool ValidateGetObjectPtrLabel(const Context *context,
                               const void *ptr,
                               GLsizei bufSize,
                               const GLsizei *length,
                               const GLchar *label);
bool ValidateGetPointerv(const Context *context, GLenum pname, void *const *params);
bool ValidateGetSamplerParameterIiv(const Context *context,
                                    SamplerID samplerPacked,
                                    GLenum pname,
                                    const GLint *params);
bool ValidateGetSamplerParameterIuiv(const Context *context,
                                     SamplerID samplerPacked,
                                     GLenum pname,
                                     const GLuint *params);
bool ValidateGetTexParameterIiv(const Context *context,
                                TextureType targetPacked,
                                GLenum pname,
                                const GLint *params);
bool ValidateGetTexParameterIuiv(const Context *context,
                                 TextureType targetPacked,
                                 GLenum pname,
                                 const GLuint *params);
bool ValidateGetnUniformfv(const Context *context,
                           ShaderProgramID programPacked,
                           UniformLocation locationPacked,
                           GLsizei bufSize,
                           const GLfloat *params);
bool ValidateGetnUniformiv(const Context *context,
                           ShaderProgramID programPacked,
                           UniformLocation locationPacked,
                           GLsizei bufSize,
                           const GLint *params);
bool ValidateGetnUniformuiv(const Context *context,
                            ShaderProgramID programPacked,
                            UniformLocation locationPacked,
                            GLsizei bufSize,
                            const GLuint *params);
bool ValidateIsEnabledi(const Context *context, GLenum target, GLuint index);
bool ValidateMinSampleShading(const Context *context, GLfloat value);
bool ValidateObjectLabel(const Context *context,
                         GLenum identifier,
                         GLuint name,
                         GLsizei length,
                         const GLchar *label);
bool ValidateObjectPtrLabel(const Context *context,
                            const void *ptr,
                            GLsizei length,
                            const GLchar *label);
bool ValidatePatchParameteri(const Context *context, GLenum pname, GLint value);
bool ValidatePopDebugGroup(const Context *context);
bool ValidatePrimitiveBoundingBox(const Context *context,
                                  GLfloat minX,
                                  GLfloat minY,
                                  GLfloat minZ,
                                  GLfloat minW,
                                  GLfloat maxX,
                                  GLfloat maxY,
                                  GLfloat maxZ,
                                  GLfloat maxW);
bool ValidatePushDebugGroup(const Context *context,
                            GLenum source,
                            GLuint id,
                            GLsizei length,
                            const GLchar *message);
bool ValidateReadnPixels(const Context *context,
                         GLint x,
                         GLint y,
                         GLsizei width,
                         GLsizei height,
                         GLenum format,
                         GLenum type,
                         GLsizei bufSize,
                         const void *data);
bool ValidateSamplerParameterIiv(const Context *context,
                                 SamplerID samplerPacked,
                                 GLenum pname,
                                 const GLint *param);
bool ValidateSamplerParameterIuiv(const Context *context,
                                  SamplerID samplerPacked,
                                  GLenum pname,
                                  const GLuint *param);
bool ValidateTexBuffer(const Context *context,
                       GLenum target,
                       GLenum internalformat,
                       BufferID bufferPacked);
bool ValidateTexBufferRange(const Context *context,
                            GLenum target,
                            GLenum internalformat,
                            BufferID bufferPacked,
                            GLintptr offset,
                            GLsizeiptr size);
bool ValidateTexParameterIiv(const Context *context,
                             TextureType targetPacked,
                             GLenum pname,
                             const GLint *params);
bool ValidateTexParameterIuiv(const Context *context,
                              TextureType targetPacked,
                              GLenum pname,
                              const GLuint *params);
bool ValidateTexStorage3DMultisample(const Context *context,
                                     TextureType targetPacked,
                                     GLsizei samples,
                                     GLenum internalformat,
                                     GLsizei width,
                                     GLsizei height,
                                     GLsizei depth,
                                     GLboolean fixedsamplelocations);
}  // namespace gl

#endif  // LIBANGLE_VALIDATION_ES32_AUTOGEN_H_
