1*8975f5c5SAndroid Build Coastguard Worker // 2*8975f5c5SAndroid Build Coastguard Worker // Copyright 2016 The ANGLE Project Authors. All rights reserved. 3*8975f5c5SAndroid Build Coastguard Worker // Use of this source code is governed by a BSD-style license that can be 4*8975f5c5SAndroid Build Coastguard Worker // found in the LICENSE file. 5*8975f5c5SAndroid Build Coastguard Worker // 6*8975f5c5SAndroid Build Coastguard Worker 7*8975f5c5SAndroid Build Coastguard Worker // queryutils.h: Utilities for querying values from GL objects 8*8975f5c5SAndroid Build Coastguard Worker 9*8975f5c5SAndroid Build Coastguard Worker #ifndef LIBANGLE_QUERYUTILS_H_ 10*8975f5c5SAndroid Build Coastguard Worker #define LIBANGLE_QUERYUTILS_H_ 11*8975f5c5SAndroid Build Coastguard Worker 12*8975f5c5SAndroid Build Coastguard Worker #include "angle_gl.h" 13*8975f5c5SAndroid Build Coastguard Worker #include "common/PackedEnums.h" 14*8975f5c5SAndroid Build Coastguard Worker #include "common/angleutils.h" 15*8975f5c5SAndroid Build Coastguard Worker #include "libANGLE/Error.h" 16*8975f5c5SAndroid Build Coastguard Worker 17*8975f5c5SAndroid Build Coastguard Worker #include <EGL/egl.h> 18*8975f5c5SAndroid Build Coastguard Worker 19*8975f5c5SAndroid Build Coastguard Worker namespace gl 20*8975f5c5SAndroid Build Coastguard Worker { 21*8975f5c5SAndroid Build Coastguard Worker class Buffer; 22*8975f5c5SAndroid Build Coastguard Worker class Context; 23*8975f5c5SAndroid Build Coastguard Worker class Sync; 24*8975f5c5SAndroid Build Coastguard Worker class Framebuffer; 25*8975f5c5SAndroid Build Coastguard Worker class GLES1State; 26*8975f5c5SAndroid Build Coastguard Worker class Program; 27*8975f5c5SAndroid Build Coastguard Worker class Renderbuffer; 28*8975f5c5SAndroid Build Coastguard Worker class Sampler; 29*8975f5c5SAndroid Build Coastguard Worker class Shader; 30*8975f5c5SAndroid Build Coastguard Worker class State; 31*8975f5c5SAndroid Build Coastguard Worker class Texture; 32*8975f5c5SAndroid Build Coastguard Worker struct TextureCaps; 33*8975f5c5SAndroid Build Coastguard Worker struct UniformBlock; 34*8975f5c5SAndroid Build Coastguard Worker struct VertexAttribute; 35*8975f5c5SAndroid Build Coastguard Worker class VertexBinding; 36*8975f5c5SAndroid Build Coastguard Worker struct VertexAttribCurrentValueData; 37*8975f5c5SAndroid Build Coastguard Worker 38*8975f5c5SAndroid Build Coastguard Worker void QueryFramebufferAttachmentParameteriv(const Context *context, 39*8975f5c5SAndroid Build Coastguard Worker const Framebuffer *framebuffer, 40*8975f5c5SAndroid Build Coastguard Worker GLenum attachment, 41*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 42*8975f5c5SAndroid Build Coastguard Worker GLint *params); 43*8975f5c5SAndroid Build Coastguard Worker void QueryBufferParameteriv(const Buffer *buffer, GLenum pname, GLint *params); 44*8975f5c5SAndroid Build Coastguard Worker void QueryBufferParameteri64v(const Buffer *buffer, GLenum pname, GLint64 *params); 45*8975f5c5SAndroid Build Coastguard Worker void QueryBufferPointerv(const Buffer *buffer, GLenum pname, void **params); 46*8975f5c5SAndroid Build Coastguard Worker void QueryProgramiv(Context *context, Program *program, GLenum pname, GLint *params); 47*8975f5c5SAndroid Build Coastguard Worker void QueryRenderbufferiv(const Context *context, 48*8975f5c5SAndroid Build Coastguard Worker const Renderbuffer *renderbuffer, 49*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 50*8975f5c5SAndroid Build Coastguard Worker GLint *params); 51*8975f5c5SAndroid Build Coastguard Worker void QueryShaderiv(const Context *context, Shader *shader, GLenum pname, GLint *params); 52*8975f5c5SAndroid Build Coastguard Worker void QueryTexLevelParameterfv(const Texture *texture, 53*8975f5c5SAndroid Build Coastguard Worker TextureTarget target, 54*8975f5c5SAndroid Build Coastguard Worker GLint level, 55*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 56*8975f5c5SAndroid Build Coastguard Worker GLfloat *params); 57*8975f5c5SAndroid Build Coastguard Worker void QueryTexLevelParameteriv(const Texture *texture, 58*8975f5c5SAndroid Build Coastguard Worker TextureTarget target, 59*8975f5c5SAndroid Build Coastguard Worker GLint level, 60*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 61*8975f5c5SAndroid Build Coastguard Worker GLint *params); 62*8975f5c5SAndroid Build Coastguard Worker void QueryTexParameterfv(const Context *context, 63*8975f5c5SAndroid Build Coastguard Worker const Texture *texture, 64*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 65*8975f5c5SAndroid Build Coastguard Worker GLfloat *params); 66*8975f5c5SAndroid Build Coastguard Worker void QueryTexParameterxv(const Context *context, 67*8975f5c5SAndroid Build Coastguard Worker const Texture *texture, 68*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 69*8975f5c5SAndroid Build Coastguard Worker GLfixed *params); 70*8975f5c5SAndroid Build Coastguard Worker void QueryTexParameteriv(const Context *context, 71*8975f5c5SAndroid Build Coastguard Worker const Texture *texture, 72*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 73*8975f5c5SAndroid Build Coastguard Worker GLint *params); 74*8975f5c5SAndroid Build Coastguard Worker void QueryTexParameterIiv(const Context *context, 75*8975f5c5SAndroid Build Coastguard Worker const Texture *texture, 76*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 77*8975f5c5SAndroid Build Coastguard Worker GLint *params); 78*8975f5c5SAndroid Build Coastguard Worker void QueryTexParameterIuiv(const Context *context, 79*8975f5c5SAndroid Build Coastguard Worker const Texture *texture, 80*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 81*8975f5c5SAndroid Build Coastguard Worker GLuint *params); 82*8975f5c5SAndroid Build Coastguard Worker void QuerySamplerParameterfv(const Sampler *sampler, GLenum pname, GLfloat *params); 83*8975f5c5SAndroid Build Coastguard Worker void QuerySamplerParameteriv(const Sampler *sampler, GLenum pname, GLint *params); 84*8975f5c5SAndroid Build Coastguard Worker void QuerySamplerParameterIiv(const Sampler *sampler, GLenum pname, GLint *params); 85*8975f5c5SAndroid Build Coastguard Worker void QuerySamplerParameterIuiv(const Sampler *sampler, GLenum pname, GLuint *params); 86*8975f5c5SAndroid Build Coastguard Worker 87*8975f5c5SAndroid Build Coastguard Worker // Warning: you should ensure binding really matches attrib.bindingIndex before using the following 88*8975f5c5SAndroid Build Coastguard Worker // functions. 89*8975f5c5SAndroid Build Coastguard Worker void QueryVertexAttribfv(const VertexAttribute &attrib, 90*8975f5c5SAndroid Build Coastguard Worker const VertexBinding &binding, 91*8975f5c5SAndroid Build Coastguard Worker const VertexAttribCurrentValueData ¤tValueData, 92*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 93*8975f5c5SAndroid Build Coastguard Worker GLfloat *params); 94*8975f5c5SAndroid Build Coastguard Worker 95*8975f5c5SAndroid Build Coastguard Worker void QueryVertexAttribiv(const VertexAttribute &attrib, 96*8975f5c5SAndroid Build Coastguard Worker const VertexBinding &binding, 97*8975f5c5SAndroid Build Coastguard Worker const VertexAttribCurrentValueData ¤tValueData, 98*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 99*8975f5c5SAndroid Build Coastguard Worker GLint *params); 100*8975f5c5SAndroid Build Coastguard Worker 101*8975f5c5SAndroid Build Coastguard Worker void QueryVertexAttribPointerv(const VertexAttribute &attrib, GLenum pname, void **pointer); 102*8975f5c5SAndroid Build Coastguard Worker 103*8975f5c5SAndroid Build Coastguard Worker void QueryVertexAttribIiv(const VertexAttribute &attrib, 104*8975f5c5SAndroid Build Coastguard Worker const VertexBinding &binding, 105*8975f5c5SAndroid Build Coastguard Worker const VertexAttribCurrentValueData ¤tValueData, 106*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 107*8975f5c5SAndroid Build Coastguard Worker GLint *params); 108*8975f5c5SAndroid Build Coastguard Worker 109*8975f5c5SAndroid Build Coastguard Worker void QueryVertexAttribIuiv(const VertexAttribute &attrib, 110*8975f5c5SAndroid Build Coastguard Worker const VertexBinding &binding, 111*8975f5c5SAndroid Build Coastguard Worker const VertexAttribCurrentValueData ¤tValueData, 112*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 113*8975f5c5SAndroid Build Coastguard Worker GLuint *params); 114*8975f5c5SAndroid Build Coastguard Worker 115*8975f5c5SAndroid Build Coastguard Worker void QueryActiveUniformBlockiv(const Program *program, 116*8975f5c5SAndroid Build Coastguard Worker UniformBlockIndex uniformBlockIndex, 117*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 118*8975f5c5SAndroid Build Coastguard Worker GLint *params); 119*8975f5c5SAndroid Build Coastguard Worker 120*8975f5c5SAndroid Build Coastguard Worker void QueryInternalFormativ(const Context *context, 121*8975f5c5SAndroid Build Coastguard Worker const Texture *texture, 122*8975f5c5SAndroid Build Coastguard Worker GLenum internalformat, 123*8975f5c5SAndroid Build Coastguard Worker const TextureCaps &format, 124*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 125*8975f5c5SAndroid Build Coastguard Worker GLsizei bufSize, 126*8975f5c5SAndroid Build Coastguard Worker GLint *params); 127*8975f5c5SAndroid Build Coastguard Worker 128*8975f5c5SAndroid Build Coastguard Worker void QueryFramebufferParameteriv(const Framebuffer *framebuffer, GLenum pname, GLint *params); 129*8975f5c5SAndroid Build Coastguard Worker 130*8975f5c5SAndroid Build Coastguard Worker angle::Result QuerySynciv(const Context *context, 131*8975f5c5SAndroid Build Coastguard Worker const Sync *sync, 132*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 133*8975f5c5SAndroid Build Coastguard Worker GLsizei bufSize, 134*8975f5c5SAndroid Build Coastguard Worker GLsizei *length, 135*8975f5c5SAndroid Build Coastguard Worker GLint *values); 136*8975f5c5SAndroid Build Coastguard Worker 137*8975f5c5SAndroid Build Coastguard Worker void SetTexParameterf(Context *context, Texture *texture, GLenum pname, GLfloat param); 138*8975f5c5SAndroid Build Coastguard Worker void SetTexParameterfv(Context *context, Texture *texture, GLenum pname, const GLfloat *params); 139*8975f5c5SAndroid Build Coastguard Worker void SetTexParameteri(Context *context, Texture *texture, GLenum pname, GLint param); 140*8975f5c5SAndroid Build Coastguard Worker void SetTexParameteriv(Context *context, Texture *texture, GLenum pname, const GLint *params); 141*8975f5c5SAndroid Build Coastguard Worker void SetTexParameterIiv(Context *context, Texture *texture, GLenum pname, const GLint *params); 142*8975f5c5SAndroid Build Coastguard Worker void SetTexParameterIuiv(Context *context, Texture *texture, GLenum pname, const GLuint *params); 143*8975f5c5SAndroid Build Coastguard Worker void SetTexParameterx(Context *context, Texture *texture, GLenum pname, GLfixed param); 144*8975f5c5SAndroid Build Coastguard Worker void SetTexParameterxv(Context *context, Texture *texture, GLenum pname, const GLfixed *params); 145*8975f5c5SAndroid Build Coastguard Worker 146*8975f5c5SAndroid Build Coastguard Worker void SetSamplerParameterf(Context *context, Sampler *sampler, GLenum pname, GLfloat param); 147*8975f5c5SAndroid Build Coastguard Worker void SetSamplerParameterfv(Context *context, Sampler *sampler, GLenum pname, const GLfloat *params); 148*8975f5c5SAndroid Build Coastguard Worker void SetSamplerParameteri(Context *context, Sampler *sampler, GLenum pname, GLint param); 149*8975f5c5SAndroid Build Coastguard Worker void SetSamplerParameteriv(Context *context, Sampler *sampler, GLenum pname, const GLint *params); 150*8975f5c5SAndroid Build Coastguard Worker void SetSamplerParameterIiv(Context *context, Sampler *sampler, GLenum pname, const GLint *params); 151*8975f5c5SAndroid Build Coastguard Worker void SetSamplerParameterIuiv(Context *context, 152*8975f5c5SAndroid Build Coastguard Worker Sampler *sampler, 153*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 154*8975f5c5SAndroid Build Coastguard Worker const GLuint *params); 155*8975f5c5SAndroid Build Coastguard Worker 156*8975f5c5SAndroid Build Coastguard Worker void SetFramebufferParameteri(const Context *context, 157*8975f5c5SAndroid Build Coastguard Worker Framebuffer *framebuffer, 158*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 159*8975f5c5SAndroid Build Coastguard Worker GLint param); 160*8975f5c5SAndroid Build Coastguard Worker 161*8975f5c5SAndroid Build Coastguard Worker void SetProgramParameteri(const Context *context, Program *program, GLenum pname, GLint value); 162*8975f5c5SAndroid Build Coastguard Worker 163*8975f5c5SAndroid Build Coastguard Worker GLint GetUniformResourceProperty(const Program *program, GLuint index, const GLenum prop); 164*8975f5c5SAndroid Build Coastguard Worker 165*8975f5c5SAndroid Build Coastguard Worker GLuint QueryProgramResourceIndex(const Program *program, 166*8975f5c5SAndroid Build Coastguard Worker GLenum programInterface, 167*8975f5c5SAndroid Build Coastguard Worker const GLchar *name); 168*8975f5c5SAndroid Build Coastguard Worker 169*8975f5c5SAndroid Build Coastguard Worker void QueryProgramResourceName(const Context *context, 170*8975f5c5SAndroid Build Coastguard Worker const Program *program, 171*8975f5c5SAndroid Build Coastguard Worker GLenum programInterface, 172*8975f5c5SAndroid Build Coastguard Worker GLuint index, 173*8975f5c5SAndroid Build Coastguard Worker GLsizei bufSize, 174*8975f5c5SAndroid Build Coastguard Worker GLsizei *length, 175*8975f5c5SAndroid Build Coastguard Worker GLchar *name); 176*8975f5c5SAndroid Build Coastguard Worker 177*8975f5c5SAndroid Build Coastguard Worker GLint QueryProgramResourceLocation(const Program *program, 178*8975f5c5SAndroid Build Coastguard Worker GLenum programInterface, 179*8975f5c5SAndroid Build Coastguard Worker const GLchar *name); 180*8975f5c5SAndroid Build Coastguard Worker void QueryProgramResourceiv(const Program *program, 181*8975f5c5SAndroid Build Coastguard Worker GLenum programInterface, 182*8975f5c5SAndroid Build Coastguard Worker UniformBlockIndex index, 183*8975f5c5SAndroid Build Coastguard Worker GLsizei propCount, 184*8975f5c5SAndroid Build Coastguard Worker const GLenum *props, 185*8975f5c5SAndroid Build Coastguard Worker GLsizei bufSize, 186*8975f5c5SAndroid Build Coastguard Worker GLsizei *length, 187*8975f5c5SAndroid Build Coastguard Worker GLint *params); 188*8975f5c5SAndroid Build Coastguard Worker 189*8975f5c5SAndroid Build Coastguard Worker void QueryProgramInterfaceiv(const Program *program, 190*8975f5c5SAndroid Build Coastguard Worker GLenum programInterface, 191*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 192*8975f5c5SAndroid Build Coastguard Worker GLint *params); 193*8975f5c5SAndroid Build Coastguard Worker 194*8975f5c5SAndroid Build Coastguard Worker angle::Result SetMemoryObjectParameteriv(const Context *context, 195*8975f5c5SAndroid Build Coastguard Worker MemoryObject *memoryObject, 196*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 197*8975f5c5SAndroid Build Coastguard Worker const GLint *params); 198*8975f5c5SAndroid Build Coastguard Worker void QueryMemoryObjectParameteriv(const MemoryObject *memoryObject, GLenum pname, GLint *params); 199*8975f5c5SAndroid Build Coastguard Worker 200*8975f5c5SAndroid Build Coastguard Worker // GLES1 emulation 201*8975f5c5SAndroid Build Coastguard Worker 202*8975f5c5SAndroid Build Coastguard Worker ClientVertexArrayType ParamToVertexArrayType(GLenum param); 203*8975f5c5SAndroid Build Coastguard Worker 204*8975f5c5SAndroid Build Coastguard Worker void SetLightParameters(GLES1State *state, 205*8975f5c5SAndroid Build Coastguard Worker GLenum light, 206*8975f5c5SAndroid Build Coastguard Worker LightParameter pname, 207*8975f5c5SAndroid Build Coastguard Worker const GLfloat *params); 208*8975f5c5SAndroid Build Coastguard Worker void GetLightParameters(const GLES1State *state, 209*8975f5c5SAndroid Build Coastguard Worker GLenum light, 210*8975f5c5SAndroid Build Coastguard Worker LightParameter pname, 211*8975f5c5SAndroid Build Coastguard Worker GLfloat *params); 212*8975f5c5SAndroid Build Coastguard Worker 213*8975f5c5SAndroid Build Coastguard Worker void SetLightModelParameters(GLES1State *state, GLenum pname, const GLfloat *params); 214*8975f5c5SAndroid Build Coastguard Worker void GetLightModelParameters(const GLES1State *state, GLenum pname, GLfloat *params); 215*8975f5c5SAndroid Build Coastguard Worker bool IsLightModelTwoSided(const GLES1State *state); 216*8975f5c5SAndroid Build Coastguard Worker 217*8975f5c5SAndroid Build Coastguard Worker void SetMaterialParameters(GLES1State *state, 218*8975f5c5SAndroid Build Coastguard Worker GLenum face, 219*8975f5c5SAndroid Build Coastguard Worker MaterialParameter pname, 220*8975f5c5SAndroid Build Coastguard Worker const GLfloat *params); 221*8975f5c5SAndroid Build Coastguard Worker void GetMaterialParameters(const GLES1State *state, 222*8975f5c5SAndroid Build Coastguard Worker GLenum face, 223*8975f5c5SAndroid Build Coastguard Worker MaterialParameter pname, 224*8975f5c5SAndroid Build Coastguard Worker GLfloat *params); 225*8975f5c5SAndroid Build Coastguard Worker 226*8975f5c5SAndroid Build Coastguard Worker unsigned int GetLightModelParameterCount(GLenum pname); 227*8975f5c5SAndroid Build Coastguard Worker unsigned int GetLightParameterCount(LightParameter pname); 228*8975f5c5SAndroid Build Coastguard Worker unsigned int GetMaterialParameterCount(MaterialParameter pname); 229*8975f5c5SAndroid Build Coastguard Worker 230*8975f5c5SAndroid Build Coastguard Worker void SetFogParameters(GLES1State *state, GLenum pname, const GLfloat *params); 231*8975f5c5SAndroid Build Coastguard Worker void GetFogParameters(const GLES1State *state, GLenum pname, GLfloat *params); 232*8975f5c5SAndroid Build Coastguard Worker unsigned int GetFogParameterCount(GLenum pname); 233*8975f5c5SAndroid Build Coastguard Worker 234*8975f5c5SAndroid Build Coastguard Worker unsigned int GetTextureEnvParameterCount(TextureEnvParameter pname); 235*8975f5c5SAndroid Build Coastguard Worker 236*8975f5c5SAndroid Build Coastguard Worker void ConvertTextureEnvFromInt(TextureEnvParameter pname, const GLint *input, GLfloat *output); 237*8975f5c5SAndroid Build Coastguard Worker void ConvertTextureEnvFromFixed(TextureEnvParameter pname, const GLfixed *input, GLfloat *output); 238*8975f5c5SAndroid Build Coastguard Worker void ConvertTextureEnvToInt(TextureEnvParameter pname, const GLfloat *input, GLint *output); 239*8975f5c5SAndroid Build Coastguard Worker void ConvertTextureEnvToFixed(TextureEnvParameter pname, const GLfloat *input, GLfixed *output); 240*8975f5c5SAndroid Build Coastguard Worker 241*8975f5c5SAndroid Build Coastguard Worker void SetTextureEnv(unsigned int unit, 242*8975f5c5SAndroid Build Coastguard Worker GLES1State *state, 243*8975f5c5SAndroid Build Coastguard Worker TextureEnvTarget target, 244*8975f5c5SAndroid Build Coastguard Worker TextureEnvParameter pname, 245*8975f5c5SAndroid Build Coastguard Worker const GLfloat *params); 246*8975f5c5SAndroid Build Coastguard Worker void GetTextureEnv(unsigned int unit, 247*8975f5c5SAndroid Build Coastguard Worker const GLES1State *state, 248*8975f5c5SAndroid Build Coastguard Worker TextureEnvTarget target, 249*8975f5c5SAndroid Build Coastguard Worker TextureEnvParameter pname, 250*8975f5c5SAndroid Build Coastguard Worker GLfloat *params); 251*8975f5c5SAndroid Build Coastguard Worker 252*8975f5c5SAndroid Build Coastguard Worker unsigned int GetPointParameterCount(PointParameter pname); 253*8975f5c5SAndroid Build Coastguard Worker 254*8975f5c5SAndroid Build Coastguard Worker void SetPointParameter(GLES1State *state, PointParameter pname, const GLfloat *params); 255*8975f5c5SAndroid Build Coastguard Worker void GetPointParameter(const GLES1State *state, PointParameter pname, GLfloat *params); 256*8975f5c5SAndroid Build Coastguard Worker 257*8975f5c5SAndroid Build Coastguard Worker void SetPointSize(GLES1State *state, GLfloat size); 258*8975f5c5SAndroid Build Coastguard Worker void GetPointSize(const GLES1State *state, GLfloat *sizeOut); 259*8975f5c5SAndroid Build Coastguard Worker 260*8975f5c5SAndroid Build Coastguard Worker unsigned int GetTexParameterCount(GLenum pname); 261*8975f5c5SAndroid Build Coastguard Worker 262*8975f5c5SAndroid Build Coastguard Worker bool GetQueryParameterInfo(const State &glState, 263*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 264*8975f5c5SAndroid Build Coastguard Worker GLenum *type, 265*8975f5c5SAndroid Build Coastguard Worker unsigned int *numParams); 266*8975f5c5SAndroid Build Coastguard Worker 267*8975f5c5SAndroid Build Coastguard Worker bool GetIndexedQueryParameterInfo(const State &glState, 268*8975f5c5SAndroid Build Coastguard Worker GLenum target, 269*8975f5c5SAndroid Build Coastguard Worker GLenum *type, 270*8975f5c5SAndroid Build Coastguard Worker unsigned int *numParams); 271*8975f5c5SAndroid Build Coastguard Worker 272*8975f5c5SAndroid Build Coastguard Worker void QueryProgramPipelineiv(const Context *context, 273*8975f5c5SAndroid Build Coastguard Worker ProgramPipeline *programPipeline, 274*8975f5c5SAndroid Build Coastguard Worker GLenum pname, 275*8975f5c5SAndroid Build Coastguard Worker GLint *params); 276*8975f5c5SAndroid Build Coastguard Worker } // namespace gl 277*8975f5c5SAndroid Build Coastguard Worker 278*8975f5c5SAndroid Build Coastguard Worker namespace egl 279*8975f5c5SAndroid Build Coastguard Worker { 280*8975f5c5SAndroid Build Coastguard Worker struct Config; 281*8975f5c5SAndroid Build Coastguard Worker class Display; 282*8975f5c5SAndroid Build Coastguard Worker class Surface; 283*8975f5c5SAndroid Build Coastguard Worker class Sync; 284*8975f5c5SAndroid Build Coastguard Worker 285*8975f5c5SAndroid Build Coastguard Worker void QueryConfigAttrib(const Config *config, EGLint attribute, EGLint *value); 286*8975f5c5SAndroid Build Coastguard Worker 287*8975f5c5SAndroid Build Coastguard Worker void QueryContextAttrib(const gl::Context *context, EGLint attribute, EGLint *value); 288*8975f5c5SAndroid Build Coastguard Worker 289*8975f5c5SAndroid Build Coastguard Worker egl::Error QuerySurfaceAttrib(const Display *display, 290*8975f5c5SAndroid Build Coastguard Worker const gl::Context *context, 291*8975f5c5SAndroid Build Coastguard Worker Surface *surface, 292*8975f5c5SAndroid Build Coastguard Worker EGLint attribute, 293*8975f5c5SAndroid Build Coastguard Worker EGLint *value); 294*8975f5c5SAndroid Build Coastguard Worker egl::Error SetSurfaceAttrib(Surface *surface, EGLint attribute, EGLint value); 295*8975f5c5SAndroid Build Coastguard Worker Error GetSyncAttrib(Display *display, SyncID sync, EGLint attribute, EGLint *value); 296*8975f5c5SAndroid Build Coastguard Worker egl::Error QuerySurfaceAttrib64KHR(const Display *display, 297*8975f5c5SAndroid Build Coastguard Worker const gl::Context *context, 298*8975f5c5SAndroid Build Coastguard Worker Surface *surface, 299*8975f5c5SAndroid Build Coastguard Worker EGLint attribute, 300*8975f5c5SAndroid Build Coastguard Worker EGLAttribKHR *value); 301*8975f5c5SAndroid Build Coastguard Worker 302*8975f5c5SAndroid Build Coastguard Worker } // namespace egl 303*8975f5c5SAndroid Build Coastguard Worker 304*8975f5c5SAndroid Build Coastguard Worker #endif // LIBANGLE_QUERYUTILS_H_ 305