2010-10-12 11:54:07 +00:00
|
|
|
/*
|
|
|
|
* Cogl
|
|
|
|
*
|
2014-02-22 01:28:54 +00:00
|
|
|
* A Low Level GPU Graphics and Utilities API
|
2010-10-12 11:54:07 +00:00
|
|
|
*
|
|
|
|
* Copyright (C) 2010 Intel Corporation.
|
|
|
|
*
|
2014-02-22 01:28:54 +00: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 11:54:07 +00:00
|
|
|
*
|
2014-02-22 01:28:54 +00:00
|
|
|
* The above copyright notice and this permission notice shall be
|
|
|
|
* included in all copies or substantial portions of the Software.
|
2010-10-12 11:54:07 +00:00
|
|
|
*
|
2014-02-22 01:28:54 +00: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 11:54:07 +00: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 15:01:41 +00:00
|
|
|
#include "cogl-attribute-buffer-private.h"
|
2011-10-25 17:45:16 +00:00
|
|
|
#include "cogl-attribute-private.h"
|
2013-07-09 22:47:29 +00:00
|
|
|
#include "cogl-framebuffer.h"
|
2010-10-12 11:54:07 +00:00
|
|
|
|
|
|
|
struct _CoglPrimitive
|
|
|
|
{
|
|
|
|
CoglObject _parent;
|
|
|
|
|
2013-01-10 14:21:04 +00:00
|
|
|
CoglIndices *indices;
|
2010-10-12 11:54:07 +00:00
|
|
|
CoglVerticesMode mode;
|
|
|
|
int first_vertex;
|
|
|
|
int n_vertices;
|
2010-10-26 17:57:33 +00:00
|
|
|
|
|
|
|
int immutable_ref;
|
2011-09-20 00:24:16 +00:00
|
|
|
|
|
|
|
CoglAttribute **attributes;
|
|
|
|
int n_attributes;
|
|
|
|
|
|
|
|
int n_embedded_attributes;
|
|
|
|
CoglAttribute *embedded_attribute;
|
2010-10-12 11:54:07 +00:00
|
|
|
};
|
|
|
|
|
2010-10-26 17:57:33 +00:00
|
|
|
CoglPrimitive *
|
|
|
|
_cogl_primitive_immutable_ref (CoglPrimitive *primitive);
|
|
|
|
|
|
|
|
void
|
|
|
|
_cogl_primitive_immutable_unref (CoglPrimitive *primitive);
|
|
|
|
|
2011-10-25 17:45:16 +00:00
|
|
|
void
|
|
|
|
_cogl_primitive_draw (CoglPrimitive *primitive,
|
2013-07-09 22:47:29 +00:00
|
|
|
CoglFramebuffer *framebuffer,
|
|
|
|
CoglPipeline *pipeline,
|
2011-10-25 17:45:16 +00:00
|
|
|
CoglDrawFlags flags);
|
|
|
|
|
2010-10-12 11:54:07 +00:00
|
|
|
#endif /* __COGL_PRIMITIVE_PRIVATE_H */
|
|
|
|
|