primitive: Adds convenience constructors
authorRobert Bragg <robert@linux.intel.com>
Tue, 12 Oct 2010 14:48:31 +0000 (15:48 +0100)
committerRobert Bragg <robert@linux.intel.com>
Wed, 3 Nov 2010 18:04:31 +0000 (18:04 +0000)
commit2d58d3f1b6b728e3cca6e1bbeabd19fc03de05df
tree5757abbd5176f82e97d416fe3e8ea31a14bb0ab1
parent0cd077dc7efc5ed3cb982ffa6c7f4f5276867338
primitive: Adds convenience constructors

This adds convenience primitive constructors named like:
  cogl_primitive_new_p3 or
  cogl_primitive_new_p3c4 or
  cogl_primitive_new_p3t2c4
where the letters correspond to the interleved vertex attributes layouts
such as CoglP3Vertex which is a struct with 3 float x,y,z members for
the [p]osition, or CoglP3T2C4Vertex which is a struct with 3 float x,y,z
members for the [p]osition, 2 float s,t members for the [t]exture
coordinates and 4 unsigned byte r,g,b,a members for the [c]olor.

The hope is that people will find these convenient enough to replace
cogl_polygon.
clutter/cogl/cogl/cogl-primitive.c
clutter/cogl/cogl/cogl-primitive.h