2010-10-12 07:54:07 -04:00
|
|
|
/*
|
|
|
|
* Cogl
|
|
|
|
*
|
2014-02-21 20:28:54 -05:00
|
|
|
* A Low Level GPU Graphics and Utilities API
|
2010-10-12 07:54:07 -04:00
|
|
|
*
|
|
|
|
* Copyright (C) 2010 Intel Corporation.
|
|
|
|
*
|
2014-02-21 20:28:54 -05:00
|
|
|
* Permission is hereby granted, free of charge, to any person
|
|
|
|
* obtaining a copy of this software and associated documentation
|
|
|
|
* files (the "Software"), to deal in the Software without
|
|
|
|
* restriction, including without limitation the rights to use, copy,
|
|
|
|
* modify, merge, publish, distribute, sublicense, and/or sell copies
|
|
|
|
* of the Software, and to permit persons to whom the Software is
|
|
|
|
* furnished to do so, subject to the following conditions:
|
2010-10-12 07:54:07 -04:00
|
|
|
*
|
2014-02-21 20:28:54 -05:00
|
|
|
* The above copyright notice and this permission notice shall be
|
|
|
|
* included in all copies or substantial portions of the Software.
|
2010-10-12 07:54:07 -04:00
|
|
|
*
|
2014-02-21 20:28:54 -05:00
|
|
|
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
|
|
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
|
|
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
|
|
* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
|
|
|
|
* BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
|
|
|
|
* ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
|
|
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
|
|
* SOFTWARE.
|
2010-10-12 07:54:07 -04:00
|
|
|
*
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Authors:
|
|
|
|
* Robert Bragg <robert@linux.intel.com>
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __COGL_PRIMITIVE_PRIVATE_H
|
|
|
|
#define __COGL_PRIMITIVE_PRIVATE_H
|
|
|
|
|
|
|
|
#include "cogl-object-private.h"
|
2011-03-02 10:01:41 -05:00
|
|
|
#include "cogl-attribute-buffer-private.h"
|
2011-10-25 13:45:16 -04:00
|
|
|
#include "cogl-attribute-private.h"
|
2013-07-09 18:47:29 -04:00
|
|
|
#include "cogl-framebuffer.h"
|
2010-10-12 07:54:07 -04:00
|
|
|
|
|
|
|
struct _CoglPrimitive
|
|
|
|
{
|
|
|
|
CoglObject _parent;
|
|
|
|
|
2013-01-10 09:21:04 -05:00
|
|
|
CoglIndices *indices;
|
2010-10-12 07:54:07 -04:00
|
|
|
CoglVerticesMode mode;
|
|
|
|
int first_vertex;
|
|
|
|
int n_vertices;
|
2010-10-26 13:57:33 -04:00
|
|
|
|
|
|
|
int immutable_ref;
|
2011-09-19 20:24:16 -04:00
|
|
|
|
|
|
|
CoglAttribute **attributes;
|
|
|
|
int n_attributes;
|
|
|
|
|
|
|
|
int n_embedded_attributes;
|
|
|
|
CoglAttribute *embedded_attribute;
|
2010-10-12 07:54:07 -04:00
|
|
|
};
|
|
|
|
|
2010-10-26 13:57:33 -04:00
|
|
|
CoglPrimitive *
|
|
|
|
_cogl_primitive_immutable_ref (CoglPrimitive *primitive);
|
|
|
|
|
|
|
|
void
|
|
|
|
_cogl_primitive_immutable_unref (CoglPrimitive *primitive);
|
|
|
|
|
2011-10-25 13:45:16 -04:00
|
|
|
void
|
|
|
|
_cogl_primitive_draw (CoglPrimitive *primitive,
|
2013-07-09 18:47:29 -04:00
|
|
|
CoglFramebuffer *framebuffer,
|
|
|
|
CoglPipeline *pipeline,
|
2011-10-25 13:45:16 -04:00
|
|
|
CoglDrawFlags flags);
|
|
|
|
|
2010-10-12 07:54:07 -04:00
|
|
|
#endif /* __COGL_PRIMITIVE_PRIVATE_H */
|
|
|
|
|