1
0
Fork 0
mutter-performance-source/cogl/cogl-pipeline-progend-glsl-private.h
Neil Roberts e38e9e0355 cogl-vertex-attribute: Use glVertexAttribPointer on GLES2
When the GLES2 wrapper is removed we can't use the fixed function API
such as glColorPointer to set the builtin attributes. Instead the GLSL
progend now maintains a cache of attribute locations that are queried
with glGetAttribLocation. The code that previously maintained a cache
of the enabled texture coord arrays has been modified to also cache
the enabled vertex attributes under GLES2. The vertex attribute API is
now the only place that is using this cache so it has been moved into
cogl-vertex-attribute.c
2010-12-13 17:28:29 +00:00

54 lines
1.5 KiB
C

/*
* Cogl
*
* An object oriented GL/GLES Abstraction/Utility Layer
*
* Copyright (C) 2010 Intel Corporation.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library. If not, see
* <http://www.gnu.org/licenses/>.
*
*
*
* Authors:
* Neil Roberts <neil@linux.intel.com>
*/
#ifndef __COGL_PIPELINE_PROGEND_GLSL_PRIVATE_H
#define __COGL_PIPELINE_PROGEND_GLSL_PRIVATE_H
#include "cogl-pipeline-private.h"
#include "cogl-vertex-attribute-private.h"
extern const CoglPipelineProgend _cogl_pipeline_glsl_progend;
#ifdef HAVE_COGL_GLES2
int
_cogl_pipeline_progend_glsl_get_position_attribute (CoglPipeline *pipeline);
int
_cogl_pipeline_progend_glsl_get_color_attribute (CoglPipeline *pipeline);
int
_cogl_pipeline_progend_glsl_get_normal_attribute (CoglPipeline *pipeline);
int
_cogl_pipeline_progend_glsl_get_tex_coord_attribute (CoglPipeline *pipeline,
int unit);
#endif /* HAVE_COGL_GLES2 */
#endif /* __COGL_PIPELINE_PROGEND_GLSL_PRIVATE_H */