/* Generated by Cython 0.17pre on Sun Sep 30 02:53:01 2012 */

#define PY_SSIZE_T_CLEAN
#include "Python.h"
#ifndef Py_PYTHON_H
    #error Python headers needed to compile C extensions, please install development version of Python.
#elif PY_VERSION_HEX < 0x02040000
    #error Cython requires Python 2.4+.
#else
#include <stddef.h> /* For offsetof */
#ifndef offsetof
#define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
#endif

#if !defined(WIN32) && !defined(MS_WINDOWS)
  #ifndef __stdcall
    #define __stdcall
  #endif
  #ifndef __cdecl
    #define __cdecl
  #endif
  #ifndef __fastcall
    #define __fastcall
  #endif
#endif

#ifndef DL_IMPORT
  #define DL_IMPORT(t) t
#endif
#ifndef DL_EXPORT
  #define DL_EXPORT(t) t
#endif

#ifndef PY_LONG_LONG
  #define PY_LONG_LONG LONG_LONG
#endif

#ifndef Py_HUGE_VAL
  #define Py_HUGE_VAL HUGE_VAL
#endif

#ifdef PYPY_VERSION
#define CYTHON_COMPILING_IN_PYPY 1
#define CYTHON_COMPILING_IN_CPYTHON 0
#else
#define CYTHON_COMPILING_IN_PYPY 0
#define CYTHON_COMPILING_IN_CPYTHON 1
#endif

#if PY_VERSION_HEX < 0x02050000
  typedef int Py_ssize_t;
  #define PY_SSIZE_T_MAX INT_MAX
  #define PY_SSIZE_T_MIN INT_MIN
  #define PY_FORMAT_SIZE_T ""
  #define PyInt_FromSsize_t(z) PyInt_FromLong(z)
  #define PyInt_AsSsize_t(o)   __Pyx_PyInt_AsInt(o)
  #define PyNumber_Index(o)    ((PyNumber_Check(o) && !PyFloat_Check(o)) ? PyNumber_Int(o) : \
                                (PyErr_Format(PyExc_TypeError, \
                                              "expected index value, got %.200s", Py_TYPE(o)->tp_name), \
                                 (PyObject*)0))
  #define PyIndex_Check(o)     (PyNumber_Check(o) && !PyFloat_Check(o) && !PyComplex_Check(o))
  #define PyErr_WarnEx(category, message, stacklevel) PyErr_Warn(category, message)
  #define __PYX_BUILD_PY_SSIZE_T "i"
#else
  #define __PYX_BUILD_PY_SSIZE_T "n"
#endif

#if PY_VERSION_HEX < 0x02060000
  #define Py_REFCNT(ob) (((PyObject*)(ob))->ob_refcnt)
  #define Py_TYPE(ob)   (((PyObject*)(ob))->ob_type)
  #define Py_SIZE(ob)   (((PyVarObject*)(ob))->ob_size)
  #define PyVarObject_HEAD_INIT(type, size) \
          PyObject_HEAD_INIT(type) size,
  #define PyType_Modified(t)

  typedef struct {
     void *buf;
     PyObject *obj;
     Py_ssize_t len;
     Py_ssize_t itemsize;
     int readonly;
     int ndim;
     char *format;
     Py_ssize_t *shape;
     Py_ssize_t *strides;
     Py_ssize_t *suboffsets;
     void *internal;
  } Py_buffer;

  #define PyBUF_SIMPLE 0
  #define PyBUF_WRITABLE 0x0001
  #define PyBUF_FORMAT 0x0004
  #define PyBUF_ND 0x0008
  #define PyBUF_STRIDES (0x0010 | PyBUF_ND)
  #define PyBUF_C_CONTIGUOUS (0x0020 | PyBUF_STRIDES)
  #define PyBUF_F_CONTIGUOUS (0x0040 | PyBUF_STRIDES)
  #define PyBUF_ANY_CONTIGUOUS (0x0080 | PyBUF_STRIDES)
  #define PyBUF_INDIRECT (0x0100 | PyBUF_STRIDES)
  #define PyBUF_RECORDS (PyBUF_STRIDES | PyBUF_FORMAT | PyBUF_WRITABLE)
  #define PyBUF_FULL (PyBUF_INDIRECT | PyBUF_FORMAT | PyBUF_WRITABLE)

  typedef int (*getbufferproc)(PyObject *, Py_buffer *, int);
  typedef void (*releasebufferproc)(PyObject *, Py_buffer *);
#endif

#if PY_MAJOR_VERSION < 3
  #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) \
          PyCode_New(a, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
#else
  #define __Pyx_BUILTIN_MODULE_NAME "builtins"
  #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) \
          PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
#endif

#if PY_MAJOR_VERSION < 3 && PY_MINOR_VERSION < 6
  #define PyUnicode_FromString(s) PyUnicode_Decode(s, strlen(s), "UTF-8", "strict")
#endif

#if PY_MAJOR_VERSION >= 3
  #define Py_TPFLAGS_CHECKTYPES 0
  #define Py_TPFLAGS_HAVE_INDEX 0
#endif

#if (PY_VERSION_HEX < 0x02060000) || (PY_MAJOR_VERSION >= 3)
  #define Py_TPFLAGS_HAVE_NEWBUFFER 0
#endif


#if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
  #define CYTHON_PEP393_ENABLED 1
  #define __Pyx_PyUnicode_READY(op)       (likely(PyUnicode_IS_READY(op)) ? \
                                              0 : _PyUnicode_Ready((PyObject *)(op)))
  #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GET_LENGTH(u)
  #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
  #define __Pyx_PyUnicode_READ(k, d, i)   PyUnicode_READ(k, d, i)
#else
  #define CYTHON_PEP393_ENABLED 0
  #define __Pyx_PyUnicode_READY(op)       (0)
  #define __Pyx_PyUnicode_GET_LENGTH(u)   PyUnicode_GET_SIZE(u)
  #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))

  #define __Pyx_PyUnicode_READ(k, d, i)   ((k=k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
#endif

#if PY_MAJOR_VERSION >= 3
  #define PyBaseString_Type            PyUnicode_Type
  #define PyStringObject               PyUnicodeObject
  #define PyString_Type                PyUnicode_Type
  #define PyString_Check               PyUnicode_Check
  #define PyString_CheckExact          PyUnicode_CheckExact
#endif

#if PY_VERSION_HEX < 0x02060000
  #define PyBytesObject                PyStringObject
  #define PyBytes_Type                 PyString_Type
  #define PyBytes_Check                PyString_Check
  #define PyBytes_CheckExact           PyString_CheckExact
  #define PyBytes_FromString           PyString_FromString
  #define PyBytes_FromStringAndSize    PyString_FromStringAndSize
  #define PyBytes_FromFormat           PyString_FromFormat
  #define PyBytes_DecodeEscape         PyString_DecodeEscape
  #define PyBytes_AsString             PyString_AsString
  #define PyBytes_AsStringAndSize      PyString_AsStringAndSize
  #define PyBytes_Size                 PyString_Size
  #define PyBytes_AS_STRING            PyString_AS_STRING
  #define PyBytes_GET_SIZE             PyString_GET_SIZE
  #define PyBytes_Repr                 PyString_Repr
  #define PyBytes_Concat               PyString_Concat
  #define PyBytes_ConcatAndDel         PyString_ConcatAndDel
#endif

#if PY_VERSION_HEX < 0x02060000
  #define PySet_Check(obj)             PyObject_TypeCheck(obj, &PySet_Type)
  #define PyFrozenSet_Check(obj)       PyObject_TypeCheck(obj, &PyFrozenSet_Type)
#endif
#ifndef PySet_CheckExact
  #define PySet_CheckExact(obj)        (Py_TYPE(obj) == &PySet_Type)
#endif

#define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)

#if PY_MAJOR_VERSION >= 3
  #define PyIntObject                  PyLongObject
  #define PyInt_Type                   PyLong_Type
  #define PyInt_Check(op)              PyLong_Check(op)
  #define PyInt_CheckExact(op)         PyLong_CheckExact(op)
  #define PyInt_FromString             PyLong_FromString
  #define PyInt_FromUnicode            PyLong_FromUnicode
  #define PyInt_FromLong               PyLong_FromLong
  #define PyInt_FromSize_t             PyLong_FromSize_t
  #define PyInt_FromSsize_t            PyLong_FromSsize_t
  #define PyInt_AsLong                 PyLong_AsLong
  #define PyInt_AS_LONG                PyLong_AS_LONG
  #define PyInt_AsSsize_t              PyLong_AsSsize_t
  #define PyInt_AsUnsignedLongMask     PyLong_AsUnsignedLongMask
  #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
#endif

#if PY_MAJOR_VERSION >= 3
  #define PyBoolObject                 PyLongObject
#endif

#if PY_VERSION_HEX < 0x03020000
  typedef long Py_hash_t;
  #define __Pyx_PyInt_FromHash_t PyInt_FromLong
  #define __Pyx_PyInt_AsHash_t   PyInt_AsLong
#else
  #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
  #define __Pyx_PyInt_AsHash_t   PyInt_AsSsize_t
#endif

#if (PY_MAJOR_VERSION < 3) || (PY_VERSION_HEX >= 0x03010300)
  #define __Pyx_PySequence_GetSlice(obj, a, b) PySequence_GetSlice(obj, a, b)
  #define __Pyx_PySequence_SetSlice(obj, a, b, value) PySequence_SetSlice(obj, a, b, value)
  #define __Pyx_PySequence_DelSlice(obj, a, b) PySequence_DelSlice(obj, a, b)
#else
  #define __Pyx_PySequence_GetSlice(obj, a, b) (unlikely(!(obj)) ? \
        (PyErr_SetString(PyExc_SystemError, "null argument to internal routine"), (PyObject*)0) : \
        (likely((obj)->ob_type->tp_as_mapping) ? (PySequence_GetSlice(obj, a, b)) : \
            (PyErr_Format(PyExc_TypeError, "'%.200s' object is unsliceable", (obj)->ob_type->tp_name), (PyObject*)0)))
  #define __Pyx_PySequence_SetSlice(obj, a, b, value) (unlikely(!(obj)) ? \
        (PyErr_SetString(PyExc_SystemError, "null argument to internal routine"), -1) : \
        (likely((obj)->ob_type->tp_as_mapping) ? (PySequence_SetSlice(obj, a, b, value)) : \
            (PyErr_Format(PyExc_TypeError, "'%.200s' object doesn't support slice assignment", (obj)->ob_type->tp_name), -1)))
  #define __Pyx_PySequence_DelSlice(obj, a, b) (unlikely(!(obj)) ? \
        (PyErr_SetString(PyExc_SystemError, "null argument to internal routine"), -1) : \
        (likely((obj)->ob_type->tp_as_mapping) ? (PySequence_DelSlice(obj, a, b)) : \
            (PyErr_Format(PyExc_TypeError, "'%.200s' object doesn't support slice deletion", (obj)->ob_type->tp_name), -1)))
#endif

#if PY_MAJOR_VERSION >= 3
  #define PyMethod_New(func, self, klass) ((self) ? PyMethod_New(func, self) : PyInstanceMethod_New(func))
#endif

#if PY_VERSION_HEX < 0x02050000
  #define __Pyx_GetAttrString(o,n)   PyObject_GetAttrString((o),((char *)(n)))
  #define __Pyx_SetAttrString(o,n,a) PyObject_SetAttrString((o),((char *)(n)),(a))
  #define __Pyx_DelAttrString(o,n)   PyObject_DelAttrString((o),((char *)(n)))
#else
  #define __Pyx_GetAttrString(o,n)   PyObject_GetAttrString((o),(n))
  #define __Pyx_SetAttrString(o,n,a) PyObject_SetAttrString((o),(n),(a))
  #define __Pyx_DelAttrString(o,n)   PyObject_DelAttrString((o),(n))
#endif

#if PY_VERSION_HEX < 0x02050000
  #define __Pyx_NAMESTR(n) ((char *)(n))
  #define __Pyx_DOCSTR(n)  ((char *)(n))
#else
  #define __Pyx_NAMESTR(n) (n)
  #define __Pyx_DOCSTR(n)  (n)
#endif

#if PY_MAJOR_VERSION >= 3
  #define __Pyx_PyNumber_Divide(x,y)         PyNumber_TrueDivide(x,y)
  #define __Pyx_PyNumber_InPlaceDivide(x,y)  PyNumber_InPlaceTrueDivide(x,y)
#else
  #define __Pyx_PyNumber_Divide(x,y)         PyNumber_Divide(x,y)
  #define __Pyx_PyNumber_InPlaceDivide(x,y)  PyNumber_InPlaceDivide(x,y)
#endif

#ifndef __PYX_EXTERN_C
  #ifdef __cplusplus
    #define __PYX_EXTERN_C extern "C"
  #else
    #define __PYX_EXTERN_C extern
  #endif
#endif

#if defined(WIN32) || defined(MS_WINDOWS)
#define _USE_MATH_DEFINES
#endif
#include <math.h>
#define __PYX_HAVE__kivy__graphics__vertex_instructions
#define __PYX_HAVE_API__kivy__graphics__vertex_instructions
#include "math.h"
#include "stdlib.h"
#include "string.h"
#include "gl_redirect.h"
#ifdef _OPENMP
#include <omp.h>
#endif /* _OPENMP */

#ifdef PYREX_WITHOUT_ASSERTIONS
#define CYTHON_WITHOUT_ASSERTIONS
#endif


/* inline attribute */
#ifndef CYTHON_INLINE
  #if defined(__GNUC__)
    #define CYTHON_INLINE __inline__
  #elif defined(_MSC_VER)
    #define CYTHON_INLINE __inline
  #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
    #define CYTHON_INLINE inline
  #else
    #define CYTHON_INLINE
  #endif
#endif

/* unused attribute */
#ifndef CYTHON_UNUSED
# if defined(__GNUC__)
#   if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
#     define CYTHON_UNUSED __attribute__ ((__unused__))
#   else
#     define CYTHON_UNUSED
#   endif
# elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
#   define CYTHON_UNUSED __attribute__ ((__unused__))
# else
#   define CYTHON_UNUSED
# endif
#endif

typedef struct {PyObject **p; char *s; const long n; const char* encoding; const char is_unicode; const char is_str; const char intern; } __Pyx_StringTabEntry; /*proto*/


/* Type Conversion Predeclarations */

#define __Pyx_PyBytes_FromUString(s) PyBytes_FromString((char*)s)
#define __Pyx_PyBytes_AsUString(s)   ((unsigned char*) PyBytes_AsString(s))

#define __Pyx_Owned_Py_None(b) (Py_INCREF(Py_None), Py_None)
#define __Pyx_PyBool_FromLong(b) ((b) ? (Py_INCREF(Py_True), Py_True) : (Py_INCREF(Py_False), Py_False))
static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*);
static CYTHON_INLINE PyObject* __Pyx_PyNumber_Int(PyObject* x);

static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t);
static CYTHON_INLINE size_t __Pyx_PyInt_AsSize_t(PyObject*);

#define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
#define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))

#ifdef __GNUC__
  /* Test for GCC > 2.95 */
  #if __GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95))
    #define likely(x)   __builtin_expect(!!(x), 1)
    #define unlikely(x) __builtin_expect(!!(x), 0)
  #else /* __GNUC__ > 2 ... */
    #define likely(x)   (x)
    #define unlikely(x) (x)
  #endif /* __GNUC__ > 2 ... */
#else /* __GNUC__ */
  #define likely(x)   (x)
  #define unlikely(x) (x)
#endif /* __GNUC__ */
    
static PyObject *__pyx_m;
static PyObject *__pyx_b;
static PyObject *__pyx_empty_tuple;
static PyObject *__pyx_empty_bytes;
static int __pyx_lineno;
static int __pyx_clineno = 0;
static const char * __pyx_cfilenm= __FILE__;
static const char *__pyx_filename;


static const char *__pyx_f[] = {
  "vertex_instructions.pyx",
  "vertex_instructions_line.pxi",
  "buffer.pxd",
  "vbo.pxd",
  "transformation.pxd",
  "texture.pxd",
  "context_instructions.pxd",
  "compiler.pxd",
  "shader.pxd",
  "instructions.pxd",
  "stencil_instructions.pxd",
};

/*--- Type declarations ---*/
struct __pyx_obj_4kivy_8graphics_12instructions_Instruction;
struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point;
struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction;
struct __pyx_obj_4kivy_8graphics_20context_instructions_MatrixInstruction;
struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform;
struct __pyx_obj_4kivy_8graphics_20context_instructions_Rotate;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle;
struct __pyx_obj_4kivy_8graphics_20context_instructions_LineWidth;
struct __pyx_obj_4kivy_8graphics_20context_instructions_Scale;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle;
struct __pyx_obj_4kivy_8graphics_20context_instructions_PopMatrix;
struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup;
struct __pyx_obj_4kivy_8graphics_12instructions_CanvasBase;
struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource;
struct __pyx_obj_4kivy_8graphics_20context_instructions_PushMatrix;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh;
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilUnUse;
struct __pyx_obj_4kivy_8graphics_7texture_Texture;
struct __pyx_obj_4kivy_8graphics_7texture_TextureRegion;
struct __pyx_obj_4kivy_8graphics_3vbo_VBO;
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilPop;
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilUse;
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilPush;
struct __pyx_obj_4kivy_8graphics_20context_instructions_Translate;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad;
struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch;
struct __pyx_obj_4kivy_8graphics_6shader_Shader;
struct __pyx_obj_4kivy_8graphics_20context_instructions_BindTexture;
struct __pyx_obj_4kivy_8graphics_12instructions_Canvas;
struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext;
struct __pyx_obj_4kivy_8graphics_6buffer_Buffer;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line;
struct __pyx_obj_4kivy_8graphics_12instructions_Callback;
struct __pyx_obj_4kivy_8graphics_14transformation_Matrix;
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse;
struct __pyx_obj_4kivy_8graphics_20context_instructions_Color;
struct __pyx_obj_4kivy_8graphics_8compiler_GraphicsCompiler;
struct __pyx_t_4kivy_8graphics_6vertex_vertex_t;
struct __pyx_t_4kivy_8graphics_6vertex_vertex_attr_t;
typedef struct __pyx_t_4kivy_8graphics_6vertex_vertex_attr_t __pyx_t_4kivy_8graphics_6vertex_vertex_attr_t;

/* "vertex.pxd":3
 * from c_opengl cimport GLuint
 * 
 * cdef struct vertex_t:             # <<<<<<<<<<<<<<
 *     float x, y
 *     float s0, t0
 */
struct __pyx_t_4kivy_8graphics_6vertex_vertex_t {
  float x;
  float y;
  float s0;
  float t0;
};

/* "vertex.pxd":7
 *     float s0, t0
 * 
 * ctypedef struct vertex_attr_t:             # <<<<<<<<<<<<<<
 *     char *name
 *     unsigned int index
 */
struct __pyx_t_4kivy_8graphics_6vertex_vertex_attr_t {
  char *name;
  unsigned int index;
  unsigned int size;
  GLuint type;
  unsigned int bytesize;
  int per_vertex;
};

/* "transformation.pxd":1
 * ctypedef double matrix_t[16]             # <<<<<<<<<<<<<<
 * 
 * cdef class Matrix:
 */
typedef double __pyx_t_4kivy_8graphics_14transformation_matrix_t[16];
struct __pyx_opt_args_4kivy_8graphics_12instructions_11Instruction_flag_update;

/* "kivy\graphics\instructions.pxd":26
 * 
 *     cdef void apply(self)
 *     cdef void flag_update(self, int do_parent=?)             # <<<<<<<<<<<<<<
 *     cdef void flag_update_done(self)
 *     cdef void set_parent(self, Instruction parent)
 */
struct __pyx_opt_args_4kivy_8graphics_12instructions_11Instruction_flag_update {
  int __pyx_n;
  int do_parent;
};

/* "kivy\graphics\instructions.pxd":1
 * cdef class Instruction             # <<<<<<<<<<<<<<
 * cdef class InstructionGroup
 * cdef class ContextInstruction
 */
struct __pyx_obj_4kivy_8graphics_12instructions_Instruction {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *__pyx_vtab;
  int flags;
  PyObject *group;
  struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *parent;
};


/* "kivy\graphics\instructions.pxd":4
 * cdef class InstructionGroup
 * cdef class ContextInstruction
 * cdef class VertexInstruction             # <<<<<<<<<<<<<<
 * cdef class CanvasBase
 * cdef class Canvas
 */
struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
  struct __pyx_obj_4kivy_8graphics_20context_instructions_BindTexture *texture_binding;
  struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *batch;
  PyObject *_tex_coords;
};


/* "kivy\graphics\vertex_instructions.pyx":32
 * 
 * 
 * cdef class Bezier(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d Bezier curve.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  PyObject *_points;
  int _segments;
  int _loop;
  int _dash_offset;
  int _dash_length;
};


/* "kivy\graphics\vertex_instructions.pyx":334
 * 
 * 
 * cdef class Point(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d line.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  PyObject *_points;
  float _pointsize;
};


/* "kivy\graphics\instructions.pxd":3
 * cdef class Instruction
 * cdef class InstructionGroup
 * cdef class ContextInstruction             # <<<<<<<<<<<<<<
 * cdef class VertexInstruction
 * cdef class CanvasBase
 */
struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
  PyObject *context_state;
  PyObject *context_push;
  PyObject *context_pop;
};


/* "context_instructions.pxd":27
 *     cdef void apply(self)
 * 
 * cdef class MatrixInstruction(ContextInstruction):             # <<<<<<<<<<<<<<
 *     cdef Matrix _matrix
 *     cdef void apply(self)
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_MatrixInstruction {
  struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *_matrix;
};


/* "context_instructions.pxd":31
 *     cdef void apply(self)
 * 
 * cdef class Transform(MatrixInstruction):             # <<<<<<<<<<<<<<
 *     cpdef transform(self, Matrix trans)
 *     cpdef translate(self, float tx, float ty, float tz)
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform {
  struct __pyx_obj_4kivy_8graphics_20context_instructions_MatrixInstruction __pyx_base;
};


/* "context_instructions.pxd":39
 *     cdef void apply(self)
 * 
 * cdef class Rotate(Transform):             # <<<<<<<<<<<<<<
 *     cdef float _angle
 *     cdef tuple _axis
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_Rotate {
  struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform __pyx_base;
  float _angle;
  PyObject *_axis;
};


/* "kivy\graphics\vertex_instructions.pyx":603
 * 
 * 
 * cdef class Rectangle(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d rectangle.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  float x;
  float y;
  float w;
  float h;
};


/* "context_instructions.pxd":1
 * cdef class LineWidth             # <<<<<<<<<<<<<<
 * cdef class Color
 * cdef class BindTexture
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_LineWidth {
  struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
};


/* "context_instructions.pxd":44
 *     cdef void apply(self)
 * 
 * cdef class Scale(Transform):             # <<<<<<<<<<<<<<
 *     cdef float s
 *     cdef void apply(self)
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_Scale {
  struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform __pyx_base;
  float s;
};


/* "kivy\graphics\vertex_instructions.pyx":498
 * 
 * 
 * cdef class Triangle(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d triangle.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  PyObject *_points;
};


/* "context_instructions.pxd":24
 *     cdef void apply(self)
 * 
 * cdef class PopMatrix(ContextInstruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * 
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_PopMatrix {
  struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
};


/* "kivy\graphics\instructions.pxd":2
 * cdef class Instruction
 * cdef class InstructionGroup             # <<<<<<<<<<<<<<
 * cdef class ContextInstruction
 * cdef class VertexInstruction
 */
struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
  PyObject *children;
  struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *compiled_children;
  struct __pyx_obj_4kivy_8graphics_8compiler_GraphicsCompiler *compiler;
};


/* "kivy\graphics\instructions.pxd":5
 * cdef class ContextInstruction
 * cdef class VertexInstruction
 * cdef class CanvasBase             # <<<<<<<<<<<<<<
 * cdef class Canvas
 * cdef class RenderContext
 */
struct __pyx_obj_4kivy_8graphics_12instructions_CanvasBase {
  struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup __pyx_base;
};

struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_6shader_ShaderSource *__pyx_vtab;
  int shader;
  int shadertype;
};


/* "context_instructions.pxd":21
 *     cdef void apply(self)
 * 
 * cdef class PushMatrix(ContextInstruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * 
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_PushMatrix {
  struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
};


/* "kivy\graphics\vertex_instructions.pyx":679
 * 
 * 
 * cdef class BorderImage(Rectangle):             # <<<<<<<<<<<<<<
 *     '''A 2d border image. The behavior of the border image is similar to the
 *     concept of CSS3 border-image.
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle __pyx_base;
  PyObject *_border;
};


/* "kivy\graphics\vertex_instructions.pyx":219
 * 
 * 
 * cdef class Mesh(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d mesh.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  PyObject *_vertices;
  PyObject *_indices;
};


/* "kivy\graphics\stencil_instructions.pxd":10
 *     cdef unsigned int _op
 *     cdef void apply(self)
 * cdef class StencilUnUse(Instruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 */
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilUnUse {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
};


/* "texture.pxd":3
 * from c_opengl cimport GLuint
 * 
 * cdef class Texture:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */
struct __pyx_obj_4kivy_8graphics_7texture_Texture {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_7texture_Texture *__pyx_vtab;
  PyObject *__weakref__;
  PyObject *_source;
  float _tex_coords[8];
  int _width;
  int _height;
  GLuint _target;
  GLuint _id;
  int _mipmap;
  PyObject *_wrap;
  PyObject *_min_filter;
  PyObject *_mag_filter;
  int _rectangle;
  PyObject *_colorfmt;
  PyObject *_bufferfmt;
  float _uvx;
  float _uvy;
  float _uvw;
  float _uvh;
  int _is_allocated;
  int _nofree;
  PyObject *observers;
};


/* "texture.pxd":37
 *     cpdef bind(self)
 * 
 * cdef class TextureRegion(Texture):             # <<<<<<<<<<<<<<
 *     cdef int x
 *     cdef int y
 */
struct __pyx_obj_4kivy_8graphics_7texture_TextureRegion {
  struct __pyx_obj_4kivy_8graphics_7texture_Texture __pyx_base;
  int x;
  int y;
  struct __pyx_obj_4kivy_8graphics_7texture_Texture *owner;
};


/* "kivy\graphics\vbo.pxd":8
 * cdef vertex_attr_t *vbo_vertex_attr_list()
 * 
 * cdef class VBO:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */
struct __pyx_obj_4kivy_8graphics_3vbo_VBO {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VBO *__pyx_vtab;
  PyObject *__weakref__;
  GLuint id;
  int usage;
  int target;
  __pyx_t_4kivy_8graphics_6vertex_vertex_attr_t *format;
  int format_count;
  struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *data;
  short flags;
  int vbo_size;
};


/* "kivy\graphics\stencil_instructions.pxd":5
 * cdef class StencilPush(Instruction):
 *     cdef void apply(self)
 * cdef class StencilPop(Instruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * cdef class StencilUse(Instruction):
 */
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilPop {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
};


/* "kivy\graphics\stencil_instructions.pxd":7
 * cdef class StencilPop(Instruction):
 *     cdef void apply(self)
 * cdef class StencilUse(Instruction):             # <<<<<<<<<<<<<<
 *     cdef unsigned int _op
 *     cdef void apply(self)
 */
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilUse {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
  unsigned int _op;
};


/* "kivy\graphics\stencil_instructions.pxd":3
 * from kivy.graphics.instructions cimport Instruction
 * 
 * cdef class StencilPush(Instruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * cdef class StencilPop(Instruction):
 */
struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilPush {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
};


/* "context_instructions.pxd":48
 *     cdef void apply(self)
 * 
 * cdef class Translate(Transform):             # <<<<<<<<<<<<<<
 *     cdef double _x, _y, _z
 *     cdef void apply(self)
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_Translate {
  struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform __pyx_base;
  double _x;
  double _y;
  double _z;
};


/* "kivy\graphics\vertex_instructions.pyx":546
 * 
 * 
 * cdef class Quad(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d quad.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  PyObject *_points;
};


/* "kivy\graphics\vbo.pxd":30
 * 
 * 
 * cdef class VertexBatch:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */
struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *__pyx_vtab;
  PyObject *__weakref__;
  struct __pyx_obj_4kivy_8graphics_3vbo_VBO *vbo;
  struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *elements;
  struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *vbo_index;
  GLuint mode;
  PyObject *mode_str;
  GLuint id;
  int usage;
  short flags;
  int elements_size;
};


/* "shader.pxd":13
 *     cdef int is_compiled(self)
 * 
 * cdef class Shader:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */
struct __pyx_obj_4kivy_8graphics_6shader_Shader {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_6shader_Shader *__pyx_vtab;
  PyObject *__weakref__;
  int _success;
  int program;
  struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *vertex_shader;
  struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *fragment_shader;
  PyObject *vert_src;
  PyObject *frag_src;
  PyObject *uniform_locations;
  PyObject *uniform_values;
};


/* "context_instructions.pxd":3
 * cdef class LineWidth
 * cdef class Color
 * cdef class BindTexture             # <<<<<<<<<<<<<<
 * 
 * from transformation cimport Matrix
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_BindTexture {
  struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  int _index;
  PyObject *_source;
  struct __pyx_obj_4kivy_8graphics_7texture_Texture *_texture;
};


/* "kivy\graphics\instructions.pxd":6
 * cdef class VertexInstruction
 * cdef class CanvasBase
 * cdef class Canvas             # <<<<<<<<<<<<<<
 * cdef class RenderContext
 * 
 */
struct __pyx_obj_4kivy_8graphics_12instructions_Canvas {
  struct __pyx_obj_4kivy_8graphics_12instructions_CanvasBase __pyx_base;
  PyObject *__weakref__;
  float _opacity;
  struct __pyx_obj_4kivy_8graphics_12instructions_CanvasBase *_before;
  struct __pyx_obj_4kivy_8graphics_12instructions_CanvasBase *_after;
};


/* "kivy\graphics\instructions.pxd":7
 * cdef class CanvasBase
 * cdef class Canvas
 * cdef class RenderContext             # <<<<<<<<<<<<<<
 * 
 * from vbo cimport *
 */
struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext {
  struct __pyx_obj_4kivy_8graphics_12instructions_Canvas __pyx_base;
  struct __pyx_obj_4kivy_8graphics_6shader_Shader *_shader;
  PyObject *state_stacks;
  struct __pyx_obj_4kivy_8graphics_7texture_Texture *default_texture;
  PyObject *bind_texture;
};


/* "buffer.pxd":1
 * cdef class Buffer:             # <<<<<<<<<<<<<<
 *     cdef void *data
 *     cdef int *l_free
 */
struct __pyx_obj_4kivy_8graphics_6buffer_Buffer {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_6buffer_Buffer *__pyx_vtab;
  void *data;
  int *l_free;
  int i_free;
  int block_size;
  int block_count;
};


/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":28
 *     return 1
 * 
 * cdef class Line(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d line.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line {
  struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  int _cap;
  int _cap_precision;
  int _joint_precision;
  int _joint;
  PyObject *_points;
  float _width;
  int _dash_offset;
  int _dash_length;
  int _use_stencil;
  int _close;
  int _mode;
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *_stencil_rect;
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *_stencil_push;
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *_stencil_use;
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *_stencil_unuse;
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *_stencil_pop;
  double _bxmin;
  double _bxmax;
  double _bymin;
  double _bymax;
  PyObject *_mode_args;
};


/* "kivy\graphics\instructions.pxd":69
 *     cdef void build(self)
 * 
 * cdef class Callback(Instruction):             # <<<<<<<<<<<<<<
 *     cdef Shader _shader
 *     cdef object func
 */
struct __pyx_obj_4kivy_8graphics_12instructions_Callback {
  struct __pyx_obj_4kivy_8graphics_12instructions_Instruction __pyx_base;
  struct __pyx_obj_4kivy_8graphics_6shader_Shader *_shader;
  PyObject *func;
  int _reset_context;
};


/* "transformation.pxd":3
 * ctypedef double matrix_t[16]
 * 
 * cdef class Matrix:             # <<<<<<<<<<<<<<
 *     cdef matrix_t mat
 *     cpdef Matrix identity(self)
 */
struct __pyx_obj_4kivy_8graphics_14transformation_Matrix {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_14transformation_Matrix *__pyx_vtab;
  __pyx_t_4kivy_8graphics_14transformation_matrix_t mat;
};


/* "kivy\graphics\vertex_instructions.pyx":804
 * 
 * 
 * cdef class Ellipse(Rectangle):             # <<<<<<<<<<<<<<
 *     '''A 2D ellipse.
 * 
 */
struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle __pyx_base;
  int _segments;
  float _angle_start;
  float _angle_end;
};


/* "context_instructions.pxd":2
 * cdef class LineWidth
 * cdef class Color             # <<<<<<<<<<<<<<
 * cdef class BindTexture
 * 
 */
struct __pyx_obj_4kivy_8graphics_20context_instructions_Color {
  struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
};


/* "compiler.pxd":1
 * cdef class GraphicsCompiler             # <<<<<<<<<<<<<<
 * 
 * from instructions cimport InstructionGroup
 */
struct __pyx_obj_4kivy_8graphics_8compiler_GraphicsCompiler {
  PyObject_HEAD
  struct __pyx_vtabstruct_4kivy_8graphics_8compiler_GraphicsCompiler *__pyx_vtab;
};



struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction {
  void (*apply)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *);
  void (*flag_update)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, struct __pyx_opt_args_4kivy_8graphics_12instructions_11Instruction_flag_update *__pyx_optional_args);
  void (*flag_update_done)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *);
  void (*set_parent)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *);
  void (*reload)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *);
  void (*radd)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *);
  void (*rinsert)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, int);
  void (*rremove)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *__pyx_vtabptr_4kivy_8graphics_12instructions_Instruction;


/* "kivy\graphics\instructions.pxd":4
 * cdef class InstructionGroup
 * cdef class ContextInstruction
 * cdef class VertexInstruction             # <<<<<<<<<<<<<<
 * cdef class CanvasBase
 * cdef class Canvas
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
  void (*build)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;


/* "kivy\graphics\vertex_instructions.pyx":219
 * 
 * 
 * cdef class Mesh(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d mesh.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Mesh {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Mesh;


/* "kivy\graphics\vertex_instructions.pyx":603
 * 
 * 
 * cdef class Rectangle(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d rectangle.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Rectangle;


/* "kivy\graphics\instructions.pxd":3
 * cdef class Instruction
 * cdef class InstructionGroup
 * cdef class ContextInstruction             # <<<<<<<<<<<<<<
 * cdef class VertexInstruction
 * cdef class CanvasBase
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
  struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *(*get_context)(struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction *);
  void (*set_state)(struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction *, PyObject *, PyObject *);
  void (*push_state)(struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction *, PyObject *);
  void (*pop_state)(struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction *, PyObject *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction *__pyx_vtabptr_4kivy_8graphics_12instructions_ContextInstruction;


/* "context_instructions.pxd":21
 *     cdef void apply(self)
 * 
 * cdef class PushMatrix(ContextInstruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_PushMatrix {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  void (*apply)(struct __pyx_obj_4kivy_8graphics_20context_instructions_PushMatrix *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_PushMatrix *__pyx_vtabptr_4kivy_8graphics_20context_instructions_PushMatrix;


/* "context_instructions.pxd":27
 *     cdef void apply(self)
 * 
 * cdef class MatrixInstruction(ContextInstruction):             # <<<<<<<<<<<<<<
 *     cdef Matrix _matrix
 *     cdef void apply(self)
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_MatrixInstruction {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  void (*apply)(struct __pyx_obj_4kivy_8graphics_20context_instructions_MatrixInstruction *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_MatrixInstruction *__pyx_vtabptr_4kivy_8graphics_20context_instructions_MatrixInstruction;


/* "context_instructions.pxd":31
 *     cdef void apply(self)
 * 
 * cdef class Transform(MatrixInstruction):             # <<<<<<<<<<<<<<
 *     cpdef transform(self, Matrix trans)
 *     cpdef translate(self, float tx, float ty, float tz)
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Transform {
  struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_MatrixInstruction __pyx_base;
  PyObject *(*transform)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform *, struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, int __pyx_skip_dispatch);
  PyObject *(*translate)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform *, float, float, float, int __pyx_skip_dispatch);
  PyObject *(*rotate)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform *, float, float, float, float, int __pyx_skip_dispatch);
  PyObject *(*scale)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform *, float, int __pyx_skip_dispatch);
  PyObject *(*identity)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform *, int __pyx_skip_dispatch);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Transform *__pyx_vtabptr_4kivy_8graphics_20context_instructions_Transform;


/* "context_instructions.pxd":48
 *     cdef void apply(self)
 * 
 * cdef class Translate(Transform):             # <<<<<<<<<<<<<<
 *     cdef double _x, _y, _z
 *     cdef void apply(self)
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Translate {
  struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Transform __pyx_base;
  PyObject *(*set_translate)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Translate *, double, double, double);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Translate *__pyx_vtabptr_4kivy_8graphics_20context_instructions_Translate;


/* "kivy\graphics\stencil_instructions.pxd":10
 *     cdef unsigned int _op
 *     cdef void apply(self)
 * cdef class StencilUnUse(Instruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 */

struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilUnUse {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilUnUse *__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilUnUse;


/* "kivy\graphics\vbo.pxd":30
 * 
 * 
 * cdef class VertexBatch:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch {
  void (*clear_data)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *);
  void (*set_data)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *, struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *, int, unsigned short *, int);
  void (*append_data)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *, struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *, int, unsigned short *, int);
  void (*draw)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *);
  void (*set_mode)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *, PyObject *);
  PyObject *(*get_mode)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *);
  int (*count)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *);
  void (*reload)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *);
  int (*have_id)(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *__pyx_vtabptr_4kivy_8graphics_3vbo_VertexBatch;


/* "kivy\graphics\instructions.pxd":2
 * cdef class Instruction
 * cdef class InstructionGroup             # <<<<<<<<<<<<<<
 * cdef class ContextInstruction
 * cdef class VertexInstruction
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_InstructionGroup {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
  void (*build)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *);
  PyObject *(*add)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, int __pyx_skip_dispatch);
  PyObject *(*insert)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, int, struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, int __pyx_skip_dispatch);
  PyObject *(*remove)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *, int __pyx_skip_dispatch);
  PyObject *(*clear)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, int __pyx_skip_dispatch);
  PyObject *(*remove_group)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, PyObject *, int __pyx_skip_dispatch);
  PyObject *(*get_group)(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *, PyObject *, int __pyx_skip_dispatch);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_InstructionGroup *__pyx_vtabptr_4kivy_8graphics_12instructions_InstructionGroup;


/* "kivy\graphics\instructions.pxd":5
 * cdef class ContextInstruction
 * cdef class VertexInstruction
 * cdef class CanvasBase             # <<<<<<<<<<<<<<
 * cdef class Canvas
 * cdef class RenderContext
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_CanvasBase {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_InstructionGroup __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_CanvasBase *__pyx_vtabptr_4kivy_8graphics_12instructions_CanvasBase;


/* "kivy\graphics\instructions.pxd":6
 * cdef class VertexInstruction
 * cdef class CanvasBase
 * cdef class Canvas             # <<<<<<<<<<<<<<
 * cdef class RenderContext
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Canvas {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_CanvasBase __pyx_base;
  PyObject *(*draw)(struct __pyx_obj_4kivy_8graphics_12instructions_Canvas *, int __pyx_skip_dispatch);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Canvas *__pyx_vtabptr_4kivy_8graphics_12instructions_Canvas;


/* "kivy\graphics\stencil_instructions.pxd":3
 * from kivy.graphics.instructions cimport Instruction
 * 
 * cdef class StencilPush(Instruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * cdef class StencilPop(Instruction):
 */

struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilPush {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilPush *__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilPush;


struct __pyx_vtabstruct_4kivy_8graphics_14transformation_Matrix {
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*identity)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, int __pyx_skip_dispatch);
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*inverse)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, int __pyx_skip_dispatch);
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*multiply)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, int __pyx_skip_dispatch);
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*rotate)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, double, double, double, double, int __pyx_skip_dispatch);
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*scale)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, double, double, double, int __pyx_skip_dispatch);
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*translate)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, double, double, double, int __pyx_skip_dispatch);
  struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *(*view_clip)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, double, double, double, double, double, double, int, int __pyx_skip_dispatch);
  PyObject *(*transform_point)(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *, double, double, double, int __pyx_skip_dispatch);
};
static struct __pyx_vtabstruct_4kivy_8graphics_14transformation_Matrix *__pyx_vtabptr_4kivy_8graphics_14transformation_Matrix;


struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_BindTexture {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  void (*apply)(struct __pyx_obj_4kivy_8graphics_20context_instructions_BindTexture *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_BindTexture *__pyx_vtabptr_4kivy_8graphics_20context_instructions_BindTexture;


/* "context_instructions.pxd":1
 * cdef class LineWidth             # <<<<<<<<<<<<<<
 * cdef class Color
 * cdef class BindTexture
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_LineWidth {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  void (*apply)(struct __pyx_obj_4kivy_8graphics_20context_instructions_LineWidth *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_LineWidth *__pyx_vtabptr_4kivy_8graphics_20context_instructions_LineWidth;


/* "shader.pxd":13
 *     cdef int is_compiled(self)
 * 
 * cdef class Shader:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_6shader_Shader {
  void (*use)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  void (*stop)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  void (*set_uniform)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, PyObject *, PyObject *);
  void (*upload_uniform)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, PyObject *, PyObject *);
  void (*upload_uniform_matrix)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, int, struct __pyx_obj_4kivy_8graphics_14transformation_Matrix *);
  int (*get_uniform_loc)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, PyObject *);
  void (*bind_attrib_locations)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  void (*build)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  void (*build_vertex)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  void (*build_fragment)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  void (*link_program)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  int (*is_linked)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
  struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *(*compile_shader)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, char *, int);
  PyObject *(*get_program_log)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, PyObject *);
  void (*process_message)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *, PyObject *, PyObject *);
  void (*reload)(struct __pyx_obj_4kivy_8graphics_6shader_Shader *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_6shader_Shader *__pyx_vtabptr_4kivy_8graphics_6shader_Shader;


/* "kivy\graphics\instructions.pxd":7
 * cdef class CanvasBase
 * cdef class Canvas
 * cdef class RenderContext             # <<<<<<<<<<<<<<
 * 
 * from vbo cimport *
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_RenderContext {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Canvas __pyx_base;
  void (*set_texture)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, int, struct __pyx_obj_4kivy_8graphics_7texture_Texture *);
  void (*set_state)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *, PyObject *);
  PyObject *(*get_state)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *);
  void (*set_states)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *);
  void (*push_state)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *);
  void (*push_states)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *);
  void (*pop_state)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *);
  void (*pop_states)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *, PyObject *);
  void (*enter)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *);
  void (*leave)(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_RenderContext *__pyx_vtabptr_4kivy_8graphics_12instructions_RenderContext;


/* "kivy\graphics\vbo.pxd":8
 * cdef vertex_attr_t *vbo_vertex_attr_list()
 * 
 * cdef class VBO:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VBO {
  void (*update_buffer)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *);
  void (*bind)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *);
  void (*unbind)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *);
  void (*add_vertex_data)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *, void *, unsigned short *, int);
  void (*update_vertex_data)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *, int, struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *, int);
  void (*remove_vertex_data)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *, unsigned short *, int);
  void (*reload)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *);
  int (*have_id)(struct __pyx_obj_4kivy_8graphics_3vbo_VBO *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VBO *__pyx_vtabptr_4kivy_8graphics_3vbo_VBO;


/* "context_instructions.pxd":39
 *     cdef void apply(self)
 * 
 * cdef class Rotate(Transform):             # <<<<<<<<<<<<<<
 *     cdef float _angle
 *     cdef tuple _axis
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Rotate {
  struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Transform __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Rotate *__pyx_vtabptr_4kivy_8graphics_20context_instructions_Rotate;


/* "texture.pxd":3
 * from c_opengl cimport GLuint
 * 
 * cdef class Texture:             # <<<<<<<<<<<<<<
 *     cdef object __weakref__
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_7texture_Texture {
  void (*update_tex_coords)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *);
  void (*set_min_filter)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *, PyObject *);
  void (*set_mag_filter)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *, PyObject *);
  void (*set_wrap)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *, PyObject *);
  void (*reload)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *);
  PyObject *(*flip_vertical)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *, int __pyx_skip_dispatch);
  PyObject *(*get_region)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *, PyObject *, PyObject *, PyObject *, PyObject *, int __pyx_skip_dispatch);
  PyObject *(*bind)(struct __pyx_obj_4kivy_8graphics_7texture_Texture *, int __pyx_skip_dispatch);
};
static struct __pyx_vtabstruct_4kivy_8graphics_7texture_Texture *__pyx_vtabptr_4kivy_8graphics_7texture_Texture;


/* "texture.pxd":37
 *     cpdef bind(self)
 * 
 * cdef class TextureRegion(Texture):             # <<<<<<<<<<<<<<
 *     cdef int x
 *     cdef int y
 */

struct __pyx_vtabstruct_4kivy_8graphics_7texture_TextureRegion {
  struct __pyx_vtabstruct_4kivy_8graphics_7texture_Texture __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_7texture_TextureRegion *__pyx_vtabptr_4kivy_8graphics_7texture_TextureRegion;


/* "context_instructions.pxd":24
 *     cdef void apply(self)
 * 
 * cdef class PopMatrix(ContextInstruction):             # <<<<<<<<<<<<<<
 *     cdef void apply(self)
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_PopMatrix {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  void (*apply)(struct __pyx_obj_4kivy_8graphics_20context_instructions_PopMatrix *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_PopMatrix *__pyx_vtabptr_4kivy_8graphics_20context_instructions_PopMatrix;


/* "kivy\graphics\vertex_instructions.pyx":334
 * 
 * 
 * cdef class Point(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d line.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Point {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Point *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Point;


/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":28
 *     return 1
 * 
 * cdef class Line(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d line.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
  void (*ensure_stencil)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *);
  void (*build_legacy)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *);
  void (*build_extended)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *);
  void (*prebuild_ellipse)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *);
  void (*prebuild_circle)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *);
  void (*prebuild_rectangle)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Line;


/* "kivy\graphics\stencil_instructions.pxd":7
 * cdef class StencilPop(Instruction):
 *     cdef void apply(self)
 * cdef class StencilUse(Instruction):             # <<<<<<<<<<<<<<
 *     cdef unsigned int _op
 *     cdef void apply(self)
 */

struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilUse {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilUse *__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilUse;


/* "kivy\graphics\instructions.pxd":69
 *     cdef void build(self)
 * 
 * cdef class Callback(Instruction):             # <<<<<<<<<<<<<<
 *     cdef Shader _shader
 *     cdef object func
 */

struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Callback {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
  void (*enter)(struct __pyx_obj_4kivy_8graphics_12instructions_Callback *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Callback *__pyx_vtabptr_4kivy_8graphics_12instructions_Callback;


/* "compiler.pxd":1
 * cdef class GraphicsCompiler             # <<<<<<<<<<<<<<
 * 
 * from instructions cimport InstructionGroup
 */

struct __pyx_vtabstruct_4kivy_8graphics_8compiler_GraphicsCompiler {
  struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *(*compile)(struct __pyx_obj_4kivy_8graphics_8compiler_GraphicsCompiler *, struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_8compiler_GraphicsCompiler *__pyx_vtabptr_4kivy_8graphics_8compiler_GraphicsCompiler;


/* "kivy\graphics\vertex_instructions.pyx":32
 * 
 * 
 * cdef class Bezier(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d Bezier curve.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Bezier;


/* "context_instructions.pxd":2
 * cdef class LineWidth
 * cdef class Color             # <<<<<<<<<<<<<<
 * cdef class BindTexture
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Color {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction __pyx_base;
  void (*apply)(struct __pyx_obj_4kivy_8graphics_20context_instructions_Color *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Color *__pyx_vtabptr_4kivy_8graphics_20context_instructions_Color;


/* "kivy\graphics\vertex_instructions.pyx":498
 * 
 * 
 * cdef class Triangle(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d triangle.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Triangle {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Triangle;


/* "context_instructions.pxd":44
 *     cdef void apply(self)
 * 
 * cdef class Scale(Transform):             # <<<<<<<<<<<<<<
 *     cdef float s
 *     cdef void apply(self)
 */

struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Scale {
  struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Transform __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Scale *__pyx_vtabptr_4kivy_8graphics_20context_instructions_Scale;


/* "kivy\graphics\vertex_instructions.pyx":546
 * 
 * 
 * cdef class Quad(VertexInstruction):             # <<<<<<<<<<<<<<
 *     '''A 2d quad.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Quad {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Quad *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Quad;


/* "buffer.pxd":1
 * cdef class Buffer:             # <<<<<<<<<<<<<<
 *     cdef void *data
 *     cdef int *l_free
 */

struct __pyx_vtabstruct_4kivy_8graphics_6buffer_Buffer {
  void (*clear)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *);
  void (*grow)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *, int);
  void (*add)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *, void *, unsigned short *, int);
  void (*remove)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *, unsigned short *, int);
  int (*count)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *);
  int (*size)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *);
  void *(*pointer)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *);
  void *(*offset_pointer)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *, int);
  void (*update)(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer *, int, void *, int);
};
static struct __pyx_vtabstruct_4kivy_8graphics_6buffer_Buffer *__pyx_vtabptr_4kivy_8graphics_6buffer_Buffer;


/* "kivy\graphics\vertex_instructions.pyx":679
 * 
 * 
 * cdef class BorderImage(Rectangle):             # <<<<<<<<<<<<<<
 *     '''A 2d border image. The behavior of the border image is similar to the
 *     concept of CSS3 border-image.
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_BorderImage {
  struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_BorderImage;


/* "kivy\graphics\vertex_instructions.pyx":804
 * 
 * 
 * cdef class Ellipse(Rectangle):             # <<<<<<<<<<<<<<
 *     '''A 2D ellipse.
 * 
 */

struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Ellipse {
  struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Ellipse;


/* "shader.pxd":5
 * from transformation cimport Matrix
 * 
 * cdef class ShaderSource:             # <<<<<<<<<<<<<<
 *     cdef int shader
 *     cdef int shadertype
 */

struct __pyx_vtabstruct_4kivy_8graphics_6shader_ShaderSource {
  PyObject *(*set_source)(struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *, char *);
  PyObject *(*get_shader_log)(struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *, int);
  void (*process_message)(struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *, PyObject *, PyObject *);
  int (*is_compiled)(struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource *);
};
static struct __pyx_vtabstruct_4kivy_8graphics_6shader_ShaderSource *__pyx_vtabptr_4kivy_8graphics_6shader_ShaderSource;


struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilPop {
  struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction __pyx_base;
};
static struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilPop *__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilPop;
#ifndef CYTHON_REFNANNY
  #define CYTHON_REFNANNY 0
#endif
#if CYTHON_REFNANNY
  typedef struct {
    void (*INCREF)(void*, PyObject*, int);
    void (*DECREF)(void*, PyObject*, int);
    void (*GOTREF)(void*, PyObject*, int);
    void (*GIVEREF)(void*, PyObject*, int);
    void* (*SetupContext)(const char*, int, const char*);
    void (*FinishContext)(void**);
  } __Pyx_RefNannyAPIStruct;
  static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
  static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname); /*proto*/
  #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
#ifdef WITH_THREAD
  #define __Pyx_RefNannySetupContext(name, acquire_gil) \
          if (acquire_gil) { \
              PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); \
              __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__); \
              PyGILState_Release(__pyx_gilstate_save); \
          } else { \
              __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__); \
          }
#else
  #define __Pyx_RefNannySetupContext(name, acquire_gil) \
          __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
#endif
  #define __Pyx_RefNannyFinishContext() \
          __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
  #define __Pyx_INCREF(r)  __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_DECREF(r)  __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_GOTREF(r)  __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  #define __Pyx_XINCREF(r)  do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
  #define __Pyx_XDECREF(r)  do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
  #define __Pyx_XGOTREF(r)  do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
  #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
#else
  #define __Pyx_RefNannyDeclarations
  #define __Pyx_RefNannySetupContext(name, acquire_gil)
  #define __Pyx_RefNannyFinishContext()
  #define __Pyx_INCREF(r) Py_INCREF(r)
  #define __Pyx_DECREF(r) Py_DECREF(r)
  #define __Pyx_GOTREF(r)
  #define __Pyx_GIVEREF(r)
  #define __Pyx_XINCREF(r) Py_XINCREF(r)
  #define __Pyx_XDECREF(r) Py_XDECREF(r)
  #define __Pyx_XGOTREF(r)
  #define __Pyx_XGIVEREF(r)
#endif /* CYTHON_REFNANNY */
#define __Pyx_CLEAR(r)    do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
#define __Pyx_XCLEAR(r)   do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)

static PyObject *__Pyx_GetName(PyObject *dict, PyObject *name); /*proto*/

static void __Pyx_RaiseArgtupleInvalid(const char* func_name, int exact,
    Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found); /*proto*/

static CYTHON_INLINE int __Pyx_CheckKeywordStrings(PyObject *kwdict, const char* function_name, int kw_allowed); /*proto*/

static PyObject* __Pyx_PyDict_GetItemDefault(PyObject* d, PyObject* key, PyObject* default_value) {
    PyObject* value;
#if PY_MAJOR_VERSION >= 3
    value = PyDict_GetItemWithError(d, key);
    if (unlikely(!value)) {
        if (unlikely(PyErr_Occurred()))
            return NULL;
        value = default_value;
    }
    Py_INCREF(value);
#else
    if (PyString_CheckExact(key) || PyUnicode_CheckExact(key) || PyInt_CheckExact(key)) {
        value = PyDict_GetItem(d, key);
        if (unlikely(!value)) {
            value = default_value;
        }
        Py_INCREF(value);
    } else {
        PyObject *m;
        m = __Pyx_GetAttrString(d, "get");
        if (!m) return NULL;
        value = PyObject_CallFunctionObjArgs(m, key,
                                             (default_value == Py_None) ? NULL : default_value, NULL);
        Py_DECREF(m);
    }
#endif
    return value;
}

static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) {
    PyObject *r;
    if (!j) return NULL;
    r = PyObject_GetItem(o, j);
    Py_DECREF(j);
    return r;
}
#define __Pyx_GetItemInt_List(o, i, size, to_py_func) (((size) <= sizeof(Py_ssize_t)) ? \
                                                    __Pyx_GetItemInt_List_Fast(o, i) : \
                                                    __Pyx_GetItemInt_Generic(o, to_py_func(i)))
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i) {
#if CYTHON_COMPILING_IN_CPYTHON
    if (likely((0 <= i) & (i < PyList_GET_SIZE(o)))) {
        PyObject *r = PyList_GET_ITEM(o, i);
        Py_INCREF(r);
        return r;
    }
    else if ((-PyList_GET_SIZE(o) <= i) & (i < 0)) {
        PyObject *r = PyList_GET_ITEM(o, PyList_GET_SIZE(o) + i);
        Py_INCREF(r);
        return r;
    }
    return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
#else
    return PySequence_GetItem(o, i);
#endif
}
#define __Pyx_GetItemInt_Tuple(o, i, size, to_py_func) (((size) <= sizeof(Py_ssize_t)) ? \
                                                    __Pyx_GetItemInt_Tuple_Fast(o, i) : \
                                                    __Pyx_GetItemInt_Generic(o, to_py_func(i)))
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i) {
#if CYTHON_COMPILING_IN_CPYTHON
    if (likely((0 <= i) & (i < PyTuple_GET_SIZE(o)))) {
        PyObject *r = PyTuple_GET_ITEM(o, i);
        Py_INCREF(r);
        return r;
    }
    else if ((-PyTuple_GET_SIZE(o) <= i) & (i < 0)) {
        PyObject *r = PyTuple_GET_ITEM(o, PyTuple_GET_SIZE(o) + i);
        Py_INCREF(r);
        return r;
    }
    return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
#else
    return PySequence_GetItem(o, i);
#endif
}
#define __Pyx_GetItemInt(o, i, size, to_py_func) (((size) <= sizeof(Py_ssize_t)) ? \
                                                    __Pyx_GetItemInt_Fast(o, i) : \
                                                    __Pyx_GetItemInt_Generic(o, to_py_func(i)))
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i) {
#if CYTHON_COMPILING_IN_CPYTHON
    if (PyList_CheckExact(o)) {
        Py_ssize_t n = (likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
        if (likely((n >= 0) & (n < PyList_GET_SIZE(o)))) {
            PyObject *r = PyList_GET_ITEM(o, n);
            Py_INCREF(r);
            return r;
        }
    }
    else if (PyTuple_CheckExact(o)) {
        Py_ssize_t n = (likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o);
        if (likely((n >= 0) & (n < PyTuple_GET_SIZE(o)))) {
            PyObject *r = PyTuple_GET_ITEM(o, n);
            Py_INCREF(r);
            return r;
        }
    }
    else if (likely(i >= 0)) {
        PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
        if (likely(m && m->sq_item)) {
            return m->sq_item(o, i);
        }
    }
#else
    if (PySequence_Check(o)) {
        return PySequence_GetItem(o, i);
    }
#endif
    return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
}

static CYTHON_INLINE Py_ssize_t __Pyx_div_Py_ssize_t(Py_ssize_t, Py_ssize_t); /* proto */

static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type); /*proto*/

static CYTHON_INLINE void __Pyx_ErrRestore(PyObject *type, PyObject *value, PyObject *tb); /*proto*/
static CYTHON_INLINE void __Pyx_ErrFetch(PyObject **type, PyObject **value, PyObject **tb); /*proto*/

static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause); /*proto*/

static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index);

static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected);

static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void);

static void __Pyx_UnpackTupleError(PyObject *, Py_ssize_t index); /*proto*/

static CYTHON_INLINE int __Pyx_IterFinish(void); /*proto*/

static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected); /*proto*/

#define __Pyx_SetItemInt(o, i, v, size, to_py_func) (((size) <= sizeof(Py_ssize_t)) ? \
                                                    __Pyx_SetItemInt_Fast(o, i, v) : \
                                                    __Pyx_SetItemInt_Generic(o, to_py_func(i), v))
static CYTHON_INLINE int __Pyx_SetItemInt_Generic(PyObject *o, PyObject *j, PyObject *v) {
    int r;
    if (!j) return -1;
    r = PyObject_SetItem(o, j, v);
    Py_DECREF(j);
    return r;
}
static CYTHON_INLINE int __Pyx_SetItemInt_Fast(PyObject *o, Py_ssize_t i, PyObject *v) {
#if CYTHON_COMPILING_IN_CPYTHON
    if (PyList_CheckExact(o)) {
        Py_ssize_t n = (likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
        if (likely((n >= 0) & (n < PyList_GET_SIZE(o)))) {
            PyObject* old = PyList_GET_ITEM(o, n);
            Py_INCREF(v);
            PyList_SET_ITEM(o, n, v);
            Py_DECREF(old);
            return 1;
        }
    } else
#endif
    if (likely(i >= 0)) {
        PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
        if (likely(m && m->sq_ass_item)) {
            return m->sq_ass_item(o, i, v);
        }
    }
    return __Pyx_SetItemInt_Generic(o, PyInt_FromSsize_t(i), v);
}

static void __Pyx_RaiseDoubleKeywordsError(const char* func_name, PyObject* kw_name); /*proto*/

static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[], \
    PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args, \
    const char* function_name); /*proto*/

static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, long level); /*proto*/

static CYTHON_INLINE void __Pyx_RaiseImportError(PyObject *name);

static PyObject *__Pyx_FindPy2Metaclass(PyObject *bases); /*proto*/

static PyObject *__Pyx_CreateClass(PyObject *bases, PyObject *dict, PyObject *name,
                                   PyObject *modname); /*proto*/

#include <string.h>

static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals); /*proto*/

static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals); /*proto*/

#if PY_MAJOR_VERSION >= 3
#define __Pyx_PyString_Equals __Pyx_PyUnicode_Equals
#else
#define __Pyx_PyString_Equals __Pyx_PyBytes_Equals
#endif

static CYTHON_INLINE unsigned char __Pyx_PyInt_AsUnsignedChar(PyObject *);

static CYTHON_INLINE unsigned short __Pyx_PyInt_AsUnsignedShort(PyObject *);

static CYTHON_INLINE unsigned int __Pyx_PyInt_AsUnsignedInt(PyObject *);

static CYTHON_INLINE char __Pyx_PyInt_AsChar(PyObject *);

static CYTHON_INLINE short __Pyx_PyInt_AsShort(PyObject *);

static CYTHON_INLINE int __Pyx_PyInt_AsInt(PyObject *);

static CYTHON_INLINE signed char __Pyx_PyInt_AsSignedChar(PyObject *);

static CYTHON_INLINE signed short __Pyx_PyInt_AsSignedShort(PyObject *);

static CYTHON_INLINE signed int __Pyx_PyInt_AsSignedInt(PyObject *);

static CYTHON_INLINE int __Pyx_PyInt_AsLongDouble(PyObject *);

static CYTHON_INLINE unsigned long __Pyx_PyInt_AsUnsignedLong(PyObject *);

static CYTHON_INLINE unsigned PY_LONG_LONG __Pyx_PyInt_AsUnsignedLongLong(PyObject *);

static CYTHON_INLINE long __Pyx_PyInt_AsLong(PyObject *);

static CYTHON_INLINE PY_LONG_LONG __Pyx_PyInt_AsLongLong(PyObject *);

static CYTHON_INLINE signed long __Pyx_PyInt_AsSignedLong(PyObject *);

static CYTHON_INLINE signed PY_LONG_LONG __Pyx_PyInt_AsSignedLongLong(PyObject *);

static void __Pyx_WriteUnraisable(const char *name, int clineno,
                                  int lineno, const char *filename); /*proto*/

static int __Pyx_check_binary_version(void);

#if !defined(__Pyx_PyIdentifier_FromString)
#if PY_MAJOR_VERSION < 3
  #define __Pyx_PyIdentifier_FromString(s) PyString_FromString(s)
#else
  #define __Pyx_PyIdentifier_FromString(s) PyUnicode_FromString(s)
#endif
#endif

static PyTypeObject *__Pyx_ImportType(const char *module_name, const char *class_name, size_t size, int strict);  /*proto*/

static PyObject *__Pyx_ImportModule(const char *name); /*proto*/

static void* __Pyx_GetVtable(PyObject *dict); /*proto*/

static int __Pyx_SetVtable(PyObject *dict, void *vtable); /*proto*/

static int __Pyx_ImportFunction(PyObject *module, const char *funcname, void (**f)(void), const char *sig); /*proto*/

typedef struct {
    int code_line;
    PyCodeObject* code_object;
} __Pyx_CodeObjectCacheEntry;
struct __Pyx_CodeObjectCache {
    int count;
    int max_count;
    __Pyx_CodeObjectCacheEntry* entries;
};
static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line);
static PyCodeObject *__pyx_find_code_object(int code_line);
static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object);

static void __Pyx_AddTraceback(const char *funcname, int c_line,
                               int py_line, const char *filename); /*proto*/

static int __Pyx_InitStrings(__Pyx_StringTabEntry *t); /*proto*/


/* Module declarations from 'kivy.graphics.buffer' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_6buffer_Buffer = 0;

/* Module declarations from 'kivy.graphics.c_opengl' */

/* Module declarations from 'kivy.graphics.vertex' */

/* Module declarations from 'kivy.graphics.vbo' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_3vbo_VBO = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_3vbo_VertexBatch = 0;

/* Module declarations from 'kivy.graphics.transformation' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_14transformation_Matrix = 0;

/* Module declarations from 'kivy.graphics.texture' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_7texture_Texture = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_7texture_TextureRegion = 0;

/* Module declarations from 'kivy.graphics.context_instructions' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_LineWidth = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_Color = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_BindTexture = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_PushMatrix = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_PopMatrix = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_MatrixInstruction = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_Transform = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_Rotate = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_Scale = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20context_instructions_Translate = 0;

/* Module declarations from 'kivy.graphics.compiler' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_8compiler_GraphicsCompiler = 0;

/* Module declarations from 'kivy.graphics.shader' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_6shader_ShaderSource = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_6shader_Shader = 0;

/* Module declarations from 'kivy.graphics.instructions' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_Instruction = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_InstructionGroup = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_ContextInstruction = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_CanvasBase = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_Canvas = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_RenderContext = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_12instructions_Callback = 0;
static struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *(*__pyx_f_4kivy_8graphics_12instructions_getActiveContext)(void); /*proto*/

/* Module declarations from 'kivy.graphics.stencil_instructions' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPush = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPop = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUse = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUnUse = 0;

/* Module declarations from 'kivy.graphics.vertex_instructions' */
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Line = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Bezier = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Mesh = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Point = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Triangle = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Quad = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_BorderImage = 0;
static PyTypeObject *__pyx_ptype_4kivy_8graphics_19vertex_instructions_Ellipse = 0;
static double __pyx_v_4kivy_8graphics_19vertex_instructions_pi;
static CYTHON_INLINE int __pyx_f_4kivy_8graphics_19vertex_instructions_line_intersection(double, double, double, double, double, double, double, double, double *, double *); /*proto*/
#define __Pyx_MODULE_NAME "kivy.graphics.vertex_instructions"
int __pyx_module_is_main_kivy__graphics__vertex_instructions = 0;

/* Implementation of 'kivy.graphics.vertex_instructions' */
static PyObject *__pyx_builtin_Exception;
static PyObject *__pyx_builtin_MemoryError;
static PyObject *__pyx_builtin_xrange;
static PyObject *__pyx_builtin_range;
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_points); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_length___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5width___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5width_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_3cap___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_3cap_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5joint___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5joint_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5close___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5close_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_7ellipse___set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_args); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6circle___set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_args); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_9rectangle___set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_args); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_points); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_8segments___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_7indices___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_4mode___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_mode); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_2add_point(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, float __pyx_v_x, float __pyx_v_y); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, PyObject *__pyx_v_points); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_9pointsize___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, float __pyx_v_pointsize); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self, PyObject *__pyx_v_points); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self, PyObject *__pyx_v_points); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self, PyObject *__pyx_v_pos); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_4size___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self, PyObject *__pyx_v_size); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage_6border___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self, PyObject *__pyx_v_b); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self); /* proto */
static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static char __pyx_k_5[] = "Invalid dash_length value, must be >= 0";
static char __pyx_k_7[] = "Invalid dash_offset value, must be >= 0";
static char __pyx_k_9[] = "Invalid width value, must be > 0";
static char __pyx_k_11[] = "Invalid cap, must be one of \"none\", \"square\", \"round\"";
static char __pyx_k_13[] = "Invalid joint, must be one of \"none\", \"miter\", \"bevel\", \"round\"";
static char __pyx_k_15[] = "Invalid cap_precision value, must be >= 1";
static char __pyx_k_18[] = "Invalid ellipse value: {0!r}";
static char __pyx_k_19[] = "Invalid number of arguments: {0} instead of 4, 6 or 7.";
static char __pyx_k_20[] = "Invalid circle value: {0!r}";
static char __pyx_k_21[] = "Invalid number of arguments: {0} instead of 3, 5 or 6.";
static char __pyx_k_22[] = "Invalid rectangle value: {0!r}";
static char __pyx_k_23[] = "Invalid number of arguments: {0} instead of 4.";
static char __pyx_k_26[] = "Invalid segments value, must be >= 2";
static char __pyx_k_32[] = "Cannot upload more than 65535 indices(OpenGL ES 2 limitation)";
static char __pyx_k_36[] = "Cannot add elements (limit is 2^15-2)";
static char __pyx_k_38[] = "Too many elements (limit is 2^15-2)";
static char __pyx_k_40[] = "Quad: invalid number of points (%d instead of 8)";
static char __pyx_k_44[] = "GBorderImage: texture missing";
static char __pyx_k_48[] = "Property for getting/settings points of the line\n\n        .. warning::\n\n            This will always reconstruct the whole graphics from the new points\n            list. It can be very CPU expensive.\n        ";
static char __pyx_k_49[] = "Property for getting/setting the length of the dashes in the curve\n\n        .. versionadded:: 1.0.8\n        ";
static char __pyx_k_50[] = "Property for getting/setting the offset between the dashes in the curve\n\n        .. versionadded:: 1.0.8\n        ";
static char __pyx_k_51[] = "Determine the width of the line, default to 1.0.\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_52[] = "Determine the cap of the line, default to 'round'. Can be one of\n        'none', 'square' or 'round'\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_53[] = "Determine the join of the line, default to 'round'. Can be one of\n        'none', 'round', 'bevel', 'miter'.\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_54[] = "Number of iteration for drawing the \"round\" cap, default to 10.\n        The cap_precision must be at least 1.\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_55[] = "Number of iteration for drawing the \"round\" joint, default to 10.\n        The joint_precision must be at least 1.\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_56[] = "If True, the line will be closed.\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_57[] = "Use this property to build an ellipse, without calculate the\n        :data:`points`. You can only set this property, not get it.\n\n        The argument must be a tuple of (x, y, width, height, angle_start,\n        angle_end, segments):\n\n        * x and y represent the bottom left of the ellipse\n        * width and height represent the size of the ellipse\n        * (optional) angle_start and angle_end are in degree. The default\n            value is 0 and 360.\n        * (optional) segments is the precision of the ellipse. The default\n            value is calculated from the range between angle.\n\n        Note that it's up to you to :data:`close` the ellipse or not.\n\n        For example, for building a simple ellipse, in python::\n\n            # simple ellipse\n            Line(ellipse=(0, 0, 150, 150))\n\n            # only from 90 to 180 degrees\n            Line(ellipse=(0, 0, 150, 150, 90, 180))\n\n            # only from 90 to 180 degrees, with few segments\n            Line(ellipse=(0, 0, 150, 150, 90, 180, 20))\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_58[] = "Use this property to build a circle, without calculate the\n        :data:`points`. You can only set this property, not get it.\n\n        The argument must be a tuple of (center_x, center_y, radius, angle_start,\n        angle_end, segments):\n\n        * center_x and center_y represent the center of the circle\n        * radius represent the radius of the circle\n        * (optional) angle_start and angle_end are in degree. The default\n            value is 0 and 360.\n        * (optional) segments is the precision of the ellipse. The default\n            value is calculated from the range between angle.\n\n        Note that it's up to you to :data:`close` the circle or not.\n\n        For example, for building a simple ellipse, in python::\n\n            # simple circle\n            Line(circle=(150, 150, 50))\n\n            # only from 90 to 180 degrees\n            Line(circle=(150, 150, 50, 90, 180))\n\n            # only from 90 to 180 degrees, with few segments\n            Line(circle=(150, 150, 50, 90, 180, 20))\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_59[] = "Use this property to build a rectangle, without calculate the\n        :data:`points`. You can only set this property, not get it.\n\n        The argument must be a tuple of (x, y, width, height)\n        angle_end, segments):\n\n        * x and y represent the bottom-left position of the rectangle\n        * width and height represent the size\n\n        The line is automatically closed.\n\n        Usage::\n\n            Line(rectangle=(0, 0, 200, 200))\n\n        .. versionadded:: 1.4.1\n        ";
static char __pyx_k_60[] = "Property for getting/settings points of the triangle\n\n        .. warning::\n\n            This will always reconstruct the whole graphics from the new points\n            list. It can be very CPU expensive.\n        ";
static char __pyx_k_61[] = "Property for getting/setting the number of segments of the curve\n        ";
static char __pyx_k_62[] = "Property for getting/stting the length of the dashes in the curve\n        ";
static char __pyx_k_63[] = "Property for getting/setting the offset between the dashes in the curve\n        ";
static char __pyx_k_64[] = "List of x, y, u, v, ... used to construct the Mesh. Right now, the\n        Mesh instruction doesn't allow you to change the format of the vertices,\n        mean it's only x/y + one texture coordinate.\n        ";
static char __pyx_k_65[] = "Vertex indices used to know which order you wanna do for drawing the\n        mesh.\n        ";
static char __pyx_k_66[] = "VBO Mode used for drawing vertices/indices. Can be one of: 'points',\n        'line_strip', 'line_loop', 'lines', 'triangle_strip', 'triangle_fan'\n        ";
static char __pyx_k_67[] = "Property for getting/settings points of the triangle\n        ";
static char __pyx_k_68[] = "Property for getting/setting point size\n        ";
static char __pyx_k_69[] = "Property for getting/settings points of the quads\n        ";
static char __pyx_k_70[] = "Property for getting/settings the position of the rectangle\n        ";
static char __pyx_k_71[] = "Property for getting/settings the size of the rectangle\n        ";
static char __pyx_k_72[] = "Property for getting/setting the border of the class\n        ";
static char __pyx_k_73[] = "Property for getting/setting the number of segments of the ellipse\n        ";
static char __pyx_k_74[] = "Angle start of the ellipse in degrees, default to 0\n        ";
static char __pyx_k_75[] = "Angle end of the ellipse in degrees, default to 360\n        ";
static char __pyx_k_76[] = "\nVertex Instructions\n===================\n\nThis module include all the classes for drawing simple vertex object.\n";
static char __pyx_k_78[] = "kivy.logger";
static char __pyx_k_79[] = "Exception fired when a graphic error is fired.\n    ";
static char __pyx_k_80[] = "kivy.graphics.vertex_instructions";
static char __pyx_k__x[] = "x";
static char __pyx_k__y[] = "y";
static char __pyx_k__op[] = "op";
static char __pyx_k__cap[] = "cap";
static char __pyx_k__pos[] = "pos";
static char __pyx_k__Line[] = "Line";
static char __pyx_k__Mesh[] = "Mesh";
static char __pyx_k__Quad[] = "Quad";
static char __pyx_k__loop[] = "loop";
static char __pyx_k__mode[] = "mode";
static char __pyx_k__none[] = "none";
static char __pyx_k__rgba[] = "rgba";
static char __pyx_k__size[] = "size";
static char __pyx_k__wrap[] = "wrap";
static char __pyx_k__Point[] = "Point";
static char __pyx_k__bevel[] = "bevel";
static char __pyx_k__close[] = "close";
static char __pyx_k__color[] = "color";
static char __pyx_k__joint[] = "joint";
static char __pyx_k__miter[] = "miter";
static char __pyx_k__range[] = "range";
static char __pyx_k__round[] = "round";
static char __pyx_k__trace[] = "trace";
static char __pyx_k__ubyte[] = "ubyte";
static char __pyx_k__width[] = "width";
static char __pyx_k__Bezier[] = "Bezier";
static char __pyx_k__Logger[] = "Logger";
static char __pyx_k__border[] = "border";
static char __pyx_k__create[] = "create";
static char __pyx_k__extend[] = "extend";
static char __pyx_k__format[] = "format";
static char __pyx_k__points[] = "points";
static char __pyx_k__repeat[] = "repeat";
static char __pyx_k__square[] = "square";
static char __pyx_k__xrange[] = "xrange";
static char __pyx_k__Ellipse[] = "Ellipse";
static char __pyx_k____all__[] = "__all__";
static char __pyx_k__indices[] = "indices";
static char __pyx_k__texture[] = "texture";
static char __pyx_k__Triangle[] = "Triangle";
static char __pyx_k____init__[] = "__init__";
static char __pyx_k____main__[] = "__main__";
static char __pyx_k____test__[] = "__test__";
static char __pyx_k__colorfmt[] = "colorfmt";
static char __pyx_k__segments[] = "segments";
static char __pyx_k__vertices[] = "vertices";
static char __pyx_k__Exception[] = "Exception";
static char __pyx_k__Rectangle[] = "Rectangle";
static char __pyx_k__angle_end[] = "angle_end";
static char __pyx_k__bufferfmt[] = "bufferfmt";
static char __pyx_k__pointsize[] = "pointsize";
static char __pyx_k__triangles[] = "triangles";
static char __pyx_k__line_strip[] = "line_strip";
static char __pyx_k__tex_coords[] = "tex_coords";
static char __pyx_k__BorderImage[] = "BorderImage";
static char __pyx_k__MemoryError[] = "MemoryError";
static char __pyx_k__angle_start[] = "angle_start";
static char __pyx_k__blit_buffer[] = "blit_buffer";
static char __pyx_k__dash_length[] = "dash_length";
static char __pyx_k__dash_offset[] = "dash_offset";
static char __pyx_k__triangle_fan[] = "triangle_fan";
static char __pyx_k__cap_precision[] = "cap_precision";
static char __pyx_k__joint_precision[] = "joint_precision";
static char __pyx_k__GraphicException[] = "GraphicException";
static PyObject *__pyx_kp_s_11;
static PyObject *__pyx_kp_s_13;
static PyObject *__pyx_kp_s_15;
static PyObject *__pyx_kp_s_18;
static PyObject *__pyx_kp_s_19;
static PyObject *__pyx_kp_s_20;
static PyObject *__pyx_kp_s_21;
static PyObject *__pyx_kp_s_22;
static PyObject *__pyx_kp_s_23;
static PyObject *__pyx_kp_s_26;
static PyObject *__pyx_kp_s_32;
static PyObject *__pyx_kp_s_36;
static PyObject *__pyx_kp_s_38;
static PyObject *__pyx_kp_s_40;
static PyObject *__pyx_kp_s_44;
static PyObject *__pyx_kp_s_5;
static PyObject *__pyx_kp_s_7;
static PyObject *__pyx_n_s_78;
static PyObject *__pyx_kp_s_79;
static PyObject *__pyx_n_s_80;
static PyObject *__pyx_kp_s_9;
static PyObject *__pyx_n_s__Bezier;
static PyObject *__pyx_n_s__BorderImage;
static PyObject *__pyx_n_s__Ellipse;
static PyObject *__pyx_n_s__Exception;
static PyObject *__pyx_n_s__GraphicException;
static PyObject *__pyx_n_s__Line;
static PyObject *__pyx_n_s__Logger;
static PyObject *__pyx_n_s__MemoryError;
static PyObject *__pyx_n_s__Mesh;
static PyObject *__pyx_n_s__Point;
static PyObject *__pyx_n_s__Quad;
static PyObject *__pyx_n_s__Rectangle;
static PyObject *__pyx_n_s__Triangle;
static PyObject *__pyx_n_s____all__;
static PyObject *__pyx_n_s____init__;
static PyObject *__pyx_n_s____main__;
static PyObject *__pyx_n_s____test__;
static PyObject *__pyx_n_s__angle_end;
static PyObject *__pyx_n_s__angle_start;
static PyObject *__pyx_n_s__bevel;
static PyObject *__pyx_n_s__blit_buffer;
static PyObject *__pyx_n_s__border;
static PyObject *__pyx_n_s__bufferfmt;
static PyObject *__pyx_n_s__cap;
static PyObject *__pyx_n_s__cap_precision;
static PyObject *__pyx_n_s__close;
static PyObject *__pyx_n_s__color;
static PyObject *__pyx_n_s__colorfmt;
static PyObject *__pyx_n_s__create;
static PyObject *__pyx_n_s__dash_length;
static PyObject *__pyx_n_s__dash_offset;
static PyObject *__pyx_n_s__extend;
static PyObject *__pyx_n_s__format;
static PyObject *__pyx_n_s__indices;
static PyObject *__pyx_n_s__joint;
static PyObject *__pyx_n_s__joint_precision;
static PyObject *__pyx_n_s__line_strip;
static PyObject *__pyx_n_s__loop;
static PyObject *__pyx_n_s__miter;
static PyObject *__pyx_n_s__mode;
static PyObject *__pyx_n_s__none;
static PyObject *__pyx_n_s__op;
static PyObject *__pyx_n_s__points;
static PyObject *__pyx_n_s__pointsize;
static PyObject *__pyx_n_s__pos;
static PyObject *__pyx_n_s__range;
static PyObject *__pyx_n_s__repeat;
static PyObject *__pyx_n_s__rgba;
static PyObject *__pyx_n_s__round;
static PyObject *__pyx_n_s__segments;
static PyObject *__pyx_n_s__size;
static PyObject *__pyx_n_s__square;
static PyObject *__pyx_n_s__tex_coords;
static PyObject *__pyx_n_s__texture;
static PyObject *__pyx_n_s__trace;
static PyObject *__pyx_n_s__triangle_fan;
static PyObject *__pyx_n_s__triangles;
static PyObject *__pyx_n_s__ubyte;
static PyObject *__pyx_n_s__vertices;
static PyObject *__pyx_n_s__width;
static PyObject *__pyx_n_s__wrap;
static PyObject *__pyx_n_s__x;
static PyObject *__pyx_n_s__xrange;
static PyObject *__pyx_n_s__y;
static PyObject *__pyx_int_0;
static PyObject *__pyx_int_1;
static PyObject *__pyx_int_2;
static PyObject *__pyx_int_3;
static PyObject *__pyx_int_10;
static PyObject *__pyx_int_100;
static PyObject *__pyx_int_180;
static PyObject *__pyx_int_360;
static PyObject *__pyx_k_tuple_1;
static PyObject *__pyx_k_tuple_2;
static PyObject *__pyx_k_tuple_3;
static PyObject *__pyx_k_tuple_4;
static PyObject *__pyx_k_tuple_6;
static PyObject *__pyx_k_tuple_8;
static PyObject *__pyx_k_tuple_10;
static PyObject *__pyx_k_tuple_12;
static PyObject *__pyx_k_tuple_14;
static PyObject *__pyx_k_tuple_16;
static PyObject *__pyx_k_tuple_17;
static PyObject *__pyx_k_tuple_24;
static PyObject *__pyx_k_tuple_25;
static PyObject *__pyx_k_tuple_27;
static PyObject *__pyx_k_tuple_28;
static PyObject *__pyx_k_tuple_29;
static PyObject *__pyx_k_tuple_30;
static PyObject *__pyx_k_tuple_31;
static PyObject *__pyx_k_tuple_33;
static PyObject *__pyx_k_tuple_34;
static PyObject *__pyx_k_tuple_35;
static PyObject *__pyx_k_tuple_37;
static PyObject *__pyx_k_tuple_39;
static PyObject *__pyx_k_tuple_41;
static PyObject *__pyx_k_tuple_42;
static PyObject *__pyx_k_tuple_43;
static PyObject *__pyx_k_tuple_45;
static PyObject *__pyx_k_tuple_46;
static PyObject *__pyx_k_tuple_47;
static PyObject *__pyx_k_tuple_77;

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":17
 * from kivy.graphics.stencil_instructions cimport StencilUse, StencilUnUse, StencilPush, StencilPop
 * 
 * cdef inline int line_intersection(double x1, double y1, double x2, double y2,             # <<<<<<<<<<<<<<
 *         double x3, double y3, double x4, double y4, double *px, double *py):
 *     cdef double u = (x1 * y2 - y1 * x2)
 */

static CYTHON_INLINE int __pyx_f_4kivy_8graphics_19vertex_instructions_line_intersection(double __pyx_v_x1, double __pyx_v_y1, double __pyx_v_x2, double __pyx_v_y2, double __pyx_v_x3, double __pyx_v_y3, double __pyx_v_x4, double __pyx_v_y4, double *__pyx_v_px, double *__pyx_v_py) {
  double __pyx_v_u;
  double __pyx_v_v;
  double __pyx_v_denom;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  double __pyx_t_2;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("line_intersection", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":19
 * cdef inline int line_intersection(double x1, double y1, double x2, double y2,
 *         double x3, double y3, double x4, double y4, double *px, double *py):
 *     cdef double u = (x1 * y2 - y1 * x2)             # <<<<<<<<<<<<<<
 *     cdef double v = (x3 * y4 - y3 * x4)
 *     cdef double denom = (x1 - x2) * (y3 - y4) - (y1 - y2) * (x3 - x4)
 */
  __pyx_v_u = ((__pyx_v_x1 * __pyx_v_y2) - (__pyx_v_y1 * __pyx_v_x2));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":20
 *         double x3, double y3, double x4, double y4, double *px, double *py):
 *     cdef double u = (x1 * y2 - y1 * x2)
 *     cdef double v = (x3 * y4 - y3 * x4)             # <<<<<<<<<<<<<<
 *     cdef double denom = (x1 - x2) * (y3 - y4) - (y1 - y2) * (x3 - x4)
 *     if denom == 0:
 */
  __pyx_v_v = ((__pyx_v_x3 * __pyx_v_y4) - (__pyx_v_y3 * __pyx_v_x4));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":21
 *     cdef double u = (x1 * y2 - y1 * x2)
 *     cdef double v = (x3 * y4 - y3 * x4)
 *     cdef double denom = (x1 - x2) * (y3 - y4) - (y1 - y2) * (x3 - x4)             # <<<<<<<<<<<<<<
 *     if denom == 0:
 *         return 0
 */
  __pyx_v_denom = (((__pyx_v_x1 - __pyx_v_x2) * (__pyx_v_y3 - __pyx_v_y4)) - ((__pyx_v_y1 - __pyx_v_y2) * (__pyx_v_x3 - __pyx_v_x4)));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":22
 *     cdef double v = (x3 * y4 - y3 * x4)
 *     cdef double denom = (x1 - x2) * (y3 - y4) - (y1 - y2) * (x3 - x4)
 *     if denom == 0:             # <<<<<<<<<<<<<<
 *         return 0
 *     px[0] = (u * (x3 - x4) - (x1 - x2) * v) / denom
 */
  __pyx_t_1 = (__pyx_v_denom == 0.0);
  if (__pyx_t_1) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":23
 *     cdef double denom = (x1 - x2) * (y3 - y4) - (y1 - y2) * (x3 - x4)
 *     if denom == 0:
 *         return 0             # <<<<<<<<<<<<<<
 *     px[0] = (u * (x3 - x4) - (x1 - x2) * v) / denom
 *     py[0] = (u * (y3 - y4) - (y1 - y2) * v) / denom
 */
    __pyx_r = 0;
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":24
 *     if denom == 0:
 *         return 0
 *     px[0] = (u * (x3 - x4) - (x1 - x2) * v) / denom             # <<<<<<<<<<<<<<
 *     py[0] = (u * (y3 - y4) - (y1 - y2) * v) / denom
 *     return 1
 */
  __pyx_t_2 = ((__pyx_v_u * (__pyx_v_x3 - __pyx_v_x4)) - ((__pyx_v_x1 - __pyx_v_x2) * __pyx_v_v));
  if (unlikely(__pyx_v_denom == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  (__pyx_v_px[0]) = (__pyx_t_2 / __pyx_v_denom);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":25
 *         return 0
 *     px[0] = (u * (x3 - x4) - (x1 - x2) * v) / denom
 *     py[0] = (u * (y3 - y4) - (y1 - y2) * v) / denom             # <<<<<<<<<<<<<<
 *     return 1
 * 
 */
  __pyx_t_2 = ((__pyx_v_u * (__pyx_v_y3 - __pyx_v_y4)) - ((__pyx_v_y1 - __pyx_v_y2) * __pyx_v_v));
  if (unlikely(__pyx_v_denom == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  (__pyx_v_py[0]) = (__pyx_t_2 / __pyx_v_denom);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":26
 *     px[0] = (u * (x3 - x4) - (x1 - x2) * v) / denom
 *     py[0] = (u * (y3 - y4) - (y1 - y2) * v) / denom
 *     return 1             # <<<<<<<<<<<<<<
 * 
 * cdef class Line(VertexInstruction):
 */
  __pyx_r = 1;
  goto __pyx_L0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.line_intersection", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":106
 *     cdef tuple _mode_args
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_t_6;
  float __pyx_t_7;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":107
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else []
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 107; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 107; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 107; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":108
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')             # <<<<<<<<<<<<<<
 *         self.points = v if v is not None else []
 *         self.batch.set_mode('line_strip')
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__points), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":109
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else []             # <<<<<<<<<<<<<<
 *         self.batch.set_mode('line_strip')
 *         self._dash_length = kwargs.get('dash_length') or 1
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = ((PyObject *)__pyx_t_3);
    __pyx_t_3 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":110
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else []
 *         self.batch.set_mode('line_strip')             # <<<<<<<<<<<<<<
 *         self._dash_length = kwargs.get('dash_length') or 1
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 */
  __pyx_t_4 = ((PyObject *)__pyx_n_s__line_strip);
  __Pyx_INCREF(__pyx_t_4);
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_mode(__pyx_v_self->__pyx_base.batch, ((PyObject*)__pyx_t_4));
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":111
 *         self.points = v if v is not None else []
 *         self.batch.set_mode('line_strip')
 *         self._dash_length = kwargs.get('dash_length') or 1             # <<<<<<<<<<<<<<
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 *         self._width = kwargs.get('width') or 1.0
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__dash_length), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(__pyx_int_1);
    __pyx_t_3 = __pyx_int_1;
  } else {
    __pyx_t_3 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_3); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_v_self->_dash_length = __pyx_t_6;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":112
 *         self.batch.set_mode('line_strip')
 *         self._dash_length = kwargs.get('dash_length') or 1
 *         self._dash_offset = kwargs.get('dash_offset') or 0             # <<<<<<<<<<<<<<
 *         self._width = kwargs.get('width') or 1.0
 *         self.joint = kwargs.get('joint') or 'round'
 */
  __pyx_t_3 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__dash_offset), Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_INCREF(__pyx_int_0);
    __pyx_t_4 = __pyx_int_0;
  } else {
    __pyx_t_4 = __pyx_t_3;
    __pyx_t_3 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_4); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_v_self->_dash_offset = __pyx_t_6;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":113
 *         self._dash_length = kwargs.get('dash_length') or 1
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 *         self._width = kwargs.get('width') or 1.0             # <<<<<<<<<<<<<<
 *         self.joint = kwargs.get('joint') or 'round'
 *         self.cap = kwargs.get('cap') or 'round'
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__width), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 113; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 113; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_3 = PyFloat_FromDouble(1.0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 113; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_2 = __pyx_t_3;
    __pyx_t_3 = 0;
  } else {
    __pyx_t_2 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_7 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_7 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 113; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_self->_width = __pyx_t_7;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":114
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 *         self._width = kwargs.get('width') or 1.0
 *         self.joint = kwargs.get('joint') or 'round'             # <<<<<<<<<<<<<<
 *         self.cap = kwargs.get('cap') or 'round'
 *         self._cap_precision = kwargs.get('cap_precision') or 10
 */
  __pyx_t_2 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__joint), Py_None); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(((PyObject *)__pyx_n_s__round));
    __pyx_t_4 = __pyx_n_s__round;
  } else {
    __pyx_t_4 = __pyx_t_2;
    __pyx_t_2 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__joint, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":115
 *         self._width = kwargs.get('width') or 1.0
 *         self.joint = kwargs.get('joint') or 'round'
 *         self.cap = kwargs.get('cap') or 'round'             # <<<<<<<<<<<<<<
 *         self._cap_precision = kwargs.get('cap_precision') or 10
 *         self._joint_precision = kwargs.get('joint_precision') or 10
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__cap), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(((PyObject *)__pyx_n_s__round));
    __pyx_t_2 = __pyx_n_s__round;
  } else {
    __pyx_t_2 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__cap, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":116
 *         self.joint = kwargs.get('joint') or 'round'
 *         self.cap = kwargs.get('cap') or 'round'
 *         self._cap_precision = kwargs.get('cap_precision') or 10             # <<<<<<<<<<<<<<
 *         self._joint_precision = kwargs.get('joint_precision') or 10
 *         self._close = int(bool(kwargs.get('close', 0)))
 */
  __pyx_t_2 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__cap_precision), Py_None); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(__pyx_int_10);
    __pyx_t_4 = __pyx_int_10;
  } else {
    __pyx_t_4 = __pyx_t_2;
    __pyx_t_2 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_4); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_v_self->_cap_precision = __pyx_t_6;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":117
 *         self.cap = kwargs.get('cap') or 'round'
 *         self._cap_precision = kwargs.get('cap_precision') or 10
 *         self._joint_precision = kwargs.get('joint_precision') or 10             # <<<<<<<<<<<<<<
 *         self._close = int(bool(kwargs.get('close', 0)))
 *         self._stencil_rect = None
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__joint_precision), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(__pyx_int_10);
    __pyx_t_2 = __pyx_int_10;
  } else {
    __pyx_t_2 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_2); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_self->_joint_precision = __pyx_t_6;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":118
 *         self._cap_precision = kwargs.get('cap_precision') or 10
 *         self._joint_precision = kwargs.get('joint_precision') or 10
 *         self._close = int(bool(kwargs.get('close', 0)))             # <<<<<<<<<<<<<<
 *         self._stencil_rect = None
 *         self._stencil_push = None
 */
  __pyx_t_2 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__close), __pyx_int_0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_self->_close = ((int)(!(!__pyx_t_5)));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":119
 *         self._joint_precision = kwargs.get('joint_precision') or 10
 *         self._close = int(bool(kwargs.get('close', 0)))
 *         self._stencil_rect = None             # <<<<<<<<<<<<<<
 *         self._stencil_push = None
 *         self._stencil_use = None
 */
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->_stencil_rect);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_rect));
  __pyx_v_self->_stencil_rect = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":120
 *         self._close = int(bool(kwargs.get('close', 0)))
 *         self._stencil_rect = None
 *         self._stencil_push = None             # <<<<<<<<<<<<<<
 *         self._stencil_use = None
 *         self._stencil_unuse = None
 */
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->_stencil_push);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_push));
  __pyx_v_self->_stencil_push = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":121
 *         self._stencil_rect = None
 *         self._stencil_push = None
 *         self._stencil_use = None             # <<<<<<<<<<<<<<
 *         self._stencil_unuse = None
 *         self._stencil_pop = None
 */
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->_stencil_use);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_use));
  __pyx_v_self->_stencil_use = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":122
 *         self._stencil_push = None
 *         self._stencil_use = None
 *         self._stencil_unuse = None             # <<<<<<<<<<<<<<
 *         self._stencil_pop = None
 *         self._use_stencil = 0
 */
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->_stencil_unuse);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_unuse));
  __pyx_v_self->_stencil_unuse = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":123
 *         self._stencil_use = None
 *         self._stencil_unuse = None
 *         self._stencil_pop = None             # <<<<<<<<<<<<<<
 *         self._use_stencil = 0
 * 
 */
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->_stencil_pop);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_pop));
  __pyx_v_self->_stencil_pop = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":124
 *         self._stencil_unuse = None
 *         self._stencil_pop = None
 *         self._use_stencil = 0             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_v_self->_use_stencil = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":126
 *         self._use_stencil = 0
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         if self._mode == LINE_MODE_ELLIPSE:
 *             self.prebuild_ellipse()
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  __Pyx_RefNannySetupContext("build", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":131
 *         elif self._mode == LINE_MODE_CIRCLE:
 *             self.prebuild_circle()
 *         elif self._mode == LINE_MODE_RECTANGLE:             # <<<<<<<<<<<<<<
 *             self.prebuild_rectangle()
 *         if self._width == 1.0:
 */
  switch (__pyx_v_self->_mode) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":127
 * 
 *     cdef void build(self):
 *         if self._mode == LINE_MODE_ELLIPSE:             # <<<<<<<<<<<<<<
 *             self.prebuild_ellipse()
 *         elif self._mode == LINE_MODE_CIRCLE:
 */
    case 1:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":128
 *     cdef void build(self):
 *         if self._mode == LINE_MODE_ELLIPSE:
 *             self.prebuild_ellipse()             # <<<<<<<<<<<<<<
 *         elif self._mode == LINE_MODE_CIRCLE:
 *             self.prebuild_circle()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->prebuild_ellipse(__pyx_v_self);
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":129
 *         if self._mode == LINE_MODE_ELLIPSE:
 *             self.prebuild_ellipse()
 *         elif self._mode == LINE_MODE_CIRCLE:             # <<<<<<<<<<<<<<
 *             self.prebuild_circle()
 *         elif self._mode == LINE_MODE_RECTANGLE:
 */
    case 2:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":130
 *             self.prebuild_ellipse()
 *         elif self._mode == LINE_MODE_CIRCLE:
 *             self.prebuild_circle()             # <<<<<<<<<<<<<<
 *         elif self._mode == LINE_MODE_RECTANGLE:
 *             self.prebuild_rectangle()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->prebuild_circle(__pyx_v_self);
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":131
 *         elif self._mode == LINE_MODE_CIRCLE:
 *             self.prebuild_circle()
 *         elif self._mode == LINE_MODE_RECTANGLE:             # <<<<<<<<<<<<<<
 *             self.prebuild_rectangle()
 *         if self._width == 1.0:
 */
    case 3:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":132
 *             self.prebuild_circle()
 *         elif self._mode == LINE_MODE_RECTANGLE:
 *             self.prebuild_rectangle()             # <<<<<<<<<<<<<<
 *         if self._width == 1.0:
 *             self.build_legacy()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->prebuild_rectangle(__pyx_v_self);
    break;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":133
 *         elif self._mode == LINE_MODE_RECTANGLE:
 *             self.prebuild_rectangle()
 *         if self._width == 1.0:             # <<<<<<<<<<<<<<
 *             self.build_legacy()
 *         else:
 */
  __pyx_t_1 = (__pyx_v_self->_width == 1.0);
  if (__pyx_t_1) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":134
 *             self.prebuild_rectangle()
 *         if self._width == 1.0:
 *             self.build_legacy()             # <<<<<<<<<<<<<<
 *         else:
 *             self.build_extended()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->build_legacy(__pyx_v_self);
    goto __pyx_L3;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":136
 *             self.build_legacy()
 *         else:
 *             self.build_extended()             # <<<<<<<<<<<<<<
 * 
 *     cdef void ensure_stencil(self):
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->build_extended(__pyx_v_self);
  }
  __pyx_L3:;

  __Pyx_RefNannyFinishContext();
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":138
 *             self.build_extended()
 * 
 *     cdef void ensure_stencil(self):             # <<<<<<<<<<<<<<
 *         if self._stencil_rect == None:
 *             self._stencil_rect = Rectangle()
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_ensure_stencil(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("ensure_stencil", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":139
 * 
 *     cdef void ensure_stencil(self):
 *         if self._stencil_rect == None:             # <<<<<<<<<<<<<<
 *             self._stencil_rect = Rectangle()
 *             self._stencil_push = StencilPush()
 */
  __pyx_t_1 = PyObject_RichCompare(((PyObject *)__pyx_v_self->_stencil_rect), Py_None, Py_EQ); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 139; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 139; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":140
 *     cdef void ensure_stencil(self):
 *         if self._stencil_rect == None:
 *             self._stencil_rect = Rectangle()             # <<<<<<<<<<<<<<
 *             self._stencil_push = StencilPush()
 *             self._stencil_pop = StencilPop()
 */
    __pyx_t_1 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle)), ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 140; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __Pyx_GOTREF(__pyx_v_self->_stencil_rect);
    __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_rect));
    __pyx_v_self->_stencil_rect = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_t_1);
    __pyx_t_1 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":141
 *         if self._stencil_rect == None:
 *             self._stencil_rect = Rectangle()
 *             self._stencil_push = StencilPush()             # <<<<<<<<<<<<<<
 *             self._stencil_pop = StencilPop()
 *             self._stencil_use = StencilUse(op=GL_LEQUAL)
 */
    __pyx_t_1 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPush)), ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __Pyx_GOTREF(__pyx_v_self->_stencil_push);
    __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_push));
    __pyx_v_self->_stencil_push = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_t_1);
    __pyx_t_1 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":142
 *             self._stencil_rect = Rectangle()
 *             self._stencil_push = StencilPush()
 *             self._stencil_pop = StencilPop()             # <<<<<<<<<<<<<<
 *             self._stencil_use = StencilUse(op=GL_LEQUAL)
 *             self._stencil_unuse = StencilUnUse()
 */
    __pyx_t_1 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPop)), ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __Pyx_GOTREF(__pyx_v_self->_stencil_pop);
    __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_pop));
    __pyx_v_self->_stencil_pop = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_t_1);
    __pyx_t_1 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":143
 *             self._stencil_push = StencilPush()
 *             self._stencil_pop = StencilPop()
 *             self._stencil_use = StencilUse(op=GL_LEQUAL)             # <<<<<<<<<<<<<<
 *             self._stencil_unuse = StencilUnUse()
 * 
 */
    __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_1));
    __pyx_t_3 = PyInt_FromLong(GL_LEQUAL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    if (PyDict_SetItem(__pyx_t_1, ((PyObject *)__pyx_n_s__op), __pyx_t_3) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUse)), ((PyObject *)__pyx_empty_tuple), ((PyObject *)__pyx_t_1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
    __Pyx_GIVEREF(__pyx_t_3);
    __Pyx_GOTREF(__pyx_v_self->_stencil_use);
    __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_use));
    __pyx_v_self->_stencil_use = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_t_3);
    __pyx_t_3 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":144
 *             self._stencil_pop = StencilPop()
 *             self._stencil_use = StencilUse(op=GL_LEQUAL)
 *             self._stencil_unuse = StencilUnUse()             # <<<<<<<<<<<<<<
 * 
 *     cdef void apply(self):
 */
    __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUnUse)), ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_GIVEREF(__pyx_t_3);
    __Pyx_GOTREF(__pyx_v_self->_stencil_unuse);
    __Pyx_DECREF(((PyObject *)__pyx_v_self->_stencil_unuse));
    __pyx_v_self->_stencil_unuse = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_t_3);
    __pyx_t_3 = 0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.ensure_stencil", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":146
 *             self._stencil_unuse = StencilUnUse()
 * 
 *     cdef void apply(self):             # <<<<<<<<<<<<<<
 *         if self._width == 1.:
 *             VertexInstruction.apply(self)
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_apply(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  double __pyx_v_alpha;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  double __pyx_t_4;
  PyObject *__pyx_t_5 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("apply", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":147
 * 
 *     cdef void apply(self):
 *         if self._width == 1.:             # <<<<<<<<<<<<<<
 *             VertexInstruction.apply(self)
 *             return
 */
  __pyx_t_1 = (__pyx_v_self->_width == 1.);
  if (__pyx_t_1) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":148
 *     cdef void apply(self):
 *         if self._width == 1.:
 *             VertexInstruction.apply(self)             # <<<<<<<<<<<<<<
 *             return
 * 
 */
    __pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction->__pyx_base.apply(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":149
 *         if self._width == 1.:
 *             VertexInstruction.apply(self)
 *             return             # <<<<<<<<<<<<<<
 * 
 *         cdef double alpha = getActiveContext()['color'][-1]
 */
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":151
 *             return
 * 
 *         cdef double alpha = getActiveContext()['color'][-1]             # <<<<<<<<<<<<<<
 *         self._use_stencil = alpha < 1
 *         if self._use_stencil:
 */
  __pyx_t_2 = ((PyObject *)__pyx_f_4kivy_8graphics_12instructions_getActiveContext()); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 151; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = PyObject_GetItem(__pyx_t_2, ((PyObject *)__pyx_n_s__color)); if (!__pyx_t_3) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 151; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_GetItemInt(__pyx_t_3, -1, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 151; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_4 = __pyx_PyFloat_AsDouble(__pyx_t_2); if (unlikely((__pyx_t_4 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 151; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_alpha = __pyx_t_4;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":152
 * 
 *         cdef double alpha = getActiveContext()['color'][-1]
 *         self._use_stencil = alpha < 1             # <<<<<<<<<<<<<<
 *         if self._use_stencil:
 *             self.ensure_stencil()
 */
  __pyx_v_self->_use_stencil = (__pyx_v_alpha < 1.0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":153
 *         cdef double alpha = getActiveContext()['color'][-1]
 *         self._use_stencil = alpha < 1
 *         if self._use_stencil:             # <<<<<<<<<<<<<<
 *             self.ensure_stencil()
 * 
 */
  if (__pyx_v_self->_use_stencil) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":154
 *         self._use_stencil = alpha < 1
 *         if self._use_stencil:
 *             self.ensure_stencil()             # <<<<<<<<<<<<<<
 * 
 *             self._stencil_push.apply()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->ensure_stencil(__pyx_v_self);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":156
 *             self.ensure_stencil()
 * 
 *             self._stencil_push.apply()             # <<<<<<<<<<<<<<
 *             VertexInstruction.apply(self)
 *             self._stencil_use.apply()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self->_stencil_push->__pyx_vtab)->apply(__pyx_v_self->_stencil_push);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":157
 * 
 *             self._stencil_push.apply()
 *             VertexInstruction.apply(self)             # <<<<<<<<<<<<<<
 *             self._stencil_use.apply()
 *             self._stencil_rect.pos = self._bxmin, self._bymin
 */
    __pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction->__pyx_base.apply(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":158
 *             self._stencil_push.apply()
 *             VertexInstruction.apply(self)
 *             self._stencil_use.apply()             # <<<<<<<<<<<<<<
 *             self._stencil_rect.pos = self._bxmin, self._bymin
 *             self._stencil_rect.size = self._bxmax - self._bxmin, self._bymax - self._bymin
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self->_stencil_use->__pyx_vtab)->apply(__pyx_v_self->_stencil_use);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":159
 *             VertexInstruction.apply(self)
 *             self._stencil_use.apply()
 *             self._stencil_rect.pos = self._bxmin, self._bymin             # <<<<<<<<<<<<<<
 *             self._stencil_rect.size = self._bxmax - self._bxmin, self._bymax - self._bymin
 *             self._stencil_rect.apply()
 */
    __pyx_t_2 = PyFloat_FromDouble(__pyx_v_self->_bxmin); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_3 = PyFloat_FromDouble(__pyx_v_self->_bymin); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_5 = PyTuple_New(2); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_3);
    __Pyx_GIVEREF(__pyx_t_3);
    __pyx_t_2 = 0;
    __pyx_t_3 = 0;
    if (PyObject_SetAttr(((PyObject *)__pyx_v_self->_stencil_rect), __pyx_n_s__pos, ((PyObject *)__pyx_t_5)) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(((PyObject *)__pyx_t_5)); __pyx_t_5 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":160
 *             self._stencil_use.apply()
 *             self._stencil_rect.pos = self._bxmin, self._bymin
 *             self._stencil_rect.size = self._bxmax - self._bxmin, self._bymax - self._bymin             # <<<<<<<<<<<<<<
 *             self._stencil_rect.apply()
 *             self._stencil_unuse.apply()
 */
    __pyx_t_5 = PyFloat_FromDouble((__pyx_v_self->_bxmax - __pyx_v_self->_bxmin)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 160; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_3 = PyFloat_FromDouble((__pyx_v_self->_bymax - __pyx_v_self->_bymin)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 160; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 160; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_5);
    __Pyx_GIVEREF(__pyx_t_5);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3);
    __Pyx_GIVEREF(__pyx_t_3);
    __pyx_t_5 = 0;
    __pyx_t_3 = 0;
    if (PyObject_SetAttr(((PyObject *)__pyx_v_self->_stencil_rect), __pyx_n_s__size, ((PyObject *)__pyx_t_2)) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 160; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":161
 *             self._stencil_rect.pos = self._bxmin, self._bymin
 *             self._stencil_rect.size = self._bxmax - self._bxmin, self._bymax - self._bymin
 *             self._stencil_rect.apply()             # <<<<<<<<<<<<<<
 *             self._stencil_unuse.apply()
 *             VertexInstruction.apply(self)
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self->_stencil_rect->__pyx_vtab)->apply(__pyx_v_self->_stencil_rect);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":162
 *             self._stencil_rect.size = self._bxmax - self._bxmin, self._bymax - self._bymin
 *             self._stencil_rect.apply()
 *             self._stencil_unuse.apply()             # <<<<<<<<<<<<<<
 *             VertexInstruction.apply(self)
 *             self._stencil_pop.apply()
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self->_stencil_unuse->__pyx_vtab)->apply(__pyx_v_self->_stencil_unuse);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":163
 *             self._stencil_rect.apply()
 *             self._stencil_unuse.apply()
 *             VertexInstruction.apply(self)             # <<<<<<<<<<<<<<
 *             self._stencil_pop.apply()
 *         else:
 */
    __pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction->__pyx_base.apply(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":164
 *             self._stencil_unuse.apply()
 *             VertexInstruction.apply(self)
 *             self._stencil_pop.apply()             # <<<<<<<<<<<<<<
 *         else:
 *             VertexInstruction.apply(self)
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self->_stencil_pop->__pyx_vtab)->apply(__pyx_v_self->_stencil_pop);
    goto __pyx_L4;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":166
 *             self._stencil_pop.apply()
 *         else:
 *             VertexInstruction.apply(self)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build_legacy(self):
 */
    __pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction->__pyx_base.apply(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self));
  }
  __pyx_L4:;

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.apply", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":168
 *             VertexInstruction.apply(self)
 * 
 *     cdef void build_legacy(self):             # <<<<<<<<<<<<<<
 *         cdef int i, count = len(self.points) / 2
 *         cdef list p = self.points
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_build_legacy(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  int __pyx_v_i;
  int __pyx_v_count;
  PyObject *__pyx_v_p = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  float __pyx_v_tex_x;
  char *__pyx_v_buf;
  struct __pyx_obj_4kivy_8graphics_7texture_Texture *__pyx_v_texture = 0;
  PyObject *__pyx_v_p_str = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  Py_ssize_t __pyx_t_2;
  int __pyx_t_3;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  int __pyx_t_6;
  int __pyx_t_7;
  int __pyx_t_8;
  PyObject *__pyx_t_9 = NULL;
  int __pyx_t_10;
  int __pyx_t_11;
  long __pyx_t_12;
  double __pyx_t_13;
  double __pyx_t_14;
  double __pyx_t_15;
  int __pyx_t_16;
  float __pyx_t_17;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build_legacy", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":169
 * 
 *     cdef void build_legacy(self):
 *         cdef int i, count = len(self.points) / 2             # <<<<<<<<<<<<<<
 *         cdef list p = self.points
 *         cdef vertex_t *vertices = NULL
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyObject_Length(__pyx_t_1); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_count = __Pyx_div_Py_ssize_t(__pyx_t_2, 2);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":170
 *     cdef void build_legacy(self):
 *         cdef int i, count = len(self.points) / 2
 *         cdef list p = self.points             # <<<<<<<<<<<<<<
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyList_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_1)->tp_name), 0))) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_p = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":171
 *         cdef int i, count = len(self.points) / 2
 *         cdef list p = self.points
 *         cdef vertex_t *vertices = NULL             # <<<<<<<<<<<<<<
 *         cdef unsigned short *indices = NULL
 *         cdef float tex_x
 */
  __pyx_v_vertices = NULL;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":172
 *         cdef list p = self.points
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL             # <<<<<<<<<<<<<<
 *         cdef float tex_x
 *         cdef char *buf = NULL
 */
  __pyx_v_indices = NULL;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":174
 *         cdef unsigned short *indices = NULL
 *         cdef float tex_x
 *         cdef char *buf = NULL             # <<<<<<<<<<<<<<
 *         cdef Texture texture = self.texture
 * 
 */
  __pyx_v_buf = NULL;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":175
 *         cdef float tex_x
 *         cdef char *buf = NULL
 *         cdef Texture texture = self.texture             # <<<<<<<<<<<<<<
 * 
 *         if count < 2:
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4kivy_8graphics_7texture_Texture))))) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_texture = ((struct __pyx_obj_4kivy_8graphics_7texture_Texture *)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":177
 *         cdef Texture texture = self.texture
 * 
 *         if count < 2:             # <<<<<<<<<<<<<<
 *             self.batch.clear_data()
 *             return
 */
  __pyx_t_3 = (__pyx_v_count < 2);
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":178
 * 
 *         if count < 2:
 *             self.batch.clear_data()             # <<<<<<<<<<<<<<
 *             return
 * 
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->clear_data(__pyx_v_self->__pyx_base.batch);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":179
 *         if count < 2:
 *             self.batch.clear_data()
 *             return             # <<<<<<<<<<<<<<
 * 
 *         if self._close:
 */
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":181
 *             return
 * 
 *         if self._close:             # <<<<<<<<<<<<<<
 *             p = p + [p[0], p[1]]
 *             count += 1
 */
  if (__pyx_v_self->_close) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":182
 * 
 *         if self._close:
 *             p = p + [p[0], p[1]]             # <<<<<<<<<<<<<<
 *             count += 1
 * 
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_5 = PyList_New(2); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    PyList_SET_ITEM(__pyx_t_5, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    PyList_SET_ITEM(__pyx_t_5, 1, __pyx_t_4);
    __Pyx_GIVEREF(__pyx_t_4);
    __pyx_t_1 = 0;
    __pyx_t_4 = 0;
    __pyx_t_4 = PyNumber_Add(((PyObject *)__pyx_v_p), ((PyObject *)__pyx_t_5)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_4));
    __Pyx_DECREF(((PyObject *)__pyx_t_5)); __pyx_t_5 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_v_p));
    __pyx_v_p = __pyx_t_4;
    __pyx_t_4 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":183
 *         if self._close:
 *             p = p + [p[0], p[1]]
 *             count += 1             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_mode('line_strip')
 */
    __pyx_v_count = (__pyx_v_count + 1);
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":185
 *             count += 1
 * 
 *         self.batch.set_mode('line_strip')             # <<<<<<<<<<<<<<
 *         if self._dash_offset != 0:
 *             if texture is None or texture._width != \
 */
  __pyx_t_4 = ((PyObject *)__pyx_n_s__line_strip);
  __Pyx_INCREF(__pyx_t_4);
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_mode(__pyx_v_self->__pyx_base.batch, ((PyObject*)__pyx_t_4));
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":186
 * 
 *         self.batch.set_mode('line_strip')
 *         if self._dash_offset != 0:             # <<<<<<<<<<<<<<
 *             if texture is None or texture._width != \
 *                 (self._dash_length + self._dash_offset) or \
 */
  __pyx_t_3 = (__pyx_v_self->_dash_offset != 0);
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":187
 *         self.batch.set_mode('line_strip')
 *         if self._dash_offset != 0:
 *             if texture is None or texture._width != \             # <<<<<<<<<<<<<<
 *                 (self._dash_length + self._dash_offset) or \
 *                 texture._height != 1:
 */
    __pyx_t_3 = (((PyObject *)__pyx_v_texture) == Py_None);
    if (!__pyx_t_3) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":188
 *         if self._dash_offset != 0:
 *             if texture is None or texture._width != \
 *                 (self._dash_length + self._dash_offset) or \             # <<<<<<<<<<<<<<
 *                 texture._height != 1:
 * 
 */
      __pyx_t_6 = (__pyx_v_texture->_width != (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset));
      if (!__pyx_t_6) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":189
 *             if texture is None or texture._width != \
 *                 (self._dash_length + self._dash_offset) or \
 *                 texture._height != 1:             # <<<<<<<<<<<<<<
 * 
 *                 self.texture = texture = Texture.create(
 */
        __pyx_t_7 = (__pyx_v_texture->_height != 1);
        __pyx_t_8 = __pyx_t_7;
      } else {
        __pyx_t_8 = __pyx_t_6;
      }
      __pyx_t_6 = __pyx_t_8;
    } else {
      __pyx_t_6 = __pyx_t_3;
    }
    if (__pyx_t_6) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":191
 *                 texture._height != 1:
 * 
 *                 self.texture = texture = Texture.create(             # <<<<<<<<<<<<<<
 *                         size=(self._dash_length + self._dash_offset, 1))
 *                 texture.wrap = 'repeat'
 */
      __pyx_t_4 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_7texture_Texture)), __pyx_n_s__create); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_4);
      __pyx_t_5 = PyDict_New(); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(((PyObject *)__pyx_t_5));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":192
 * 
 *                 self.texture = texture = Texture.create(
 *                         size=(self._dash_length + self._dash_offset, 1))             # <<<<<<<<<<<<<<
 *                 texture.wrap = 'repeat'
 * 
 */
      __pyx_t_1 = PyInt_FromLong((__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 192; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __pyx_t_9 = PyTuple_New(2); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 192; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_9);
      PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_1);
      __Pyx_GIVEREF(__pyx_t_1);
      __Pyx_INCREF(__pyx_int_1);
      PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_int_1);
      __Pyx_GIVEREF(__pyx_int_1);
      __pyx_t_1 = 0;
      if (PyDict_SetItem(__pyx_t_5, ((PyObject *)__pyx_n_s__size), ((PyObject *)__pyx_t_9)) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(((PyObject *)__pyx_t_9)); __pyx_t_9 = 0;
      __pyx_t_9 = PyObject_Call(__pyx_t_4, ((PyObject *)__pyx_empty_tuple), ((PyObject *)__pyx_t_5)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_9);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_DECREF(((PyObject *)__pyx_t_5)); __pyx_t_5 = 0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":191
 *                 texture._height != 1:
 * 
 *                 self.texture = texture = Texture.create(             # <<<<<<<<<<<<<<
 *                         size=(self._dash_length + self._dash_offset, 1))
 *                 texture.wrap = 'repeat'
 */
      if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      if (!(likely(((__pyx_t_9) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_9, __pyx_ptype_4kivy_8graphics_7texture_Texture))))) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_INCREF(__pyx_t_9);
      __Pyx_DECREF(((PyObject *)__pyx_v_texture));
      __pyx_v_texture = ((struct __pyx_obj_4kivy_8graphics_7texture_Texture *)__pyx_t_9);
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":193
 *                 self.texture = texture = Texture.create(
 *                         size=(self._dash_length + self._dash_offset, 1))
 *                 texture.wrap = 'repeat'             # <<<<<<<<<<<<<<
 * 
 *             # create a buffer to fill our texture
 */
      if (PyObject_SetAttr(((PyObject *)__pyx_v_texture), __pyx_n_s__wrap, ((PyObject *)__pyx_n_s__repeat)) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 193; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      goto __pyx_L6;
    }
    __pyx_L6:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":196
 * 
 *             # create a buffer to fill our texture
 *             buf = <char *>malloc(4 * (self._dash_length + self._dash_offset))             # <<<<<<<<<<<<<<
 *             memset(buf, 255, self._dash_length * 4)
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)
 */
    __pyx_v_buf = ((char *)malloc((4 * (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset))));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":197
 *             # create a buffer to fill our texture
 *             buf = <char *>malloc(4 * (self._dash_length + self._dash_offset))
 *             memset(buf, 255, self._dash_length * 4)             # <<<<<<<<<<<<<<
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)
 */
    memset(__pyx_v_buf, 255, (__pyx_v_self->_dash_length * 4));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":198
 *             buf = <char *>malloc(4 * (self._dash_length + self._dash_offset))
 *             memset(buf, 255, self._dash_length * 4)
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)             # <<<<<<<<<<<<<<
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)
 * 
 */
    memset((__pyx_v_buf + (__pyx_v_self->_dash_length * 4)), 0, (__pyx_v_self->_dash_offset * 4));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":199
 *             memset(buf, 255, self._dash_length * 4)
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)             # <<<<<<<<<<<<<<
 * 
 *             self.texture.blit_buffer(p_str, colorfmt='rgba', bufferfmt='ubyte')
 */
    __pyx_t_9 = PyString_FromStringAndSize(__pyx_v_buf, ((__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset) * 4)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 199; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_9);
    __pyx_v_p_str = __pyx_t_9;
    __pyx_t_9 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":201
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)
 * 
 *             self.texture.blit_buffer(p_str, colorfmt='rgba', bufferfmt='ubyte')             # <<<<<<<<<<<<<<
 *             free(buf)
 * 
 */
    __pyx_t_9 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_9);
    __pyx_t_5 = PyObject_GetAttr(__pyx_t_9, __pyx_n_s__blit_buffer); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
    __pyx_t_9 = PyTuple_New(1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_9);
    __Pyx_INCREF(__pyx_v_p_str);
    PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_p_str);
    __Pyx_GIVEREF(__pyx_v_p_str);
    __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_4));
    if (PyDict_SetItem(__pyx_t_4, ((PyObject *)__pyx_n_s__colorfmt), ((PyObject *)__pyx_n_s__rgba)) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    if (PyDict_SetItem(__pyx_t_4, ((PyObject *)__pyx_n_s__bufferfmt), ((PyObject *)__pyx_n_s__ubyte)) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_1 = PyObject_Call(__pyx_t_5, ((PyObject *)__pyx_t_9), ((PyObject *)__pyx_t_4)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_9)); __pyx_t_9 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":202
 * 
 *             self.texture.blit_buffer(p_str, colorfmt='rgba', bufferfmt='ubyte')
 *             free(buf)             # <<<<<<<<<<<<<<
 * 
 *         elif texture is not None:
 */
    free(__pyx_v_buf);
    goto __pyx_L5;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":204
 *             free(buf)
 * 
 *         elif texture is not None:             # <<<<<<<<<<<<<<
 *             self.texture = None
 * 
 */
  __pyx_t_6 = (((PyObject *)__pyx_v_texture) != Py_None);
  if (__pyx_t_6) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":205
 * 
 *         elif texture is not None:
 *             self.texture = None             # <<<<<<<<<<<<<<
 * 
 *         vertices = <vertex_t *>malloc(count * sizeof(vertex_t))
 */
    if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture, Py_None) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 205; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":207
 *             self.texture = None
 * 
 *         vertices = <vertex_t *>malloc(count * sizeof(vertex_t))             # <<<<<<<<<<<<<<
 *         if vertices == NULL:
 *             raise MemoryError('vertices')
 */
  __pyx_v_vertices = ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)malloc((__pyx_v_count * (sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)))));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":208
 * 
 *         vertices = <vertex_t *>malloc(count * sizeof(vertex_t))
 *         if vertices == NULL:             # <<<<<<<<<<<<<<
 *             raise MemoryError('vertices')
 * 
 */
  __pyx_t_6 = (__pyx_v_vertices == NULL);
  if (__pyx_t_6) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":209
 *         vertices = <vertex_t *>malloc(count * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(count * sizeof(unsigned short))
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_1), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 209; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 209; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L7;
  }
  __pyx_L7:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":211
 *             raise MemoryError('vertices')
 * 
 *         indices = <unsigned short *>malloc(count * sizeof(unsigned short))             # <<<<<<<<<<<<<<
 *         if indices == NULL:
 *             free(vertices)
 */
  __pyx_v_indices = ((unsigned short *)malloc((__pyx_v_count * (sizeof(unsigned short)))));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":212
 * 
 *         indices = <unsigned short *>malloc(count * sizeof(unsigned short))
 *         if indices == NULL:             # <<<<<<<<<<<<<<
 *             free(vertices)
 *             raise MemoryError('indices')
 */
  __pyx_t_6 = (__pyx_v_indices == NULL);
  if (__pyx_t_6) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":213
 *         indices = <unsigned short *>malloc(count * sizeof(unsigned short))
 *         if indices == NULL:
 *             free(vertices)             # <<<<<<<<<<<<<<
 *             raise MemoryError('indices')
 * 
 */
    free(__pyx_v_vertices);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":214
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         tex_x = 0
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_2), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L8;
  }
  __pyx_L8:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":216
 *             raise MemoryError('indices')
 * 
 *         tex_x = 0             # <<<<<<<<<<<<<<
 *         for i in xrange(count):
 *             if self._dash_offset != 0 and i > 0:
 */
  __pyx_v_tex_x = 0.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":217
 * 
 *         tex_x = 0
 *         for i in xrange(count):             # <<<<<<<<<<<<<<
 *             if self._dash_offset != 0 and i > 0:
 *                 tex_x += sqrt(
 */
  __pyx_t_10 = __pyx_v_count;
  for (__pyx_t_11 = 0; __pyx_t_11 < __pyx_t_10; __pyx_t_11+=1) {
    __pyx_v_i = __pyx_t_11;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":218
 *         tex_x = 0
 *         for i in xrange(count):
 *             if self._dash_offset != 0 and i > 0:             # <<<<<<<<<<<<<<
 *                 tex_x += sqrt(
 *                         pow(p[i * 2]     - p[(i - 1) * 2], 2)  +
 */
    __pyx_t_6 = (__pyx_v_self->_dash_offset != 0);
    if (__pyx_t_6) {
      __pyx_t_3 = (__pyx_v_i > 0);
      __pyx_t_8 = __pyx_t_3;
    } else {
      __pyx_t_8 = __pyx_t_6;
    }
    if (__pyx_t_8) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":220
 *             if self._dash_offset != 0 and i > 0:
 *                 tex_x += sqrt(
 *                         pow(p[i * 2]     - p[(i - 1) * 2], 2)  +             # <<<<<<<<<<<<<<
 *                         pow(p[i * 2 + 1] - p[(i - 1) * 2 + 1], 2)) / (
 *                                 self._dash_length + self._dash_offset)
 */
      if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_12 = (__pyx_v_i * 2);
      __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_12, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_12 = ((__pyx_v_i - 1) * 2);
      __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_12, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_4);
      __pyx_t_9 = PyNumber_Subtract(__pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_9);
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __pyx_t_13 = __pyx_PyFloat_AsDouble(__pyx_t_9); if (unlikely((__pyx_t_13 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":221
 *                 tex_x += sqrt(
 *                         pow(p[i * 2]     - p[(i - 1) * 2], 2)  +
 *                         pow(p[i * 2 + 1] - p[(i - 1) * 2 + 1], 2)) / (             # <<<<<<<<<<<<<<
 *                                 self._dash_length + self._dash_offset)
 * 
 */
      if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_12 = ((__pyx_v_i * 2) + 1);
      __pyx_t_9 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_12, sizeof(long), PyInt_FromLong); if (!__pyx_t_9) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_9);
      if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_12 = (((__pyx_v_i - 1) * 2) + 1);
      __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_12, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_4);
      __pyx_t_1 = PyNumber_Subtract(__pyx_t_9, __pyx_t_4); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __pyx_t_14 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_14 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __pyx_t_15 = sqrt((pow(__pyx_t_13, 2.0) + pow(__pyx_t_14, 2.0)));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":222
 *                         pow(p[i * 2]     - p[(i - 1) * 2], 2)  +
 *                         pow(p[i * 2 + 1] - p[(i - 1) * 2 + 1], 2)) / (
 *                                 self._dash_length + self._dash_offset)             # <<<<<<<<<<<<<<
 * 
 *                 vertices[i].s0 = tex_x
 */
      __pyx_t_16 = (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset);
      if (unlikely(__pyx_t_16 == 0)) {
        PyErr_Format(PyExc_ZeroDivisionError, "float division");
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_v_tex_x = (__pyx_v_tex_x + (__pyx_t_15 / __pyx_t_16));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":224
 *                                 self._dash_length + self._dash_offset)
 * 
 *                 vertices[i].s0 = tex_x             # <<<<<<<<<<<<<<
 *                 vertices[i].t0 = 0
 * 
 */
      (__pyx_v_vertices[__pyx_v_i]).s0 = __pyx_v_tex_x;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":225
 * 
 *                 vertices[i].s0 = tex_x
 *                 vertices[i].t0 = 0             # <<<<<<<<<<<<<<
 * 
 *             vertices[i].x = p[i * 2]
 */
      (__pyx_v_vertices[__pyx_v_i]).t0 = 0.0;
      goto __pyx_L11;
    }
    __pyx_L11:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":227
 *                 vertices[i].t0 = 0
 * 
 *             vertices[i].x = p[i * 2]             # <<<<<<<<<<<<<<
 *             vertices[i].y = p[i * 2 + 1]
 *             indices[i] = i
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_12 = (__pyx_v_i * 2);
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_12, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_i]).x = __pyx_t_17;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":228
 * 
 *             vertices[i].x = p[i * 2]
 *             vertices[i].y = p[i * 2 + 1]             # <<<<<<<<<<<<<<
 *             indices[i] = i
 * 
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_12 = ((__pyx_v_i * 2) + 1);
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_12, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_i]).y = __pyx_t_17;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":229
 *             vertices[i].x = p[i * 2]
 *             vertices[i].y = p[i * 2 + 1]
 *             indices[i] = i             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, count, indices, count)
 */
    (__pyx_v_indices[__pyx_v_i]) = __pyx_v_i;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":231
 *             indices[i] = i
 * 
 *         self.batch.set_data(vertices, count, indices, count)             # <<<<<<<<<<<<<<
 * 
 *         free(vertices)
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, __pyx_v_count, __pyx_v_indices, __pyx_v_count);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":233
 *         self.batch.set_data(vertices, count, indices, count)
 * 
 *         free(vertices)             # <<<<<<<<<<<<<<
 *         free(indices)
 * 
 */
  free(__pyx_v_vertices);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":234
 * 
 *         free(vertices)
 *         free(indices)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build_extended(self):
 */
  free(__pyx_v_indices);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.build_legacy", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_p);
  __Pyx_XDECREF((PyObject *)__pyx_v_texture);
  __Pyx_XDECREF(__pyx_v_p_str);
  __Pyx_RefNannyFinishContext();
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":236
 *         free(indices)
 * 
 *     cdef void build_extended(self):             # <<<<<<<<<<<<<<
 *         cdef int i, j, count = len(self.points) / 2
 *         cdef list p = self.points
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_build_extended(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  int __pyx_v_i;
  int __pyx_v_j;
  int __pyx_v_count;
  PyObject *__pyx_v_p = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  int __pyx_v_cap;
  CYTHON_UNUSED char *__pyx_v_buf;
  CYTHON_UNUSED struct __pyx_obj_4kivy_8graphics_7texture_Texture *__pyx_v_texture = 0;
  unsigned int __pyx_v_vertices_count;
  unsigned int __pyx_v_indices_count;
  unsigned int __pyx_v_iv;
  unsigned int __pyx_v_ii;
  double __pyx_v_ax;
  double __pyx_v_ay;
  double __pyx_v_bx;
  double __pyx_v_by;
  double __pyx_v_cx;
  double __pyx_v_cy;
  double __pyx_v_angle;
  double __pyx_v_a1;
  double __pyx_v_a2;
  double __pyx_v_x1;
  double __pyx_v_y1;
  double __pyx_v_x2;
  double __pyx_v_y2;
  double __pyx_v_x3;
  double __pyx_v_y3;
  double __pyx_v_x4;
  double __pyx_v_y4;
  double __pyx_v_sx1;
  double __pyx_v_sy1;
  double __pyx_v_sx4;
  double __pyx_v_sy4;
  double __pyx_v_sangle;
  double __pyx_v_pcx;
  double __pyx_v_pcy;
  double __pyx_v_px1;
  double __pyx_v_py1;
  double __pyx_v_px2;
  double __pyx_v_py2;
  double __pyx_v_px3;
  double __pyx_v_py3;
  double __pyx_v_px4;
  double __pyx_v_py4;
  double __pyx_v_pangle;
  double __pyx_v_pangle2;
  double __pyx_v_w;
  double __pyx_v_ix;
  double __pyx_v_iy;
  unsigned int __pyx_v_piv;
  unsigned int __pyx_v_piv2;
  double __pyx_v_jangle;
  double __pyx_v_cos1;
  double __pyx_v_cos2;
  double __pyx_v_sin1;
  double __pyx_v_sin2;
  double __pyx_v_a0;
  PyObject *__pyx_v_step = NULL;
  long __pyx_v_pivstart;
  long __pyx_v_pivend;
  unsigned int __pyx_v_siv;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  Py_ssize_t __pyx_t_2;
  int __pyx_t_3;
  int __pyx_t_4;
  PyObject *__pyx_t_5 = NULL;
  long __pyx_t_6;
  int __pyx_t_7;
  long __pyx_t_8;
  double __pyx_t_9;
  int __pyx_t_10;
  int __pyx_t_11;
  int __pyx_t_12;
  PyObject *__pyx_t_13 = NULL;
  unsigned int __pyx_t_14;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build_extended", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":237
 * 
 *     cdef void build_extended(self):
 *         cdef int i, j, count = len(self.points) / 2             # <<<<<<<<<<<<<<
 *         cdef list p = self.points
 *         cdef vertex_t *vertices = NULL
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 237; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyObject_Length(__pyx_t_1); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 237; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_count = __Pyx_div_Py_ssize_t(__pyx_t_2, 2);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":238
 *     cdef void build_extended(self):
 *         cdef int i, j, count = len(self.points) / 2
 *         cdef list p = self.points             # <<<<<<<<<<<<<<
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 238; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyList_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_1)->tp_name), 0))) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 238; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_p = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":239
 *         cdef int i, j, count = len(self.points) / 2
 *         cdef list p = self.points
 *         cdef vertex_t *vertices = NULL             # <<<<<<<<<<<<<<
 *         cdef unsigned short *indices = NULL
 *         cdef float tex_x
 */
  __pyx_v_vertices = NULL;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":240
 *         cdef list p = self.points
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL             # <<<<<<<<<<<<<<
 *         cdef float tex_x
 *         cdef int cap
 */
  __pyx_v_indices = NULL;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":243
 *         cdef float tex_x
 *         cdef int cap
 *         cdef char *buf = NULL             # <<<<<<<<<<<<<<
 *         cdef Texture texture = self.texture
 * 
 */
  __pyx_v_buf = NULL;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":244
 *         cdef int cap
 *         cdef char *buf = NULL
 *         cdef Texture texture = self.texture             # <<<<<<<<<<<<<<
 * 
 *         self._bxmin = 999999999
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 244; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4kivy_8graphics_7texture_Texture))))) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 244; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_texture = ((struct __pyx_obj_4kivy_8graphics_7texture_Texture *)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":246
 *         cdef Texture texture = self.texture
 * 
 *         self._bxmin = 999999999             # <<<<<<<<<<<<<<
 *         self._bymin = 999999999
 *         self._bxmax = -999999999
 */
  __pyx_v_self->_bxmin = 999999999.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":247
 * 
 *         self._bxmin = 999999999
 *         self._bymin = 999999999             # <<<<<<<<<<<<<<
 *         self._bxmax = -999999999
 *         self._bymax = -999999999
 */
  __pyx_v_self->_bymin = 999999999.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":248
 *         self._bxmin = 999999999
 *         self._bymin = 999999999
 *         self._bxmax = -999999999             # <<<<<<<<<<<<<<
 *         self._bymax = -999999999
 * 
 */
  __pyx_v_self->_bxmax = -999999999.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":249
 *         self._bymin = 999999999
 *         self._bxmax = -999999999
 *         self._bymax = -999999999             # <<<<<<<<<<<<<<
 * 
 *         if count < 2:
 */
  __pyx_v_self->_bymax = -999999999.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":251
 *         self._bymax = -999999999
 * 
 *         if count < 2:             # <<<<<<<<<<<<<<
 *             self.batch.clear_data()
 *             return
 */
  __pyx_t_3 = (__pyx_v_count < 2);
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":252
 * 
 *         if count < 2:
 *             self.batch.clear_data()             # <<<<<<<<<<<<<<
 *             return
 * 
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->clear_data(__pyx_v_self->__pyx_base.batch);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":253
 *         if count < 2:
 *             self.batch.clear_data()
 *             return             # <<<<<<<<<<<<<<
 * 
 *         cap = self._cap
 */
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":255
 *             return
 * 
 *         cap = self._cap             # <<<<<<<<<<<<<<
 *         if self._close and count > 2:
 *             p = p + p[0:4]
 */
  __pyx_v_cap = __pyx_v_self->_cap;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":256
 * 
 *         cap = self._cap
 *         if self._close and count > 2:             # <<<<<<<<<<<<<<
 *             p = p + p[0:4]
 *             count += 2
 */
  if (__pyx_v_self->_close) {
    __pyx_t_3 = (__pyx_v_count > 2);
    __pyx_t_4 = __pyx_t_3;
  } else {
    __pyx_t_4 = __pyx_v_self->_close;
  }
  if (__pyx_t_4) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":257
 *         cap = self._cap
 *         if self._close and count > 2:
 *             p = p + p[0:4]             # <<<<<<<<<<<<<<
 *             count += 2
 *             cap = LINE_CAP_NONE
 */
    __pyx_t_1 = __Pyx_PySequence_GetSlice(((PyObject *)__pyx_v_p), 0, 4); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_1));
    __pyx_t_5 = PyNumber_Add(((PyObject *)__pyx_v_p), ((PyObject *)__pyx_t_1)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_5));
    __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_v_p));
    __pyx_v_p = __pyx_t_5;
    __pyx_t_5 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":258
 *         if self._close and count > 2:
 *             p = p + p[0:4]
 *             count += 2             # <<<<<<<<<<<<<<
 *             cap = LINE_CAP_NONE
 * 
 */
    __pyx_v_count = (__pyx_v_count + 2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":259
 *             p = p + p[0:4]
 *             count += 2
 *             cap = LINE_CAP_NONE             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_mode('triangles')
 */
    __pyx_v_cap = 0;
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":261
 *             cap = LINE_CAP_NONE
 * 
 *         self.batch.set_mode('triangles')             # <<<<<<<<<<<<<<
 *         cdef unsigned int vertices_count = (count - 1) * 4
 *         cdef unsigned int indices_count = (count - 1) * 6
 */
  __pyx_t_5 = ((PyObject *)__pyx_n_s__triangles);
  __Pyx_INCREF(__pyx_t_5);
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_mode(__pyx_v_self->__pyx_base.batch, ((PyObject*)__pyx_t_5));
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":262
 * 
 *         self.batch.set_mode('triangles')
 *         cdef unsigned int vertices_count = (count - 1) * 4             # <<<<<<<<<<<<<<
 *         cdef unsigned int indices_count = (count - 1) * 6
 *         cdef unsigned int iv = 0, ii = 0
 */
  __pyx_v_vertices_count = ((__pyx_v_count - 1) * 4);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":263
 *         self.batch.set_mode('triangles')
 *         cdef unsigned int vertices_count = (count - 1) * 4
 *         cdef unsigned int indices_count = (count - 1) * 6             # <<<<<<<<<<<<<<
 *         cdef unsigned int iv = 0, ii = 0
 * 
 */
  __pyx_v_indices_count = ((__pyx_v_count - 1) * 6);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":264
 *         cdef unsigned int vertices_count = (count - 1) * 4
 *         cdef unsigned int indices_count = (count - 1) * 6
 *         cdef unsigned int iv = 0, ii = 0             # <<<<<<<<<<<<<<
 * 
 *         if self._joint == LINE_JOINT_BEVEL:
 */
  __pyx_v_iv = 0;
  __pyx_v_ii = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":272
 *             indices_count += (self._joint_precision * 3) * (count - 2)
 *             vertices_count += (self._joint_precision) * (count - 2)
 *         elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *             indices_count += (count - 2) * 6
 *             vertices_count += (count - 2) * 2
 */
  switch (__pyx_v_self->_joint) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":266
 *         cdef unsigned int iv = 0, ii = 0
 * 
 *         if self._joint == LINE_JOINT_BEVEL:             # <<<<<<<<<<<<<<
 *             indices_count += (count - 2) * 3
 *             vertices_count += (count - 2)
 */
    case 2:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":267
 * 
 *         if self._joint == LINE_JOINT_BEVEL:
 *             indices_count += (count - 2) * 3             # <<<<<<<<<<<<<<
 *             vertices_count += (count - 2)
 *         elif self._joint == LINE_JOINT_ROUND:
 */
    __pyx_v_indices_count = (__pyx_v_indices_count + ((__pyx_v_count - 2) * 3));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":268
 *         if self._joint == LINE_JOINT_BEVEL:
 *             indices_count += (count - 2) * 3
 *             vertices_count += (count - 2)             # <<<<<<<<<<<<<<
 *         elif self._joint == LINE_JOINT_ROUND:
 *             indices_count += (self._joint_precision * 3) * (count - 2)
 */
    __pyx_v_vertices_count = (__pyx_v_vertices_count + (__pyx_v_count - 2));
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":269
 *             indices_count += (count - 2) * 3
 *             vertices_count += (count - 2)
 *         elif self._joint == LINE_JOINT_ROUND:             # <<<<<<<<<<<<<<
 *             indices_count += (self._joint_precision * 3) * (count - 2)
 *             vertices_count += (self._joint_precision) * (count - 2)
 */
    case 3:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":270
 *             vertices_count += (count - 2)
 *         elif self._joint == LINE_JOINT_ROUND:
 *             indices_count += (self._joint_precision * 3) * (count - 2)             # <<<<<<<<<<<<<<
 *             vertices_count += (self._joint_precision) * (count - 2)
 *         elif self._joint == LINE_JOINT_MITER:
 */
    __pyx_v_indices_count = (__pyx_v_indices_count + ((__pyx_v_self->_joint_precision * 3) * (__pyx_v_count - 2)));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":271
 *         elif self._joint == LINE_JOINT_ROUND:
 *             indices_count += (self._joint_precision * 3) * (count - 2)
 *             vertices_count += (self._joint_precision) * (count - 2)             # <<<<<<<<<<<<<<
 *         elif self._joint == LINE_JOINT_MITER:
 *             indices_count += (count - 2) * 6
 */
    __pyx_v_vertices_count = (__pyx_v_vertices_count + (__pyx_v_self->_joint_precision * (__pyx_v_count - 2)));
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":272
 *             indices_count += (self._joint_precision * 3) * (count - 2)
 *             vertices_count += (self._joint_precision) * (count - 2)
 *         elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *             indices_count += (count - 2) * 6
 *             vertices_count += (count - 2) * 2
 */
    case 1:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":273
 *             vertices_count += (self._joint_precision) * (count - 2)
 *         elif self._joint == LINE_JOINT_MITER:
 *             indices_count += (count - 2) * 6             # <<<<<<<<<<<<<<
 *             vertices_count += (count - 2) * 2
 * 
 */
    __pyx_v_indices_count = (__pyx_v_indices_count + ((__pyx_v_count - 2) * 6));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":274
 *         elif self._joint == LINE_JOINT_MITER:
 *             indices_count += (count - 2) * 6
 *             vertices_count += (count - 2) * 2             # <<<<<<<<<<<<<<
 * 
 *         if cap == LINE_CAP_SQUARE:
 */
    __pyx_v_vertices_count = (__pyx_v_vertices_count + ((__pyx_v_count - 2) * 2));
    break;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":279
 *             indices_count += 12
 *             vertices_count += 4
 *         elif cap == LINE_CAP_ROUND:             # <<<<<<<<<<<<<<
 *             indices_count += (self._cap_precision * 3) * 2
 *             vertices_count += (self._cap_precision) * 2
 */
  switch (__pyx_v_cap) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":276
 *             vertices_count += (count - 2) * 2
 * 
 *         if cap == LINE_CAP_SQUARE:             # <<<<<<<<<<<<<<
 *             indices_count += 12
 *             vertices_count += 4
 */
    case 1:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":277
 * 
 *         if cap == LINE_CAP_SQUARE:
 *             indices_count += 12             # <<<<<<<<<<<<<<
 *             vertices_count += 4
 *         elif cap == LINE_CAP_ROUND:
 */
    __pyx_v_indices_count = (__pyx_v_indices_count + 12);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":278
 *         if cap == LINE_CAP_SQUARE:
 *             indices_count += 12
 *             vertices_count += 4             # <<<<<<<<<<<<<<
 *         elif cap == LINE_CAP_ROUND:
 *             indices_count += (self._cap_precision * 3) * 2
 */
    __pyx_v_vertices_count = (__pyx_v_vertices_count + 4);
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":279
 *             indices_count += 12
 *             vertices_count += 4
 *         elif cap == LINE_CAP_ROUND:             # <<<<<<<<<<<<<<
 *             indices_count += (self._cap_precision * 3) * 2
 *             vertices_count += (self._cap_precision) * 2
 */
    case 2:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":280
 *             vertices_count += 4
 *         elif cap == LINE_CAP_ROUND:
 *             indices_count += (self._cap_precision * 3) * 2             # <<<<<<<<<<<<<<
 *             vertices_count += (self._cap_precision) * 2
 * 
 */
    __pyx_v_indices_count = (__pyx_v_indices_count + ((__pyx_v_self->_cap_precision * 3) * 2));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":281
 *         elif cap == LINE_CAP_ROUND:
 *             indices_count += (self._cap_precision * 3) * 2
 *             vertices_count += (self._cap_precision) * 2             # <<<<<<<<<<<<<<
 * 
 *         vertices = <vertex_t *>malloc(vertices_count * sizeof(vertex_t))
 */
    __pyx_v_vertices_count = (__pyx_v_vertices_count + (__pyx_v_self->_cap_precision * 2));
    break;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":283
 *             vertices_count += (self._cap_precision) * 2
 * 
 *         vertices = <vertex_t *>malloc(vertices_count * sizeof(vertex_t))             # <<<<<<<<<<<<<<
 *         if vertices == NULL:
 *             raise MemoryError('vertices')
 */
  __pyx_v_vertices = ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)malloc((__pyx_v_vertices_count * (sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)))));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":284
 * 
 *         vertices = <vertex_t *>malloc(vertices_count * sizeof(vertex_t))
 *         if vertices == NULL:             # <<<<<<<<<<<<<<
 *             raise MemoryError('vertices')
 * 
 */
  __pyx_t_4 = (__pyx_v_vertices == NULL);
  if (__pyx_t_4) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":285
 *         vertices = <vertex_t *>malloc(vertices_count * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(indices_count * sizeof(unsigned short))
 */
    __pyx_t_5 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_3), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 285; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 285; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":287
 *             raise MemoryError('vertices')
 * 
 *         indices = <unsigned short *>malloc(indices_count * sizeof(unsigned short))             # <<<<<<<<<<<<<<
 *         if indices == NULL:
 *             free(vertices)
 */
  __pyx_v_indices = ((unsigned short *)malloc((__pyx_v_indices_count * (sizeof(unsigned short)))));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":288
 * 
 *         indices = <unsigned short *>malloc(indices_count * sizeof(unsigned short))
 *         if indices == NULL:             # <<<<<<<<<<<<<<
 *             free(vertices)
 *             raise MemoryError('indices')
 */
  __pyx_t_4 = (__pyx_v_indices == NULL);
  if (__pyx_t_4) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":289
 *         indices = <unsigned short *>malloc(indices_count * sizeof(unsigned short))
 *         if indices == NULL:
 *             free(vertices)             # <<<<<<<<<<<<<<
 *             raise MemoryError('indices')
 * 
 */
    free(__pyx_v_vertices);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":290
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         cdef double ax, ay, bx, by, cx, cy, angle, a1, a2
 */
    __pyx_t_5 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 290; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 290; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L6;
  }
  __pyx_L6:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":296
 *         cdef double sx1, sy1, sx4, sy4, sangle
 *         cdef double pcx, pcy, px1, py1, px2, py2, px3, py3, px4, py4, pangle, pangle2
 *         cdef double w = self._width             # <<<<<<<<<<<<<<
 *         cdef double ix, iy
 *         cdef unsigned int piv, pii2, piv2
 */
  __pyx_v_w = __pyx_v_self->_width;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":300
 *         cdef unsigned int piv, pii2, piv2
 *         cdef double jangle
 *         angle = sangle = 0             # <<<<<<<<<<<<<<
 *         piv = pcx = pcy = cx = cy = ii = iv = ix = iy = 0
 *         px1 = px2 = px3 = px4 = py1 = py2 = py3 = py4 = 0
 */
  __pyx_v_angle = 0;
  __pyx_v_sangle = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":301
 *         cdef double jangle
 *         angle = sangle = 0
 *         piv = pcx = pcy = cx = cy = ii = iv = ix = iy = 0             # <<<<<<<<<<<<<<
 *         px1 = px2 = px3 = px4 = py1 = py2 = py3 = py4 = 0
 *         sx1 = sy1 = sx4 = sy4 = 0
 */
  __pyx_v_piv = 0;
  __pyx_v_pcx = 0;
  __pyx_v_pcy = 0;
  __pyx_v_cx = 0;
  __pyx_v_cy = 0;
  __pyx_v_ii = 0;
  __pyx_v_iv = 0;
  __pyx_v_ix = 0;
  __pyx_v_iy = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":302
 *         angle = sangle = 0
 *         piv = pcx = pcy = cx = cy = ii = iv = ix = iy = 0
 *         px1 = px2 = px3 = px4 = py1 = py2 = py3 = py4 = 0             # <<<<<<<<<<<<<<
 *         sx1 = sy1 = sx4 = sy4 = 0
 *         x1 = x2 = x3 = x4 = y1 = y2 = y3 = y4 = 0
 */
  __pyx_v_px1 = 0;
  __pyx_v_px2 = 0;
  __pyx_v_px3 = 0;
  __pyx_v_px4 = 0;
  __pyx_v_py1 = 0;
  __pyx_v_py2 = 0;
  __pyx_v_py3 = 0;
  __pyx_v_py4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":303
 *         piv = pcx = pcy = cx = cy = ii = iv = ix = iy = 0
 *         px1 = px2 = px3 = px4 = py1 = py2 = py3 = py4 = 0
 *         sx1 = sy1 = sx4 = sy4 = 0             # <<<<<<<<<<<<<<
 *         x1 = x2 = x3 = x4 = y1 = y2 = y3 = y4 = 0
 *         cdef double cos1 = 0, cos2 = 0, sin1 = 0, sin2 = 0
 */
  __pyx_v_sx1 = 0;
  __pyx_v_sy1 = 0;
  __pyx_v_sx4 = 0;
  __pyx_v_sy4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":304
 *         px1 = px2 = px3 = px4 = py1 = py2 = py3 = py4 = 0
 *         sx1 = sy1 = sx4 = sy4 = 0
 *         x1 = x2 = x3 = x4 = y1 = y2 = y3 = y4 = 0             # <<<<<<<<<<<<<<
 *         cdef double cos1 = 0, cos2 = 0, sin1 = 0, sin2 = 0
 *         for i in range(0, count - 1):
 */
  __pyx_v_x1 = 0;
  __pyx_v_x2 = 0;
  __pyx_v_x3 = 0;
  __pyx_v_x4 = 0;
  __pyx_v_y1 = 0;
  __pyx_v_y2 = 0;
  __pyx_v_y3 = 0;
  __pyx_v_y4 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":305
 *         sx1 = sy1 = sx4 = sy4 = 0
 *         x1 = x2 = x3 = x4 = y1 = y2 = y3 = y4 = 0
 *         cdef double cos1 = 0, cos2 = 0, sin1 = 0, sin2 = 0             # <<<<<<<<<<<<<<
 *         for i in range(0, count - 1):
 *             ax = p[i * 2]
 */
  __pyx_v_cos1 = 0.0;
  __pyx_v_cos2 = 0.0;
  __pyx_v_sin1 = 0.0;
  __pyx_v_sin2 = 0.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":306
 *         x1 = x2 = x3 = x4 = y1 = y2 = y3 = y4 = 0
 *         cdef double cos1 = 0, cos2 = 0, sin1 = 0, sin2 = 0
 *         for i in range(0, count - 1):             # <<<<<<<<<<<<<<
 *             ax = p[i * 2]
 *             ay = p[i * 2 + 1]
 */
  __pyx_t_6 = (__pyx_v_count - 1);
  for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) {
    __pyx_v_i = __pyx_t_7;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":307
 *         cdef double cos1 = 0, cos2 = 0, sin1 = 0, sin2 = 0
 *         for i in range(0, count - 1):
 *             ax = p[i * 2]             # <<<<<<<<<<<<<<
 *             ay = p[i * 2 + 1]
 *             bx = p[i * 2 + 2]
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = (__pyx_v_i * 2);
    __pyx_t_5 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_5) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_v_ax = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":308
 *         for i in range(0, count - 1):
 *             ax = p[i * 2]
 *             ay = p[i * 2 + 1]             # <<<<<<<<<<<<<<
 *             bx = p[i * 2 + 2]
 *             by = p[i * 2 + 3]
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 308; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = ((__pyx_v_i * 2) + 1);
    __pyx_t_5 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_5) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 308; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 308; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_v_ay = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":309
 *             ax = p[i * 2]
 *             ay = p[i * 2 + 1]
 *             bx = p[i * 2 + 2]             # <<<<<<<<<<<<<<
 *             by = p[i * 2 + 3]
 * 
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 309; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = ((__pyx_v_i * 2) + 2);
    __pyx_t_5 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_5) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 309; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 309; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_v_bx = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":310
 *             ay = p[i * 2 + 1]
 *             bx = p[i * 2 + 2]
 *             by = p[i * 2 + 3]             # <<<<<<<<<<<<<<
 * 
 *             if i > 0 and self._joint != LINE_JOINT_NONE:
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 310; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = ((__pyx_v_i * 2) + 3);
    __pyx_t_5 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_5) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 310; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 310; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_v_by = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":312
 *             by = p[i * 2 + 3]
 * 
 *             if i > 0 and self._joint != LINE_JOINT_NONE:             # <<<<<<<<<<<<<<
 *                 pcx = cx
 *                 pcy = cy
 */
    __pyx_t_4 = (__pyx_v_i > 0);
    if (__pyx_t_4) {
      __pyx_t_3 = (__pyx_v_self->_joint != 0);
      __pyx_t_10 = __pyx_t_3;
    } else {
      __pyx_t_10 = __pyx_t_4;
    }
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":313
 * 
 *             if i > 0 and self._joint != LINE_JOINT_NONE:
 *                 pcx = cx             # <<<<<<<<<<<<<<
 *                 pcy = cy
 *                 px1 = x1
 */
      __pyx_v_pcx = __pyx_v_cx;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":314
 *             if i > 0 and self._joint != LINE_JOINT_NONE:
 *                 pcx = cx
 *                 pcy = cy             # <<<<<<<<<<<<<<
 *                 px1 = x1
 *                 px2 = x2
 */
      __pyx_v_pcy = __pyx_v_cy;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":315
 *                 pcx = cx
 *                 pcy = cy
 *                 px1 = x1             # <<<<<<<<<<<<<<
 *                 px2 = x2
 *                 px3 = x3
 */
      __pyx_v_px1 = __pyx_v_x1;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":316
 *                 pcy = cy
 *                 px1 = x1
 *                 px2 = x2             # <<<<<<<<<<<<<<
 *                 px3 = x3
 *                 px4 = x4
 */
      __pyx_v_px2 = __pyx_v_x2;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":317
 *                 px1 = x1
 *                 px2 = x2
 *                 px3 = x3             # <<<<<<<<<<<<<<
 *                 px4 = x4
 *                 py1 = y1
 */
      __pyx_v_px3 = __pyx_v_x3;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":318
 *                 px2 = x2
 *                 px3 = x3
 *                 px4 = x4             # <<<<<<<<<<<<<<
 *                 py1 = y1
 *                 py2 = y2
 */
      __pyx_v_px4 = __pyx_v_x4;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":319
 *                 px3 = x3
 *                 px4 = x4
 *                 py1 = y1             # <<<<<<<<<<<<<<
 *                 py2 = y2
 *                 py3 = y3
 */
      __pyx_v_py1 = __pyx_v_y1;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":320
 *                 px4 = x4
 *                 py1 = y1
 *                 py2 = y2             # <<<<<<<<<<<<<<
 *                 py3 = y3
 *                 py4 = y4
 */
      __pyx_v_py2 = __pyx_v_y2;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":321
 *                 py1 = y1
 *                 py2 = y2
 *                 py3 = y3             # <<<<<<<<<<<<<<
 *                 py4 = y4
 * 
 */
      __pyx_v_py3 = __pyx_v_y3;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":322
 *                 py2 = y2
 *                 py3 = y3
 *                 py4 = y4             # <<<<<<<<<<<<<<
 * 
 *             piv2 = piv
 */
      __pyx_v_py4 = __pyx_v_y4;
      goto __pyx_L9;
    }
    __pyx_L9:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":324
 *                 py4 = y4
 * 
 *             piv2 = piv             # <<<<<<<<<<<<<<
 *             piv = iv
 *             pangle2 = pangle
 */
    __pyx_v_piv2 = __pyx_v_piv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":325
 * 
 *             piv2 = piv
 *             piv = iv             # <<<<<<<<<<<<<<
 *             pangle2 = pangle
 *             pangle = angle
 */
    __pyx_v_piv = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":326
 *             piv2 = piv
 *             piv = iv
 *             pangle2 = pangle             # <<<<<<<<<<<<<<
 *             pangle = angle
 * 
 */
    __pyx_v_pangle2 = __pyx_v_pangle;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":327
 *             piv = iv
 *             pangle2 = pangle
 *             pangle = angle             # <<<<<<<<<<<<<<
 * 
 *             # calculate the orientation of the segment, between pi and -pi
 */
    __pyx_v_pangle = __pyx_v_angle;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":330
 * 
 *             # calculate the orientation of the segment, between pi and -pi
 *             cx = bx - ax             # <<<<<<<<<<<<<<
 *             cy = by - ay
 *             angle = atan2(cy, cx)
 */
    __pyx_v_cx = (__pyx_v_bx - __pyx_v_ax);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":331
 *             # calculate the orientation of the segment, between pi and -pi
 *             cx = bx - ax
 *             cy = by - ay             # <<<<<<<<<<<<<<
 *             angle = atan2(cy, cx)
 *             a1 = angle - PI2
 */
    __pyx_v_cy = (__pyx_v_by - __pyx_v_ay);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":332
 *             cx = bx - ax
 *             cy = by - ay
 *             angle = atan2(cy, cx)             # <<<<<<<<<<<<<<
 *             a1 = angle - PI2
 *             a2 = angle + PI2
 */
    __pyx_v_angle = atan2(__pyx_v_cy, __pyx_v_cx);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":333
 *             cy = by - ay
 *             angle = atan2(cy, cx)
 *             a1 = angle - PI2             # <<<<<<<<<<<<<<
 *             a2 = angle + PI2
 * 
 */
    __pyx_v_a1 = (__pyx_v_angle - 1.5707963267948966);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":334
 *             angle = atan2(cy, cx)
 *             a1 = angle - PI2
 *             a2 = angle + PI2             # <<<<<<<<<<<<<<
 * 
 *             # calculate the position of the segment
 */
    __pyx_v_a2 = (__pyx_v_angle + 1.5707963267948966);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":337
 * 
 *             # calculate the position of the segment
 *             cos1 = cos(a1) * w             # <<<<<<<<<<<<<<
 *             sin1 = sin(a1) * w
 *             cos2 = cos(a2) * w
 */
    __pyx_v_cos1 = (cos(__pyx_v_a1) * __pyx_v_w);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":338
 *             # calculate the position of the segment
 *             cos1 = cos(a1) * w
 *             sin1 = sin(a1) * w             # <<<<<<<<<<<<<<
 *             cos2 = cos(a2) * w
 *             sin2 = sin(a2) * w
 */
    __pyx_v_sin1 = (sin(__pyx_v_a1) * __pyx_v_w);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":339
 *             cos1 = cos(a1) * w
 *             sin1 = sin(a1) * w
 *             cos2 = cos(a2) * w             # <<<<<<<<<<<<<<
 *             sin2 = sin(a2) * w
 *             x1 = ax + cos1
 */
    __pyx_v_cos2 = (cos(__pyx_v_a2) * __pyx_v_w);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":340
 *             sin1 = sin(a1) * w
 *             cos2 = cos(a2) * w
 *             sin2 = sin(a2) * w             # <<<<<<<<<<<<<<
 *             x1 = ax + cos1
 *             y1 = ay + sin1
 */
    __pyx_v_sin2 = (sin(__pyx_v_a2) * __pyx_v_w);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":341
 *             cos2 = cos(a2) * w
 *             sin2 = sin(a2) * w
 *             x1 = ax + cos1             # <<<<<<<<<<<<<<
 *             y1 = ay + sin1
 *             x4 = ax + cos2
 */
    __pyx_v_x1 = (__pyx_v_ax + __pyx_v_cos1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":342
 *             sin2 = sin(a2) * w
 *             x1 = ax + cos1
 *             y1 = ay + sin1             # <<<<<<<<<<<<<<
 *             x4 = ax + cos2
 *             y4 = ay + sin2
 */
    __pyx_v_y1 = (__pyx_v_ay + __pyx_v_sin1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":343
 *             x1 = ax + cos1
 *             y1 = ay + sin1
 *             x4 = ax + cos2             # <<<<<<<<<<<<<<
 *             y4 = ay + sin2
 *             x2 = bx + cos1
 */
    __pyx_v_x4 = (__pyx_v_ax + __pyx_v_cos2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":344
 *             y1 = ay + sin1
 *             x4 = ax + cos2
 *             y4 = ay + sin2             # <<<<<<<<<<<<<<
 *             x2 = bx + cos1
 *             y2 = by + sin1
 */
    __pyx_v_y4 = (__pyx_v_ay + __pyx_v_sin2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":345
 *             x4 = ax + cos2
 *             y4 = ay + sin2
 *             x2 = bx + cos1             # <<<<<<<<<<<<<<
 *             y2 = by + sin1
 *             x3 = bx + cos2
 */
    __pyx_v_x2 = (__pyx_v_bx + __pyx_v_cos1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":346
 *             y4 = ay + sin2
 *             x2 = bx + cos1
 *             y2 = by + sin1             # <<<<<<<<<<<<<<
 *             x3 = bx + cos2
 *             y3 = by + sin2
 */
    __pyx_v_y2 = (__pyx_v_by + __pyx_v_sin1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":347
 *             x2 = bx + cos1
 *             y2 = by + sin1
 *             x3 = bx + cos2             # <<<<<<<<<<<<<<
 *             y3 = by + sin2
 * 
 */
    __pyx_v_x3 = (__pyx_v_bx + __pyx_v_cos2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":348
 *             y2 = by + sin1
 *             x3 = bx + cos2
 *             y3 = by + sin2             # <<<<<<<<<<<<<<
 * 
 *             if i == 0:
 */
    __pyx_v_y3 = (__pyx_v_by + __pyx_v_sin2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":350
 *             y3 = by + sin2
 * 
 *             if i == 0:             # <<<<<<<<<<<<<<
 *                 sx1 = x1
 *                 sy1 = y1
 */
    __pyx_t_10 = (__pyx_v_i == 0);
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":351
 * 
 *             if i == 0:
 *                 sx1 = x1             # <<<<<<<<<<<<<<
 *                 sy1 = y1
 *                 sx4 = x4
 */
      __pyx_v_sx1 = __pyx_v_x1;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":352
 *             if i == 0:
 *                 sx1 = x1
 *                 sy1 = y1             # <<<<<<<<<<<<<<
 *                 sx4 = x4
 *                 sy4 = y4
 */
      __pyx_v_sy1 = __pyx_v_y1;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":353
 *                 sx1 = x1
 *                 sy1 = y1
 *                 sx4 = x4             # <<<<<<<<<<<<<<
 *                 sy4 = y4
 *                 sangle = angle
 */
      __pyx_v_sx4 = __pyx_v_x4;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":354
 *                 sy1 = y1
 *                 sx4 = x4
 *                 sy4 = y4             # <<<<<<<<<<<<<<
 *                 sangle = angle
 * 
 */
      __pyx_v_sy4 = __pyx_v_y4;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":355
 *                 sx4 = x4
 *                 sy4 = y4
 *                 sangle = angle             # <<<<<<<<<<<<<<
 * 
 *             indices[ii    ] = iv
 */
      __pyx_v_sangle = __pyx_v_angle;
      goto __pyx_L10;
    }
    __pyx_L10:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":357
 *                 sangle = angle
 * 
 *             indices[ii    ] = iv             # <<<<<<<<<<<<<<
 *             indices[ii + 1] = iv + 1
 *             indices[ii + 2] = iv + 2
 */
    (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":358
 * 
 *             indices[ii    ] = iv
 *             indices[ii + 1] = iv + 1             # <<<<<<<<<<<<<<
 *             indices[ii + 2] = iv + 2
 *             indices[ii + 3] = iv
 */
    (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":359
 *             indices[ii    ] = iv
 *             indices[ii + 1] = iv + 1
 *             indices[ii + 2] = iv + 2             # <<<<<<<<<<<<<<
 *             indices[ii + 3] = iv
 *             indices[ii + 4] = iv + 2
 */
    (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_iv + 2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":360
 *             indices[ii + 1] = iv + 1
 *             indices[ii + 2] = iv + 2
 *             indices[ii + 3] = iv             # <<<<<<<<<<<<<<
 *             indices[ii + 4] = iv + 2
 *             indices[ii + 5] = iv + 3
 */
    (__pyx_v_indices[(__pyx_v_ii + 3)]) = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":361
 *             indices[ii + 2] = iv + 2
 *             indices[ii + 3] = iv
 *             indices[ii + 4] = iv + 2             # <<<<<<<<<<<<<<
 *             indices[ii + 5] = iv + 3
 *             ii += 6
 */
    (__pyx_v_indices[(__pyx_v_ii + 4)]) = (__pyx_v_iv + 2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":362
 *             indices[ii + 3] = iv
 *             indices[ii + 4] = iv + 2
 *             indices[ii + 5] = iv + 3             # <<<<<<<<<<<<<<
 *             ii += 6
 * 
 */
    (__pyx_v_indices[(__pyx_v_ii + 5)]) = (__pyx_v_iv + 3);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":363
 *             indices[ii + 4] = iv + 2
 *             indices[ii + 5] = iv + 3
 *             ii += 6             # <<<<<<<<<<<<<<
 * 
 *             vertices[iv].x = x1
 */
    __pyx_v_ii = (__pyx_v_ii + 6);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":365
 *             ii += 6
 * 
 *             vertices[iv].x = x1             # <<<<<<<<<<<<<<
 *             vertices[iv].y = y1
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_x1;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":366
 * 
 *             vertices[iv].x = x1
 *             vertices[iv].y = y1             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_y1;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":367
 *             vertices[iv].x = x1
 *             vertices[iv].y = y1
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             iv += 1
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":368
 *             vertices[iv].y = y1
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             iv += 1
 *             vertices[iv].x = x2
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":369
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             iv += 1             # <<<<<<<<<<<<<<
 *             vertices[iv].x = x2
 *             vertices[iv].y = y2
 */
    __pyx_v_iv = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":370
 *             vertices[iv].t0 = 0
 *             iv += 1
 *             vertices[iv].x = x2             # <<<<<<<<<<<<<<
 *             vertices[iv].y = y2
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_x2;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":371
 *             iv += 1
 *             vertices[iv].x = x2
 *             vertices[iv].y = y2             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_y2;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":372
 *             vertices[iv].x = x2
 *             vertices[iv].y = y2
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             iv += 1
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":373
 *             vertices[iv].y = y2
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             iv += 1
 *             vertices[iv].x = x3
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":374
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             iv += 1             # <<<<<<<<<<<<<<
 *             vertices[iv].x = x3
 *             vertices[iv].y = y3
 */
    __pyx_v_iv = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":375
 *             vertices[iv].t0 = 0
 *             iv += 1
 *             vertices[iv].x = x3             # <<<<<<<<<<<<<<
 *             vertices[iv].y = y3
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_x3;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":376
 *             iv += 1
 *             vertices[iv].x = x3
 *             vertices[iv].y = y3             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_y3;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":377
 *             vertices[iv].x = x3
 *             vertices[iv].y = y3
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             iv += 1
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":378
 *             vertices[iv].y = y3
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             iv += 1
 *             vertices[iv].x = x4
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":379
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             iv += 1             # <<<<<<<<<<<<<<
 *             vertices[iv].x = x4
 *             vertices[iv].y = y4
 */
    __pyx_v_iv = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":380
 *             vertices[iv].t0 = 0
 *             iv += 1
 *             vertices[iv].x = x4             # <<<<<<<<<<<<<<
 *             vertices[iv].y = y4
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_x4;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":381
 *             iv += 1
 *             vertices[iv].x = x4
 *             vertices[iv].y = y4             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_y4;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":382
 *             vertices[iv].x = x4
 *             vertices[iv].y = y4
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             iv += 1
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":383
 *             vertices[iv].y = y4
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             iv += 1
 * 
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":384
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             iv += 1             # <<<<<<<<<<<<<<
 * 
 *             # joint generation
 */
    __pyx_v_iv = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":387
 * 
 *             # joint generation
 *             if i == 0 or self._joint == LINE_JOINT_NONE:             # <<<<<<<<<<<<<<
 *                 continue
 * 
 */
    __pyx_t_10 = (__pyx_v_i == 0);
    if (!__pyx_t_10) {
      __pyx_t_4 = (__pyx_v_self->_joint == 0);
      __pyx_t_3 = __pyx_t_4;
    } else {
      __pyx_t_3 = __pyx_t_10;
    }
    if (__pyx_t_3) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":388
 *             # joint generation
 *             if i == 0 or self._joint == LINE_JOINT_NONE:
 *                 continue             # <<<<<<<<<<<<<<
 * 
 *             # calculate the angle of the previous and current segment
 */
      goto __pyx_L7_continue;
      goto __pyx_L11;
    }
    __pyx_L11:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":393
 *             jangle = atan2(
 *                 cx * pcy - cy * pcx,
 *                 cx * pcx + cy * pcy)             # <<<<<<<<<<<<<<
 * 
 *             # in case of the angle is NULL, avoid the generation
 */
    __pyx_v_jangle = atan2(((__pyx_v_cx * __pyx_v_pcy) - (__pyx_v_cy * __pyx_v_pcx)), ((__pyx_v_cx * __pyx_v_pcx) + (__pyx_v_cy * __pyx_v_pcy)));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":396
 * 
 *             # in case of the angle is NULL, avoid the generation
 *             if jangle == 0 or jangle == PI or jangle == -PI:             # <<<<<<<<<<<<<<
 *                 if self._joint == LINE_JOINT_ROUND:
 *                     vertices_count -= self._joint_precision
 */
    __pyx_t_3 = (__pyx_v_jangle == 0.0);
    if (!__pyx_t_3) {
      __pyx_t_10 = (__pyx_v_jangle == 3.141592653589793);
      if (!__pyx_t_10) {
        __pyx_t_4 = (__pyx_v_jangle == -3.141592653589793);
        __pyx_t_11 = __pyx_t_4;
      } else {
        __pyx_t_11 = __pyx_t_10;
      }
      __pyx_t_10 = __pyx_t_11;
    } else {
      __pyx_t_10 = __pyx_t_3;
    }
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":403
 *                     vertices_count -= 1
 *                     indices_count -= 3
 *                 elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *                     vertices_count -= 2
 *                     indices_count -= 6
 */
      switch (__pyx_v_self->_joint) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":397
 *             # in case of the angle is NULL, avoid the generation
 *             if jangle == 0 or jangle == PI or jangle == -PI:
 *                 if self._joint == LINE_JOINT_ROUND:             # <<<<<<<<<<<<<<
 *                     vertices_count -= self._joint_precision
 *                     indices_count -= self._joint_precision * 3
 */
        case 3:

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":398
 *             if jangle == 0 or jangle == PI or jangle == -PI:
 *                 if self._joint == LINE_JOINT_ROUND:
 *                     vertices_count -= self._joint_precision             # <<<<<<<<<<<<<<
 *                     indices_count -= self._joint_precision * 3
 *                 elif self._joint == LINE_JOINT_BEVEL:
 */
        __pyx_v_vertices_count = (__pyx_v_vertices_count - __pyx_v_self->_joint_precision);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":399
 *                 if self._joint == LINE_JOINT_ROUND:
 *                     vertices_count -= self._joint_precision
 *                     indices_count -= self._joint_precision * 3             # <<<<<<<<<<<<<<
 *                 elif self._joint == LINE_JOINT_BEVEL:
 *                     vertices_count -= 1
 */
        __pyx_v_indices_count = (__pyx_v_indices_count - (__pyx_v_self->_joint_precision * 3));
        break;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":400
 *                     vertices_count -= self._joint_precision
 *                     indices_count -= self._joint_precision * 3
 *                 elif self._joint == LINE_JOINT_BEVEL:             # <<<<<<<<<<<<<<
 *                     vertices_count -= 1
 *                     indices_count -= 3
 */
        case 2:

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":401
 *                     indices_count -= self._joint_precision * 3
 *                 elif self._joint == LINE_JOINT_BEVEL:
 *                     vertices_count -= 1             # <<<<<<<<<<<<<<
 *                     indices_count -= 3
 *                 elif self._joint == LINE_JOINT_MITER:
 */
        __pyx_v_vertices_count = (__pyx_v_vertices_count - 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":402
 *                 elif self._joint == LINE_JOINT_BEVEL:
 *                     vertices_count -= 1
 *                     indices_count -= 3             # <<<<<<<<<<<<<<
 *                 elif self._joint == LINE_JOINT_MITER:
 *                     vertices_count -= 2
 */
        __pyx_v_indices_count = (__pyx_v_indices_count - 3);
        break;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":403
 *                     vertices_count -= 1
 *                     indices_count -= 3
 *                 elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *                     vertices_count -= 2
 *                     indices_count -= 6
 */
        case 1:

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":404
 *                     indices_count -= 3
 *                 elif self._joint == LINE_JOINT_MITER:
 *                     vertices_count -= 2             # <<<<<<<<<<<<<<
 *                     indices_count -= 6
 *                 continue
 */
        __pyx_v_vertices_count = (__pyx_v_vertices_count - 2);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":405
 *                 elif self._joint == LINE_JOINT_MITER:
 *                     vertices_count -= 2
 *                     indices_count -= 6             # <<<<<<<<<<<<<<
 *                 continue
 * 
 */
        __pyx_v_indices_count = (__pyx_v_indices_count - 6);
        break;
      }

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":406
 *                     vertices_count -= 2
 *                     indices_count -= 6
 *                 continue             # <<<<<<<<<<<<<<
 * 
 *             if self._joint == LINE_JOINT_BEVEL:
 */
      goto __pyx_L7_continue;
      goto __pyx_L12;
    }
    __pyx_L12:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":466
 * 
 * 
 *             elif self._joint == LINE_JOINT_ROUND:             # <<<<<<<<<<<<<<
 * 
 *                 # cap end
 */
    switch (__pyx_v_self->_joint) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":408
 *                 continue
 * 
 *             if self._joint == LINE_JOINT_BEVEL:             # <<<<<<<<<<<<<<
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay
 */
      case 2:

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":409
 * 
 *             if self._joint == LINE_JOINT_BEVEL:
 *                 vertices[iv].x = ax             # <<<<<<<<<<<<<<
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0
 */
      (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_ax;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":410
 *             if self._joint == LINE_JOINT_BEVEL:
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay             # <<<<<<<<<<<<<<
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 */
      (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_ay;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":411
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *                 vertices[iv].t0 = 0
 *                 if jangle < 0:
 */
      (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":412
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *                 if jangle < 0:
 *                     indices[ii] = piv2 + 1
 */
      (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":413
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 *                 if jangle < 0:             # <<<<<<<<<<<<<<
 *                     indices[ii] = piv2 + 1
 *                     indices[ii + 1] = piv
 */
      __pyx_t_10 = (__pyx_v_jangle < 0.0);
      if (__pyx_t_10) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":414
 *                 vertices[iv].t0 = 0
 *                 if jangle < 0:
 *                     indices[ii] = piv2 + 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = piv
 *                     indices[ii + 2] = iv
 */
        (__pyx_v_indices[__pyx_v_ii]) = (__pyx_v_piv2 + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":415
 *                 if jangle < 0:
 *                     indices[ii] = piv2 + 1
 *                     indices[ii + 1] = piv             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = iv
 *                 else:
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = __pyx_v_piv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":416
 *                     indices[ii] = piv2 + 1
 *                     indices[ii + 1] = piv
 *                     indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                 else:
 *                     indices[ii] = piv2 + 2
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
        goto __pyx_L13;
      }
      /*else*/ {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":418
 *                     indices[ii + 2] = iv
 *                 else:
 *                     indices[ii] = piv2 + 2             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = piv + 3
 *                     indices[ii + 2] = iv
 */
        (__pyx_v_indices[__pyx_v_ii]) = (__pyx_v_piv2 + 2);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":419
 *                 else:
 *                     indices[ii] = piv2 + 2
 *                     indices[ii + 1] = piv + 3             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = iv
 *                 ii += 3
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_piv + 3);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":420
 *                     indices[ii] = piv2 + 2
 *                     indices[ii + 1] = piv + 3
 *                     indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                 ii += 3
 *                 iv += 1
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
      }
      __pyx_L13:;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":421
 *                     indices[ii + 1] = piv + 3
 *                     indices[ii + 2] = iv
 *                 ii += 3             # <<<<<<<<<<<<<<
 *                 iv += 1
 * 
 */
      __pyx_v_ii = (__pyx_v_ii + 3);

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":422
 *                     indices[ii + 2] = iv
 *                 ii += 3
 *                 iv += 1             # <<<<<<<<<<<<<<
 * 
 *             elif self._joint == LINE_JOINT_MITER:
 */
      __pyx_v_iv = (__pyx_v_iv + 1);
      break;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":424
 *                 iv += 1
 * 
 *             elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay
 */
      case 1:

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":425
 * 
 *             elif self._joint == LINE_JOINT_MITER:
 *                 vertices[iv].x = ax             # <<<<<<<<<<<<<<
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0
 */
      (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_ax;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":426
 *             elif self._joint == LINE_JOINT_MITER:
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay             # <<<<<<<<<<<<<<
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 */
      (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_ay;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":427
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *                 vertices[iv].t0 = 0
 *                 if jangle < 0:
 */
      (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":428
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *                 if jangle < 0:
 *                     if line_intersection(px1, py1, px2, py2, x1, y1, x2, y2, &ix, &iy) == 0:
 */
      (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":429
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 *                 if jangle < 0:             # <<<<<<<<<<<<<<
 *                     if line_intersection(px1, py1, px2, py2, x1, y1, x2, y2, &ix, &iy) == 0:
 *                         vertices_count -= 2
 */
      __pyx_t_10 = (__pyx_v_jangle < 0.0);
      if (__pyx_t_10) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":430
 *                 vertices[iv].t0 = 0
 *                 if jangle < 0:
 *                     if line_intersection(px1, py1, px2, py2, x1, y1, x2, y2, &ix, &iy) == 0:             # <<<<<<<<<<<<<<
 *                         vertices_count -= 2
 *                         indices_count -= 6
 */
        __pyx_t_10 = (__pyx_f_4kivy_8graphics_19vertex_instructions_line_intersection(__pyx_v_px1, __pyx_v_py1, __pyx_v_px2, __pyx_v_py2, __pyx_v_x1, __pyx_v_y1, __pyx_v_x2, __pyx_v_y2, (&__pyx_v_ix), (&__pyx_v_iy)) == 0);
        if (__pyx_t_10) {

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":431
 *                 if jangle < 0:
 *                     if line_intersection(px1, py1, px2, py2, x1, y1, x2, y2, &ix, &iy) == 0:
 *                         vertices_count -= 2             # <<<<<<<<<<<<<<
 *                         indices_count -= 6
 *                         continue
 */
          __pyx_v_vertices_count = (__pyx_v_vertices_count - 2);

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":432
 *                     if line_intersection(px1, py1, px2, py2, x1, y1, x2, y2, &ix, &iy) == 0:
 *                         vertices_count -= 2
 *                         indices_count -= 6             # <<<<<<<<<<<<<<
 *                         continue
 *                     vertices[iv + 1].x = ix
 */
          __pyx_v_indices_count = (__pyx_v_indices_count - 6);

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":433
 *                         vertices_count -= 2
 *                         indices_count -= 6
 *                         continue             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].x = ix
 *                     vertices[iv + 1].y = iy
 */
          goto __pyx_L7_continue;
          goto __pyx_L15;
        }
        __pyx_L15:;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":434
 *                         indices_count -= 6
 *                         continue
 *                     vertices[iv + 1].x = ix             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].y = iy
 *                     vertices[iv + 1].s0 = 0
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).x = __pyx_v_ix;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":435
 *                         continue
 *                     vertices[iv + 1].x = ix
 *                     vertices[iv + 1].y = iy             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].s0 = 0
 *                     vertices[iv + 1].t0 = 0
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).y = __pyx_v_iy;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":436
 *                     vertices[iv + 1].x = ix
 *                     vertices[iv + 1].y = iy
 *                     vertices[iv + 1].s0 = 0             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].t0 = 0
 *                     indices[ii] = iv
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).s0 = 0.0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":437
 *                     vertices[iv + 1].y = iy
 *                     vertices[iv + 1].s0 = 0
 *                     vertices[iv + 1].t0 = 0             # <<<<<<<<<<<<<<
 *                     indices[ii] = iv
 *                     indices[ii + 1] = iv + 1
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).t0 = 0.0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":438
 *                     vertices[iv + 1].s0 = 0
 *                     vertices[iv + 1].t0 = 0
 *                     indices[ii] = iv             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = iv + 1
 *                     indices[ii + 2] = piv2 + 1
 */
        (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_iv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":439
 *                     vertices[iv + 1].t0 = 0
 *                     indices[ii] = iv
 *                     indices[ii + 1] = iv + 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = piv2 + 1
 *                     indices[ii + 3] = iv
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":440
 *                     indices[ii] = iv
 *                     indices[ii + 1] = iv + 1
 *                     indices[ii + 2] = piv2 + 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 3] = iv
 *                     indices[ii + 4] = piv
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_piv2 + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":441
 *                     indices[ii + 1] = iv + 1
 *                     indices[ii + 2] = piv2 + 1
 *                     indices[ii + 3] = iv             # <<<<<<<<<<<<<<
 *                     indices[ii + 4] = piv
 *                     indices[ii + 5] = iv + 1
 */
        (__pyx_v_indices[(__pyx_v_ii + 3)]) = __pyx_v_iv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":442
 *                     indices[ii + 2] = piv2 + 1
 *                     indices[ii + 3] = iv
 *                     indices[ii + 4] = piv             # <<<<<<<<<<<<<<
 *                     indices[ii + 5] = iv + 1
 *                     ii += 6
 */
        (__pyx_v_indices[(__pyx_v_ii + 4)]) = __pyx_v_piv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":443
 *                     indices[ii + 3] = iv
 *                     indices[ii + 4] = piv
 *                     indices[ii + 5] = iv + 1             # <<<<<<<<<<<<<<
 *                     ii += 6
 *                     iv += 2
 */
        (__pyx_v_indices[(__pyx_v_ii + 5)]) = (__pyx_v_iv + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":444
 *                     indices[ii + 4] = piv
 *                     indices[ii + 5] = iv + 1
 *                     ii += 6             # <<<<<<<<<<<<<<
 *                     iv += 2
 *                 else:
 */
        __pyx_v_ii = (__pyx_v_ii + 6);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":445
 *                     indices[ii + 5] = iv + 1
 *                     ii += 6
 *                     iv += 2             # <<<<<<<<<<<<<<
 *                 else:
 *                     if line_intersection(px3, py3, px4, py4, x3, y3, x4, y4, &ix, &iy) == 0:
 */
        __pyx_v_iv = (__pyx_v_iv + 2);
        goto __pyx_L14;
      }
      /*else*/ {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":447
 *                     iv += 2
 *                 else:
 *                     if line_intersection(px3, py3, px4, py4, x3, y3, x4, y4, &ix, &iy) == 0:             # <<<<<<<<<<<<<<
 *                         vertices_count -= 2
 *                         indices_count -= 6
 */
        __pyx_t_10 = (__pyx_f_4kivy_8graphics_19vertex_instructions_line_intersection(__pyx_v_px3, __pyx_v_py3, __pyx_v_px4, __pyx_v_py4, __pyx_v_x3, __pyx_v_y3, __pyx_v_x4, __pyx_v_y4, (&__pyx_v_ix), (&__pyx_v_iy)) == 0);
        if (__pyx_t_10) {

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":448
 *                 else:
 *                     if line_intersection(px3, py3, px4, py4, x3, y3, x4, y4, &ix, &iy) == 0:
 *                         vertices_count -= 2             # <<<<<<<<<<<<<<
 *                         indices_count -= 6
 *                         continue
 */
          __pyx_v_vertices_count = (__pyx_v_vertices_count - 2);

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":449
 *                     if line_intersection(px3, py3, px4, py4, x3, y3, x4, y4, &ix, &iy) == 0:
 *                         vertices_count -= 2
 *                         indices_count -= 6             # <<<<<<<<<<<<<<
 *                         continue
 *                     vertices[iv + 1].x = ix
 */
          __pyx_v_indices_count = (__pyx_v_indices_count - 6);

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":450
 *                         vertices_count -= 2
 *                         indices_count -= 6
 *                         continue             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].x = ix
 *                     vertices[iv + 1].y = iy
 */
          goto __pyx_L7_continue;
          goto __pyx_L16;
        }
        __pyx_L16:;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":451
 *                         indices_count -= 6
 *                         continue
 *                     vertices[iv + 1].x = ix             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].y = iy
 *                     vertices[iv + 1].s0 = 0
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).x = __pyx_v_ix;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":452
 *                         continue
 *                     vertices[iv + 1].x = ix
 *                     vertices[iv + 1].y = iy             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].s0 = 0
 *                     vertices[iv + 1].t0 = 0
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).y = __pyx_v_iy;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":453
 *                     vertices[iv + 1].x = ix
 *                     vertices[iv + 1].y = iy
 *                     vertices[iv + 1].s0 = 0             # <<<<<<<<<<<<<<
 *                     vertices[iv + 1].t0 = 0
 *                     indices[ii] = iv
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).s0 = 0.0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":454
 *                     vertices[iv + 1].y = iy
 *                     vertices[iv + 1].s0 = 0
 *                     vertices[iv + 1].t0 = 0             # <<<<<<<<<<<<<<
 *                     indices[ii] = iv
 *                     indices[ii + 1] = iv + 1
 */
        (__pyx_v_vertices[(__pyx_v_iv + 1)]).t0 = 0.0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":455
 *                     vertices[iv + 1].s0 = 0
 *                     vertices[iv + 1].t0 = 0
 *                     indices[ii] = iv             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = iv + 1
 *                     indices[ii + 2] = piv2 + 2
 */
        (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_iv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":456
 *                     vertices[iv + 1].t0 = 0
 *                     indices[ii] = iv
 *                     indices[ii + 1] = iv + 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = piv2 + 2
 *                     indices[ii + 3] = iv
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":457
 *                     indices[ii] = iv
 *                     indices[ii + 1] = iv + 1
 *                     indices[ii + 2] = piv2 + 2             # <<<<<<<<<<<<<<
 *                     indices[ii + 3] = iv
 *                     indices[ii + 4] = piv + 3
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_piv2 + 2);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":458
 *                     indices[ii + 1] = iv + 1
 *                     indices[ii + 2] = piv2 + 2
 *                     indices[ii + 3] = iv             # <<<<<<<<<<<<<<
 *                     indices[ii + 4] = piv + 3
 *                     indices[ii + 5] = iv + 1
 */
        (__pyx_v_indices[(__pyx_v_ii + 3)]) = __pyx_v_iv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":459
 *                     indices[ii + 2] = piv2 + 2
 *                     indices[ii + 3] = iv
 *                     indices[ii + 4] = piv + 3             # <<<<<<<<<<<<<<
 *                     indices[ii + 5] = iv + 1
 *                     ii += 6
 */
        (__pyx_v_indices[(__pyx_v_ii + 4)]) = (__pyx_v_piv + 3);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":460
 *                     indices[ii + 3] = iv
 *                     indices[ii + 4] = piv + 3
 *                     indices[ii + 5] = iv + 1             # <<<<<<<<<<<<<<
 *                     ii += 6
 *                     iv += 2
 */
        (__pyx_v_indices[(__pyx_v_ii + 5)]) = (__pyx_v_iv + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":461
 *                     indices[ii + 4] = piv + 3
 *                     indices[ii + 5] = iv + 1
 *                     ii += 6             # <<<<<<<<<<<<<<
 *                     iv += 2
 * 
 */
        __pyx_v_ii = (__pyx_v_ii + 6);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":462
 *                     indices[ii + 5] = iv + 1
 *                     ii += 6
 *                     iv += 2             # <<<<<<<<<<<<<<
 * 
 * 
 */
        __pyx_v_iv = (__pyx_v_iv + 2);
      }
      __pyx_L14:;
      break;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":466
 * 
 * 
 *             elif self._joint == LINE_JOINT_ROUND:             # <<<<<<<<<<<<<<
 * 
 *                 # cap end
 */
      case 3:

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":469
 * 
 *                 # cap end
 *                 if jangle < 0:             # <<<<<<<<<<<<<<
 *                     a1 = pangle2 - PI2
 *                     a2 = angle + PI2
 */
      __pyx_t_10 = (__pyx_v_jangle < 0.0);
      if (__pyx_t_10) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":470
 *                 # cap end
 *                 if jangle < 0:
 *                     a1 = pangle2 - PI2             # <<<<<<<<<<<<<<
 *                     a2 = angle + PI2
 *                     a0 = a2
 */
        __pyx_v_a1 = (__pyx_v_pangle2 - 1.5707963267948966);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":471
 *                 if jangle < 0:
 *                     a1 = pangle2 - PI2
 *                     a2 = angle + PI2             # <<<<<<<<<<<<<<
 *                     a0 = a2
 *                     step = (abs(jangle)) / float(self._joint_precision)
 */
        __pyx_v_a2 = (__pyx_v_angle + 1.5707963267948966);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":472
 *                     a1 = pangle2 - PI2
 *                     a2 = angle + PI2
 *                     a0 = a2             # <<<<<<<<<<<<<<
 *                     step = (abs(jangle)) / float(self._joint_precision)
 *                     pivstart = piv + 3
 */
        __pyx_v_a0 = __pyx_v_a2;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":473
 *                     a2 = angle + PI2
 *                     a0 = a2
 *                     step = (abs(jangle)) / float(self._joint_precision)             # <<<<<<<<<<<<<<
 *                     pivstart = piv + 3
 *                     pivend = piv2 + 1
 */
        __pyx_t_9 = fabs(__pyx_v_jangle);
        if (unlikely(((double)__pyx_v_self->_joint_precision) == 0)) {
          PyErr_Format(PyExc_ZeroDivisionError, "float division");
          {__pyx_filename = __pyx_f[1]; __pyx_lineno = 473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        __pyx_t_5 = PyFloat_FromDouble((__pyx_t_9 / ((double)__pyx_v_self->_joint_precision))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_5);
        __Pyx_XDECREF(__pyx_v_step);
        __pyx_v_step = __pyx_t_5;
        __pyx_t_5 = 0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":474
 *                     a0 = a2
 *                     step = (abs(jangle)) / float(self._joint_precision)
 *                     pivstart = piv + 3             # <<<<<<<<<<<<<<
 *                     pivend = piv2 + 1
 *                 else:
 */
        __pyx_v_pivstart = (__pyx_v_piv + 3);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":475
 *                     step = (abs(jangle)) / float(self._joint_precision)
 *                     pivstart = piv + 3
 *                     pivend = piv2 + 1             # <<<<<<<<<<<<<<
 *                 else:
 *                     a1 = angle - PI2
 */
        __pyx_v_pivend = (__pyx_v_piv2 + 1);
        goto __pyx_L17;
      }
      /*else*/ {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":477
 *                     pivend = piv2 + 1
 *                 else:
 *                     a1 = angle - PI2             # <<<<<<<<<<<<<<
 *                     a2 = pangle2 + PI2
 *                     a0 = a1
 */
        __pyx_v_a1 = (__pyx_v_angle - 1.5707963267948966);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":478
 *                 else:
 *                     a1 = angle - PI2
 *                     a2 = pangle2 + PI2             # <<<<<<<<<<<<<<
 *                     a0 = a1
 *                     step = -(abs(jangle)) / float(self._joint_precision)
 */
        __pyx_v_a2 = (__pyx_v_pangle2 + 1.5707963267948966);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":479
 *                     a1 = angle - PI2
 *                     a2 = pangle2 + PI2
 *                     a0 = a1             # <<<<<<<<<<<<<<
 *                     step = -(abs(jangle)) / float(self._joint_precision)
 *                     pivstart = piv
 */
        __pyx_v_a0 = __pyx_v_a1;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":480
 *                     a2 = pangle2 + PI2
 *                     a0 = a1
 *                     step = -(abs(jangle)) / float(self._joint_precision)             # <<<<<<<<<<<<<<
 *                     pivstart = piv
 *                     pivend = piv2 + 2
 */
        __pyx_t_9 = (-fabs(__pyx_v_jangle));
        if (unlikely(((double)__pyx_v_self->_joint_precision) == 0)) {
          PyErr_Format(PyExc_ZeroDivisionError, "float division");
          {__pyx_filename = __pyx_f[1]; __pyx_lineno = 480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        __pyx_t_5 = PyFloat_FromDouble((__pyx_t_9 / ((double)__pyx_v_self->_joint_precision))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_5);
        __Pyx_XDECREF(__pyx_v_step);
        __pyx_v_step = __pyx_t_5;
        __pyx_t_5 = 0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":481
 *                     a0 = a1
 *                     step = -(abs(jangle)) / float(self._joint_precision)
 *                     pivstart = piv             # <<<<<<<<<<<<<<
 *                     pivend = piv2 + 2
 *                 siv = iv
 */
        __pyx_v_pivstart = __pyx_v_piv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":482
 *                     step = -(abs(jangle)) / float(self._joint_precision)
 *                     pivstart = piv
 *                     pivend = piv2 + 2             # <<<<<<<<<<<<<<
 *                 siv = iv
 *                 vertices[iv].x = ax
 */
        __pyx_v_pivend = (__pyx_v_piv2 + 2);
      }
      __pyx_L17:;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":483
 *                     pivstart = piv
 *                     pivend = piv2 + 2
 *                 siv = iv             # <<<<<<<<<<<<<<
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay
 */
      __pyx_v_siv = __pyx_v_iv;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":484
 *                     pivend = piv2 + 2
 *                 siv = iv
 *                 vertices[iv].x = ax             # <<<<<<<<<<<<<<
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0
 */
      (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_ax;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":485
 *                 siv = iv
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay             # <<<<<<<<<<<<<<
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 */
      (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_ay;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":486
 *                 vertices[iv].x = ax
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *                 vertices[iv].t0 = 0
 *                 iv += 1
 */
      (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":487
 *                 vertices[iv].y = ay
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *                 iv += 1
 *                 for j in xrange(0, self._joint_precision - 1):
 */
      (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":488
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 *                 iv += 1             # <<<<<<<<<<<<<<
 *                 for j in xrange(0, self._joint_precision - 1):
 *                     vertices[iv].x = ax - cos(a0 - step * j) * w
 */
      __pyx_v_iv = (__pyx_v_iv + 1);

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":489
 *                 vertices[iv].t0 = 0
 *                 iv += 1
 *                 for j in xrange(0, self._joint_precision - 1):             # <<<<<<<<<<<<<<
 *                     vertices[iv].x = ax - cos(a0 - step * j) * w
 *                     vertices[iv].y = ay - sin(a0 - step * j) * w
 */
      __pyx_t_8 = (__pyx_v_self->_joint_precision - 1);
      for (__pyx_t_12 = 0; __pyx_t_12 < __pyx_t_8; __pyx_t_12+=1) {
        __pyx_v_j = __pyx_t_12;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":490
 *                 iv += 1
 *                 for j in xrange(0, self._joint_precision - 1):
 *                     vertices[iv].x = ax - cos(a0 - step * j) * w             # <<<<<<<<<<<<<<
 *                     vertices[iv].y = ay - sin(a0 - step * j) * w
 *                     vertices[iv].s0 = 0
 */
        __pyx_t_5 = PyFloat_FromDouble(__pyx_v_a0); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_5);
        __pyx_t_1 = PyInt_FromLong(__pyx_v_j); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_1);
        __pyx_t_13 = PyNumber_Multiply(__pyx_v_step, __pyx_t_1); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_13);
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __pyx_t_1 = PyNumber_Subtract(__pyx_t_5, __pyx_t_13); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        (__pyx_v_vertices[__pyx_v_iv]).x = (__pyx_v_ax - (cos(__pyx_t_9) * __pyx_v_w));

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":491
 *                 for j in xrange(0, self._joint_precision - 1):
 *                     vertices[iv].x = ax - cos(a0 - step * j) * w
 *                     vertices[iv].y = ay - sin(a0 - step * j) * w             # <<<<<<<<<<<<<<
 *                     vertices[iv].s0 = 0
 *                     vertices[iv].t0 = 0
 */
        __pyx_t_1 = PyFloat_FromDouble(__pyx_v_a0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 491; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_1);
        __pyx_t_13 = PyInt_FromLong(__pyx_v_j); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 491; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_13);
        __pyx_t_5 = PyNumber_Multiply(__pyx_v_step, __pyx_t_13); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 491; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_5);
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        __pyx_t_13 = PyNumber_Subtract(__pyx_t_1, __pyx_t_5); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 491; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_13);
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
        __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_13); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 491; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        (__pyx_v_vertices[__pyx_v_iv]).y = (__pyx_v_ay - (sin(__pyx_t_9) * __pyx_v_w));

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":492
 *                     vertices[iv].x = ax - cos(a0 - step * j) * w
 *                     vertices[iv].y = ay - sin(a0 - step * j) * w
 *                     vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *                     vertices[iv].t0 = 0
 *                     if j == 0:
 */
        (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":493
 *                     vertices[iv].y = ay - sin(a0 - step * j) * w
 *                     vertices[iv].s0 = 0
 *                     vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *                     if j == 0:
 *                         indices[ii] = siv
 */
        (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":494
 *                     vertices[iv].s0 = 0
 *                     vertices[iv].t0 = 0
 *                     if j == 0:             # <<<<<<<<<<<<<<
 *                         indices[ii] = siv
 *                         indices[ii + 1] = pivstart
 */
        __pyx_t_10 = (__pyx_v_j == 0);
        if (__pyx_t_10) {

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":495
 *                     vertices[iv].t0 = 0
 *                     if j == 0:
 *                         indices[ii] = siv             # <<<<<<<<<<<<<<
 *                         indices[ii + 1] = pivstart
 *                         indices[ii + 2] = iv
 */
          (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":496
 *                     if j == 0:
 *                         indices[ii] = siv
 *                         indices[ii + 1] = pivstart             # <<<<<<<<<<<<<<
 *                         indices[ii + 2] = iv
 *                     else:
 */
          (__pyx_v_indices[(__pyx_v_ii + 1)]) = __pyx_v_pivstart;

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":497
 *                         indices[ii] = siv
 *                         indices[ii + 1] = pivstart
 *                         indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                     else:
 *                         indices[ii] = siv
 */
          (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
          goto __pyx_L20;
        }
        /*else*/ {

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":499
 *                         indices[ii + 2] = iv
 *                     else:
 *                         indices[ii] = siv             # <<<<<<<<<<<<<<
 *                         indices[ii + 1] = iv - 1
 *                         indices[ii + 2] = iv
 */
          (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":500
 *                     else:
 *                         indices[ii] = siv
 *                         indices[ii + 1] = iv - 1             # <<<<<<<<<<<<<<
 *                         indices[ii + 2] = iv
 *                     iv += 1
 */
          (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv - 1);

          /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":501
 *                         indices[ii] = siv
 *                         indices[ii + 1] = iv - 1
 *                         indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                     iv += 1
 *                     ii += 3
 */
          (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
        }
        __pyx_L20:;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":502
 *                         indices[ii + 1] = iv - 1
 *                         indices[ii + 2] = iv
 *                     iv += 1             # <<<<<<<<<<<<<<
 *                     ii += 3
 *                 indices[ii] = siv
 */
        __pyx_v_iv = (__pyx_v_iv + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":503
 *                         indices[ii + 2] = iv
 *                     iv += 1
 *                     ii += 3             # <<<<<<<<<<<<<<
 *                 indices[ii] = siv
 *                 indices[ii + 1] = iv - 1
 */
        __pyx_v_ii = (__pyx_v_ii + 3);
      }

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":504
 *                     iv += 1
 *                     ii += 3
 *                 indices[ii] = siv             # <<<<<<<<<<<<<<
 *                 indices[ii + 1] = iv - 1
 *                 indices[ii + 2] = pivend
 */
      (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":505
 *                     ii += 3
 *                 indices[ii] = siv
 *                 indices[ii + 1] = iv - 1             # <<<<<<<<<<<<<<
 *                 indices[ii + 2] = pivend
 *                 ii += 3
 */
      (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv - 1);

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":506
 *                 indices[ii] = siv
 *                 indices[ii + 1] = iv - 1
 *                 indices[ii + 2] = pivend             # <<<<<<<<<<<<<<
 *                 ii += 3
 * 
 */
      (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_pivend;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":507
 *                 indices[ii + 1] = iv - 1
 *                 indices[ii + 2] = pivend
 *                 ii += 3             # <<<<<<<<<<<<<<
 * 
 *         # caps
 */
      __pyx_v_ii = (__pyx_v_ii + 3);
      break;
    }
    __pyx_L7_continue:;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":544
 *             iv += 2
 * 
 *         elif cap == LINE_CAP_ROUND:             # <<<<<<<<<<<<<<
 * 
 *             # cap start
 */
  switch (__pyx_v_cap) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":510
 * 
 *         # caps
 *         if cap == LINE_CAP_SQUARE:             # <<<<<<<<<<<<<<
 *             vertices[iv].x = x2 + cos(angle) * w
 *             vertices[iv].y = y2 + sin(angle) * w
 */
    case 1:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":511
 *         # caps
 *         if cap == LINE_CAP_SQUARE:
 *             vertices[iv].x = x2 + cos(angle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv].y = y2 + sin(angle) * w
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = (__pyx_v_x2 + (cos(__pyx_v_angle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":512
 *         if cap == LINE_CAP_SQUARE:
 *             vertices[iv].x = x2 + cos(angle) * w
 *             vertices[iv].y = y2 + sin(angle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = (__pyx_v_y2 + (sin(__pyx_v_angle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":513
 *             vertices[iv].x = x2 + cos(angle) * w
 *             vertices[iv].y = y2 + sin(angle) * w
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             vertices[iv + 1].x = x3 + cos(angle) * w
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":514
 *             vertices[iv].y = y2 + sin(angle) * w
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].x = x3 + cos(angle) * w
 *             vertices[iv + 1].y = y3 + sin(angle) * w
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":515
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             vertices[iv + 1].x = x3 + cos(angle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].y = y3 + sin(angle) * w
 *             vertices[iv + 1].s0 = 0
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).x = (__pyx_v_x3 + (cos(__pyx_v_angle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":516
 *             vertices[iv].t0 = 0
 *             vertices[iv + 1].x = x3 + cos(angle) * w
 *             vertices[iv + 1].y = y3 + sin(angle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].s0 = 0
 *             vertices[iv + 1].t0 = 0
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).y = (__pyx_v_y3 + (sin(__pyx_v_angle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":517
 *             vertices[iv + 1].x = x3 + cos(angle) * w
 *             vertices[iv + 1].y = y3 + sin(angle) * w
 *             vertices[iv + 1].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].t0 = 0
 *             indices[ii] = piv + 1
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":518
 *             vertices[iv + 1].y = y3 + sin(angle) * w
 *             vertices[iv + 1].s0 = 0
 *             vertices[iv + 1].t0 = 0             # <<<<<<<<<<<<<<
 *             indices[ii] = piv + 1
 *             indices[ii + 1] = piv + 2
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":519
 *             vertices[iv + 1].s0 = 0
 *             vertices[iv + 1].t0 = 0
 *             indices[ii] = piv + 1             # <<<<<<<<<<<<<<
 *             indices[ii + 1] = piv + 2
 *             indices[ii + 2] = iv + 1
 */
    (__pyx_v_indices[__pyx_v_ii]) = (__pyx_v_piv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":520
 *             vertices[iv + 1].t0 = 0
 *             indices[ii] = piv + 1
 *             indices[ii + 1] = piv + 2             # <<<<<<<<<<<<<<
 *             indices[ii + 2] = iv + 1
 *             indices[ii + 3] = piv + 1
 */
    (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_piv + 2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":521
 *             indices[ii] = piv + 1
 *             indices[ii + 1] = piv + 2
 *             indices[ii + 2] = iv + 1             # <<<<<<<<<<<<<<
 *             indices[ii + 3] = piv + 1
 *             indices[ii + 4] = iv
 */
    (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":522
 *             indices[ii + 1] = piv + 2
 *             indices[ii + 2] = iv + 1
 *             indices[ii + 3] = piv + 1             # <<<<<<<<<<<<<<
 *             indices[ii + 4] = iv
 *             indices[ii + 5] = iv + 1
 */
    (__pyx_v_indices[(__pyx_v_ii + 3)]) = (__pyx_v_piv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":523
 *             indices[ii + 2] = iv + 1
 *             indices[ii + 3] = piv + 1
 *             indices[ii + 4] = iv             # <<<<<<<<<<<<<<
 *             indices[ii + 5] = iv + 1
 *             ii += 6
 */
    (__pyx_v_indices[(__pyx_v_ii + 4)]) = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":524
 *             indices[ii + 3] = piv + 1
 *             indices[ii + 4] = iv
 *             indices[ii + 5] = iv + 1             # <<<<<<<<<<<<<<
 *             ii += 6
 *             iv += 2
 */
    (__pyx_v_indices[(__pyx_v_ii + 5)]) = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":525
 *             indices[ii + 4] = iv
 *             indices[ii + 5] = iv + 1
 *             ii += 6             # <<<<<<<<<<<<<<
 *             iv += 2
 *             vertices[iv].x = sx1 - cos(sangle) * w
 */
    __pyx_v_ii = (__pyx_v_ii + 6);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":526
 *             indices[ii + 5] = iv + 1
 *             ii += 6
 *             iv += 2             # <<<<<<<<<<<<<<
 *             vertices[iv].x = sx1 - cos(sangle) * w
 *             vertices[iv].y = sy1 - sin(sangle) * w
 */
    __pyx_v_iv = (__pyx_v_iv + 2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":527
 *             ii += 6
 *             iv += 2
 *             vertices[iv].x = sx1 - cos(sangle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv].y = sy1 - sin(sangle) * w
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = (__pyx_v_sx1 - (cos(__pyx_v_sangle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":528
 *             iv += 2
 *             vertices[iv].x = sx1 - cos(sangle) * w
 *             vertices[iv].y = sy1 - sin(sangle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = (__pyx_v_sy1 - (sin(__pyx_v_sangle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":529
 *             vertices[iv].x = sx1 - cos(sangle) * w
 *             vertices[iv].y = sy1 - sin(sangle) * w
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             vertices[iv + 1].x = sx4 - cos(sangle) * w
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":530
 *             vertices[iv].y = sy1 - sin(sangle) * w
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].x = sx4 - cos(sangle) * w
 *             vertices[iv + 1].y = sy4 - sin(sangle) * w
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":531
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             vertices[iv + 1].x = sx4 - cos(sangle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].y = sy4 - sin(sangle) * w
 *             vertices[iv + 1].s0 = 0
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).x = (__pyx_v_sx4 - (cos(__pyx_v_sangle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":532
 *             vertices[iv].t0 = 0
 *             vertices[iv + 1].x = sx4 - cos(sangle) * w
 *             vertices[iv + 1].y = sy4 - sin(sangle) * w             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].s0 = 0
 *             vertices[iv + 1].t0 = 0
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).y = (__pyx_v_sy4 - (sin(__pyx_v_sangle) * __pyx_v_w));

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":533
 *             vertices[iv + 1].x = sx4 - cos(sangle) * w
 *             vertices[iv + 1].y = sy4 - sin(sangle) * w
 *             vertices[iv + 1].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].t0 = 0
 *             indices[ii] = 0
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":534
 *             vertices[iv + 1].y = sy4 - sin(sangle) * w
 *             vertices[iv + 1].s0 = 0
 *             vertices[iv + 1].t0 = 0             # <<<<<<<<<<<<<<
 *             indices[ii] = 0
 *             indices[ii + 1] = 3
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":535
 *             vertices[iv + 1].s0 = 0
 *             vertices[iv + 1].t0 = 0
 *             indices[ii] = 0             # <<<<<<<<<<<<<<
 *             indices[ii + 1] = 3
 *             indices[ii + 2] = iv + 1
 */
    (__pyx_v_indices[__pyx_v_ii]) = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":536
 *             vertices[iv + 1].t0 = 0
 *             indices[ii] = 0
 *             indices[ii + 1] = 3             # <<<<<<<<<<<<<<
 *             indices[ii + 2] = iv + 1
 *             indices[ii + 3] = 0
 */
    (__pyx_v_indices[(__pyx_v_ii + 1)]) = 3;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":537
 *             indices[ii] = 0
 *             indices[ii + 1] = 3
 *             indices[ii + 2] = iv + 1             # <<<<<<<<<<<<<<
 *             indices[ii + 3] = 0
 *             indices[ii + 4] = iv
 */
    (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":538
 *             indices[ii + 1] = 3
 *             indices[ii + 2] = iv + 1
 *             indices[ii + 3] = 0             # <<<<<<<<<<<<<<
 *             indices[ii + 4] = iv
 *             indices[ii + 5] = iv + 1
 */
    (__pyx_v_indices[(__pyx_v_ii + 3)]) = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":539
 *             indices[ii + 2] = iv + 1
 *             indices[ii + 3] = 0
 *             indices[ii + 4] = iv             # <<<<<<<<<<<<<<
 *             indices[ii + 5] = iv + 1
 *             ii += 6
 */
    (__pyx_v_indices[(__pyx_v_ii + 4)]) = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":540
 *             indices[ii + 3] = 0
 *             indices[ii + 4] = iv
 *             indices[ii + 5] = iv + 1             # <<<<<<<<<<<<<<
 *             ii += 6
 *             iv += 2
 */
    (__pyx_v_indices[(__pyx_v_ii + 5)]) = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":541
 *             indices[ii + 4] = iv
 *             indices[ii + 5] = iv + 1
 *             ii += 6             # <<<<<<<<<<<<<<
 *             iv += 2
 * 
 */
    __pyx_v_ii = (__pyx_v_ii + 6);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":542
 *             indices[ii + 5] = iv + 1
 *             ii += 6
 *             iv += 2             # <<<<<<<<<<<<<<
 * 
 *         elif cap == LINE_CAP_ROUND:
 */
    __pyx_v_iv = (__pyx_v_iv + 2);
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":544
 *             iv += 2
 * 
 *         elif cap == LINE_CAP_ROUND:             # <<<<<<<<<<<<<<
 * 
 *             # cap start
 */
    case 2:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":547
 * 
 *             # cap start
 *             a1 = sangle - PI2             # <<<<<<<<<<<<<<
 *             a2 = sangle + PI2
 *             step = (a1 - a2) / float(self._cap_precision)
 */
    __pyx_v_a1 = (__pyx_v_sangle - 1.5707963267948966);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":548
 *             # cap start
 *             a1 = sangle - PI2
 *             a2 = sangle + PI2             # <<<<<<<<<<<<<<
 *             step = (a1 - a2) / float(self._cap_precision)
 *             siv = iv
 */
    __pyx_v_a2 = (__pyx_v_sangle + 1.5707963267948966);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":549
 *             a1 = sangle - PI2
 *             a2 = sangle + PI2
 *             step = (a1 - a2) / float(self._cap_precision)             # <<<<<<<<<<<<<<
 *             siv = iv
 *             cx = p[0]
 */
    __pyx_t_9 = (__pyx_v_a1 - __pyx_v_a2);
    if (unlikely(((double)__pyx_v_self->_cap_precision) == 0)) {
      PyErr_Format(PyExc_ZeroDivisionError, "float division");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 549; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_13 = PyFloat_FromDouble((__pyx_t_9 / ((double)__pyx_v_self->_cap_precision))); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 549; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_13);
    __Pyx_XDECREF(__pyx_v_step);
    __pyx_v_step = __pyx_t_13;
    __pyx_t_13 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":550
 *             a2 = sangle + PI2
 *             step = (a1 - a2) / float(self._cap_precision)
 *             siv = iv             # <<<<<<<<<<<<<<
 *             cx = p[0]
 *             cy = p[1]
 */
    __pyx_v_siv = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":551
 *             step = (a1 - a2) / float(self._cap_precision)
 *             siv = iv
 *             cx = p[0]             # <<<<<<<<<<<<<<
 *             cy = p[1]
 *             vertices[iv].x = cx
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_13 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_13) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_13);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_13); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
    __pyx_v_cx = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":552
 *             siv = iv
 *             cx = p[0]
 *             cy = p[1]             # <<<<<<<<<<<<<<
 *             vertices[iv].x = cx
 *             vertices[iv].y = cy
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 552; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_13 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_13) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 552; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_13);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_13); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 552; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
    __pyx_v_cy = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":553
 *             cx = p[0]
 *             cy = p[1]
 *             vertices[iv].x = cx             # <<<<<<<<<<<<<<
 *             vertices[iv].y = cy
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_cx;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":554
 *             cy = p[1]
 *             vertices[iv].x = cx
 *             vertices[iv].y = cy             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_cy;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":555
 *             vertices[iv].x = cx
 *             vertices[iv].y = cy
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             iv += 1
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":556
 *             vertices[iv].y = cy
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             iv += 1
 *             for i in xrange(0, self._cap_precision - 1):
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":557
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             iv += 1             # <<<<<<<<<<<<<<
 *             for i in xrange(0, self._cap_precision - 1):
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 */
    __pyx_v_iv = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":558
 *             vertices[iv].t0 = 0
 *             iv += 1
 *             for i in xrange(0, self._cap_precision - 1):             # <<<<<<<<<<<<<<
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 */
    __pyx_t_6 = (__pyx_v_self->_cap_precision - 1);
    for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) {
      __pyx_v_i = __pyx_t_7;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":559
 *             iv += 1
 *             for i in xrange(0, self._cap_precision - 1):
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w             # <<<<<<<<<<<<<<
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 *                 vertices[iv].s0 = 0
 */
      __pyx_t_13 = PyFloat_FromDouble(__pyx_v_a1); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_13);
      __pyx_t_5 = PyInt_FromLong(__pyx_v_i); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_5);
      __pyx_t_1 = PyNumber_Multiply(__pyx_v_step, __pyx_t_5); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __pyx_t_5 = PyNumber_Add(__pyx_t_13, __pyx_t_1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_5);
      __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      (__pyx_v_vertices[__pyx_v_iv]).x = (__pyx_v_cx + (cos(__pyx_t_9) * __pyx_v_w));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":560
 *             for i in xrange(0, self._cap_precision - 1):
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w             # <<<<<<<<<<<<<<
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 */
      __pyx_t_5 = PyFloat_FromDouble(__pyx_v_a1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_5);
      __pyx_t_1 = PyInt_FromLong(__pyx_v_i); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __pyx_t_13 = PyNumber_Multiply(__pyx_v_step, __pyx_t_1); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_13);
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __pyx_t_1 = PyNumber_Add(__pyx_t_5, __pyx_t_13); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
      __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      (__pyx_v_vertices[__pyx_v_iv]).y = (__pyx_v_cy + (sin(__pyx_t_9) * __pyx_v_w));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":561
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 *                 vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *                 vertices[iv].t0 = 0
 *                 if i == 0:
 */
      (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":562
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *                 if i == 0:
 *                     indices[ii] = siv
 */
      (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":563
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 *                 if i == 0:             # <<<<<<<<<<<<<<
 *                     indices[ii] = siv
 *                     indices[ii + 1] = 0
 */
      __pyx_t_10 = (__pyx_v_i == 0);
      if (__pyx_t_10) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":564
 *                 vertices[iv].t0 = 0
 *                 if i == 0:
 *                     indices[ii] = siv             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = 0
 *                     indices[ii + 2] = iv
 */
        (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":565
 *                 if i == 0:
 *                     indices[ii] = siv
 *                     indices[ii + 1] = 0             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = iv
 *                 else:
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = 0;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":566
 *                     indices[ii] = siv
 *                     indices[ii + 1] = 0
 *                     indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                 else:
 *                     indices[ii] = siv
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
        goto __pyx_L23;
      }
      /*else*/ {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":568
 *                     indices[ii + 2] = iv
 *                 else:
 *                     indices[ii] = siv             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = iv - 1
 *                     indices[ii + 2] = iv
 */
        (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":569
 *                 else:
 *                     indices[ii] = siv
 *                     indices[ii + 1] = iv - 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = iv
 *                 iv += 1
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv - 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":570
 *                     indices[ii] = siv
 *                     indices[ii + 1] = iv - 1
 *                     indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                 iv += 1
 *                 ii += 3
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
      }
      __pyx_L23:;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":571
 *                     indices[ii + 1] = iv - 1
 *                     indices[ii + 2] = iv
 *                 iv += 1             # <<<<<<<<<<<<<<
 *                 ii += 3
 *             indices[ii] = siv
 */
      __pyx_v_iv = (__pyx_v_iv + 1);

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":572
 *                     indices[ii + 2] = iv
 *                 iv += 1
 *                 ii += 3             # <<<<<<<<<<<<<<
 *             indices[ii] = siv
 *             indices[ii + 1] = iv - 1
 */
      __pyx_v_ii = (__pyx_v_ii + 3);
    }

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":573
 *                 iv += 1
 *                 ii += 3
 *             indices[ii] = siv             # <<<<<<<<<<<<<<
 *             indices[ii + 1] = iv - 1
 *             indices[ii + 2] = 3
 */
    (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":574
 *                 ii += 3
 *             indices[ii] = siv
 *             indices[ii + 1] = iv - 1             # <<<<<<<<<<<<<<
 *             indices[ii + 2] = 3
 *             ii += 3
 */
    (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv - 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":575
 *             indices[ii] = siv
 *             indices[ii + 1] = iv - 1
 *             indices[ii + 2] = 3             # <<<<<<<<<<<<<<
 *             ii += 3
 * 
 */
    (__pyx_v_indices[(__pyx_v_ii + 2)]) = 3;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":576
 *             indices[ii + 1] = iv - 1
 *             indices[ii + 2] = 3
 *             ii += 3             # <<<<<<<<<<<<<<
 * 
 *             # cap end
 */
    __pyx_v_ii = (__pyx_v_ii + 3);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":579
 * 
 *             # cap end
 *             a1 = angle - PI2             # <<<<<<<<<<<<<<
 *             a2 = angle + PI2
 *             step = (a2 - a1) / float(self._cap_precision)
 */
    __pyx_v_a1 = (__pyx_v_angle - 1.5707963267948966);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":580
 *             # cap end
 *             a1 = angle - PI2
 *             a2 = angle + PI2             # <<<<<<<<<<<<<<
 *             step = (a2 - a1) / float(self._cap_precision)
 *             siv = iv
 */
    __pyx_v_a2 = (__pyx_v_angle + 1.5707963267948966);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":581
 *             a1 = angle - PI2
 *             a2 = angle + PI2
 *             step = (a2 - a1) / float(self._cap_precision)             # <<<<<<<<<<<<<<
 *             siv = iv
 *             cx = p[-2]
 */
    __pyx_t_9 = (__pyx_v_a2 - __pyx_v_a1);
    if (unlikely(((double)__pyx_v_self->_cap_precision) == 0)) {
      PyErr_Format(PyExc_ZeroDivisionError, "float division");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 581; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = PyFloat_FromDouble((__pyx_t_9 / ((double)__pyx_v_self->_cap_precision))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 581; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_v_step);
    __pyx_v_step = __pyx_t_1;
    __pyx_t_1 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":582
 *             a2 = angle + PI2
 *             step = (a2 - a1) / float(self._cap_precision)
 *             siv = iv             # <<<<<<<<<<<<<<
 *             cx = p[-2]
 *             cy = p[-1]
 */
    __pyx_v_siv = __pyx_v_iv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":583
 *             step = (a2 - a1) / float(self._cap_precision)
 *             siv = iv
 *             cx = p[-2]             # <<<<<<<<<<<<<<
 *             cy = p[-1]
 *             vertices[iv].x = cx
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), -2, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __pyx_v_cx = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":584
 *             siv = iv
 *             cx = p[-2]
 *             cy = p[-1]             # <<<<<<<<<<<<<<
 *             vertices[iv].x = cx
 *             vertices[iv].y = cy
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), -1, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __pyx_v_cy = __pyx_t_9;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":585
 *             cx = p[-2]
 *             cy = p[-1]
 *             vertices[iv].x = cx             # <<<<<<<<<<<<<<
 *             vertices[iv].y = cy
 *             vertices[iv].s0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = __pyx_v_cx;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":586
 *             cy = p[-1]
 *             vertices[iv].x = cx
 *             vertices[iv].y = cy             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = __pyx_v_cy;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":587
 *             vertices[iv].x = cx
 *             vertices[iv].y = cy
 *             vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = 0
 *             iv += 1
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":588
 *             vertices[iv].y = cy
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *             iv += 1
 *             for i in xrange(0, self._cap_precision - 1):
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":589
 *             vertices[iv].s0 = 0
 *             vertices[iv].t0 = 0
 *             iv += 1             # <<<<<<<<<<<<<<
 *             for i in xrange(0, self._cap_precision - 1):
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 */
    __pyx_v_iv = (__pyx_v_iv + 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":590
 *             vertices[iv].t0 = 0
 *             iv += 1
 *             for i in xrange(0, self._cap_precision - 1):             # <<<<<<<<<<<<<<
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 */
    __pyx_t_6 = (__pyx_v_self->_cap_precision - 1);
    for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) {
      __pyx_v_i = __pyx_t_7;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":591
 *             iv += 1
 *             for i in xrange(0, self._cap_precision - 1):
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w             # <<<<<<<<<<<<<<
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 *                 vertices[iv].s0 = 0
 */
      __pyx_t_1 = PyFloat_FromDouble(__pyx_v_a1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __pyx_t_13 = PyInt_FromLong(__pyx_v_i); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_13);
      __pyx_t_5 = PyNumber_Multiply(__pyx_v_step, __pyx_t_13); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_5);
      __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
      __pyx_t_13 = PyNumber_Add(__pyx_t_1, __pyx_t_5); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_13);
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_13); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
      (__pyx_v_vertices[__pyx_v_iv]).x = (__pyx_v_cx + (cos(__pyx_t_9) * __pyx_v_w));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":592
 *             for i in xrange(0, self._cap_precision - 1):
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w             # <<<<<<<<<<<<<<
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 */
      __pyx_t_13 = PyFloat_FromDouble(__pyx_v_a1); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_13);
      __pyx_t_5 = PyInt_FromLong(__pyx_v_i); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_5);
      __pyx_t_1 = PyNumber_Multiply(__pyx_v_step, __pyx_t_5); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __pyx_t_5 = PyNumber_Add(__pyx_t_13, __pyx_t_1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_5);
      __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      (__pyx_v_vertices[__pyx_v_iv]).y = (__pyx_v_cy + (sin(__pyx_t_9) * __pyx_v_w));

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":593
 *                 vertices[iv].x = cx + cos(a1 + step * i) * w
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 *                 vertices[iv].s0 = 0             # <<<<<<<<<<<<<<
 *                 vertices[iv].t0 = 0
 *                 if i == 0:
 */
      (__pyx_v_vertices[__pyx_v_iv]).s0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":594
 *                 vertices[iv].y = cy + sin(a1 + step * i) * w
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0             # <<<<<<<<<<<<<<
 *                 if i == 0:
 *                     indices[ii] = siv
 */
      (__pyx_v_vertices[__pyx_v_iv]).t0 = 0.0;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":595
 *                 vertices[iv].s0 = 0
 *                 vertices[iv].t0 = 0
 *                 if i == 0:             # <<<<<<<<<<<<<<
 *                     indices[ii] = siv
 *                     indices[ii + 1] = piv + 1
 */
      __pyx_t_10 = (__pyx_v_i == 0);
      if (__pyx_t_10) {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":596
 *                 vertices[iv].t0 = 0
 *                 if i == 0:
 *                     indices[ii] = siv             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = piv + 1
 *                     indices[ii + 2] = iv
 */
        (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":597
 *                 if i == 0:
 *                     indices[ii] = siv
 *                     indices[ii + 1] = piv + 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = iv
 *                 else:
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_piv + 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":598
 *                     indices[ii] = siv
 *                     indices[ii + 1] = piv + 1
 *                     indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                 else:
 *                     indices[ii] = siv
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
        goto __pyx_L26;
      }
      /*else*/ {

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":600
 *                     indices[ii + 2] = iv
 *                 else:
 *                     indices[ii] = siv             # <<<<<<<<<<<<<<
 *                     indices[ii + 1] = iv - 1
 *                     indices[ii + 2] = iv
 */
        (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":601
 *                 else:
 *                     indices[ii] = siv
 *                     indices[ii + 1] = iv - 1             # <<<<<<<<<<<<<<
 *                     indices[ii + 2] = iv
 *                 iv += 1
 */
        (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv - 1);

        /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":602
 *                     indices[ii] = siv
 *                     indices[ii + 1] = iv - 1
 *                     indices[ii + 2] = iv             # <<<<<<<<<<<<<<
 *                 iv += 1
 *                 ii += 3
 */
        (__pyx_v_indices[(__pyx_v_ii + 2)]) = __pyx_v_iv;
      }
      __pyx_L26:;

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":603
 *                     indices[ii + 1] = iv - 1
 *                     indices[ii + 2] = iv
 *                 iv += 1             # <<<<<<<<<<<<<<
 *                 ii += 3
 *             indices[ii] = siv
 */
      __pyx_v_iv = (__pyx_v_iv + 1);

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":604
 *                     indices[ii + 2] = iv
 *                 iv += 1
 *                 ii += 3             # <<<<<<<<<<<<<<
 *             indices[ii] = siv
 *             indices[ii + 1] = iv - 1
 */
      __pyx_v_ii = (__pyx_v_ii + 3);
    }

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":605
 *                 iv += 1
 *                 ii += 3
 *             indices[ii] = siv             # <<<<<<<<<<<<<<
 *             indices[ii + 1] = iv - 1
 *             indices[ii + 2] = piv + 2
 */
    (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_siv;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":606
 *                 ii += 3
 *             indices[ii] = siv
 *             indices[ii + 1] = iv - 1             # <<<<<<<<<<<<<<
 *             indices[ii + 2] = piv + 2
 *             ii += 3
 */
    (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv - 1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":607
 *             indices[ii] = siv
 *             indices[ii + 1] = iv - 1
 *             indices[ii + 2] = piv + 2             # <<<<<<<<<<<<<<
 *             ii += 3
 * 
 */
    (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_piv + 2);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":608
 *             indices[ii + 1] = iv - 1
 *             indices[ii + 2] = piv + 2
 *             ii += 3             # <<<<<<<<<<<<<<
 * 
 *         #print 'ii=', ii, 'indices_count=', indices_count
 */
    __pyx_v_ii = (__pyx_v_ii + 3);
    break;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":614
 * 
 *         # compute bbox
 *         for i in xrange(vertices_count):             # <<<<<<<<<<<<<<
 *             if vertices[i].x < self._bxmin:
 *                 self._bxmin = vertices[i].x
 */
  __pyx_t_14 = __pyx_v_vertices_count;
  for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_14; __pyx_t_7+=1) {
    __pyx_v_i = __pyx_t_7;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":615
 *         # compute bbox
 *         for i in xrange(vertices_count):
 *             if vertices[i].x < self._bxmin:             # <<<<<<<<<<<<<<
 *                 self._bxmin = vertices[i].x
 *             if vertices[i].x > self._bxmax:
 */
    __pyx_t_10 = ((__pyx_v_vertices[__pyx_v_i]).x < __pyx_v_self->_bxmin);
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":616
 *         for i in xrange(vertices_count):
 *             if vertices[i].x < self._bxmin:
 *                 self._bxmin = vertices[i].x             # <<<<<<<<<<<<<<
 *             if vertices[i].x > self._bxmax:
 *                 self._bxmax = vertices[i].x
 */
      __pyx_v_self->_bxmin = (__pyx_v_vertices[__pyx_v_i]).x;
      goto __pyx_L29;
    }
    __pyx_L29:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":617
 *             if vertices[i].x < self._bxmin:
 *                 self._bxmin = vertices[i].x
 *             if vertices[i].x > self._bxmax:             # <<<<<<<<<<<<<<
 *                 self._bxmax = vertices[i].x
 *             if vertices[i].y < self._bymin:
 */
    __pyx_t_10 = ((__pyx_v_vertices[__pyx_v_i]).x > __pyx_v_self->_bxmax);
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":618
 *                 self._bxmin = vertices[i].x
 *             if vertices[i].x > self._bxmax:
 *                 self._bxmax = vertices[i].x             # <<<<<<<<<<<<<<
 *             if vertices[i].y < self._bymin:
 *                 self._bymin = vertices[i].y
 */
      __pyx_v_self->_bxmax = (__pyx_v_vertices[__pyx_v_i]).x;
      goto __pyx_L30;
    }
    __pyx_L30:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":619
 *             if vertices[i].x > self._bxmax:
 *                 self._bxmax = vertices[i].x
 *             if vertices[i].y < self._bymin:             # <<<<<<<<<<<<<<
 *                 self._bymin = vertices[i].y
 *             if vertices[i].y > self._bymax:
 */
    __pyx_t_10 = ((__pyx_v_vertices[__pyx_v_i]).y < __pyx_v_self->_bymin);
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":620
 *                 self._bxmax = vertices[i].x
 *             if vertices[i].y < self._bymin:
 *                 self._bymin = vertices[i].y             # <<<<<<<<<<<<<<
 *             if vertices[i].y > self._bymax:
 *                 self._bymax = vertices[i].y
 */
      __pyx_v_self->_bymin = (__pyx_v_vertices[__pyx_v_i]).y;
      goto __pyx_L31;
    }
    __pyx_L31:;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":621
 *             if vertices[i].y < self._bymin:
 *                 self._bymin = vertices[i].y
 *             if vertices[i].y > self._bymax:             # <<<<<<<<<<<<<<
 *                 self._bymax = vertices[i].y
 * 
 */
    __pyx_t_10 = ((__pyx_v_vertices[__pyx_v_i]).y > __pyx_v_self->_bymax);
    if (__pyx_t_10) {

      /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":622
 *                 self._bymin = vertices[i].y
 *             if vertices[i].y > self._bymax:
 *                 self._bymax = vertices[i].y             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, vertices_count, indices, indices_count)
 */
      __pyx_v_self->_bymax = (__pyx_v_vertices[__pyx_v_i]).y;
      goto __pyx_L32;
    }
    __pyx_L32:;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":624
 *                 self._bymax = vertices[i].y
 * 
 *         self.batch.set_data(vertices, vertices_count, indices, indices_count)             # <<<<<<<<<<<<<<
 * 
 *         free(vertices)
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, __pyx_v_vertices_count, __pyx_v_indices, __pyx_v_indices_count);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":626
 *         self.batch.set_data(vertices, vertices_count, indices, indices_count)
 * 
 *         free(vertices)             # <<<<<<<<<<<<<<
 *         free(indices)
 * 
 */
  free(__pyx_v_vertices);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":627
 * 
 *         free(vertices)
 *         free(indices)             # <<<<<<<<<<<<<<
 * 
 * 
 */
  free(__pyx_v_indices);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_13);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.build_extended", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_p);
  __Pyx_XDECREF((PyObject *)__pyx_v_texture);
  __Pyx_XDECREF(__pyx_v_step);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6points_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6points_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6points___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":639
 *             list. It can be very CPU expensive.
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._points
 *         def __set__(self, points):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":640
 *         '''
 *         def __get__(self):
 *             return self._points             # <<<<<<<<<<<<<<
 *         def __set__(self, points):
 *             self._points = list(points)
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_points));
  __pyx_r = ((PyObject *)__pyx_v_self->_points);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6points_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_points));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":641
 *         def __get__(self):
 *             return self._points
 *         def __set__(self, points):             # <<<<<<<<<<<<<<
 *             self._points = list(points)
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":642
 *             return self._points
 *         def __set__(self, points):
 *             self._points = list(points)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 642; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_points);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_points);
  __Pyx_GIVEREF(__pyx_v_points);
  __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 642; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_2);
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":643
 *         def __set__(self, points):
 *             self._points = list(points)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property dash_length:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.points.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_length___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":650
 *         .. versionadded:: 1.0.8
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._dash_length
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_length___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":651
 *         '''
 *         def __get__(self):
 *             return self._dash_length             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_dash_length); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 651; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.dash_length.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":653
 *             return self._dash_length
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":654
 * 
 *         def __set__(self, value):
 *             if value < 0:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 *             self._dash_length = value
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_0, Py_LT); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":655
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_length = value
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_6), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":656
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 *             self._dash_length = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_v_value); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_dash_length = __pyx_t_4;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":657
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 *             self._dash_length = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property dash_offset:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.dash_length.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":664
 *         .. versionadded:: 1.0.8
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._dash_offset
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":665
 *         '''
 *         def __get__(self):
 *             return self._dash_offset             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_dash_offset); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.dash_offset.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":667
 *             return self._dash_offset
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":668
 * 
 *         def __set__(self, value):
 *             if value < 0:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 *             self._dash_offset = value
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_0, Py_LT); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":669
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_offset = value
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_8), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":670
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 *             self._dash_offset = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_v_value); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_dash_offset = __pyx_t_4;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":671
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 *             self._dash_offset = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property width:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.dash_offset.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5width_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5width_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5width___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":678
 *         .. versionadded:: 1.4.1
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._width
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5width___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":679
 *         '''
 *         def __get__(self):
 *             return self._width             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->_width); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.width.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5width_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5width_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5width_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":681
 *             return self._width
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value <= 0:
 *                 raise GraphicException('Invalid width value, must be > 0')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5width_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  float __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":682
 * 
 *         def __set__(self, value):
 *             if value <= 0:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid width value, must be > 0')
 *             self._width = value
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_0, Py_LE); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":683
 *         def __set__(self, value):
 *             if value <= 0:
 *                 raise GraphicException('Invalid width value, must be > 0')             # <<<<<<<<<<<<<<
 *             self._width = value
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_10), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":684
 *             if value <= 0:
 *                 raise GraphicException('Invalid width value, must be > 0')
 *             self._width = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = __pyx_PyFloat_AsFloat(__pyx_v_value); if (unlikely((__pyx_t_4 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 684; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_width = __pyx_t_4;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":685
 *                 raise GraphicException('Invalid width value, must be > 0')
 *             self._width = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property cap:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.width.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_3cap_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_3cap_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_3cap___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":693
 *         .. versionadded:: 1.4.1
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             if self._cap == LINE_CAP_SQUARE:
 *                 return 'square'
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_3cap___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":696
 *             if self._cap == LINE_CAP_SQUARE:
 *                 return 'square'
 *             elif self._cap == LINE_CAP_ROUND:             # <<<<<<<<<<<<<<
 *                 return 'round'
 *             return 'none'
 */
  switch (__pyx_v_self->_cap) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":694
 *         '''
 *         def __get__(self):
 *             if self._cap == LINE_CAP_SQUARE:             # <<<<<<<<<<<<<<
 *                 return 'square'
 *             elif self._cap == LINE_CAP_ROUND:
 */
    case 1:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":695
 *         def __get__(self):
 *             if self._cap == LINE_CAP_SQUARE:
 *                 return 'square'             # <<<<<<<<<<<<<<
 *             elif self._cap == LINE_CAP_ROUND:
 *                 return 'round'
 */
    __Pyx_XDECREF(__pyx_r);
    __Pyx_INCREF(((PyObject *)__pyx_n_s__square));
    __pyx_r = ((PyObject *)__pyx_n_s__square);
    goto __pyx_L0;
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":696
 *             if self._cap == LINE_CAP_SQUARE:
 *                 return 'square'
 *             elif self._cap == LINE_CAP_ROUND:             # <<<<<<<<<<<<<<
 *                 return 'round'
 *             return 'none'
 */
    case 2:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":697
 *                 return 'square'
 *             elif self._cap == LINE_CAP_ROUND:
 *                 return 'round'             # <<<<<<<<<<<<<<
 *             return 'none'
 * 
 */
    __Pyx_XDECREF(__pyx_r);
    __Pyx_INCREF(((PyObject *)__pyx_n_s__round));
    __pyx_r = ((PyObject *)__pyx_n_s__round);
    goto __pyx_L0;
    break;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":698
 *             elif self._cap == LINE_CAP_ROUND:
 *                 return 'round'
 *             return 'none'             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__none));
  __pyx_r = ((PyObject *)__pyx_n_s__none);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_3cap_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_3cap_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_3cap_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":700
 *             return 'none'
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value not in ('none', 'square', 'round'):
 *                 raise GraphicException('Invalid cap, must be one of '
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_3cap_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  int __pyx_t_3;
  int __pyx_t_4;
  PyObject *__pyx_t_5 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":701
 * 
 *         def __set__(self, value):
 *             if value not in ('none', 'square', 'round'):             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid cap, must be one of '
 *                         '"none", "square", "round"')
 */
  __Pyx_INCREF(__pyx_v_value);
  __pyx_t_1 = __pyx_v_value;
  __pyx_t_2 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__none), Py_NE); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 701; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (((int)__pyx_t_2)) {
    __pyx_t_3 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__square), Py_NE); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 701; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_4 = ((int)__pyx_t_3);
  } else {
    __pyx_t_4 = ((int)__pyx_t_2);
  }
  if (__pyx_t_4) {
    __pyx_t_2 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__round), Py_NE); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 701; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_3 = ((int)__pyx_t_2);
  } else {
    __pyx_t_3 = __pyx_t_4;
  }
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_4 = __pyx_t_3;
  if (__pyx_t_4) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":702
 *         def __set__(self, value):
 *             if value not in ('none', 'square', 'round'):
 *                 raise GraphicException('Invalid cap, must be one of '             # <<<<<<<<<<<<<<
 *                         '"none", "square", "round"')
 *             if value == 'square':
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_5 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_12), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":704
 *                 raise GraphicException('Invalid cap, must be one of '
 *                         '"none", "square", "round"')
 *             if value == 'square':             # <<<<<<<<<<<<<<
 *                 self._cap = LINE_CAP_SQUARE
 *             elif value == 'round':
 */
  __pyx_t_4 = __Pyx_PyString_Equals(__pyx_v_value, ((PyObject *)__pyx_n_s__square), Py_EQ); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 704; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__pyx_t_4) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":705
 *                         '"none", "square", "round"')
 *             if value == 'square':
 *                 self._cap = LINE_CAP_SQUARE             # <<<<<<<<<<<<<<
 *             elif value == 'round':
 *                 self._cap = LINE_CAP_ROUND
 */
    __pyx_v_self->_cap = 1;
    goto __pyx_L4;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":706
 *             if value == 'square':
 *                 self._cap = LINE_CAP_SQUARE
 *             elif value == 'round':             # <<<<<<<<<<<<<<
 *                 self._cap = LINE_CAP_ROUND
 *             else:
 */
  __pyx_t_4 = __Pyx_PyString_Equals(__pyx_v_value, ((PyObject *)__pyx_n_s__round), Py_EQ); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 706; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__pyx_t_4) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":707
 *                 self._cap = LINE_CAP_SQUARE
 *             elif value == 'round':
 *                 self._cap = LINE_CAP_ROUND             # <<<<<<<<<<<<<<
 *             else:
 *                 self._cap = LINE_CAP_NONE
 */
    __pyx_v_self->_cap = 2;
    goto __pyx_L4;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":709
 *                 self._cap = LINE_CAP_ROUND
 *             else:
 *                 self._cap = LINE_CAP_NONE             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
    __pyx_v_self->_cap = 0;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":710
 *             else:
 *                 self._cap = LINE_CAP_NONE
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property joint:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.cap.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5joint_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5joint_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5joint___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":719
 *         '''
 * 
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             if self._joint == LINE_JOINT_ROUND:
 *                 return 'round'
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5joint___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":724
 *             elif self._joint == LINE_JOINT_BEVEL:
 *                 return 'bevel'
 *             elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *                 return 'miter'
 *             return 'none'
 */
  switch (__pyx_v_self->_joint) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":720
 * 
 *         def __get__(self):
 *             if self._joint == LINE_JOINT_ROUND:             # <<<<<<<<<<<<<<
 *                 return 'round'
 *             elif self._joint == LINE_JOINT_BEVEL:
 */
    case 3:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":721
 *         def __get__(self):
 *             if self._joint == LINE_JOINT_ROUND:
 *                 return 'round'             # <<<<<<<<<<<<<<
 *             elif self._joint == LINE_JOINT_BEVEL:
 *                 return 'bevel'
 */
    __Pyx_XDECREF(__pyx_r);
    __Pyx_INCREF(((PyObject *)__pyx_n_s__round));
    __pyx_r = ((PyObject *)__pyx_n_s__round);
    goto __pyx_L0;
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":722
 *             if self._joint == LINE_JOINT_ROUND:
 *                 return 'round'
 *             elif self._joint == LINE_JOINT_BEVEL:             # <<<<<<<<<<<<<<
 *                 return 'bevel'
 *             elif self._joint == LINE_JOINT_MITER:
 */
    case 2:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":723
 *                 return 'round'
 *             elif self._joint == LINE_JOINT_BEVEL:
 *                 return 'bevel'             # <<<<<<<<<<<<<<
 *             elif self._joint == LINE_JOINT_MITER:
 *                 return 'miter'
 */
    __Pyx_XDECREF(__pyx_r);
    __Pyx_INCREF(((PyObject *)__pyx_n_s__bevel));
    __pyx_r = ((PyObject *)__pyx_n_s__bevel);
    goto __pyx_L0;
    break;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":724
 *             elif self._joint == LINE_JOINT_BEVEL:
 *                 return 'bevel'
 *             elif self._joint == LINE_JOINT_MITER:             # <<<<<<<<<<<<<<
 *                 return 'miter'
 *             return 'none'
 */
    case 1:

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":725
 *                 return 'bevel'
 *             elif self._joint == LINE_JOINT_MITER:
 *                 return 'miter'             # <<<<<<<<<<<<<<
 *             return 'none'
 * 
 */
    __Pyx_XDECREF(__pyx_r);
    __Pyx_INCREF(((PyObject *)__pyx_n_s__miter));
    __pyx_r = ((PyObject *)__pyx_n_s__miter);
    goto __pyx_L0;
    break;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":726
 *             elif self._joint == LINE_JOINT_MITER:
 *                 return 'miter'
 *             return 'none'             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__none));
  __pyx_r = ((PyObject *)__pyx_n_s__none);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5joint_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5joint_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5joint_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":728
 *             return 'none'
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value not in ('none', 'miter', 'bevel', 'round'):
 *                 raise GraphicException('Invalid joint, must be one of '
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5joint_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  int __pyx_t_3;
  int __pyx_t_4;
  PyObject *__pyx_t_5 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":729
 * 
 *         def __set__(self, value):
 *             if value not in ('none', 'miter', 'bevel', 'round'):             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid joint, must be one of '
 *                     '"none", "miter", "bevel", "round"')
 */
  __Pyx_INCREF(__pyx_v_value);
  __pyx_t_1 = __pyx_v_value;
  __pyx_t_2 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__none), Py_NE); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (((int)__pyx_t_2)) {
    __pyx_t_3 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__miter), Py_NE); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_4 = ((int)__pyx_t_3);
  } else {
    __pyx_t_4 = ((int)__pyx_t_2);
  }
  if (__pyx_t_4) {
    __pyx_t_2 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__bevel), Py_NE); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_3 = ((int)__pyx_t_2);
  } else {
    __pyx_t_3 = __pyx_t_4;
  }
  if (__pyx_t_3) {
    __pyx_t_4 = __Pyx_PyString_Equals(__pyx_t_1, ((PyObject *)__pyx_n_s__round), Py_NE); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_2 = ((int)__pyx_t_4);
  } else {
    __pyx_t_2 = __pyx_t_3;
  }
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_3 = __pyx_t_2;
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":730
 *         def __set__(self, value):
 *             if value not in ('none', 'miter', 'bevel', 'round'):
 *                 raise GraphicException('Invalid joint, must be one of '             # <<<<<<<<<<<<<<
 *                     '"none", "miter", "bevel", "round"')
 *             if value == 'round':
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 730; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_5 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_14), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 730; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 730; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":732
 *                 raise GraphicException('Invalid joint, must be one of '
 *                     '"none", "miter", "bevel", "round"')
 *             if value == 'round':             # <<<<<<<<<<<<<<
 *                 self._joint = LINE_JOINT_ROUND
 *             elif value == 'bevel':
 */
  __pyx_t_3 = __Pyx_PyString_Equals(__pyx_v_value, ((PyObject *)__pyx_n_s__round), Py_EQ); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 732; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":733
 *                     '"none", "miter", "bevel", "round"')
 *             if value == 'round':
 *                 self._joint = LINE_JOINT_ROUND             # <<<<<<<<<<<<<<
 *             elif value == 'bevel':
 *                 self._joint = LINE_JOINT_BEVEL
 */
    __pyx_v_self->_joint = 3;
    goto __pyx_L4;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":734
 *             if value == 'round':
 *                 self._joint = LINE_JOINT_ROUND
 *             elif value == 'bevel':             # <<<<<<<<<<<<<<
 *                 self._joint = LINE_JOINT_BEVEL
 *             elif value == 'miter':
 */
  __pyx_t_3 = __Pyx_PyString_Equals(__pyx_v_value, ((PyObject *)__pyx_n_s__bevel), Py_EQ); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":735
 *                 self._joint = LINE_JOINT_ROUND
 *             elif value == 'bevel':
 *                 self._joint = LINE_JOINT_BEVEL             # <<<<<<<<<<<<<<
 *             elif value == 'miter':
 *                 self._joint = LINE_JOINT_MITER
 */
    __pyx_v_self->_joint = 2;
    goto __pyx_L4;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":736
 *             elif value == 'bevel':
 *                 self._joint = LINE_JOINT_BEVEL
 *             elif value == 'miter':             # <<<<<<<<<<<<<<
 *                 self._joint = LINE_JOINT_MITER
 *             else:
 */
  __pyx_t_3 = __Pyx_PyString_Equals(__pyx_v_value, ((PyObject *)__pyx_n_s__miter), Py_EQ); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__pyx_t_3) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":737
 *                 self._joint = LINE_JOINT_BEVEL
 *             elif value == 'miter':
 *                 self._joint = LINE_JOINT_MITER             # <<<<<<<<<<<<<<
 *             else:
 *                 self._joint = LINE_JOINT_NONE
 */
    __pyx_v_self->_joint = 1;
    goto __pyx_L4;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":739
 *                 self._joint = LINE_JOINT_MITER
 *             else:
 *                 self._joint = LINE_JOINT_NONE             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
    __pyx_v_self->_joint = 0;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":740
 *             else:
 *                 self._joint = LINE_JOINT_NONE
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property cap_precision:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.joint.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":749
 *         '''
 * 
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._cap_precision
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":750
 * 
 *         def __get__(self):
 *             return self._cap_precision             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_cap_precision); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 750; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.cap_precision.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":752
 *             return self._cap_precision
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":753
 * 
 *         def __set__(self, value):
 *             if value < 1:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 *             self._cap_precision = int(value)
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_1, Py_LT); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 753; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 753; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":754
 *         def __set__(self, value):
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')             # <<<<<<<<<<<<<<
 *             self._cap_precision = int(value)
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 754; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_16), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 754; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 754; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":755
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 *             self._cap_precision = int(value)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 755; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_INCREF(__pyx_v_value);
  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_value);
  __Pyx_GIVEREF(__pyx_v_value);
  __pyx_t_1 = PyObject_Call(((PyObject *)((PyObject*)(&PyInt_Type))), ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 755; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_t_1); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 755; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_self->_cap_precision = __pyx_t_4;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":756
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 *             self._cap_precision = int(value)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property joint_precision:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.cap_precision.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":765
 *         '''
 * 
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._joint_precision
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":766
 * 
 *         def __get__(self):
 *             return self._joint_precision             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_joint_precision); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 766; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.joint_precision.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":768
 *             return self._joint_precision
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":769
 * 
 *         def __set__(self, value):
 *             if value < 1:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 *             self._joint_precision = int(value)
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_1, Py_LT); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":770
 *         def __set__(self, value):
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')             # <<<<<<<<<<<<<<
 *             self._joint_precision = int(value)
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 770; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_17), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 770; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 770; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":771
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 *             self._joint_precision = int(value)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 771; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_INCREF(__pyx_v_value);
  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_value);
  __Pyx_GIVEREF(__pyx_v_value);
  __pyx_t_1 = PyObject_Call(((PyObject *)((PyObject*)(&PyInt_Type))), ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 771; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_t_1); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 771; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_self->_joint_precision = __pyx_t_4;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":772
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')
 *             self._joint_precision = int(value)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property close:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.joint_precision.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5close_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5close_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5close___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":780
 *         '''
 * 
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._close
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5close___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":781
 * 
 *         def __get__(self):
 *             return self._close             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_close); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 781; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.close.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5close_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5close_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5close_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":783
 *             return self._close
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             self._close = int(bool(value))
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_5close_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":784
 * 
 *         def __set__(self, value):
 *             self._close = int(bool(value))             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_value); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_close = ((int)(!(!__pyx_t_1)));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":785
 *         def __set__(self, value):
 *             self._close = int(bool(value))
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property ellipse:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.close.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_7ellipse_1__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_args); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_7ellipse_1__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_args) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_7ellipse___set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_args));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":817
 *         '''
 * 
 *         def __set__(self, args):             # <<<<<<<<<<<<<<
 *             if args == None:
 *                 raise GraphicException(
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_7ellipse___set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_args) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  Py_ssize_t __pyx_t_6;
  int __pyx_t_7;
  int __pyx_t_8;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":818
 * 
 *         def __set__(self, args):
 *             if args == None:             # <<<<<<<<<<<<<<
 *                 raise GraphicException(
 *                         'Invalid ellipse value: {0!r}'.format(args))
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_args, Py_None, Py_EQ); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":819
 *         def __set__(self, args):
 *             if args == None:
 *                 raise GraphicException(             # <<<<<<<<<<<<<<
 *                         'Invalid ellipse value: {0!r}'.format(args))
 *             if len(args) not in (4, 6, 7):
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":820
 *             if args == None:
 *                 raise GraphicException(
 *                         'Invalid ellipse value: {0!r}'.format(args))             # <<<<<<<<<<<<<<
 *             if len(args) not in (4, 6, 7):
 *                 raise GraphicException('Invalid number of arguments: '
 */
    __pyx_t_3 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_18), __pyx_n_s__format); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 820; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 820; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_INCREF(__pyx_v_args);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_args);
    __Pyx_GIVEREF(__pyx_v_args);
    __pyx_t_5 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 820; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_5);
    __Pyx_GIVEREF(__pyx_t_5);
    __pyx_t_5 = 0;
    __pyx_t_5 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":821
 *                 raise GraphicException(
 *                         'Invalid ellipse value: {0!r}'.format(args))
 *             if len(args) not in (4, 6, 7):             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 4, 6 or 7.'.format(len(args)))
 */
  __pyx_t_6 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 821; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_t_2 = ((int)(__pyx_t_6 != 4));
  if (__pyx_t_2) {
    __pyx_t_7 = ((int)(__pyx_t_6 != 6));
    __pyx_t_8 = __pyx_t_7;
  } else {
    __pyx_t_8 = __pyx_t_2;
  }
  if (__pyx_t_8) {
    __pyx_t_2 = ((int)(__pyx_t_6 != 7));
    __pyx_t_7 = __pyx_t_2;
  } else {
    __pyx_t_7 = __pyx_t_8;
  }
  __pyx_t_8 = __pyx_t_7;
  if (__pyx_t_8) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":822
 *                         'Invalid ellipse value: {0!r}'.format(args))
 *             if len(args) not in (4, 6, 7):
 *                 raise GraphicException('Invalid number of arguments: '             # <<<<<<<<<<<<<<
 *                         '{0} instead of 4, 6 or 7.'.format(len(args)))
 *             self._mode_args = tuple(args)
 */
    __pyx_t_5 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":823
 *             if len(args) not in (4, 6, 7):
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 4, 6 or 7.'.format(len(args)))             # <<<<<<<<<<<<<<
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_ELLIPSE
 */
    __pyx_t_4 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_19), __pyx_n_s__format); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_6 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_4, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_5, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":824
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 4, 6 or 7.'.format(len(args)))
 *             self._mode_args = tuple(args)             # <<<<<<<<<<<<<<
 *             self._mode = LINE_MODE_ELLIPSE
 *             self.flag_update()
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_args);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_args);
  __Pyx_GIVEREF(__pyx_v_args);
  __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)(&PyTuple_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_3);
  __Pyx_GOTREF(__pyx_v_self->_mode_args);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_mode_args));
  __pyx_v_self->_mode_args = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":825
 *                         '{0} instead of 4, 6 or 7.'.format(len(args)))
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_ELLIPSE             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_v_self->_mode = 1;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":826
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_ELLIPSE
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     cdef void prebuild_ellipse(self):
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.ellipse.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":828
 *             self.flag_update()
 * 
 *     cdef void prebuild_ellipse(self):             # <<<<<<<<<<<<<<
 *         cdef double x, y, w, h, angle_start = 0, angle_end = 360
 *         cdef int angle_dir, segments = 0
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_prebuild_ellipse(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  double __pyx_v_x;
  double __pyx_v_y;
  double __pyx_v_w;
  double __pyx_v_h;
  double __pyx_v_angle_start;
  double __pyx_v_angle_end;
  int __pyx_v_angle_dir;
  int __pyx_v_segments;
  double __pyx_v_angle_range;
  PyObject *__pyx_v_args = 0;
  PyObject *__pyx_v_points = 0;
  double __pyx_v_angle;
  double __pyx_v_rx;
  double __pyx_v_ry;
  PyObject *__pyx_v_i = NULL;
  __Pyx_RefNannyDeclarations
  Py_ssize_t __pyx_t_1;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *(*__pyx_t_8)(PyObject *);
  double __pyx_t_9;
  double __pyx_t_10;
  double __pyx_t_11;
  double __pyx_t_12;
  PyObject *__pyx_t_13 = NULL;
  PyObject *__pyx_t_14 = NULL;
  double __pyx_t_15;
  double __pyx_t_16;
  PyObject *__pyx_t_17 = NULL;
  int __pyx_t_18;
  long __pyx_t_19;
  PyObject *(*__pyx_t_20)(PyObject *);
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("prebuild_ellipse", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":829
 * 
 *     cdef void prebuild_ellipse(self):
 *         cdef double x, y, w, h, angle_start = 0, angle_end = 360             # <<<<<<<<<<<<<<
 *         cdef int angle_dir, segments = 0
 *         cdef double angle_range
 */
  __pyx_v_angle_start = 0.0;
  __pyx_v_angle_end = 360.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":830
 *     cdef void prebuild_ellipse(self):
 *         cdef double x, y, w, h, angle_start = 0, angle_end = 360
 *         cdef int angle_dir, segments = 0             # <<<<<<<<<<<<<<
 *         cdef double angle_range
 *         cdef tuple args = self._mode_args
 */
  __pyx_v_segments = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":832
 *         cdef int angle_dir, segments = 0
 *         cdef double angle_range
 *         cdef tuple args = self._mode_args             # <<<<<<<<<<<<<<
 * 
 *         if len(args) == 4:
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_mode_args));
  __pyx_v_args = __pyx_v_self->_mode_args;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":834
 *         cdef tuple args = self._mode_args
 * 
 *         if len(args) == 4:             # <<<<<<<<<<<<<<
 *             x, y, w, h = args
 *         elif len(args) == 6:
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 834; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_1 == 4);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":835
 * 
 *         if len(args) == 4:
 *             x, y, w, h = args             # <<<<<<<<<<<<<<
 *         elif len(args) == 6:
 *             x, y, w, h, angle_start, angle_end = args
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 4)) {
        if (PyTuple_GET_SIZE(sequence) > 4) __Pyx_RaiseTooManyValuesError(4);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_3);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_5);
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 3); 
      __Pyx_INCREF(__pyx_t_6);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 4); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      PyObject** temps[4] = {&__pyx_t_3,&__pyx_t_4,&__pyx_t_5,&__pyx_t_6};
      __pyx_t_7 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_7);
      __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext;
      for (index=0; index < 4; index++) {
        PyObject* item = __pyx_t_8(__pyx_t_7); if (unlikely(!item)) goto __pyx_L4_unpacking_failed;
        __Pyx_GOTREF(item);
        *(temps[index]) = item;
      }
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 4) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_8 = NULL;
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      goto __pyx_L5_unpacking_done;
      __pyx_L4_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __pyx_t_8 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L5_unpacking_done:;
    }
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_11 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_11 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_12 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely((__pyx_t_12 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 835; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __pyx_v_x = __pyx_t_9;
    __pyx_v_y = __pyx_t_10;
    __pyx_v_w = __pyx_t_11;
    __pyx_v_h = __pyx_t_12;
    goto __pyx_L3;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":836
 *         if len(args) == 4:
 *             x, y, w, h = args
 *         elif len(args) == 6:             # <<<<<<<<<<<<<<
 *             x, y, w, h, angle_start, angle_end = args
 *         elif len(args) == 7:
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_1 == 6);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":837
 *             x, y, w, h = args
 *         elif len(args) == 6:
 *             x, y, w, h, angle_start, angle_end = args             # <<<<<<<<<<<<<<
 *         elif len(args) == 7:
 *             x, y, w, h, angle_start, angle_end, segments = args
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 6)) {
        if (PyTuple_GET_SIZE(sequence) > 6) __Pyx_RaiseTooManyValuesError(6);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_6);
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_5);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 3); 
      __Pyx_INCREF(__pyx_t_3);
      __pyx_t_7 = PyTuple_GET_ITEM(sequence, 4); 
      __Pyx_INCREF(__pyx_t_7);
      __pyx_t_13 = PyTuple_GET_ITEM(sequence, 5); 
      __Pyx_INCREF(__pyx_t_13);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 6); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      PyObject** temps[6] = {&__pyx_t_6,&__pyx_t_5,&__pyx_t_4,&__pyx_t_3,&__pyx_t_7,&__pyx_t_13};
      __pyx_t_14 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_14);
      __pyx_t_8 = Py_TYPE(__pyx_t_14)->tp_iternext;
      for (index=0; index < 6; index++) {
        PyObject* item = __pyx_t_8(__pyx_t_14); if (unlikely(!item)) goto __pyx_L6_unpacking_failed;
        __Pyx_GOTREF(item);
        *(temps[index]) = item;
      }
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_14), 6) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_8 = NULL;
      __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
      goto __pyx_L7_unpacking_done;
      __pyx_L6_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
      __pyx_t_8 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L7_unpacking_done:;
    }
    __pyx_t_12 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely((__pyx_t_12 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __pyx_t_11 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_11 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_15 = __pyx_PyFloat_AsDouble(__pyx_t_7); if (unlikely((__pyx_t_15 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __pyx_t_16 = __pyx_PyFloat_AsDouble(__pyx_t_13); if (unlikely((__pyx_t_16 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
    __pyx_v_x = __pyx_t_12;
    __pyx_v_y = __pyx_t_11;
    __pyx_v_w = __pyx_t_10;
    __pyx_v_h = __pyx_t_9;
    __pyx_v_angle_start = __pyx_t_15;
    __pyx_v_angle_end = __pyx_t_16;
    goto __pyx_L3;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":838
 *         elif len(args) == 6:
 *             x, y, w, h, angle_start, angle_end = args
 *         elif len(args) == 7:             # <<<<<<<<<<<<<<
 *             x, y, w, h, angle_start, angle_end, segments = args
 *             segments += 2
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_1 == 7);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":839
 *             x, y, w, h, angle_start, angle_end = args
 *         elif len(args) == 7:
 *             x, y, w, h, angle_start, angle_end, segments = args             # <<<<<<<<<<<<<<
 *             segments += 2
 *         else:
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 7)) {
        if (PyTuple_GET_SIZE(sequence) > 7) __Pyx_RaiseTooManyValuesError(7);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_13 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_13);
      __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_7);
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_3);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 3); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 4); 
      __Pyx_INCREF(__pyx_t_5);
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 5); 
      __Pyx_INCREF(__pyx_t_6);
      __pyx_t_14 = PyTuple_GET_ITEM(sequence, 6); 
      __Pyx_INCREF(__pyx_t_14);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 7); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      PyObject** temps[7] = {&__pyx_t_13,&__pyx_t_7,&__pyx_t_3,&__pyx_t_4,&__pyx_t_5,&__pyx_t_6,&__pyx_t_14};
      __pyx_t_17 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_17)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_17);
      __pyx_t_8 = Py_TYPE(__pyx_t_17)->tp_iternext;
      for (index=0; index < 7; index++) {
        PyObject* item = __pyx_t_8(__pyx_t_17); if (unlikely(!item)) goto __pyx_L8_unpacking_failed;
        __Pyx_GOTREF(item);
        *(temps[index]) = item;
      }
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_17), 7) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_8 = NULL;
      __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
      goto __pyx_L9_unpacking_done;
      __pyx_L8_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
      __pyx_t_8 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L9_unpacking_done:;
    }
    __pyx_t_16 = __pyx_PyFloat_AsDouble(__pyx_t_13); if (unlikely((__pyx_t_16 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
    __pyx_t_15 = __pyx_PyFloat_AsDouble(__pyx_t_7); if (unlikely((__pyx_t_15 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_11 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_11 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_12 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely((__pyx_t_12 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __pyx_t_18 = __Pyx_PyInt_AsInt(__pyx_t_14); if (unlikely((__pyx_t_18 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
    __pyx_v_x = __pyx_t_16;
    __pyx_v_y = __pyx_t_15;
    __pyx_v_w = __pyx_t_9;
    __pyx_v_h = __pyx_t_10;
    __pyx_v_angle_start = __pyx_t_11;
    __pyx_v_angle_end = __pyx_t_12;
    __pyx_v_segments = __pyx_t_18;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":840
 *         elif len(args) == 7:
 *             x, y, w, h, angle_start, angle_end, segments = args
 *             segments += 2             # <<<<<<<<<<<<<<
 *         else:
 *             assert(0)
 */
    __pyx_v_segments = (__pyx_v_segments + 2);
    goto __pyx_L3;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":842
 *             segments += 2
 *         else:
 *             assert(0)             # <<<<<<<<<<<<<<
 * 
 *         if angle_end > angle_start:
 */
    #ifndef CYTHON_WITHOUT_ASSERTIONS
    if (unlikely(!0)) {
      PyErr_SetNone(PyExc_AssertionError);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 842; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    #endif
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":844
 *             assert(0)
 * 
 *         if angle_end > angle_start:             # <<<<<<<<<<<<<<
 *             angle_dir = 1
 *         else:
 */
  __pyx_t_2 = (__pyx_v_angle_end > __pyx_v_angle_start);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":845
 * 
 *         if angle_end > angle_start:
 *             angle_dir = 1             # <<<<<<<<<<<<<<
 *         else:
 *             angle_dir = -1
 */
    __pyx_v_angle_dir = 1;
    goto __pyx_L10;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":847
 *             angle_dir = 1
 *         else:
 *             angle_dir = -1             # <<<<<<<<<<<<<<
 *         if segments == 0:
 *             segments = int(abs(angle_end - angle_start) / 2) + 3
 */
    __pyx_v_angle_dir = -1;
  }
  __pyx_L10:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":848
 *         else:
 *             angle_dir = -1
 *         if segments == 0:             # <<<<<<<<<<<<<<
 *             segments = int(abs(angle_end - angle_start) / 2) + 3
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 */
  __pyx_t_2 = (__pyx_v_segments == 0);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":849
 *             angle_dir = -1
 *         if segments == 0:
 *             segments = int(abs(angle_end - angle_start) / 2) + 3             # <<<<<<<<<<<<<<
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = angle_start * 0.017453292519943295
 */
    __pyx_t_14 = PyFloat_FromDouble((fabs((__pyx_v_angle_end - __pyx_v_angle_start)) / 2.0)); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_14);
    __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_14);
    __Pyx_GIVEREF(__pyx_t_14);
    __pyx_t_14 = 0;
    __pyx_t_14 = PyObject_Call(((PyObject *)((PyObject*)(&PyInt_Type))), ((PyObject *)__pyx_t_6), NULL); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_14);
    __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
    __pyx_t_6 = PyNumber_Add(__pyx_t_14, __pyx_int_3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
    __pyx_t_18 = __Pyx_PyInt_AsInt(__pyx_t_6); if (unlikely((__pyx_t_18 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __pyx_v_segments = __pyx_t_18;
    goto __pyx_L11;
  }
  __pyx_L11:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":851
 *             segments = int(abs(angle_end - angle_start) / 2) + 3
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = angle_start * 0.017453292519943295             # <<<<<<<<<<<<<<
 *         angle_end = angle_end * 0.017453292519943295
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)
 */
  __pyx_v_angle_start = (__pyx_v_angle_start * 0.017453292519943295);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":852
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = angle_start * 0.017453292519943295
 *         angle_end = angle_end * 0.017453292519943295             # <<<<<<<<<<<<<<
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)
 * 
 */
  __pyx_v_angle_end = (__pyx_v_angle_end * 0.017453292519943295);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":853
 *         angle_start = angle_start * 0.017453292519943295
 *         angle_end = angle_end * 0.017453292519943295
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)             # <<<<<<<<<<<<<<
 * 
 *         cdef list points = [0, 0] * segments
 */
  __pyx_t_12 = fabs((__pyx_v_angle_end - __pyx_v_angle_start));
  __pyx_t_19 = (__pyx_v_segments - 2);
  if (unlikely(__pyx_t_19 == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_v_angle_range = (__pyx_t_12 / __pyx_t_19);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":855
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)
 * 
 *         cdef list points = [0, 0] * segments             # <<<<<<<<<<<<<<
 *         cdef double angle
 *         cdef double rx = w * 0.5
 */
  __pyx_t_6 = PyList_New(2 * ((__pyx_v_segments<0) ? 0:__pyx_v_segments)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_6);
  { Py_ssize_t __pyx_temp;
    for (__pyx_temp=0; __pyx_temp < __pyx_v_segments; __pyx_temp++) {
      __Pyx_INCREF(__pyx_int_0);
      PyList_SET_ITEM(__pyx_t_6, __pyx_temp * 2, __pyx_int_0);
      __Pyx_GIVEREF(__pyx_int_0);
      __Pyx_INCREF(__pyx_int_0);
      PyList_SET_ITEM(__pyx_t_6, __pyx_temp * 2 + 1, __pyx_int_0);
      __Pyx_GIVEREF(__pyx_int_0);
    }
  }
  __pyx_v_points = __pyx_t_6;
  __pyx_t_6 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":857
 *         cdef list points = [0, 0] * segments
 *         cdef double angle
 *         cdef double rx = w * 0.5             # <<<<<<<<<<<<<<
 *         cdef double ry = h * 0.5
 *         for i in xrange(0, segments * 2, 2):
 */
  __pyx_v_rx = (__pyx_v_w * 0.5);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":858
 *         cdef double angle
 *         cdef double rx = w * 0.5
 *         cdef double ry = h * 0.5             # <<<<<<<<<<<<<<
 *         for i in xrange(0, segments * 2, 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 */
  __pyx_v_ry = (__pyx_v_h * 0.5);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":859
 *         cdef double rx = w * 0.5
 *         cdef double ry = h * 0.5
 *         for i in xrange(0, segments * 2, 2):             # <<<<<<<<<<<<<<
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             points[i] = (x + rx) + (rx * sin(angle))
 */
  __pyx_t_6 = PyInt_FromLong((__pyx_v_segments * 2)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_6);
  __pyx_t_14 = PyTuple_New(3); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_14);
  __Pyx_INCREF(__pyx_int_0);
  PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_int_0);
  __Pyx_GIVEREF(__pyx_int_0);
  PyTuple_SET_ITEM(__pyx_t_14, 1, __pyx_t_6);
  __Pyx_GIVEREF(__pyx_t_6);
  __Pyx_INCREF(__pyx_int_2);
  PyTuple_SET_ITEM(__pyx_t_14, 2, __pyx_int_2);
  __Pyx_GIVEREF(__pyx_int_2);
  __pyx_t_6 = 0;
  __pyx_t_6 = PyObject_Call(__pyx_builtin_xrange, ((PyObject *)__pyx_t_14), NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_6);
  __Pyx_DECREF(((PyObject *)__pyx_t_14)); __pyx_t_14 = 0;
  if (PyList_CheckExact(__pyx_t_6) || PyTuple_CheckExact(__pyx_t_6)) {
    __pyx_t_14 = __pyx_t_6; __Pyx_INCREF(__pyx_t_14); __pyx_t_1 = 0;
    __pyx_t_20 = NULL;
  } else {
    __pyx_t_1 = -1; __pyx_t_14 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_14);
    __pyx_t_20 = Py_TYPE(__pyx_t_14)->tp_iternext;
  }
  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  for (;;) {
    if (!__pyx_t_20 && PyList_CheckExact(__pyx_t_14)) {
      if (__pyx_t_1 >= PyList_GET_SIZE(__pyx_t_14)) break;
      __pyx_t_6 = PyList_GET_ITEM(__pyx_t_14, __pyx_t_1); __Pyx_INCREF(__pyx_t_6); __pyx_t_1++;
    } else if (!__pyx_t_20 && PyTuple_CheckExact(__pyx_t_14)) {
      if (__pyx_t_1 >= PyTuple_GET_SIZE(__pyx_t_14)) break;
      __pyx_t_6 = PyTuple_GET_ITEM(__pyx_t_14, __pyx_t_1); __Pyx_INCREF(__pyx_t_6); __pyx_t_1++;
    } else {
      __pyx_t_6 = __pyx_t_20(__pyx_t_14);
      if (unlikely(!__pyx_t_6)) {
        if (PyErr_Occurred()) {
          if (likely(PyErr_ExceptionMatches(PyExc_StopIteration))) PyErr_Clear();
          else {__pyx_filename = __pyx_f[1]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        break;
      }
      __Pyx_GOTREF(__pyx_t_6);
    }
    __Pyx_XDECREF(__pyx_v_i);
    __pyx_v_i = __pyx_t_6;
    __pyx_t_6 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":860
 *         cdef double ry = h * 0.5
 *         for i in xrange(0, segments * 2, 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)             # <<<<<<<<<<<<<<
 *             points[i] = (x + rx) + (rx * sin(angle))
 *             points[i + 1] = (y + ry) + (ry * cos(angle))
 */
    __pyx_t_6 = PyFloat_FromDouble(__pyx_v_angle_start); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_5 = PyInt_FromLong(__pyx_v_angle_dir); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_4 = PyNumber_Subtract(__pyx_v_i, __pyx_int_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_3 = PyNumber_Multiply(__pyx_t_5, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_4 = PyFloat_FromDouble(__pyx_v_angle_range); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_5 = PyNumber_Multiply(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_4 = PyNumber_Add(__pyx_t_6, __pyx_t_5); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_12 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_12 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_v_angle = __pyx_t_12;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":861
 *         for i in xrange(0, segments * 2, 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             points[i] = (x + rx) + (rx * sin(angle))             # <<<<<<<<<<<<<<
 *             points[i + 1] = (y + ry) + (ry * cos(angle))
 * 
 */
    __pyx_t_4 = PyFloat_FromDouble(((__pyx_v_x + __pyx_v_rx) + (__pyx_v_rx * sin(__pyx_v_angle)))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 861; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    if (PyObject_SetItem(((PyObject *)__pyx_v_points), __pyx_v_i, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 861; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":862
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             points[i] = (x + rx) + (rx * sin(angle))
 *             points[i + 1] = (y + ry) + (ry * cos(angle))             # <<<<<<<<<<<<<<
 * 
 *         self._points = points
 */
    __pyx_t_4 = PyFloat_FromDouble(((__pyx_v_y + __pyx_v_ry) + (__pyx_v_ry * cos(__pyx_v_angle)))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 862; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_5 = PyNumber_Add(__pyx_v_i, __pyx_int_1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 862; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    if (PyObject_SetItem(((PyObject *)__pyx_v_points), __pyx_t_5, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 862; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  }
  __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":864
 *             points[i + 1] = (y + ry) + (ry * cos(angle))
 * 
 *         self._points = points             # <<<<<<<<<<<<<<
 * 
 * 
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_points));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_points));
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = __pyx_v_points;

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_13);
  __Pyx_XDECREF(__pyx_t_14);
  __Pyx_XDECREF(__pyx_t_17);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.prebuild_ellipse", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_args);
  __Pyx_XDECREF(__pyx_v_points);
  __Pyx_XDECREF(__pyx_v_i);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6circle_1__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_args); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6circle_1__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_args) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6circle___set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_args));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":897
 *         '''
 * 
 *         def __set__(self, args):             # <<<<<<<<<<<<<<
 *             if args == None:
 *                 raise GraphicException(
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_6circle___set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_args) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  Py_ssize_t __pyx_t_6;
  int __pyx_t_7;
  int __pyx_t_8;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":898
 * 
 *         def __set__(self, args):
 *             if args == None:             # <<<<<<<<<<<<<<
 *                 raise GraphicException(
 *                         'Invalid circle value: {0!r}'.format(args))
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_args, Py_None, Py_EQ); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":899
 *         def __set__(self, args):
 *             if args == None:
 *                 raise GraphicException(             # <<<<<<<<<<<<<<
 *                         'Invalid circle value: {0!r}'.format(args))
 *             if len(args) not in (3, 5, 6):
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":900
 *             if args == None:
 *                 raise GraphicException(
 *                         'Invalid circle value: {0!r}'.format(args))             # <<<<<<<<<<<<<<
 *             if len(args) not in (3, 5, 6):
 *                 raise GraphicException('Invalid number of arguments: '
 */
    __pyx_t_3 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_20), __pyx_n_s__format); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_INCREF(__pyx_v_args);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_args);
    __Pyx_GIVEREF(__pyx_v_args);
    __pyx_t_5 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_5);
    __Pyx_GIVEREF(__pyx_t_5);
    __pyx_t_5 = 0;
    __pyx_t_5 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":901
 *                 raise GraphicException(
 *                         'Invalid circle value: {0!r}'.format(args))
 *             if len(args) not in (3, 5, 6):             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 3, 5 or 6.'.format(len(args)))
 */
  __pyx_t_6 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_t_2 = ((int)(__pyx_t_6 != 3));
  if (__pyx_t_2) {
    __pyx_t_7 = ((int)(__pyx_t_6 != 5));
    __pyx_t_8 = __pyx_t_7;
  } else {
    __pyx_t_8 = __pyx_t_2;
  }
  if (__pyx_t_8) {
    __pyx_t_2 = ((int)(__pyx_t_6 != 6));
    __pyx_t_7 = __pyx_t_2;
  } else {
    __pyx_t_7 = __pyx_t_8;
  }
  __pyx_t_8 = __pyx_t_7;
  if (__pyx_t_8) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":902
 *                         'Invalid circle value: {0!r}'.format(args))
 *             if len(args) not in (3, 5, 6):
 *                 raise GraphicException('Invalid number of arguments: '             # <<<<<<<<<<<<<<
 *                         '{0} instead of 3, 5 or 6.'.format(len(args)))
 *             self._mode_args = tuple(args)
 */
    __pyx_t_5 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":903
 *             if len(args) not in (3, 5, 6):
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 3, 5 or 6.'.format(len(args)))             # <<<<<<<<<<<<<<
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_CIRCLE
 */
    __pyx_t_4 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_21), __pyx_n_s__format); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_6 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_4, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_5, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":904
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 3, 5 or 6.'.format(len(args)))
 *             self._mode_args = tuple(args)             # <<<<<<<<<<<<<<
 *             self._mode = LINE_MODE_CIRCLE
 *             self.flag_update()
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_args);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_args);
  __Pyx_GIVEREF(__pyx_v_args);
  __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)(&PyTuple_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_3);
  __Pyx_GOTREF(__pyx_v_self->_mode_args);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_mode_args));
  __pyx_v_self->_mode_args = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":905
 *                         '{0} instead of 3, 5 or 6.'.format(len(args)))
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_CIRCLE             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_v_self->_mode = 2;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":906
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_CIRCLE
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     cdef void prebuild_circle(self):
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.circle.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":908
 *             self.flag_update()
 * 
 *     cdef void prebuild_circle(self):             # <<<<<<<<<<<<<<
 *         cdef double x, y, r, angle_start = 0, angle_end = 360
 *         cdef int angle_dir, segments = 0
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_prebuild_circle(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  double __pyx_v_x;
  double __pyx_v_y;
  double __pyx_v_r;
  double __pyx_v_angle_start;
  double __pyx_v_angle_end;
  int __pyx_v_angle_dir;
  int __pyx_v_segments;
  double __pyx_v_angle_range;
  PyObject *__pyx_v_args = 0;
  PyObject *__pyx_v_points = 0;
  double __pyx_v_angle;
  PyObject *__pyx_v_i = NULL;
  __Pyx_RefNannyDeclarations
  Py_ssize_t __pyx_t_1;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  PyObject *(*__pyx_t_7)(PyObject *);
  double __pyx_t_8;
  double __pyx_t_9;
  double __pyx_t_10;
  PyObject *__pyx_t_11 = NULL;
  PyObject *__pyx_t_12 = NULL;
  double __pyx_t_13;
  double __pyx_t_14;
  PyObject *__pyx_t_15 = NULL;
  int __pyx_t_16;
  long __pyx_t_17;
  PyObject *(*__pyx_t_18)(PyObject *);
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("prebuild_circle", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":909
 * 
 *     cdef void prebuild_circle(self):
 *         cdef double x, y, r, angle_start = 0, angle_end = 360             # <<<<<<<<<<<<<<
 *         cdef int angle_dir, segments = 0
 *         cdef double angle_range
 */
  __pyx_v_angle_start = 0.0;
  __pyx_v_angle_end = 360.0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":910
 *     cdef void prebuild_circle(self):
 *         cdef double x, y, r, angle_start = 0, angle_end = 360
 *         cdef int angle_dir, segments = 0             # <<<<<<<<<<<<<<
 *         cdef double angle_range
 *         cdef tuple args = self._mode_args
 */
  __pyx_v_segments = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":912
 *         cdef int angle_dir, segments = 0
 *         cdef double angle_range
 *         cdef tuple args = self._mode_args             # <<<<<<<<<<<<<<
 * 
 *         if len(args) == 3:
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_mode_args));
  __pyx_v_args = __pyx_v_self->_mode_args;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":914
 *         cdef tuple args = self._mode_args
 * 
 *         if len(args) == 3:             # <<<<<<<<<<<<<<
 *             x, y, r = args
 *         elif len(args) == 5:
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_1 == 3);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":915
 * 
 *         if len(args) == 3:
 *             x, y, r = args             # <<<<<<<<<<<<<<
 *         elif len(args) == 5:
 *             x, y, r, angle_start, angle_end = args
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 3)) {
        if (PyTuple_GET_SIZE(sequence) > 3) __Pyx_RaiseTooManyValuesError(3);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_3);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_5);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 3); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      __pyx_t_6 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_6);
      __pyx_t_7 = Py_TYPE(__pyx_t_6)->tp_iternext;
      index = 0; __pyx_t_3 = __pyx_t_7(__pyx_t_6); if (unlikely(!__pyx_t_3)) goto __pyx_L4_unpacking_failed;
      __Pyx_GOTREF(__pyx_t_3);
      index = 1; __pyx_t_4 = __pyx_t_7(__pyx_t_6); if (unlikely(!__pyx_t_4)) goto __pyx_L4_unpacking_failed;
      __Pyx_GOTREF(__pyx_t_4);
      index = 2; __pyx_t_5 = __pyx_t_7(__pyx_t_6); if (unlikely(!__pyx_t_5)) goto __pyx_L4_unpacking_failed;
      __Pyx_GOTREF(__pyx_t_5);
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_6), 3) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_7 = NULL;
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      goto __pyx_L5_unpacking_done;
      __pyx_L4_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      __pyx_t_7 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L5_unpacking_done:;
    }
    __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_8 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_v_x = __pyx_t_8;
    __pyx_v_y = __pyx_t_9;
    __pyx_v_r = __pyx_t_10;
    goto __pyx_L3;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":916
 *         if len(args) == 3:
 *             x, y, r = args
 *         elif len(args) == 5:             # <<<<<<<<<<<<<<
 *             x, y, r, angle_start, angle_end = args
 *         elif len(args) == 6:
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 916; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_1 == 5);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":917
 *             x, y, r = args
 *         elif len(args) == 5:
 *             x, y, r, angle_start, angle_end = args             # <<<<<<<<<<<<<<
 *         elif len(args) == 6:
 *             x, y, r, angle_start, angle_end, segments = args
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 5)) {
        if (PyTuple_GET_SIZE(sequence) > 5) __Pyx_RaiseTooManyValuesError(5);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_5);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_3);
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 3); 
      __Pyx_INCREF(__pyx_t_6);
      __pyx_t_11 = PyTuple_GET_ITEM(sequence, 4); 
      __Pyx_INCREF(__pyx_t_11);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 5); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      PyObject** temps[5] = {&__pyx_t_5,&__pyx_t_4,&__pyx_t_3,&__pyx_t_6,&__pyx_t_11};
      __pyx_t_12 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_12);
      __pyx_t_7 = Py_TYPE(__pyx_t_12)->tp_iternext;
      for (index=0; index < 5; index++) {
        PyObject* item = __pyx_t_7(__pyx_t_12); if (unlikely(!item)) goto __pyx_L6_unpacking_failed;
        __Pyx_GOTREF(item);
        *(temps[index]) = item;
      }
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_12), 5) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_7 = NULL;
      __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
      goto __pyx_L7_unpacking_done;
      __pyx_L6_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
      __pyx_t_7 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L7_unpacking_done:;
    }
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_8 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_13 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely((__pyx_t_13 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __pyx_t_14 = __pyx_PyFloat_AsDouble(__pyx_t_11); if (unlikely((__pyx_t_14 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
    __pyx_v_x = __pyx_t_10;
    __pyx_v_y = __pyx_t_9;
    __pyx_v_r = __pyx_t_8;
    __pyx_v_angle_start = __pyx_t_13;
    __pyx_v_angle_end = __pyx_t_14;
    goto __pyx_L3;
  }

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":918
 *         elif len(args) == 5:
 *             x, y, r, angle_start, angle_end = args
 *         elif len(args) == 6:             # <<<<<<<<<<<<<<
 *             x, y, r, angle_start, angle_end, segments = args
 *             segments += 2
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_1 == 6);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":919
 *             x, y, r, angle_start, angle_end = args
 *         elif len(args) == 6:
 *             x, y, r, angle_start, angle_end, segments = args             # <<<<<<<<<<<<<<
 *             segments += 2
 *         else:
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 6)) {
        if (PyTuple_GET_SIZE(sequence) > 6) __Pyx_RaiseTooManyValuesError(6);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_11 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_11);
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_6);
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_3);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 3); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 4); 
      __Pyx_INCREF(__pyx_t_5);
      __pyx_t_12 = PyTuple_GET_ITEM(sequence, 5); 
      __Pyx_INCREF(__pyx_t_12);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 6); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      PyObject** temps[6] = {&__pyx_t_11,&__pyx_t_6,&__pyx_t_3,&__pyx_t_4,&__pyx_t_5,&__pyx_t_12};
      __pyx_t_15 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_15);
      __pyx_t_7 = Py_TYPE(__pyx_t_15)->tp_iternext;
      for (index=0; index < 6; index++) {
        PyObject* item = __pyx_t_7(__pyx_t_15); if (unlikely(!item)) goto __pyx_L8_unpacking_failed;
        __Pyx_GOTREF(item);
        *(temps[index]) = item;
      }
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_15), 6) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_7 = NULL;
      __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
      goto __pyx_L9_unpacking_done;
      __pyx_L8_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
      __pyx_t_7 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L9_unpacking_done:;
    }
    __pyx_t_14 = __pyx_PyFloat_AsDouble(__pyx_t_11); if (unlikely((__pyx_t_14 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
    __pyx_t_13 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely((__pyx_t_13 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_8 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_16 = __Pyx_PyInt_AsInt(__pyx_t_12); if (unlikely((__pyx_t_16 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
    __pyx_v_x = __pyx_t_14;
    __pyx_v_y = __pyx_t_13;
    __pyx_v_r = __pyx_t_8;
    __pyx_v_angle_start = __pyx_t_9;
    __pyx_v_angle_end = __pyx_t_10;
    __pyx_v_segments = __pyx_t_16;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":920
 *         elif len(args) == 6:
 *             x, y, r, angle_start, angle_end, segments = args
 *             segments += 2             # <<<<<<<<<<<<<<
 *         else:
 *             assert(0)
 */
    __pyx_v_segments = (__pyx_v_segments + 2);
    goto __pyx_L3;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":922
 *             segments += 2
 *         else:
 *             assert(0)             # <<<<<<<<<<<<<<
 * 
 *         if angle_end > angle_start:
 */
    #ifndef CYTHON_WITHOUT_ASSERTIONS
    if (unlikely(!0)) {
      PyErr_SetNone(PyExc_AssertionError);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    #endif
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":924
 *             assert(0)
 * 
 *         if angle_end > angle_start:             # <<<<<<<<<<<<<<
 *             angle_dir = 1
 *         else:
 */
  __pyx_t_2 = (__pyx_v_angle_end > __pyx_v_angle_start);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":925
 * 
 *         if angle_end > angle_start:
 *             angle_dir = 1             # <<<<<<<<<<<<<<
 *         else:
 *             angle_dir = -1
 */
    __pyx_v_angle_dir = 1;
    goto __pyx_L10;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":927
 *             angle_dir = 1
 *         else:
 *             angle_dir = -1             # <<<<<<<<<<<<<<
 *         if segments == 0:
 *             segments = int(abs(angle_end - angle_start) / 2) + 3
 */
    __pyx_v_angle_dir = -1;
  }
  __pyx_L10:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":928
 *         else:
 *             angle_dir = -1
 *         if segments == 0:             # <<<<<<<<<<<<<<
 *             segments = int(abs(angle_end - angle_start) / 2) + 3
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 */
  __pyx_t_2 = (__pyx_v_segments == 0);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":929
 *             angle_dir = -1
 *         if segments == 0:
 *             segments = int(abs(angle_end - angle_start) / 2) + 3             # <<<<<<<<<<<<<<
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = angle_start * 0.017453292519943295
 */
    __pyx_t_12 = PyFloat_FromDouble((fabs((__pyx_v_angle_end - __pyx_v_angle_start)) / 2.0)); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 929; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_12);
    __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 929; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_12);
    __Pyx_GIVEREF(__pyx_t_12);
    __pyx_t_12 = 0;
    __pyx_t_12 = PyObject_Call(((PyObject *)((PyObject*)(&PyInt_Type))), ((PyObject *)__pyx_t_5), NULL); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 929; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_12);
    __Pyx_DECREF(((PyObject *)__pyx_t_5)); __pyx_t_5 = 0;
    __pyx_t_5 = PyNumber_Add(__pyx_t_12, __pyx_int_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 929; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
    __pyx_t_16 = __Pyx_PyInt_AsInt(__pyx_t_5); if (unlikely((__pyx_t_16 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 929; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_v_segments = __pyx_t_16;
    goto __pyx_L11;
  }
  __pyx_L11:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":931
 *             segments = int(abs(angle_end - angle_start) / 2) + 3
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = angle_start * 0.017453292519943295             # <<<<<<<<<<<<<<
 *         angle_end = angle_end * 0.017453292519943295
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)
 */
  __pyx_v_angle_start = (__pyx_v_angle_start * 0.017453292519943295);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":932
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = angle_start * 0.017453292519943295
 *         angle_end = angle_end * 0.017453292519943295             # <<<<<<<<<<<<<<
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)
 * 
 */
  __pyx_v_angle_end = (__pyx_v_angle_end * 0.017453292519943295);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":933
 *         angle_start = angle_start * 0.017453292519943295
 *         angle_end = angle_end * 0.017453292519943295
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)             # <<<<<<<<<<<<<<
 * 
 *         cdef list points = [0, 0] * segments
 */
  __pyx_t_10 = fabs((__pyx_v_angle_end - __pyx_v_angle_start));
  __pyx_t_17 = (__pyx_v_segments - 2);
  if (unlikely(__pyx_t_17 == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 933; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_v_angle_range = (__pyx_t_10 / __pyx_t_17);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":935
 *         angle_range = abs(angle_end - angle_start) / (segments - 2)
 * 
 *         cdef list points = [0, 0] * segments             # <<<<<<<<<<<<<<
 *         cdef double angle
 *         for i in xrange(0, segments * 2, 2):
 */
  __pyx_t_5 = PyList_New(2 * ((__pyx_v_segments<0) ? 0:__pyx_v_segments)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 935; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_5);
  { Py_ssize_t __pyx_temp;
    for (__pyx_temp=0; __pyx_temp < __pyx_v_segments; __pyx_temp++) {
      __Pyx_INCREF(__pyx_int_0);
      PyList_SET_ITEM(__pyx_t_5, __pyx_temp * 2, __pyx_int_0);
      __Pyx_GIVEREF(__pyx_int_0);
      __Pyx_INCREF(__pyx_int_0);
      PyList_SET_ITEM(__pyx_t_5, __pyx_temp * 2 + 1, __pyx_int_0);
      __Pyx_GIVEREF(__pyx_int_0);
    }
  }
  __pyx_v_points = __pyx_t_5;
  __pyx_t_5 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":937
 *         cdef list points = [0, 0] * segments
 *         cdef double angle
 *         for i in xrange(0, segments * 2, 2):             # <<<<<<<<<<<<<<
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             points[i] = x + (r * sin(angle))
 */
  __pyx_t_5 = PyInt_FromLong((__pyx_v_segments * 2)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_5);
  __pyx_t_12 = PyTuple_New(3); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_12);
  __Pyx_INCREF(__pyx_int_0);
  PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_int_0);
  __Pyx_GIVEREF(__pyx_int_0);
  PyTuple_SET_ITEM(__pyx_t_12, 1, __pyx_t_5);
  __Pyx_GIVEREF(__pyx_t_5);
  __Pyx_INCREF(__pyx_int_2);
  PyTuple_SET_ITEM(__pyx_t_12, 2, __pyx_int_2);
  __Pyx_GIVEREF(__pyx_int_2);
  __pyx_t_5 = 0;
  __pyx_t_5 = PyObject_Call(__pyx_builtin_xrange, ((PyObject *)__pyx_t_12), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_5);
  __Pyx_DECREF(((PyObject *)__pyx_t_12)); __pyx_t_12 = 0;
  if (PyList_CheckExact(__pyx_t_5) || PyTuple_CheckExact(__pyx_t_5)) {
    __pyx_t_12 = __pyx_t_5; __Pyx_INCREF(__pyx_t_12); __pyx_t_1 = 0;
    __pyx_t_18 = NULL;
  } else {
    __pyx_t_1 = -1; __pyx_t_12 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_12);
    __pyx_t_18 = Py_TYPE(__pyx_t_12)->tp_iternext;
  }
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  for (;;) {
    if (!__pyx_t_18 && PyList_CheckExact(__pyx_t_12)) {
      if (__pyx_t_1 >= PyList_GET_SIZE(__pyx_t_12)) break;
      __pyx_t_5 = PyList_GET_ITEM(__pyx_t_12, __pyx_t_1); __Pyx_INCREF(__pyx_t_5); __pyx_t_1++;
    } else if (!__pyx_t_18 && PyTuple_CheckExact(__pyx_t_12)) {
      if (__pyx_t_1 >= PyTuple_GET_SIZE(__pyx_t_12)) break;
      __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_12, __pyx_t_1); __Pyx_INCREF(__pyx_t_5); __pyx_t_1++;
    } else {
      __pyx_t_5 = __pyx_t_18(__pyx_t_12);
      if (unlikely(!__pyx_t_5)) {
        if (PyErr_Occurred()) {
          if (likely(PyErr_ExceptionMatches(PyExc_StopIteration))) PyErr_Clear();
          else {__pyx_filename = __pyx_f[1]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        break;
      }
      __Pyx_GOTREF(__pyx_t_5);
    }
    __Pyx_XDECREF(__pyx_v_i);
    __pyx_v_i = __pyx_t_5;
    __pyx_t_5 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":938
 *         cdef double angle
 *         for i in xrange(0, segments * 2, 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)             # <<<<<<<<<<<<<<
 *             points[i] = x + (r * sin(angle))
 *             points[i + 1] = y + (r * cos(angle))
 */
    __pyx_t_5 = PyFloat_FromDouble(__pyx_v_angle_start); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __pyx_t_4 = PyInt_FromLong(__pyx_v_angle_dir); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_3 = PyNumber_Subtract(__pyx_v_i, __pyx_int_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_6 = PyNumber_Multiply(__pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_3 = PyFloat_FromDouble(__pyx_v_angle_range); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyNumber_Multiply(__pyx_t_6, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_3 = PyNumber_Add(__pyx_t_5, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_v_angle = __pyx_t_10;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":939
 *         for i in xrange(0, segments * 2, 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             points[i] = x + (r * sin(angle))             # <<<<<<<<<<<<<<
 *             points[i + 1] = y + (r * cos(angle))
 *         self._points = points
 */
    __pyx_t_3 = PyFloat_FromDouble((__pyx_v_x + (__pyx_v_r * sin(__pyx_v_angle)))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 939; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    if (PyObject_SetItem(((PyObject *)__pyx_v_points), __pyx_v_i, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 939; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":940
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             points[i] = x + (r * sin(angle))
 *             points[i + 1] = y + (r * cos(angle))             # <<<<<<<<<<<<<<
 *         self._points = points
 * 
 */
    __pyx_t_3 = PyFloat_FromDouble((__pyx_v_y + (__pyx_v_r * cos(__pyx_v_angle)))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 940; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyNumber_Add(__pyx_v_i, __pyx_int_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 940; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    if (PyObject_SetItem(((PyObject *)__pyx_v_points), __pyx_t_4, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 940; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  }
  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":941
 *             points[i] = x + (r * sin(angle))
 *             points[i + 1] = y + (r * cos(angle))
 *         self._points = points             # <<<<<<<<<<<<<<
 * 
 *     property rectangle:
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_points));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_points));
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = __pyx_v_points;

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_11);
  __Pyx_XDECREF(__pyx_t_12);
  __Pyx_XDECREF(__pyx_t_15);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.prebuild_circle", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_args);
  __Pyx_XDECREF(__pyx_v_points);
  __Pyx_XDECREF(__pyx_v_i);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_9rectangle_1__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_args); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_9rectangle_1__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_args) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_9rectangle___set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self), ((PyObject *)__pyx_v_args));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":962
 *         '''
 * 
 *         def __set__(self, args):             # <<<<<<<<<<<<<<
 *             if args == None:
 *                 raise GraphicException(
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Line_9rectangle___set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self, PyObject *__pyx_v_args) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  Py_ssize_t __pyx_t_6;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":963
 * 
 *         def __set__(self, args):
 *             if args == None:             # <<<<<<<<<<<<<<
 *                 raise GraphicException(
 *                         'Invalid rectangle value: {0!r}'.format(args))
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_args, Py_None, Py_EQ); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":964
 *         def __set__(self, args):
 *             if args == None:
 *                 raise GraphicException(             # <<<<<<<<<<<<<<
 *                         'Invalid rectangle value: {0!r}'.format(args))
 *             if len(args) != 4:
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 964; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":965
 *             if args == None:
 *                 raise GraphicException(
 *                         'Invalid rectangle value: {0!r}'.format(args))             # <<<<<<<<<<<<<<
 *             if len(args) != 4:
 *                 raise GraphicException('Invalid number of arguments: '
 */
    __pyx_t_3 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_22), __pyx_n_s__format); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_INCREF(__pyx_v_args);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_args);
    __Pyx_GIVEREF(__pyx_v_args);
    __pyx_t_5 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 964; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_5);
    __Pyx_GIVEREF(__pyx_t_5);
    __pyx_t_5 = 0;
    __pyx_t_5 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 964; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 964; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":966
 *                 raise GraphicException(
 *                         'Invalid rectangle value: {0!r}'.format(args))
 *             if len(args) != 4:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 4.'.format(len(args)))
 */
  __pyx_t_6 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 966; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_t_2 = (__pyx_t_6 != 4);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":967
 *                         'Invalid rectangle value: {0!r}'.format(args))
 *             if len(args) != 4:
 *                 raise GraphicException('Invalid number of arguments: '             # <<<<<<<<<<<<<<
 *                         '{0} instead of 4.'.format(len(args)))
 *             self._mode_args = tuple(args)
 */
    __pyx_t_5 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":968
 *             if len(args) != 4:
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 4.'.format(len(args)))             # <<<<<<<<<<<<<<
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_RECTANGLE
 */
    __pyx_t_4 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_23), __pyx_n_s__format); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_6 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_4, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_5, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":969
 *                 raise GraphicException('Invalid number of arguments: '
 *                         '{0} instead of 4.'.format(len(args)))
 *             self._mode_args = tuple(args)             # <<<<<<<<<<<<<<
 *             self._mode = LINE_MODE_RECTANGLE
 *             self.flag_update()
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 969; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_args);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_args);
  __Pyx_GIVEREF(__pyx_v_args);
  __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)(&PyTuple_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 969; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_3);
  __Pyx_GOTREF(__pyx_v_self->_mode_args);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_mode_args));
  __pyx_v_self->_mode_args = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":970
 *                         '{0} instead of 4.'.format(len(args)))
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_RECTANGLE             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_v_self->_mode = 3;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":971
 *             self._mode_args = tuple(args)
 *             self._mode = LINE_MODE_RECTANGLE
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     cdef void prebuild_rectangle(self):
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Line.rectangle.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":973
 *             self.flag_update()
 * 
 *     cdef void prebuild_rectangle(self):             # <<<<<<<<<<<<<<
 *         cdef double x, y, width, height
 *         cdef int angle_dir, segments = 0
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Line_prebuild_rectangle(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *__pyx_v_self) {
  double __pyx_v_x;
  double __pyx_v_y;
  double __pyx_v_width;
  double __pyx_v_height;
  CYTHON_UNUSED int __pyx_v_segments;
  PyObject *__pyx_v_args = 0;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  Py_ssize_t __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  PyObject *(*__pyx_t_8)(PyObject *);
  double __pyx_t_9;
  double __pyx_t_10;
  double __pyx_t_11;
  double __pyx_t_12;
  PyObject *__pyx_t_13 = NULL;
  PyObject *__pyx_t_14 = NULL;
  PyObject *__pyx_t_15 = NULL;
  PyObject *__pyx_t_16 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("prebuild_rectangle", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":975
 *     cdef void prebuild_rectangle(self):
 *         cdef double x, y, width, height
 *         cdef int angle_dir, segments = 0             # <<<<<<<<<<<<<<
 *         cdef double angle_range
 *         cdef tuple args = self._mode_args
 */
  __pyx_v_segments = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":977
 *         cdef int angle_dir, segments = 0
 *         cdef double angle_range
 *         cdef tuple args = self._mode_args             # <<<<<<<<<<<<<<
 * 
 *         if args == None:
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_mode_args));
  __pyx_v_args = __pyx_v_self->_mode_args;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":979
 *         cdef tuple args = self._mode_args
 * 
 *         if args == None:             # <<<<<<<<<<<<<<
 *             raise GraphicException(
 *                     'Invalid ellipse value: {0!r}'.format(args))
 */
  __pyx_t_1 = PyObject_RichCompare(((PyObject *)__pyx_v_args), Py_None, Py_EQ); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 979; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 979; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":980
 * 
 *         if args == None:
 *             raise GraphicException(             # <<<<<<<<<<<<<<
 *                     'Invalid ellipse value: {0!r}'.format(args))
 * 
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":981
 *         if args == None:
 *             raise GraphicException(
 *                     'Invalid ellipse value: {0!r}'.format(args))             # <<<<<<<<<<<<<<
 * 
 *         if len(args) == 4:
 */
    __pyx_t_3 = PyObject_GetAttr(((PyObject *)__pyx_kp_s_18), __pyx_n_s__format); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_INCREF(((PyObject *)__pyx_v_args));
    PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_args));
    __Pyx_GIVEREF(((PyObject *)__pyx_v_args));
    __pyx_t_5 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_5);
    __Pyx_GIVEREF(__pyx_t_5);
    __pyx_t_5 = 0;
    __pyx_t_5 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":983
 *                     'Invalid ellipse value: {0!r}'.format(args))
 * 
 *         if len(args) == 4:             # <<<<<<<<<<<<<<
 *             x, y, width, height = args
 *         else:
 */
  if (unlikely(((PyObject *)__pyx_v_args) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[1]; __pyx_lineno = 983; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_6 = PyTuple_GET_SIZE(((PyObject *)__pyx_v_args)); 
  __pyx_t_2 = (__pyx_t_6 == 4);
  if (__pyx_t_2) {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":984
 * 
 *         if len(args) == 4:
 *             x, y, width, height = args             # <<<<<<<<<<<<<<
 *         else:
 *             assert(0)
 */
    #if CYTHON_COMPILING_IN_CPYTHON
    if (likely(PyTuple_CheckExact(((PyObject *)__pyx_v_args)))) {
      PyObject* sequence = ((PyObject *)__pyx_v_args);
      if (unlikely(PyTuple_GET_SIZE(sequence) != 4)) {
        if (PyTuple_GET_SIZE(sequence) > 4) __Pyx_RaiseTooManyValuesError(4);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_5);
      __pyx_t_4 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_4);
      __pyx_t_1 = PyTuple_GET_ITEM(sequence, 2); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_3 = PyTuple_GET_ITEM(sequence, 3); 
      __Pyx_INCREF(__pyx_t_3);
    } else
    if (1) {
      __Pyx_UnpackTupleError(((PyObject *)__pyx_v_args), 4); {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    } else
    #endif
    {
      Py_ssize_t index = -1;
      PyObject** temps[4] = {&__pyx_t_5,&__pyx_t_4,&__pyx_t_1,&__pyx_t_3};
      __pyx_t_7 = PyObject_GetIter(((PyObject *)__pyx_v_args)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_7);
      __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext;
      for (index=0; index < 4; index++) {
        PyObject* item = __pyx_t_8(__pyx_t_7); if (unlikely(!item)) goto __pyx_L5_unpacking_failed;
        __Pyx_GOTREF(item);
        *(temps[index]) = item;
      }
      if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 4) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_t_8 = NULL;
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      goto __pyx_L6_unpacking_done;
      __pyx_L5_unpacking_failed:;
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __pyx_t_8 = NULL;
      if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __pyx_L6_unpacking_done:;
    }
    __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_5); if (unlikely((__pyx_t_9 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    __pyx_t_10 = __pyx_PyFloat_AsDouble(__pyx_t_4); if (unlikely((__pyx_t_10 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_11 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_11 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __pyx_t_12 = __pyx_PyFloat_AsDouble(__pyx_t_3); if (unlikely((__pyx_t_12 == (double)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_v_x = __pyx_t_9;
    __pyx_v_y = __pyx_t_10;
    __pyx_v_width = __pyx_t_11;
    __pyx_v_height = __pyx_t_12;
    goto __pyx_L4;
  }
  /*else*/ {

    /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":986
 *             x, y, width, height = args
 *         else:
 *             assert(0)             # <<<<<<<<<<<<<<
 * 
 *         self._points = [x, y, x + width, y, x + width, y + height, x, y + height]
 */
    #ifndef CYTHON_WITHOUT_ASSERTIONS
    if (unlikely(!0)) {
      PyErr_SetNone(PyExc_AssertionError);
      {__pyx_filename = __pyx_f[1]; __pyx_lineno = 986; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    #endif
  }
  __pyx_L4:;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":988
 *             assert(0)
 * 
 *         self._points = [x, y, x + width, y, x + width, y + height, x, y + height]             # <<<<<<<<<<<<<<
 *         self._close = 1
 */
  __pyx_t_3 = PyFloat_FromDouble(__pyx_v_x); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_y); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = PyFloat_FromDouble((__pyx_v_x + __pyx_v_width)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = PyFloat_FromDouble(__pyx_v_y); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_5);
  __pyx_t_7 = PyFloat_FromDouble((__pyx_v_x + __pyx_v_width)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_7);
  __pyx_t_13 = PyFloat_FromDouble((__pyx_v_y + __pyx_v_height)); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_13);
  __pyx_t_14 = PyFloat_FromDouble(__pyx_v_x); if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_14);
  __pyx_t_15 = PyFloat_FromDouble((__pyx_v_y + __pyx_v_height)); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_15);
  __pyx_t_16 = PyList_New(8); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_16);
  PyList_SET_ITEM(__pyx_t_16, 0, __pyx_t_3);
  __Pyx_GIVEREF(__pyx_t_3);
  PyList_SET_ITEM(__pyx_t_16, 1, __pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  PyList_SET_ITEM(__pyx_t_16, 2, __pyx_t_4);
  __Pyx_GIVEREF(__pyx_t_4);
  PyList_SET_ITEM(__pyx_t_16, 3, __pyx_t_5);
  __Pyx_GIVEREF(__pyx_t_5);
  PyList_SET_ITEM(__pyx_t_16, 4, __pyx_t_7);
  __Pyx_GIVEREF(__pyx_t_7);
  PyList_SET_ITEM(__pyx_t_16, 5, __pyx_t_13);
  __Pyx_GIVEREF(__pyx_t_13);
  PyList_SET_ITEM(__pyx_t_16, 6, __pyx_t_14);
  __Pyx_GIVEREF(__pyx_t_14);
  PyList_SET_ITEM(__pyx_t_16, 7, __pyx_t_15);
  __Pyx_GIVEREF(__pyx_t_15);
  __pyx_t_3 = 0;
  __pyx_t_1 = 0;
  __pyx_t_4 = 0;
  __pyx_t_5 = 0;
  __pyx_t_7 = 0;
  __pyx_t_13 = 0;
  __pyx_t_14 = 0;
  __pyx_t_15 = 0;
  __Pyx_GIVEREF(((PyObject *)__pyx_t_16));
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = __pyx_t_16;
  __pyx_t_16 = 0;

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":989
 * 
 *         self._points = [x, y, x + width, y, x + width, y + height, x, y + height]
 *         self._close = 1             # <<<<<<<<<<<<<<
 */
  __pyx_v_self->_close = 1;

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_13);
  __Pyx_XDECREF(__pyx_t_14);
  __Pyx_XDECREF(__pyx_t_15);
  __Pyx_XDECREF(__pyx_t_16);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Line.prebuild_rectangle", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_args);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":65
 *     cdef int _dash_offset, _dash_length
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_t_6;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":66
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else [0, 0, 0, 0, 0, 0, 0, 0]
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 66; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 66; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 66; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":67
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')             # <<<<<<<<<<<<<<
 *         self.points = v if v is not None else [0, 0, 0, 0, 0, 0, 0, 0]
 *         self._segments = kwargs.get('segments') or 10
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__points), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 67; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":68
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else [0, 0, 0, 0, 0, 0, 0, 0]             # <<<<<<<<<<<<<<
 *         self._segments = kwargs.get('segments') or 10
 *         self._loop = kwargs.get('loop') or False
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __pyx_t_3 = PyList_New(8); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 68; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 0, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 1, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 2, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 3, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 4, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 5, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 6, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __Pyx_INCREF(__pyx_int_0);
    PyList_SET_ITEM(__pyx_t_3, 7, __pyx_int_0);
    __Pyx_GIVEREF(__pyx_int_0);
    __pyx_t_4 = ((PyObject *)__pyx_t_3);
    __pyx_t_3 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 68; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":69
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else [0, 0, 0, 0, 0, 0, 0, 0]
 *         self._segments = kwargs.get('segments') or 10             # <<<<<<<<<<<<<<
 *         self._loop = kwargs.get('loop') or False
 *         if self._loop:
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__segments), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(__pyx_int_10);
    __pyx_t_3 = __pyx_int_10;
  } else {
    __pyx_t_3 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_3); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_v_self->_segments = __pyx_t_6;

  /* "kivy\graphics\vertex_instructions.pyx":70
 *         self.points = v if v is not None else [0, 0, 0, 0, 0, 0, 0, 0]
 *         self._segments = kwargs.get('segments') or 10
 *         self._loop = kwargs.get('loop') or False             # <<<<<<<<<<<<<<
 *         if self._loop:
 *             self.points.extend(self.points[:2])
 */
  __pyx_t_3 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__loop), Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 70; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 70; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_4 = __Pyx_PyBool_FromLong(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 70; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_2 = __pyx_t_4;
    __pyx_t_4 = 0;
  } else {
    __pyx_t_2 = __pyx_t_3;
    __pyx_t_3 = 0;
  }
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 70; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_self->_loop = __pyx_t_5;

  /* "kivy\graphics\vertex_instructions.pyx":71
 *         self._segments = kwargs.get('segments') or 10
 *         self._loop = kwargs.get('loop') or False
 *         if self._loop:             # <<<<<<<<<<<<<<
 *             self.points.extend(self.points[:2])
 *         self._dash_length = kwargs.get('dash_length') or 1
 */
  if (__pyx_v_self->_loop) {

    /* "kivy\graphics\vertex_instructions.pyx":72
 *         self._loop = kwargs.get('loop') or False
 *         if self._loop:
 *             self.points.extend(self.points[:2])             # <<<<<<<<<<<<<<
 *         self._dash_length = kwargs.get('dash_length') or 1
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 */
    __pyx_t_2 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_3 = PyObject_GetAttr(__pyx_t_2, __pyx_n_s__extend); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_4 = __Pyx_PySequence_GetSlice(__pyx_t_2, 0, 2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_4);
    __Pyx_GIVEREF(__pyx_t_4);
    __pyx_t_4 = 0;
    __pyx_t_4 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":73
 *         if self._loop:
 *             self.points.extend(self.points[:2])
 *         self._dash_length = kwargs.get('dash_length') or 1             # <<<<<<<<<<<<<<
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 *         self.batch.set_mode('line_strip')
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__dash_length), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 73; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 73; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(__pyx_int_1);
    __pyx_t_2 = __pyx_int_1;
  } else {
    __pyx_t_2 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_2); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 73; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_self->_dash_length = __pyx_t_6;

  /* "kivy\graphics\vertex_instructions.pyx":74
 *             self.points.extend(self.points[:2])
 *         self._dash_length = kwargs.get('dash_length') or 1
 *         self._dash_offset = kwargs.get('dash_offset') or 0             # <<<<<<<<<<<<<<
 *         self.batch.set_mode('line_strip')
 * 
 */
  __pyx_t_2 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__dash_offset), Py_None); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(__pyx_int_0);
    __pyx_t_4 = __pyx_int_0;
  } else {
    __pyx_t_4 = __pyx_t_2;
    __pyx_t_2 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_4); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_v_self->_dash_offset = __pyx_t_6;

  /* "kivy\graphics\vertex_instructions.pyx":75
 *         self._dash_length = kwargs.get('dash_length') or 1
 *         self._dash_offset = kwargs.get('dash_offset') or 0
 *         self.batch.set_mode('line_strip')             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_4 = ((PyObject *)__pyx_n_s__line_strip);
  __Pyx_INCREF(__pyx_t_4);
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_mode(__pyx_v_self->__pyx_base.batch, ((PyObject*)__pyx_t_4));
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":77
 *         self.batch.set_mode('line_strip')
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef int x, i, j
 *         cdef float l
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_6Bezier_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self) {
  int __pyx_v_x;
  int __pyx_v_i;
  int __pyx_v_j;
  float __pyx_v_l;
  PyObject *__pyx_v_T = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  float __pyx_v_tex_x;
  char *__pyx_v_buf;
  struct __pyx_obj_4kivy_8graphics_7texture_Texture *__pyx_v_texture = 0;
  PyObject *__pyx_v_p_str = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  int __pyx_t_3;
  int __pyx_t_4;
  int __pyx_t_5;
  int __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  int __pyx_t_9;
  int __pyx_t_10;
  double __pyx_t_11;
  Py_ssize_t __pyx_t_12;
  int __pyx_t_13;
  Py_ssize_t __pyx_t_14;
  Py_ssize_t __pyx_t_15;
  int __pyx_t_16;
  long __pyx_t_17;
  float __pyx_t_18;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":80
 *         cdef int x, i, j
 *         cdef float l
 *         cdef list T = self.points[:]             # <<<<<<<<<<<<<<
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PySequence_GetSlice(__pyx_t_1, 0, PY_SSIZE_T_MAX); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (!(likely(PyList_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_2)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_T = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":81
 *         cdef float l
 *         cdef list T = self.points[:]
 *         cdef vertex_t *vertices = NULL             # <<<<<<<<<<<<<<
 *         cdef unsigned short *indices = NULL
 *         cdef float tex_x
 */
  __pyx_v_vertices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":82
 *         cdef list T = self.points[:]
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL             # <<<<<<<<<<<<<<
 *         cdef float tex_x
 *         cdef char *buf = NULL
 */
  __pyx_v_indices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":84
 *         cdef unsigned short *indices = NULL
 *         cdef float tex_x
 *         cdef char *buf = NULL             # <<<<<<<<<<<<<<
 *         cdef Texture texture = self.texture
 * 
 */
  __pyx_v_buf = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":85
 *         cdef float tex_x
 *         cdef char *buf = NULL
 *         cdef Texture texture = self.texture             # <<<<<<<<<<<<<<
 * 
 *         if self._dash_offset != 0:
 */
  __pyx_t_2 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_4kivy_8graphics_7texture_Texture))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_texture = ((struct __pyx_obj_4kivy_8graphics_7texture_Texture *)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":87
 *         cdef Texture texture = self.texture
 * 
 *         if self._dash_offset != 0:             # <<<<<<<<<<<<<<
 *             if texture is None or texture._width != \
 *                 (self._dash_length + self._dash_offset) or \
 */
  __pyx_t_3 = (__pyx_v_self->_dash_offset != 0);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":88
 * 
 *         if self._dash_offset != 0:
 *             if texture is None or texture._width != \             # <<<<<<<<<<<<<<
 *                 (self._dash_length + self._dash_offset) or \
 *                 texture._height != 1:
 */
    __pyx_t_3 = (((PyObject *)__pyx_v_texture) == Py_None);
    if (!__pyx_t_3) {

      /* "kivy\graphics\vertex_instructions.pyx":89
 *         if self._dash_offset != 0:
 *             if texture is None or texture._width != \
 *                 (self._dash_length + self._dash_offset) or \             # <<<<<<<<<<<<<<
 *                 texture._height != 1:
 * 
 */
      __pyx_t_4 = (__pyx_v_texture->_width != (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset));
      if (!__pyx_t_4) {

        /* "kivy\graphics\vertex_instructions.pyx":90
 *             if texture is None or texture._width != \
 *                 (self._dash_length + self._dash_offset) or \
 *                 texture._height != 1:             # <<<<<<<<<<<<<<
 * 
 *                 self.texture = texture = Texture.create(
 */
        __pyx_t_5 = (__pyx_v_texture->_height != 1);
        __pyx_t_6 = __pyx_t_5;
      } else {
        __pyx_t_6 = __pyx_t_4;
      }
      __pyx_t_4 = __pyx_t_6;
    } else {
      __pyx_t_4 = __pyx_t_3;
    }
    if (__pyx_t_4) {

      /* "kivy\graphics\vertex_instructions.pyx":92
 *                 texture._height != 1:
 * 
 *                 self.texture = texture = Texture.create(             # <<<<<<<<<<<<<<
 *                         size=(self._dash_length + self._dash_offset, 1))
 *                 texture.wrap = 'repeat'
 */
      __pyx_t_2 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_7texture_Texture)), __pyx_n_s__create); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_2);
      __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(((PyObject *)__pyx_t_1));

      /* "kivy\graphics\vertex_instructions.pyx":93
 * 
 *                 self.texture = texture = Texture.create(
 *                         size=(self._dash_length + self._dash_offset, 1))             # <<<<<<<<<<<<<<
 *                 texture.wrap = 'repeat'
 * 
 */
      __pyx_t_7 = PyInt_FromLong((__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 93; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_7);
      __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 93; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_8);
      PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7);
      __Pyx_GIVEREF(__pyx_t_7);
      __Pyx_INCREF(__pyx_int_1);
      PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_int_1);
      __Pyx_GIVEREF(__pyx_int_1);
      __pyx_t_7 = 0;
      if (PyDict_SetItem(__pyx_t_1, ((PyObject *)__pyx_n_s__size), ((PyObject *)__pyx_t_8)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_DECREF(((PyObject *)__pyx_t_8)); __pyx_t_8 = 0;
      __pyx_t_8 = PyObject_Call(__pyx_t_2, ((PyObject *)__pyx_empty_tuple), ((PyObject *)__pyx_t_1)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_GOTREF(__pyx_t_8);
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;

      /* "kivy\graphics\vertex_instructions.pyx":92
 *                 texture._height != 1:
 * 
 *                 self.texture = texture = Texture.create(             # <<<<<<<<<<<<<<
 *                         size=(self._dash_length + self._dash_offset, 1))
 *                 texture.wrap = 'repeat'
 */
      if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture, __pyx_t_8) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      if (!(likely(((__pyx_t_8) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_8, __pyx_ptype_4kivy_8graphics_7texture_Texture))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      __Pyx_INCREF(__pyx_t_8);
      __Pyx_DECREF(((PyObject *)__pyx_v_texture));
      __pyx_v_texture = ((struct __pyx_obj_4kivy_8graphics_7texture_Texture *)__pyx_t_8);
      __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;

      /* "kivy\graphics\vertex_instructions.pyx":94
 *                 self.texture = texture = Texture.create(
 *                         size=(self._dash_length + self._dash_offset, 1))
 *                 texture.wrap = 'repeat'             # <<<<<<<<<<<<<<
 * 
 *             # create a buffer to fill our texture
 */
      if (PyObject_SetAttr(((PyObject *)__pyx_v_texture), __pyx_n_s__wrap, ((PyObject *)__pyx_n_s__repeat)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 94; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      goto __pyx_L4;
    }
    __pyx_L4:;

    /* "kivy\graphics\vertex_instructions.pyx":97
 * 
 *             # create a buffer to fill our texture
 *             buf = <char *>malloc(4 * (self._dash_length + self._dash_offset))             # <<<<<<<<<<<<<<
 *             memset(buf, 255, self._dash_length * 4)
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)
 */
    __pyx_v_buf = ((char *)malloc((4 * (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset))));

    /* "kivy\graphics\vertex_instructions.pyx":98
 *             # create a buffer to fill our texture
 *             buf = <char *>malloc(4 * (self._dash_length + self._dash_offset))
 *             memset(buf, 255, self._dash_length * 4)             # <<<<<<<<<<<<<<
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)
 * 
 */
    memset(__pyx_v_buf, 255, (__pyx_v_self->_dash_length * 4));

    /* "kivy\graphics\vertex_instructions.pyx":99
 *             buf = <char *>malloc(4 * (self._dash_length + self._dash_offset))
 *             memset(buf, 255, self._dash_length * 4)
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)             # <<<<<<<<<<<<<<
 * 
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)
 */
    memset((__pyx_v_buf + (__pyx_v_self->_dash_length * 4)), 0, (__pyx_v_self->_dash_offset * 4));

    /* "kivy\graphics\vertex_instructions.pyx":101
 *             memset(buf + self._dash_length * 4, 0, self._dash_offset * 4)
 * 
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)             # <<<<<<<<<<<<<<
 * 
 *             texture.blit_buffer(p_str, colorfmt='rgba', bufferfmt='ubyte')
 */
    __pyx_t_8 = PyString_FromStringAndSize(__pyx_v_buf, ((__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset) * 4)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 101; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_8);
    __pyx_v_p_str = __pyx_t_8;
    __pyx_t_8 = 0;

    /* "kivy\graphics\vertex_instructions.pyx":103
 *             p_str = PyString_FromStringAndSize(buf,  (self._dash_length + self._dash_offset) * 4)
 * 
 *             texture.blit_buffer(p_str, colorfmt='rgba', bufferfmt='ubyte')             # <<<<<<<<<<<<<<
 *             free(buf)
 * 
 */
    __pyx_t_8 = PyObject_GetAttr(((PyObject *)__pyx_v_texture), __pyx_n_s__blit_buffer); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_8);
    __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_INCREF(__pyx_v_p_str);
    PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_p_str);
    __Pyx_GIVEREF(__pyx_v_p_str);
    __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_2));
    if (PyDict_SetItem(__pyx_t_2, ((PyObject *)__pyx_n_s__colorfmt), ((PyObject *)__pyx_n_s__rgba)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    if (PyDict_SetItem(__pyx_t_2, ((PyObject *)__pyx_n_s__bufferfmt), ((PyObject *)__pyx_n_s__ubyte)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_7 = PyObject_Call(__pyx_t_8, ((PyObject *)__pyx_t_1), ((PyObject *)__pyx_t_2)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;

    /* "kivy\graphics\vertex_instructions.pyx":104
 * 
 *             texture.blit_buffer(p_str, colorfmt='rgba', bufferfmt='ubyte')
 *             free(buf)             # <<<<<<<<<<<<<<
 * 
 *         elif texture is not None:
 */
    free(__pyx_v_buf);
    goto __pyx_L3;
  }

  /* "kivy\graphics\vertex_instructions.pyx":106
 *             free(buf)
 * 
 *         elif texture is not None:             # <<<<<<<<<<<<<<
 *             self.texture = None
 * 
 */
  __pyx_t_4 = (((PyObject *)__pyx_v_texture) != Py_None);
  if (__pyx_t_4) {

    /* "kivy\graphics\vertex_instructions.pyx":107
 * 
 *         elif texture is not None:
 *             self.texture = None             # <<<<<<<<<<<<<<
 * 
 *         vertices = <vertex_t *>malloc((self._segments + 1) * sizeof(vertex_t))
 */
    if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture, Py_None) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 107; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":109
 *             self.texture = None
 * 
 *         vertices = <vertex_t *>malloc((self._segments + 1) * sizeof(vertex_t))             # <<<<<<<<<<<<<<
 *         if vertices == NULL:
 *             raise MemoryError('vertices')
 */
  __pyx_v_vertices = ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)malloc(((__pyx_v_self->_segments + 1) * (sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)))));

  /* "kivy\graphics\vertex_instructions.pyx":110
 * 
 *         vertices = <vertex_t *>malloc((self._segments + 1) * sizeof(vertex_t))
 *         if vertices == NULL:             # <<<<<<<<<<<<<<
 *             raise MemoryError('vertices')
 * 
 */
  __pyx_t_4 = (__pyx_v_vertices == NULL);
  if (__pyx_t_4) {

    /* "kivy\graphics\vertex_instructions.pyx":111
 *         vertices = <vertex_t *>malloc((self._segments + 1) * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(
 */
    __pyx_t_7 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_24), NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_Raise(__pyx_t_7, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "kivy\graphics\vertex_instructions.pyx":114
 * 
 *         indices = <unsigned short *>malloc(
 *                 (self._segments + 1) * sizeof(unsigned short))             # <<<<<<<<<<<<<<
 *         if indices == NULL:
 *             free(vertices)
 */
  __pyx_v_indices = ((unsigned short *)malloc(((__pyx_v_self->_segments + 1) * (sizeof(unsigned short)))));

  /* "kivy\graphics\vertex_instructions.pyx":115
 *         indices = <unsigned short *>malloc(
 *                 (self._segments + 1) * sizeof(unsigned short))
 *         if indices == NULL:             # <<<<<<<<<<<<<<
 *             free(vertices)
 *             raise MemoryError('indices')
 */
  __pyx_t_4 = (__pyx_v_indices == NULL);
  if (__pyx_t_4) {

    /* "kivy\graphics\vertex_instructions.pyx":116
 *                 (self._segments + 1) * sizeof(unsigned short))
 *         if indices == NULL:
 *             free(vertices)             # <<<<<<<<<<<<<<
 *             raise MemoryError('indices')
 * 
 */
    free(__pyx_v_vertices);

    /* "kivy\graphics\vertex_instructions.pyx":117
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         tex_x = x = 0
 */
    __pyx_t_7 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_25), NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_Raise(__pyx_t_7, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L6;
  }
  __pyx_L6:;

  /* "kivy\graphics\vertex_instructions.pyx":119
 *             raise MemoryError('indices')
 * 
 *         tex_x = x = 0             # <<<<<<<<<<<<<<
 *         for x in xrange(self._segments):
 *             l = x / (1.0 * self._segments)
 */
  __pyx_v_tex_x = 0;
  __pyx_v_x = 0;

  /* "kivy\graphics\vertex_instructions.pyx":120
 * 
 *         tex_x = x = 0
 *         for x in xrange(self._segments):             # <<<<<<<<<<<<<<
 *             l = x / (1.0 * self._segments)
 *             # http://en.wikipedia.org/wiki/De_Casteljau%27s_algorithm
 */
  __pyx_t_9 = __pyx_v_self->_segments;
  for (__pyx_t_10 = 0; __pyx_t_10 < __pyx_t_9; __pyx_t_10+=1) {
    __pyx_v_x = __pyx_t_10;

    /* "kivy\graphics\vertex_instructions.pyx":121
 *         tex_x = x = 0
 *         for x in xrange(self._segments):
 *             l = x / (1.0 * self._segments)             # <<<<<<<<<<<<<<
 *             # http://en.wikipedia.org/wiki/De_Casteljau%27s_algorithm
 *             # as the list is in the form of (x1, y1, x2, y2...) iteration is
 */
    __pyx_t_11 = (1.0 * __pyx_v_self->_segments);
    if (unlikely(__pyx_t_11 == 0)) {
      PyErr_Format(PyExc_ZeroDivisionError, "float division");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 121; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_v_l = (__pyx_v_x / __pyx_t_11);

    /* "kivy\graphics\vertex_instructions.pyx":127
 *             # replaced with a calculation of "xn + x(n+1) - xn" x(n+1) is
 *             # placed at n+2. each iteration makes the list one item shorter
 *             for i in range(1, len(T)):             # <<<<<<<<<<<<<<
 *                 for j in xrange(len(T) - 2*i):
 *                     T[j] = T[j] + (T[j+2] - T[j]) * l
 */
    if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_12 = PyList_GET_SIZE(((PyObject *)__pyx_v_T)); 
    for (__pyx_t_13 = 1; __pyx_t_13 < __pyx_t_12; __pyx_t_13+=1) {
      __pyx_v_i = __pyx_t_13;

      /* "kivy\graphics\vertex_instructions.pyx":128
 *             # placed at n+2. each iteration makes the list one item shorter
 *             for i in range(1, len(T)):
 *                 for j in xrange(len(T) - 2*i):             # <<<<<<<<<<<<<<
 *                     T[j] = T[j] + (T[j+2] - T[j]) * l
 * 
 */
      if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_14 = PyList_GET_SIZE(((PyObject *)__pyx_v_T)); 
      __pyx_t_15 = (__pyx_t_14 - (2 * __pyx_v_i));
      for (__pyx_t_16 = 0; __pyx_t_16 < __pyx_t_15; __pyx_t_16+=1) {
        __pyx_v_j = __pyx_t_16;

        /* "kivy\graphics\vertex_instructions.pyx":129
 *             for i in range(1, len(T)):
 *                 for j in xrange(len(T) - 2*i):
 *                     T[j] = T[j] + (T[j+2] - T[j]) * l             # <<<<<<<<<<<<<<
 * 
 *             # we got the coordinates of the point in T[0] and T[1]
 */
        if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
          PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
          {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        __pyx_t_7 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), __pyx_v_j, sizeof(int), PyInt_FromLong); if (!__pyx_t_7) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_7);
        if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
          PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
          {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        __pyx_t_17 = (__pyx_v_j + 2);
        __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), __pyx_t_17, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_2);
        if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
          PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
          {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), __pyx_v_j, sizeof(int), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_1);
        __pyx_t_8 = PyNumber_Subtract(__pyx_t_2, __pyx_t_1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_8);
        __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __pyx_t_1 = PyFloat_FromDouble(__pyx_v_l); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_1);
        __pyx_t_2 = PyNumber_Multiply(__pyx_t_8, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_2);
        __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __pyx_t_1 = PyNumber_Add(__pyx_t_7, __pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
        __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
        if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
          PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
          {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        }
        if (__Pyx_SetItemInt(((PyObject *)__pyx_v_T), __pyx_v_j, __pyx_t_1, sizeof(int), PyInt_FromLong) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      }
    }

    /* "kivy\graphics\vertex_instructions.pyx":132
 * 
 *             # we got the coordinates of the point in T[0] and T[1]
 *             vertices[x].x = T[0]             # <<<<<<<<<<<<<<
 *             vertices[x].y = T[1]
 *             if self._dash_offset != 0 and x > 0:
 */
    if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_18 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_18 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_x]).x = __pyx_t_18;

    /* "kivy\graphics\vertex_instructions.pyx":133
 *             # we got the coordinates of the point in T[0] and T[1]
 *             vertices[x].x = T[0]
 *             vertices[x].y = T[1]             # <<<<<<<<<<<<<<
 *             if self._dash_offset != 0 and x > 0:
 *                 tex_x += sqrt(
 */
    if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_18 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_18 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_x]).y = __pyx_t_18;

    /* "kivy\graphics\vertex_instructions.pyx":134
 *             vertices[x].x = T[0]
 *             vertices[x].y = T[1]
 *             if self._dash_offset != 0 and x > 0:             # <<<<<<<<<<<<<<
 *                 tex_x += sqrt(
 *                         pow(vertices[x].x - vertices[x-1].x, 2) +
 */
    __pyx_t_4 = (__pyx_v_self->_dash_offset != 0);
    if (__pyx_t_4) {
      __pyx_t_3 = (__pyx_v_x > 0);
      __pyx_t_6 = __pyx_t_3;
    } else {
      __pyx_t_6 = __pyx_t_4;
    }
    if (__pyx_t_6) {

      /* "kivy\graphics\vertex_instructions.pyx":137
 *                 tex_x += sqrt(
 *                         pow(vertices[x].x - vertices[x-1].x, 2) +
 *                         pow(vertices[x].y - vertices[x-1].y, 2)) / (             # <<<<<<<<<<<<<<
 *                                 self._dash_length + self._dash_offset)
 * 
 */
      __pyx_t_11 = sqrt((pow(((__pyx_v_vertices[__pyx_v_x]).x - (__pyx_v_vertices[(__pyx_v_x - 1)]).x), 2.0) + pow(((__pyx_v_vertices[__pyx_v_x]).y - (__pyx_v_vertices[(__pyx_v_x - 1)]).y), 2.0)));

      /* "kivy\graphics\vertex_instructions.pyx":138
 *                         pow(vertices[x].x - vertices[x-1].x, 2) +
 *                         pow(vertices[x].y - vertices[x-1].y, 2)) / (
 *                                 self._dash_length + self._dash_offset)             # <<<<<<<<<<<<<<
 * 
 *                 vertices[x].s0 = tex_x
 */
      __pyx_t_13 = (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset);
      if (unlikely(__pyx_t_13 == 0)) {
        PyErr_Format(PyExc_ZeroDivisionError, "float division");
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_v_tex_x = (__pyx_v_tex_x + (__pyx_t_11 / __pyx_t_13));

      /* "kivy\graphics\vertex_instructions.pyx":140
 *                                 self._dash_length + self._dash_offset)
 * 
 *                 vertices[x].s0 = tex_x             # <<<<<<<<<<<<<<
 *                 vertices[x].t0 = 0
 * 
 */
      (__pyx_v_vertices[__pyx_v_x]).s0 = __pyx_v_tex_x;

      /* "kivy\graphics\vertex_instructions.pyx":141
 * 
 *                 vertices[x].s0 = tex_x
 *                 vertices[x].t0 = 0             # <<<<<<<<<<<<<<
 * 
 *             indices[x] = x
 */
      (__pyx_v_vertices[__pyx_v_x]).t0 = 0.0;
      goto __pyx_L13;
    }
    __pyx_L13:;

    /* "kivy\graphics\vertex_instructions.pyx":143
 *                 vertices[x].t0 = 0
 * 
 *             indices[x] = x             # <<<<<<<<<<<<<<
 * 
 *         # add one last point to join the curve to the end
 */
    (__pyx_v_indices[__pyx_v_x]) = __pyx_v_x;
  }

  /* "kivy\graphics\vertex_instructions.pyx":146
 * 
 *         # add one last point to join the curve to the end
 *         vertices[x+1].x = T[-2]             # <<<<<<<<<<<<<<
 *         vertices[x+1].y = T[-1]
 * 
 */
  if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 146; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), -2, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 146; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_18 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_18 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 146; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  (__pyx_v_vertices[(__pyx_v_x + 1)]).x = __pyx_t_18;

  /* "kivy\graphics\vertex_instructions.pyx":147
 *         # add one last point to join the curve to the end
 *         vertices[x+1].x = T[-2]
 *         vertices[x+1].y = T[-1]             # <<<<<<<<<<<<<<
 * 
 *         tex_x += sqrt(
 */
  if (unlikely(((PyObject *)__pyx_v_T) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_T), -1, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_18 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_18 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  (__pyx_v_vertices[(__pyx_v_x + 1)]).y = __pyx_t_18;

  /* "kivy\graphics\vertex_instructions.pyx":151
 *         tex_x += sqrt(
 *                 (vertices[x+1].x - vertices[x].x) ** 2 +
 *                 (vertices[x+1].y - vertices[x].y) ** 2) / (             # <<<<<<<<<<<<<<
 *                         self._dash_length + self._dash_offset)
 * 
 */
  __pyx_t_11 = sqrt((powf(((__pyx_v_vertices[(__pyx_v_x + 1)]).x - (__pyx_v_vertices[__pyx_v_x]).x), 2.0) + powf(((__pyx_v_vertices[(__pyx_v_x + 1)]).y - (__pyx_v_vertices[__pyx_v_x]).y), 2.0)));

  /* "kivy\graphics\vertex_instructions.pyx":152
 *                 (vertices[x+1].x - vertices[x].x) ** 2 +
 *                 (vertices[x+1].y - vertices[x].y) ** 2) / (
 *                         self._dash_length + self._dash_offset)             # <<<<<<<<<<<<<<
 * 
 *         vertices[x+1].s0 = tex_x
 */
  __pyx_t_9 = (__pyx_v_self->_dash_length + __pyx_v_self->_dash_offset);
  if (unlikely(__pyx_t_9 == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 151; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_v_tex_x = (__pyx_v_tex_x + (__pyx_t_11 / __pyx_t_9));

  /* "kivy\graphics\vertex_instructions.pyx":154
 *                         self._dash_length + self._dash_offset)
 * 
 *         vertices[x+1].s0 = tex_x             # <<<<<<<<<<<<<<
 *         vertices[x+1].t0 = 0
 *         indices[x+1] = x + 1
 */
  (__pyx_v_vertices[(__pyx_v_x + 1)]).s0 = __pyx_v_tex_x;

  /* "kivy\graphics\vertex_instructions.pyx":155
 * 
 *         vertices[x+1].s0 = tex_x
 *         vertices[x+1].t0 = 0             # <<<<<<<<<<<<<<
 *         indices[x+1] = x + 1
 * 
 */
  (__pyx_v_vertices[(__pyx_v_x + 1)]).t0 = 0.0;

  /* "kivy\graphics\vertex_instructions.pyx":156
 *         vertices[x+1].s0 = tex_x
 *         vertices[x+1].t0 = 0
 *         indices[x+1] = x + 1             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(
 */
  (__pyx_v_indices[(__pyx_v_x + 1)]) = (__pyx_v_x + 1);

  /* "kivy\graphics\vertex_instructions.pyx":162
 *                 self._segments + 1,
 *                 indices,
 *                 self._segments + 1)             # <<<<<<<<<<<<<<
 * 
 *         free(vertices)
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, (__pyx_v_self->_segments + 1), __pyx_v_indices, (__pyx_v_self->_segments + 1));

  /* "kivy\graphics\vertex_instructions.pyx":164
 *                 self._segments + 1)
 * 
 *         free(vertices)             # <<<<<<<<<<<<<<
 *         free(indices)
 * 
 */
  free(__pyx_v_vertices);

  /* "kivy\graphics\vertex_instructions.pyx":165
 * 
 *         free(vertices)
 *         free(indices)             # <<<<<<<<<<<<<<
 * 
 *     property points:
 */
  free(__pyx_v_indices);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Bezier.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_T);
  __Pyx_XDECREF((PyObject *)__pyx_v_texture);
  __Pyx_XDECREF(__pyx_v_p_str);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_6points_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_6points_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_6points___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":175
 *             list. It can be very CPU expensive.
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._points
 *         def __set__(self, points):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":176
 *         '''
 *         def __get__(self):
 *             return self._points             # <<<<<<<<<<<<<<
 *         def __set__(self, points):
 *             self._points = list(points)
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_points));
  __pyx_r = ((PyObject *)__pyx_v_self->_points);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_6points_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self), ((PyObject *)__pyx_v_points));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":177
 *         def __get__(self):
 *             return self._points
 *         def __set__(self, points):             # <<<<<<<<<<<<<<
 *             self._points = list(points)
 *             if self._loop:
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":178
 *             return self._points
 *         def __set__(self, points):
 *             self._points = list(points)             # <<<<<<<<<<<<<<
 *             if self._loop:
 *                 self._points.extend(points[:2])
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 178; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_points);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_points);
  __Pyx_GIVEREF(__pyx_v_points);
  __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 178; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_2);
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":179
 *         def __set__(self, points):
 *             self._points = list(points)
 *             if self._loop:             # <<<<<<<<<<<<<<
 *                 self._points.extend(points[:2])
 *             self.flag_update()
 */
  if (__pyx_v_self->_loop) {

    /* "kivy\graphics\vertex_instructions.pyx":180
 *             self._points = list(points)
 *             if self._loop:
 *                 self._points.extend(points[:2])             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
    __pyx_t_2 = PyObject_GetAttr(((PyObject *)__pyx_v_self->_points), __pyx_n_s__extend); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_1 = __Pyx_PySequence_GetSlice(__pyx_v_points, 0, 2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_2, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":181
 *             if self._loop:
 *                 self._points.extend(points[:2])
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property segments:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.points.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_8segments___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":186
 *         '''Property for getting/setting the number of segments of the curve
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._segments
 *         def __set__(self, value):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_8segments___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":187
 *         '''
 *         def __get__(self):
 *             return self._segments             # <<<<<<<<<<<<<<
 *         def __set__(self, value):
 *             if value <= 1:
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_segments); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 187; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.segments.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":188
 *         def __get__(self):
 *             return self._segments
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value <= 1:
 *                 raise GraphicException('Invalid segments value, must be >= 2')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":189
 *             return self._segments
 *         def __set__(self, value):
 *             if value <= 1:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid segments value, must be >= 2')
 *             self._segments = value
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_1, Py_LE); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "kivy\graphics\vertex_instructions.pyx":190
 *         def __set__(self, value):
 *             if value <= 1:
 *                 raise GraphicException('Invalid segments value, must be >= 2')             # <<<<<<<<<<<<<<
 *             self._segments = value
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 190; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_27), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 190; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 190; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":191
 *             if value <= 1:
 *                 raise GraphicException('Invalid segments value, must be >= 2')
 *             self._segments = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_v_value); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_segments = __pyx_t_4;

  /* "kivy\graphics\vertex_instructions.pyx":192
 *                 raise GraphicException('Invalid segments value, must be >= 2')
 *             self._segments = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property dash_length:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.segments.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":197
 *         '''Property for getting/stting the length of the dashes in the curve
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._dash_length
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":198
 *         '''
 *         def __get__(self):
 *             return self._dash_length             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_dash_length); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 198; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.dash_length.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":200
 *             return self._dash_length
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":201
 * 
 *         def __set__(self, value):
 *             if value < 0:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 *             self._dash_length = value
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_0, Py_LT); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "kivy\graphics\vertex_instructions.pyx":202
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_length = value
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_28), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":203
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 *             self._dash_length = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_v_value); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_dash_length = __pyx_t_4;

  /* "kivy\graphics\vertex_instructions.pyx":204
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')
 *             self._dash_length = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property dash_offset:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.dash_length.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":209
 *         '''Property for getting/setting the offset between the dashes in the curve
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._dash_offset
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":210
 *         '''
 *         def __get__(self):
 *             return self._dash_offset             # <<<<<<<<<<<<<<
 * 
 *         def __set__(self, value):
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_dash_offset); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 210; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.dash_offset.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":212
 *             return self._dash_offset
 * 
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":213
 * 
 *         def __set__(self, value):
 *             if value < 0:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 *             self._dash_offset = value
 */
  __pyx_t_1 = PyObject_RichCompare(__pyx_v_value, __pyx_int_0, Py_LT); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 213; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 213; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "kivy\graphics\vertex_instructions.pyx":214
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_offset = value
 *             self.flag_update()
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_3 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_29), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":215
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 *             self._dash_offset = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_v_value); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 215; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_dash_offset = __pyx_t_4;

  /* "kivy\graphics\vertex_instructions.pyx":216
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')
 *             self._dash_offset = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Bezier.dash_offset.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":255
 *     cdef list _indices
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('vertices')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":256
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('vertices')
 *         self.vertices = v if v is not None else []
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":257
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('vertices')             # <<<<<<<<<<<<<<
 *         self.vertices = v if v is not None else []
 *         v = kwargs.get('indices')
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__vertices), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":258
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('vertices')
 *         self.vertices = v if v is not None else []             # <<<<<<<<<<<<<<
 *         v = kwargs.get('indices')
 *         self.indices = v if v is not None else []
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 258; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = ((PyObject *)__pyx_t_3);
    __pyx_t_3 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__vertices, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 258; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":259
 *         v = kwargs.get('vertices')
 *         self.vertices = v if v is not None else []
 *         v = kwargs.get('indices')             # <<<<<<<<<<<<<<
 *         self.indices = v if v is not None else []
 *         self.mode = kwargs.get('mode') or 'points'
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__indices), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 259; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_v_v);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":260
 *         self.vertices = v if v is not None else []
 *         v = kwargs.get('indices')
 *         self.indices = v if v is not None else []             # <<<<<<<<<<<<<<
 *         self.mode = kwargs.get('mode') or 'points'
 * 
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 260; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = ((PyObject *)__pyx_t_3);
    __pyx_t_3 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__indices, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 260; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":261
 *         v = kwargs.get('indices')
 *         self.indices = v if v is not None else []
 *         self.mode = kwargs.get('mode') or 'points'             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__mode), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 261; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 261; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(((PyObject *)__pyx_n_s__points));
    __pyx_t_3 = __pyx_n_s__points;
  } else {
    __pyx_t_3 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__mode, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 261; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Mesh.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":263
 *         self.mode = kwargs.get('mode') or 'points'
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef int i, vcount = len(self._vertices) / 4
 *         cdef int icount = len(self._indices)
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Mesh_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self) {
  int __pyx_v_i;
  int __pyx_v_vcount;
  int __pyx_v_icount;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  PyObject *__pyx_v_lvertices = 0;
  PyObject *__pyx_v_lindices = 0;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  Py_ssize_t __pyx_t_2;
  int __pyx_t_3;
  int __pyx_t_4;
  int __pyx_t_5;
  int __pyx_t_6;
  int __pyx_t_7;
  long __pyx_t_8;
  float __pyx_t_9;
  unsigned short __pyx_t_10;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":264
 * 
 *     cdef void build(self):
 *         cdef int i, vcount = len(self._vertices) / 4             # <<<<<<<<<<<<<<
 *         cdef int icount = len(self._indices)
 *         cdef vertex_t *vertices = NULL
 */
  __pyx_t_1 = ((PyObject *)__pyx_v_self->_vertices);
  __Pyx_INCREF(__pyx_t_1);
  if (unlikely(__pyx_t_1 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 264; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); 
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_vcount = __Pyx_div_Py_ssize_t(__pyx_t_2, 4);

  /* "kivy\graphics\vertex_instructions.pyx":265
 *     cdef void build(self):
 *         cdef int i, vcount = len(self._vertices) / 4
 *         cdef int icount = len(self._indices)             # <<<<<<<<<<<<<<
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 */
  __pyx_t_1 = ((PyObject *)__pyx_v_self->_indices);
  __Pyx_INCREF(__pyx_t_1);
  if (unlikely(__pyx_t_1 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 265; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); 
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_icount = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":266
 *         cdef int i, vcount = len(self._vertices) / 4
 *         cdef int icount = len(self._indices)
 *         cdef vertex_t *vertices = NULL             # <<<<<<<<<<<<<<
 *         cdef unsigned short *indices = NULL
 *         cdef list lvertices = self._vertices
 */
  __pyx_v_vertices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":267
 *         cdef int icount = len(self._indices)
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL             # <<<<<<<<<<<<<<
 *         cdef list lvertices = self._vertices
 *         cdef list lindices = self._indices
 */
  __pyx_v_indices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":268
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 *         cdef list lvertices = self._vertices             # <<<<<<<<<<<<<<
 *         cdef list lindices = self._indices
 * 
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_vertices));
  __pyx_v_lvertices = __pyx_v_self->_vertices;

  /* "kivy\graphics\vertex_instructions.pyx":269
 *         cdef unsigned short *indices = NULL
 *         cdef list lvertices = self._vertices
 *         cdef list lindices = self._indices             # <<<<<<<<<<<<<<
 * 
 *         if vcount == 0 or icount == 0:
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_indices));
  __pyx_v_lindices = __pyx_v_self->_indices;

  /* "kivy\graphics\vertex_instructions.pyx":271
 *         cdef list lindices = self._indices
 * 
 *         if vcount == 0 or icount == 0:             # <<<<<<<<<<<<<<
 *             self.batch.clear_data()
 *             return
 */
  __pyx_t_3 = (__pyx_v_vcount == 0);
  if (!__pyx_t_3) {
    __pyx_t_4 = (__pyx_v_icount == 0);
    __pyx_t_5 = __pyx_t_4;
  } else {
    __pyx_t_5 = __pyx_t_3;
  }
  if (__pyx_t_5) {

    /* "kivy\graphics\vertex_instructions.pyx":272
 * 
 *         if vcount == 0 or icount == 0:
 *             self.batch.clear_data()             # <<<<<<<<<<<<<<
 *             return
 * 
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->clear_data(__pyx_v_self->__pyx_base.batch);

    /* "kivy\graphics\vertex_instructions.pyx":273
 *         if vcount == 0 or icount == 0:
 *             self.batch.clear_data()
 *             return             # <<<<<<<<<<<<<<
 * 
 *         vertices = <vertex_t *>malloc(vcount * sizeof(vertex_t))
 */
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":275
 *             return
 * 
 *         vertices = <vertex_t *>malloc(vcount * sizeof(vertex_t))             # <<<<<<<<<<<<<<
 *         if vertices == NULL:
 *             raise MemoryError('vertices')
 */
  __pyx_v_vertices = ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)malloc((__pyx_v_vcount * (sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)))));

  /* "kivy\graphics\vertex_instructions.pyx":276
 * 
 *         vertices = <vertex_t *>malloc(vcount * sizeof(vertex_t))
 *         if vertices == NULL:             # <<<<<<<<<<<<<<
 *             raise MemoryError('vertices')
 * 
 */
  __pyx_t_5 = (__pyx_v_vertices == NULL);
  if (__pyx_t_5) {

    /* "kivy\graphics\vertex_instructions.pyx":277
 *         vertices = <vertex_t *>malloc(vcount * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(icount * sizeof(unsigned short))
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_30), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 277; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 277; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "kivy\graphics\vertex_instructions.pyx":279
 *             raise MemoryError('vertices')
 * 
 *         indices = <unsigned short *>malloc(icount * sizeof(unsigned short))             # <<<<<<<<<<<<<<
 *         if indices == NULL:
 *             free(vertices)
 */
  __pyx_v_indices = ((unsigned short *)malloc((__pyx_v_icount * (sizeof(unsigned short)))));

  /* "kivy\graphics\vertex_instructions.pyx":280
 * 
 *         indices = <unsigned short *>malloc(icount * sizeof(unsigned short))
 *         if indices == NULL:             # <<<<<<<<<<<<<<
 *             free(vertices)
 *             raise MemoryError('indices')
 */
  __pyx_t_5 = (__pyx_v_indices == NULL);
  if (__pyx_t_5) {

    /* "kivy\graphics\vertex_instructions.pyx":281
 *         indices = <unsigned short *>malloc(icount * sizeof(unsigned short))
 *         if indices == NULL:
 *             free(vertices)             # <<<<<<<<<<<<<<
 *             raise MemoryError('indices')
 * 
 */
    free(__pyx_v_vertices);

    /* "kivy\graphics\vertex_instructions.pyx":282
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         for i in xrange(vcount):
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_31), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "kivy\graphics\vertex_instructions.pyx":284
 *             raise MemoryError('indices')
 * 
 *         for i in xrange(vcount):             # <<<<<<<<<<<<<<
 *             vertices[i].x = lvertices[i * 4]
 *             vertices[i].y = lvertices[i * 4 + 1]
 */
  __pyx_t_6 = __pyx_v_vcount;
  for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) {
    __pyx_v_i = __pyx_t_7;

    /* "kivy\graphics\vertex_instructions.pyx":285
 * 
 *         for i in xrange(vcount):
 *             vertices[i].x = lvertices[i * 4]             # <<<<<<<<<<<<<<
 *             vertices[i].y = lvertices[i * 4 + 1]
 *             vertices[i].s0 = lvertices[i * 4 + 2]
 */
    if (unlikely(((PyObject *)__pyx_v_lvertices) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 285; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = (__pyx_v_i * 4);
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_lvertices), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 285; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_9 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_9 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 285; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_i]).x = __pyx_t_9;

    /* "kivy\graphics\vertex_instructions.pyx":286
 *         for i in xrange(vcount):
 *             vertices[i].x = lvertices[i * 4]
 *             vertices[i].y = lvertices[i * 4 + 1]             # <<<<<<<<<<<<<<
 *             vertices[i].s0 = lvertices[i * 4 + 2]
 *             vertices[i].t0 = lvertices[i * 4 + 3]
 */
    if (unlikely(((PyObject *)__pyx_v_lvertices) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 286; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = ((__pyx_v_i * 4) + 1);
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_lvertices), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 286; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_9 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_9 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 286; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_i]).y = __pyx_t_9;

    /* "kivy\graphics\vertex_instructions.pyx":287
 *             vertices[i].x = lvertices[i * 4]
 *             vertices[i].y = lvertices[i * 4 + 1]
 *             vertices[i].s0 = lvertices[i * 4 + 2]             # <<<<<<<<<<<<<<
 *             vertices[i].t0 = lvertices[i * 4 + 3]
 * 
 */
    if (unlikely(((PyObject *)__pyx_v_lvertices) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 287; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = ((__pyx_v_i * 4) + 2);
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_lvertices), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 287; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_9 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_9 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 287; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_i]).s0 = __pyx_t_9;

    /* "kivy\graphics\vertex_instructions.pyx":288
 *             vertices[i].y = lvertices[i * 4 + 1]
 *             vertices[i].s0 = lvertices[i * 4 + 2]
 *             vertices[i].t0 = lvertices[i * 4 + 3]             # <<<<<<<<<<<<<<
 * 
 *         for i in xrange(icount):
 */
    if (unlikely(((PyObject *)__pyx_v_lvertices) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 288; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_8 = ((__pyx_v_i * 4) + 3);
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_lvertices), __pyx_t_8, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 288; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_9 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_9 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 288; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_vertices[__pyx_v_i]).t0 = __pyx_t_9;
  }

  /* "kivy\graphics\vertex_instructions.pyx":290
 *             vertices[i].t0 = lvertices[i * 4 + 3]
 * 
 *         for i in xrange(icount):             # <<<<<<<<<<<<<<
 *             indices[i] = lindices[i]
 * 
 */
  __pyx_t_6 = __pyx_v_icount;
  for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) {
    __pyx_v_i = __pyx_t_7;

    /* "kivy\graphics\vertex_instructions.pyx":291
 * 
 *         for i in xrange(icount):
 *             indices[i] = lindices[i]             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, vcount, indices, icount)
 */
    if (unlikely(((PyObject *)__pyx_v_lindices) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 291; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_lindices), __pyx_v_i, sizeof(int), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 291; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_10 = __Pyx_PyInt_AsUnsignedShort(__pyx_t_1); if (unlikely((__pyx_t_10 == (unsigned short)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 291; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    (__pyx_v_indices[__pyx_v_i]) = __pyx_t_10;
  }

  /* "kivy\graphics\vertex_instructions.pyx":293
 *             indices[i] = lindices[i]
 * 
 *         self.batch.set_data(vertices, vcount, indices, icount)             # <<<<<<<<<<<<<<
 * 
 *         free(vertices)
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, __pyx_v_vcount, __pyx_v_indices, __pyx_v_icount);

  /* "kivy\graphics\vertex_instructions.pyx":295
 *         self.batch.set_data(vertices, vcount, indices, icount)
 * 
 *         free(vertices)             # <<<<<<<<<<<<<<
 *         free(indices)
 * 
 */
  free(__pyx_v_vertices);

  /* "kivy\graphics\vertex_instructions.pyx":296
 * 
 *         free(vertices)
 *         free(indices)             # <<<<<<<<<<<<<<
 * 
 *     property vertices:
 */
  free(__pyx_v_indices);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Mesh.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_lvertices);
  __Pyx_XDECREF(__pyx_v_lindices);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":303
 *         mean it's only x/y + one texture coordinate.
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._vertices
 *         def __set__(self, value):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":304
 *         '''
 *         def __get__(self):
 *             return self._vertices             # <<<<<<<<<<<<<<
 *         def __set__(self, value):
 *             self._vertices = list(value)
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_vertices));
  __pyx_r = ((PyObject *)__pyx_v_self->_vertices);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":305
 *         def __get__(self):
 *             return self._vertices
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             self._vertices = list(value)
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":306
 *             return self._vertices
 *         def __set__(self, value):
 *             self._vertices = list(value)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_value);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_value);
  __Pyx_GIVEREF(__pyx_v_value);
  __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_2);
  __Pyx_GOTREF(__pyx_v_self->_vertices);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_vertices));
  __pyx_v_self->_vertices = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":307
 *         def __set__(self, value):
 *             self._vertices = list(value)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property indices:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Mesh.vertices.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_7indices___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":313
 *         mesh.
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._indices
 *         def __set__(self, value):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_7indices___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":314
 *         '''
 *         def __get__(self):
 *             return self._indices             # <<<<<<<<<<<<<<
 *         def __set__(self, value):
 *             if len(value) > 65535:
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_indices));
  __pyx_r = ((PyObject *)__pyx_v_self->_indices);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":315
 *         def __get__(self):
 *             return self._indices
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             if len(value) > 65535:
 *                 raise GraphicException(
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  Py_ssize_t __pyx_t_1;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":316
 *             return self._indices
 *         def __set__(self, value):
 *             if len(value) > 65535:             # <<<<<<<<<<<<<<
 *                 raise GraphicException(
 *                     'Cannot upload more than 65535 indices'
 */
  __pyx_t_1 = PyObject_Length(__pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_t_2 = (__pyx_t_1 > 65535);
  if (__pyx_t_2) {

    /* "kivy\graphics\vertex_instructions.pyx":317
 *         def __set__(self, value):
 *             if len(value) > 65535:
 *                 raise GraphicException(             # <<<<<<<<<<<<<<
 *                     'Cannot upload more than 65535 indices'
 *                     '(OpenGL ES 2 limitation)')
 */
    __pyx_t_3 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_k_tuple_33), NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_Raise(__pyx_t_4, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":320
 *                     'Cannot upload more than 65535 indices'
 *                     '(OpenGL ES 2 limitation)')
 *             self._indices = list(value)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 320; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_INCREF(__pyx_v_value);
  PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_value);
  __Pyx_GIVEREF(__pyx_v_value);
  __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 320; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
  __Pyx_GIVEREF(__pyx_t_3);
  __Pyx_GOTREF(__pyx_v_self->_indices);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_indices));
  __pyx_v_self->_indices = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":321
 *                     '(OpenGL ES 2 limitation)')
 *             self._indices = list(value)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property mode:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Mesh.indices.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_4mode___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":327
 *         'line_strip', 'line_loop', 'lines', 'triangle_strip', 'triangle_fan'
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             self.batch.get_mode()
 *         def __set__(self, mode):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_4mode___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":328
 *         '''
 *         def __get__(self):
 *             self.batch.get_mode()             # <<<<<<<<<<<<<<
 *         def __set__(self, mode):
 *             self.batch.set_mode(mode)
 */
  __pyx_t_1 = ((PyObject *)((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->get_mode(__pyx_v_self->__pyx_base.batch)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 328; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Mesh.mode.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_mode); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_mode) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)__pyx_v_self), ((PyObject *)__pyx_v_mode));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":329
 *         def __get__(self):
 *             self.batch.get_mode()
 *         def __set__(self, mode):             # <<<<<<<<<<<<<<
 *             self.batch.set_mode(mode)
 * 
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *__pyx_v_self, PyObject *__pyx_v_mode) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":330
 *             self.batch.get_mode()
 *         def __set__(self, mode):
 *             self.batch.set_mode(mode)             # <<<<<<<<<<<<<<
 * 
 * 
 */
  if (!(likely(PyString_CheckExact(__pyx_v_mode))||((__pyx_v_mode) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected str, got %.200s", Py_TYPE(__pyx_v_mode)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 330; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_t_1 = __pyx_v_mode;
  __Pyx_INCREF(__pyx_t_1);
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_mode(__pyx_v_self->__pyx_base.batch, ((PyObject*)__pyx_t_1));
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Mesh.mode.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":354
 *     cdef float _pointsize
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":355
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else []
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 355; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 355; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 355; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":356
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')             # <<<<<<<<<<<<<<
 *         self.points = v if v is not None else []
 *         self.pointsize = kwargs.get('pointsize') or 1.
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__points), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 356; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":357
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else []             # <<<<<<<<<<<<<<
 *         self.pointsize = kwargs.get('pointsize') or 1.
 * 
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = ((PyObject *)__pyx_t_3);
    __pyx_t_3 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":358
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else []
 *         self.pointsize = kwargs.get('pointsize') or 1.             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__pointsize), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 358; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 358; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_3 = PyFloat_FromDouble(1.); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 358; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_2 = __pyx_t_3;
    __pyx_t_3 = 0;
  } else {
    __pyx_t_2 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__pointsize, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 358; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Point.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":360
 *         self.pointsize = kwargs.get('pointsize') or 1.
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef float t0, t1, t2, t3, t4, t5, t6, t7
 *         cdef float x, y, ps = self._pointsize
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_5Point_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self) {
  float __pyx_v_t0;
  float __pyx_v_t1;
  float __pyx_v_t2;
  float __pyx_v_t3;
  float __pyx_v_t4;
  float __pyx_v_t5;
  float __pyx_v_t6;
  float __pyx_v_t7;
  float __pyx_v_x;
  float __pyx_v_y;
  float __pyx_v_ps;
  int __pyx_v_i;
  int __pyx_v_iv;
  int __pyx_v_ii;
  int __pyx_v_count;
  PyObject *__pyx_v_p = 0;
  PyObject *__pyx_v_tc = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  Py_ssize_t __pyx_t_2;
  int __pyx_t_3;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  PyObject *__pyx_t_11 = NULL;
  PyObject *(*__pyx_t_12)(PyObject *);
  float __pyx_t_13;
  float __pyx_t_14;
  float __pyx_t_15;
  float __pyx_t_16;
  float __pyx_t_17;
  float __pyx_t_18;
  float __pyx_t_19;
  float __pyx_t_20;
  int __pyx_t_21;
  int __pyx_t_22;
  long __pyx_t_23;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":362
 *     cdef void build(self):
 *         cdef float t0, t1, t2, t3, t4, t5, t6, t7
 *         cdef float x, y, ps = self._pointsize             # <<<<<<<<<<<<<<
 *         cdef int i, iv, ii, count = <int>(len(self._points) * 0.5)
 *         cdef list p = self.points
 */
  __pyx_v_ps = __pyx_v_self->_pointsize;

  /* "kivy\graphics\vertex_instructions.pyx":363
 *         cdef float t0, t1, t2, t3, t4, t5, t6, t7
 *         cdef float x, y, ps = self._pointsize
 *         cdef int i, iv, ii, count = <int>(len(self._points) * 0.5)             # <<<<<<<<<<<<<<
 *         cdef list p = self.points
 *         cdef list tc = self._tex_coords
 */
  __pyx_t_1 = ((PyObject *)__pyx_v_self->_points);
  __Pyx_INCREF(__pyx_t_1);
  if (unlikely(__pyx_t_1 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 363; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); 
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_count = ((int)(__pyx_t_2 * 0.5));

  /* "kivy\graphics\vertex_instructions.pyx":364
 *         cdef float x, y, ps = self._pointsize
 *         cdef int i, iv, ii, count = <int>(len(self._points) * 0.5)
 *         cdef list p = self.points             # <<<<<<<<<<<<<<
 *         cdef list tc = self._tex_coords
 *         cdef vertex_t *vertices = NULL
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyList_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_1)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_p = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":365
 *         cdef int i, iv, ii, count = <int>(len(self._points) * 0.5)
 *         cdef list p = self.points
 *         cdef list tc = self._tex_coords             # <<<<<<<<<<<<<<
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base._tex_coords));
  __pyx_v_tc = __pyx_v_self->__pyx_base._tex_coords;

  /* "kivy\graphics\vertex_instructions.pyx":366
 *         cdef list p = self.points
 *         cdef list tc = self._tex_coords
 *         cdef vertex_t *vertices = NULL             # <<<<<<<<<<<<<<
 *         cdef unsigned short *indices = NULL
 * 
 */
  __pyx_v_vertices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":367
 *         cdef list tc = self._tex_coords
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL             # <<<<<<<<<<<<<<
 * 
 *         #if there is no points...nothing to do
 */
  __pyx_v_indices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":370
 * 
 *         #if there is no points...nothing to do
 *         if count < 1:             # <<<<<<<<<<<<<<
 *             self.batch.clear_data()
 *             return
 */
  __pyx_t_3 = (__pyx_v_count < 1);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":371
 *         #if there is no points...nothing to do
 *         if count < 1:
 *             self.batch.clear_data()             # <<<<<<<<<<<<<<
 *             return
 * 
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->clear_data(__pyx_v_self->__pyx_base.batch);

    /* "kivy\graphics\vertex_instructions.pyx":372
 *         if count < 1:
 *             self.batch.clear_data()
 *             return             # <<<<<<<<<<<<<<
 * 
 *         vertices = <vertex_t *>malloc(count * 4 * sizeof(vertex_t))
 */
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":374
 *             return
 * 
 *         vertices = <vertex_t *>malloc(count * 4 * sizeof(vertex_t))             # <<<<<<<<<<<<<<
 *         if vertices == NULL:
 *             raise MemoryError('vertices')
 */
  __pyx_v_vertices = ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)malloc(((__pyx_v_count * 4) * (sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)))));

  /* "kivy\graphics\vertex_instructions.pyx":375
 * 
 *         vertices = <vertex_t *>malloc(count * 4 * sizeof(vertex_t))
 *         if vertices == NULL:             # <<<<<<<<<<<<<<
 *             raise MemoryError('vertices')
 * 
 */
  __pyx_t_3 = (__pyx_v_vertices == NULL);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":376
 *         vertices = <vertex_t *>malloc(count * 4 * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(count * 6 * sizeof(unsigned short))
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_34), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 376; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 376; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "kivy\graphics\vertex_instructions.pyx":378
 *             raise MemoryError('vertices')
 * 
 *         indices = <unsigned short *>malloc(count * 6 * sizeof(unsigned short))             # <<<<<<<<<<<<<<
 *         if indices == NULL:
 *             free(vertices)
 */
  __pyx_v_indices = ((unsigned short *)malloc(((__pyx_v_count * 6) * (sizeof(unsigned short)))));

  /* "kivy\graphics\vertex_instructions.pyx":379
 * 
 *         indices = <unsigned short *>malloc(count * 6 * sizeof(unsigned short))
 *         if indices == NULL:             # <<<<<<<<<<<<<<
 *             free(vertices)
 *             raise MemoryError('indices')
 */
  __pyx_t_3 = (__pyx_v_indices == NULL);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":380
 *         indices = <unsigned short *>malloc(count * 6 * sizeof(unsigned short))
 *         if indices == NULL:
 *             free(vertices)             # <<<<<<<<<<<<<<
 *             raise MemoryError('indices')
 * 
 */
    free(__pyx_v_vertices);

    /* "kivy\graphics\vertex_instructions.pyx":381
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_35), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "kivy\graphics\vertex_instructions.pyx":383
 *             raise MemoryError('indices')
 * 
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc             # <<<<<<<<<<<<<<
 * 
 *         for i in xrange(count):
 */
  #if CYTHON_COMPILING_IN_CPYTHON
  if (PyList_CheckExact(((PyObject *)__pyx_v_tc))) {
    PyObject* sequence = ((PyObject *)__pyx_v_tc);
    PyObject** temps[8] = {&__pyx_t_1,&__pyx_t_4,&__pyx_t_5,&__pyx_t_6,&__pyx_t_7,&__pyx_t_8,&__pyx_t_9,&__pyx_t_10};
    if (unlikely(PyList_GET_SIZE(sequence) != 8)) {
      if (PyList_GET_SIZE(sequence) > 8) __Pyx_RaiseTooManyValuesError(8);
      else __Pyx_RaiseNeedMoreValuesError(PyList_GET_SIZE(sequence));
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    for (__pyx_t_2=0; __pyx_t_2 < 8; __pyx_t_2++) {
      PyObject* item = PyList_GET_ITEM(sequence, __pyx_t_2);
      *(temps[__pyx_t_2]) = item;
      __Pyx_INCREF(item);
    }
  } else
  #endif
  {
    Py_ssize_t index = -1;
    PyObject** temps[8] = {&__pyx_t_1,&__pyx_t_4,&__pyx_t_5,&__pyx_t_6,&__pyx_t_7,&__pyx_t_8,&__pyx_t_9,&__pyx_t_10};
    __pyx_t_11 = PyObject_GetIter(((PyObject *)__pyx_v_tc)); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_11);
    __pyx_t_12 = Py_TYPE(__pyx_t_11)->tp_iternext;
    for (index=0; index < 8; index++) {
      PyObject* item = __pyx_t_12(__pyx_t_11); if (unlikely(!item)) goto __pyx_L6_unpacking_failed;
      __Pyx_GOTREF(item);
      *(temps[index]) = item;
    }
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_12(__pyx_t_11), 8) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_12 = NULL;
    __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
    goto __pyx_L7_unpacking_done;
    __pyx_L6_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
    __pyx_t_12 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_L7_unpacking_done:;
  }
  __pyx_t_13 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_13 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_14 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_14 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_15 = __pyx_PyFloat_AsFloat(__pyx_t_5); if (unlikely((__pyx_t_15 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  __pyx_t_16 = __pyx_PyFloat_AsFloat(__pyx_t_6); if (unlikely((__pyx_t_16 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_7); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  __pyx_t_18 = __pyx_PyFloat_AsFloat(__pyx_t_8); if (unlikely((__pyx_t_18 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  __pyx_t_19 = __pyx_PyFloat_AsFloat(__pyx_t_9); if (unlikely((__pyx_t_19 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  __pyx_t_20 = __pyx_PyFloat_AsFloat(__pyx_t_10); if (unlikely((__pyx_t_20 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
  __pyx_v_t0 = __pyx_t_13;
  __pyx_v_t1 = __pyx_t_14;
  __pyx_v_t2 = __pyx_t_15;
  __pyx_v_t3 = __pyx_t_16;
  __pyx_v_t4 = __pyx_t_17;
  __pyx_v_t5 = __pyx_t_18;
  __pyx_v_t6 = __pyx_t_19;
  __pyx_v_t7 = __pyx_t_20;

  /* "kivy\graphics\vertex_instructions.pyx":385
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc
 * 
 *         for i in xrange(count):             # <<<<<<<<<<<<<<
 *             x = p[i * 2]
 *             y = p[i * 2 + 1]
 */
  __pyx_t_21 = __pyx_v_count;
  for (__pyx_t_22 = 0; __pyx_t_22 < __pyx_t_21; __pyx_t_22+=1) {
    __pyx_v_i = __pyx_t_22;

    /* "kivy\graphics\vertex_instructions.pyx":386
 * 
 *         for i in xrange(count):
 *             x = p[i * 2]             # <<<<<<<<<<<<<<
 *             y = p[i * 2 + 1]
 *             iv = i * 4
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_23 = (__pyx_v_i * 2);
    __pyx_t_10 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_23, sizeof(long), PyInt_FromLong); if (!__pyx_t_10) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_10);
    __pyx_t_20 = __pyx_PyFloat_AsFloat(__pyx_t_10); if (unlikely((__pyx_t_20 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 386; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
    __pyx_v_x = __pyx_t_20;

    /* "kivy\graphics\vertex_instructions.pyx":387
 *         for i in xrange(count):
 *             x = p[i * 2]
 *             y = p[i * 2 + 1]             # <<<<<<<<<<<<<<
 *             iv = i * 4
 *             vertices[iv].x = x - ps
 */
    if (unlikely(((PyObject *)__pyx_v_p) == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_23 = ((__pyx_v_i * 2) + 1);
    __pyx_t_10 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_p), __pyx_t_23, sizeof(long), PyInt_FromLong); if (!__pyx_t_10) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_10);
    __pyx_t_20 = __pyx_PyFloat_AsFloat(__pyx_t_10); if (unlikely((__pyx_t_20 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
    __pyx_v_y = __pyx_t_20;

    /* "kivy\graphics\vertex_instructions.pyx":388
 *             x = p[i * 2]
 *             y = p[i * 2 + 1]
 *             iv = i * 4             # <<<<<<<<<<<<<<
 *             vertices[iv].x = x - ps
 *             vertices[iv].y = y - ps
 */
    __pyx_v_iv = (__pyx_v_i * 4);

    /* "kivy\graphics\vertex_instructions.pyx":389
 *             y = p[i * 2 + 1]
 *             iv = i * 4
 *             vertices[iv].x = x - ps             # <<<<<<<<<<<<<<
 *             vertices[iv].y = y - ps
 *             vertices[iv].s0 = t0
 */
    (__pyx_v_vertices[__pyx_v_iv]).x = (__pyx_v_x - __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":390
 *             iv = i * 4
 *             vertices[iv].x = x - ps
 *             vertices[iv].y = y - ps             # <<<<<<<<<<<<<<
 *             vertices[iv].s0 = t0
 *             vertices[iv].t0 = t1
 */
    (__pyx_v_vertices[__pyx_v_iv]).y = (__pyx_v_y - __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":391
 *             vertices[iv].x = x - ps
 *             vertices[iv].y = y - ps
 *             vertices[iv].s0 = t0             # <<<<<<<<<<<<<<
 *             vertices[iv].t0 = t1
 *             vertices[iv + 1].x = x + ps
 */
    (__pyx_v_vertices[__pyx_v_iv]).s0 = __pyx_v_t0;

    /* "kivy\graphics\vertex_instructions.pyx":392
 *             vertices[iv].y = y - ps
 *             vertices[iv].s0 = t0
 *             vertices[iv].t0 = t1             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].x = x + ps
 *             vertices[iv + 1].y = y - ps
 */
    (__pyx_v_vertices[__pyx_v_iv]).t0 = __pyx_v_t1;

    /* "kivy\graphics\vertex_instructions.pyx":393
 *             vertices[iv].s0 = t0
 *             vertices[iv].t0 = t1
 *             vertices[iv + 1].x = x + ps             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].y = y - ps
 *             vertices[iv + 1].s0 = t2
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).x = (__pyx_v_x + __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":394
 *             vertices[iv].t0 = t1
 *             vertices[iv + 1].x = x + ps
 *             vertices[iv + 1].y = y - ps             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].s0 = t2
 *             vertices[iv + 1].t0 = t3
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).y = (__pyx_v_y - __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":395
 *             vertices[iv + 1].x = x + ps
 *             vertices[iv + 1].y = y - ps
 *             vertices[iv + 1].s0 = t2             # <<<<<<<<<<<<<<
 *             vertices[iv + 1].t0 = t3
 *             vertices[iv + 2].x = x + ps
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).s0 = __pyx_v_t2;

    /* "kivy\graphics\vertex_instructions.pyx":396
 *             vertices[iv + 1].y = y - ps
 *             vertices[iv + 1].s0 = t2
 *             vertices[iv + 1].t0 = t3             # <<<<<<<<<<<<<<
 *             vertices[iv + 2].x = x + ps
 *             vertices[iv + 2].y = y + ps
 */
    (__pyx_v_vertices[(__pyx_v_iv + 1)]).t0 = __pyx_v_t3;

    /* "kivy\graphics\vertex_instructions.pyx":397
 *             vertices[iv + 1].s0 = t2
 *             vertices[iv + 1].t0 = t3
 *             vertices[iv + 2].x = x + ps             # <<<<<<<<<<<<<<
 *             vertices[iv + 2].y = y + ps
 *             vertices[iv + 2].s0 = t4
 */
    (__pyx_v_vertices[(__pyx_v_iv + 2)]).x = (__pyx_v_x + __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":398
 *             vertices[iv + 1].t0 = t3
 *             vertices[iv + 2].x = x + ps
 *             vertices[iv + 2].y = y + ps             # <<<<<<<<<<<<<<
 *             vertices[iv + 2].s0 = t4
 *             vertices[iv + 2].t0 = t5
 */
    (__pyx_v_vertices[(__pyx_v_iv + 2)]).y = (__pyx_v_y + __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":399
 *             vertices[iv + 2].x = x + ps
 *             vertices[iv + 2].y = y + ps
 *             vertices[iv + 2].s0 = t4             # <<<<<<<<<<<<<<
 *             vertices[iv + 2].t0 = t5
 *             vertices[iv + 3].x = x - ps
 */
    (__pyx_v_vertices[(__pyx_v_iv + 2)]).s0 = __pyx_v_t4;

    /* "kivy\graphics\vertex_instructions.pyx":400
 *             vertices[iv + 2].y = y + ps
 *             vertices[iv + 2].s0 = t4
 *             vertices[iv + 2].t0 = t5             # <<<<<<<<<<<<<<
 *             vertices[iv + 3].x = x - ps
 *             vertices[iv + 3].y = y + ps
 */
    (__pyx_v_vertices[(__pyx_v_iv + 2)]).t0 = __pyx_v_t5;

    /* "kivy\graphics\vertex_instructions.pyx":401
 *             vertices[iv + 2].s0 = t4
 *             vertices[iv + 2].t0 = t5
 *             vertices[iv + 3].x = x - ps             # <<<<<<<<<<<<<<
 *             vertices[iv + 3].y = y + ps
 *             vertices[iv + 3].s0 = t6
 */
    (__pyx_v_vertices[(__pyx_v_iv + 3)]).x = (__pyx_v_x - __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":402
 *             vertices[iv + 2].t0 = t5
 *             vertices[iv + 3].x = x - ps
 *             vertices[iv + 3].y = y + ps             # <<<<<<<<<<<<<<
 *             vertices[iv + 3].s0 = t6
 *             vertices[iv + 3].t0 = t7
 */
    (__pyx_v_vertices[(__pyx_v_iv + 3)]).y = (__pyx_v_y + __pyx_v_ps);

    /* "kivy\graphics\vertex_instructions.pyx":403
 *             vertices[iv + 3].x = x - ps
 *             vertices[iv + 3].y = y + ps
 *             vertices[iv + 3].s0 = t6             # <<<<<<<<<<<<<<
 *             vertices[iv + 3].t0 = t7
 * 
 */
    (__pyx_v_vertices[(__pyx_v_iv + 3)]).s0 = __pyx_v_t6;

    /* "kivy\graphics\vertex_instructions.pyx":404
 *             vertices[iv + 3].y = y + ps
 *             vertices[iv + 3].s0 = t6
 *             vertices[iv + 3].t0 = t7             # <<<<<<<<<<<<<<
 * 
 *             ii = i * 6
 */
    (__pyx_v_vertices[(__pyx_v_iv + 3)]).t0 = __pyx_v_t7;

    /* "kivy\graphics\vertex_instructions.pyx":406
 *             vertices[iv + 3].t0 = t7
 * 
 *             ii = i * 6             # <<<<<<<<<<<<<<
 *             indices[ii] = iv
 *             indices[ii + 1] = iv + 1
 */
    __pyx_v_ii = (__pyx_v_i * 6);

    /* "kivy\graphics\vertex_instructions.pyx":407
 * 
 *             ii = i * 6
 *             indices[ii] = iv             # <<<<<<<<<<<<<<
 *             indices[ii + 1] = iv + 1
 *             indices[ii + 2] = iv + 2
 */
    (__pyx_v_indices[__pyx_v_ii]) = __pyx_v_iv;

    /* "kivy\graphics\vertex_instructions.pyx":408
 *             ii = i * 6
 *             indices[ii] = iv
 *             indices[ii + 1] = iv + 1             # <<<<<<<<<<<<<<
 *             indices[ii + 2] = iv + 2
 *             indices[ii + 3] = iv + 2
 */
    (__pyx_v_indices[(__pyx_v_ii + 1)]) = (__pyx_v_iv + 1);

    /* "kivy\graphics\vertex_instructions.pyx":409
 *             indices[ii] = iv
 *             indices[ii + 1] = iv + 1
 *             indices[ii + 2] = iv + 2             # <<<<<<<<<<<<<<
 *             indices[ii + 3] = iv + 2
 *             indices[ii + 4] = iv + 3
 */
    (__pyx_v_indices[(__pyx_v_ii + 2)]) = (__pyx_v_iv + 2);

    /* "kivy\graphics\vertex_instructions.pyx":410
 *             indices[ii + 1] = iv + 1
 *             indices[ii + 2] = iv + 2
 *             indices[ii + 3] = iv + 2             # <<<<<<<<<<<<<<
 *             indices[ii + 4] = iv + 3
 *             indices[ii + 5] = iv
 */
    (__pyx_v_indices[(__pyx_v_ii + 3)]) = (__pyx_v_iv + 2);

    /* "kivy\graphics\vertex_instructions.pyx":411
 *             indices[ii + 2] = iv + 2
 *             indices[ii + 3] = iv + 2
 *             indices[ii + 4] = iv + 3             # <<<<<<<<<<<<<<
 *             indices[ii + 5] = iv
 * 
 */
    (__pyx_v_indices[(__pyx_v_ii + 4)]) = (__pyx_v_iv + 3);

    /* "kivy\graphics\vertex_instructions.pyx":412
 *             indices[ii + 3] = iv + 2
 *             indices[ii + 4] = iv + 3
 *             indices[ii + 5] = iv             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, count * 4, indices, count * 6)
 */
    (__pyx_v_indices[(__pyx_v_ii + 5)]) = __pyx_v_iv;
  }

  /* "kivy\graphics\vertex_instructions.pyx":414
 *             indices[ii + 5] = iv
 * 
 *         self.batch.set_data(vertices, count * 4, indices, count * 6)             # <<<<<<<<<<<<<<
 * 
 *         free(vertices)
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, (__pyx_v_count * 4), __pyx_v_indices, (__pyx_v_count * 6));

  /* "kivy\graphics\vertex_instructions.pyx":416
 *         self.batch.set_data(vertices, count * 4, indices, count * 6)
 * 
 *         free(vertices)             # <<<<<<<<<<<<<<
 *         free(indices)
 * 
 */
  free(__pyx_v_vertices);

  /* "kivy\graphics\vertex_instructions.pyx":417
 * 
 *         free(vertices)
 *         free(indices)             # <<<<<<<<<<<<<<
 * 
 *     def add_point(self, float x, float y):
 */
  free(__pyx_v_indices);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_XDECREF(__pyx_t_11);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Point.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_p);
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_3add_point(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static char __pyx_doc_4kivy_8graphics_19vertex_instructions_5Point_2add_point[] = "Add a point into the current :data:`points` list.\n\n        If you intend to add multiple point, prefer to use this method, instead\n        of reassign a new :data:`points` list. Assigning a new :data:`points`\n        list will recalculate and reupload the whole buffer into GPU.\n        If you use add_point, it will only upload the changes.\n        ";
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_3add_point(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  float __pyx_v_x;
  float __pyx_v_y;
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("add_point (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s__x,&__pyx_n_s__y,0};
    PyObject* values[2] = {0,0};
    if (unlikely(__pyx_kwds)) {
      Py_ssize_t kw_args;
      const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
      switch (pos_args) {
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s__x)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        case  1:
        if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s__y)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("add_point", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "add_point") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
      values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
    }
    __pyx_v_x = __pyx_PyFloat_AsFloat(values[0]); if (unlikely((__pyx_v_x == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
    __pyx_v_y = __pyx_PyFloat_AsFloat(values[1]); if (unlikely((__pyx_v_y == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("add_point", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
  __pyx_L3_error:;
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Point.add_point", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return NULL;
  __pyx_L4_argument_unpacking_done:;
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_2add_point(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self), __pyx_v_x, __pyx_v_y);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":419
 *         free(indices)
 * 
 *     def add_point(self, float x, float y):             # <<<<<<<<<<<<<<
 *         '''Add a point into the current :data:`points` list.
 * 
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_2add_point(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, float __pyx_v_x, float __pyx_v_y) {
  float __pyx_v_t0;
  float __pyx_v_t1;
  float __pyx_v_t2;
  float __pyx_v_t3;
  float __pyx_v_t4;
  float __pyx_v_t5;
  float __pyx_v_t6;
  float __pyx_v_t7;
  float __pyx_v_ps;
  int __pyx_v_iv;
  int __pyx_v_count;
  PyObject *__pyx_v_tc = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t __pyx_v_vertices[4];
  unsigned short __pyx_v_indices[6];
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  Py_ssize_t __pyx_t_2;
  int __pyx_t_3;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  PyObject *__pyx_t_11 = NULL;
  PyObject *__pyx_t_12 = NULL;
  PyObject *(*__pyx_t_13)(PyObject *);
  float __pyx_t_14;
  float __pyx_t_15;
  float __pyx_t_16;
  float __pyx_t_17;
  float __pyx_t_18;
  float __pyx_t_19;
  float __pyx_t_20;
  float __pyx_t_21;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("add_point", 0);

  /* "kivy\graphics\vertex_instructions.pyx":428
 *         '''
 *         cdef float t0, t1, t2, t3, t4, t5, t6, t7
 *         cdef float ps = self._pointsize             # <<<<<<<<<<<<<<
 *         cdef int iv, count = <int>(len(self._points) * 0.5)
 *         cdef list tc = self._tex_coords
 */
  __pyx_v_ps = __pyx_v_self->_pointsize;

  /* "kivy\graphics\vertex_instructions.pyx":429
 *         cdef float t0, t1, t2, t3, t4, t5, t6, t7
 *         cdef float ps = self._pointsize
 *         cdef int iv, count = <int>(len(self._points) * 0.5)             # <<<<<<<<<<<<<<
 *         cdef list tc = self._tex_coords
 *         cdef vertex_t vertices[4]
 */
  __pyx_t_1 = ((PyObject *)__pyx_v_self->_points);
  __Pyx_INCREF(__pyx_t_1);
  if (unlikely(__pyx_t_1 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 429; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); 
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_count = ((int)(__pyx_t_2 * 0.5));

  /* "kivy\graphics\vertex_instructions.pyx":430
 *         cdef float ps = self._pointsize
 *         cdef int iv, count = <int>(len(self._points) * 0.5)
 *         cdef list tc = self._tex_coords             # <<<<<<<<<<<<<<
 *         cdef vertex_t vertices[4]
 *         cdef unsigned short indices[6]
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base._tex_coords));
  __pyx_v_tc = __pyx_v_self->__pyx_base._tex_coords;

  /* "kivy\graphics\vertex_instructions.pyx":434
 *         cdef unsigned short indices[6]
 * 
 *         if len(self._points) > 2**15 - 2:             # <<<<<<<<<<<<<<
 *             raise GraphicException('Cannot add elements (limit is 2^15-2)')
 * 
 */
  __pyx_t_1 = ((PyObject *)__pyx_v_self->_points);
  __Pyx_INCREF(__pyx_t_1);
  if (unlikely(__pyx_t_1 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); 
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_3 = (__pyx_t_2 > 32766);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":435
 * 
 *         if len(self._points) > 2**15 - 2:
 *             raise GraphicException('Cannot add elements (limit is 2^15-2)')             # <<<<<<<<<<<<<<
 * 
 *         self._points.append(x)
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_k_tuple_37), NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_4, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":437
 *             raise GraphicException('Cannot add elements (limit is 2^15-2)')
 * 
 *         self._points.append(x)             # <<<<<<<<<<<<<<
 *         self._points.append(y)
 * 
 */
  if (unlikely(((PyObject *)__pyx_v_self->_points) == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "append");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 437; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = PyFloat_FromDouble(__pyx_v_x); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 437; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = PyList_Append(__pyx_v_self->_points, __pyx_t_4); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 437; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":438
 * 
 *         self._points.append(x)
 *         self._points.append(y)             # <<<<<<<<<<<<<<
 * 
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc
 */
  if (unlikely(((PyObject *)__pyx_v_self->_points) == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "append");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = PyFloat_FromDouble(__pyx_v_y); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = PyList_Append(__pyx_v_self->_points, __pyx_t_4); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":440
 *         self._points.append(y)
 * 
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc             # <<<<<<<<<<<<<<
 *         vertices[0].x = x - ps
 *         vertices[0].y = y - ps
 */
  #if CYTHON_COMPILING_IN_CPYTHON
  if (PyList_CheckExact(((PyObject *)__pyx_v_tc))) {
    PyObject* sequence = ((PyObject *)__pyx_v_tc);
    PyObject** temps[8] = {&__pyx_t_4,&__pyx_t_1,&__pyx_t_6,&__pyx_t_7,&__pyx_t_8,&__pyx_t_9,&__pyx_t_10,&__pyx_t_11};
    if (unlikely(PyList_GET_SIZE(sequence) != 8)) {
      if (PyList_GET_SIZE(sequence) > 8) __Pyx_RaiseTooManyValuesError(8);
      else __Pyx_RaiseNeedMoreValuesError(PyList_GET_SIZE(sequence));
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    for (__pyx_t_2=0; __pyx_t_2 < 8; __pyx_t_2++) {
      PyObject* item = PyList_GET_ITEM(sequence, __pyx_t_2);
      *(temps[__pyx_t_2]) = item;
      __Pyx_INCREF(item);
    }
  } else
  #endif
  {
    Py_ssize_t index = -1;
    PyObject** temps[8] = {&__pyx_t_4,&__pyx_t_1,&__pyx_t_6,&__pyx_t_7,&__pyx_t_8,&__pyx_t_9,&__pyx_t_10,&__pyx_t_11};
    __pyx_t_12 = PyObject_GetIter(((PyObject *)__pyx_v_tc)); if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_12);
    __pyx_t_13 = Py_TYPE(__pyx_t_12)->tp_iternext;
    for (index=0; index < 8; index++) {
      PyObject* item = __pyx_t_13(__pyx_t_12); if (unlikely(!item)) goto __pyx_L4_unpacking_failed;
      __Pyx_GOTREF(item);
      *(temps[index]) = item;
    }
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_13(__pyx_t_12), 8) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_13 = NULL;
    __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
    goto __pyx_L5_unpacking_done;
    __pyx_L4_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;
    __pyx_t_13 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_L5_unpacking_done:;
  }
  __pyx_t_14 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_14 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_15 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_15 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_16 = __pyx_PyFloat_AsFloat(__pyx_t_6); if (unlikely((__pyx_t_16 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_7); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  __pyx_t_18 = __pyx_PyFloat_AsFloat(__pyx_t_8); if (unlikely((__pyx_t_18 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  __pyx_t_19 = __pyx_PyFloat_AsFloat(__pyx_t_9); if (unlikely((__pyx_t_19 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  __pyx_t_20 = __pyx_PyFloat_AsFloat(__pyx_t_10); if (unlikely((__pyx_t_20 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
  __pyx_t_21 = __pyx_PyFloat_AsFloat(__pyx_t_11); if (unlikely((__pyx_t_21 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
  __pyx_v_t0 = __pyx_t_14;
  __pyx_v_t1 = __pyx_t_15;
  __pyx_v_t2 = __pyx_t_16;
  __pyx_v_t3 = __pyx_t_17;
  __pyx_v_t4 = __pyx_t_18;
  __pyx_v_t5 = __pyx_t_19;
  __pyx_v_t6 = __pyx_t_20;
  __pyx_v_t7 = __pyx_t_21;

  /* "kivy\graphics\vertex_instructions.pyx":441
 * 
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc
 *         vertices[0].x = x - ps             # <<<<<<<<<<<<<<
 *         vertices[0].y = y - ps
 *         vertices[0].s0 = t0
 */
  (__pyx_v_vertices[0]).x = (__pyx_v_x - __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":442
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc
 *         vertices[0].x = x - ps
 *         vertices[0].y = y - ps             # <<<<<<<<<<<<<<
 *         vertices[0].s0 = t0
 *         vertices[0].t0 = t1
 */
  (__pyx_v_vertices[0]).y = (__pyx_v_y - __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":443
 *         vertices[0].x = x - ps
 *         vertices[0].y = y - ps
 *         vertices[0].s0 = t0             # <<<<<<<<<<<<<<
 *         vertices[0].t0 = t1
 *         vertices[1].x = x + ps
 */
  (__pyx_v_vertices[0]).s0 = __pyx_v_t0;

  /* "kivy\graphics\vertex_instructions.pyx":444
 *         vertices[0].y = y - ps
 *         vertices[0].s0 = t0
 *         vertices[0].t0 = t1             # <<<<<<<<<<<<<<
 *         vertices[1].x = x + ps
 *         vertices[1].y = y - ps
 */
  (__pyx_v_vertices[0]).t0 = __pyx_v_t1;

  /* "kivy\graphics\vertex_instructions.pyx":445
 *         vertices[0].s0 = t0
 *         vertices[0].t0 = t1
 *         vertices[1].x = x + ps             # <<<<<<<<<<<<<<
 *         vertices[1].y = y - ps
 *         vertices[1].s0 = t2
 */
  (__pyx_v_vertices[1]).x = (__pyx_v_x + __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":446
 *         vertices[0].t0 = t1
 *         vertices[1].x = x + ps
 *         vertices[1].y = y - ps             # <<<<<<<<<<<<<<
 *         vertices[1].s0 = t2
 *         vertices[1].t0 = t3
 */
  (__pyx_v_vertices[1]).y = (__pyx_v_y - __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":447
 *         vertices[1].x = x + ps
 *         vertices[1].y = y - ps
 *         vertices[1].s0 = t2             # <<<<<<<<<<<<<<
 *         vertices[1].t0 = t3
 *         vertices[2].x = x + ps
 */
  (__pyx_v_vertices[1]).s0 = __pyx_v_t2;

  /* "kivy\graphics\vertex_instructions.pyx":448
 *         vertices[1].y = y - ps
 *         vertices[1].s0 = t2
 *         vertices[1].t0 = t3             # <<<<<<<<<<<<<<
 *         vertices[2].x = x + ps
 *         vertices[2].y = y + ps
 */
  (__pyx_v_vertices[1]).t0 = __pyx_v_t3;

  /* "kivy\graphics\vertex_instructions.pyx":449
 *         vertices[1].s0 = t2
 *         vertices[1].t0 = t3
 *         vertices[2].x = x + ps             # <<<<<<<<<<<<<<
 *         vertices[2].y = y + ps
 *         vertices[2].s0 = t4
 */
  (__pyx_v_vertices[2]).x = (__pyx_v_x + __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":450
 *         vertices[1].t0 = t3
 *         vertices[2].x = x + ps
 *         vertices[2].y = y + ps             # <<<<<<<<<<<<<<
 *         vertices[2].s0 = t4
 *         vertices[2].t0 = t5
 */
  (__pyx_v_vertices[2]).y = (__pyx_v_y + __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":451
 *         vertices[2].x = x + ps
 *         vertices[2].y = y + ps
 *         vertices[2].s0 = t4             # <<<<<<<<<<<<<<
 *         vertices[2].t0 = t5
 *         vertices[3].x = x - ps
 */
  (__pyx_v_vertices[2]).s0 = __pyx_v_t4;

  /* "kivy\graphics\vertex_instructions.pyx":452
 *         vertices[2].y = y + ps
 *         vertices[2].s0 = t4
 *         vertices[2].t0 = t5             # <<<<<<<<<<<<<<
 *         vertices[3].x = x - ps
 *         vertices[3].y = y + ps
 */
  (__pyx_v_vertices[2]).t0 = __pyx_v_t5;

  /* "kivy\graphics\vertex_instructions.pyx":453
 *         vertices[2].s0 = t4
 *         vertices[2].t0 = t5
 *         vertices[3].x = x - ps             # <<<<<<<<<<<<<<
 *         vertices[3].y = y + ps
 *         vertices[3].s0 = t6
 */
  (__pyx_v_vertices[3]).x = (__pyx_v_x - __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":454
 *         vertices[2].t0 = t5
 *         vertices[3].x = x - ps
 *         vertices[3].y = y + ps             # <<<<<<<<<<<<<<
 *         vertices[3].s0 = t6
 *         vertices[3].t0 = t7
 */
  (__pyx_v_vertices[3]).y = (__pyx_v_y + __pyx_v_ps);

  /* "kivy\graphics\vertex_instructions.pyx":455
 *         vertices[3].x = x - ps
 *         vertices[3].y = y + ps
 *         vertices[3].s0 = t6             # <<<<<<<<<<<<<<
 *         vertices[3].t0 = t7
 * 
 */
  (__pyx_v_vertices[3]).s0 = __pyx_v_t6;

  /* "kivy\graphics\vertex_instructions.pyx":456
 *         vertices[3].y = y + ps
 *         vertices[3].s0 = t6
 *         vertices[3].t0 = t7             # <<<<<<<<<<<<<<
 * 
 *         iv = count * 4
 */
  (__pyx_v_vertices[3]).t0 = __pyx_v_t7;

  /* "kivy\graphics\vertex_instructions.pyx":458
 *         vertices[3].t0 = t7
 * 
 *         iv = count * 4             # <<<<<<<<<<<<<<
 *         indices[0] = iv
 *         indices[1] = iv + 1
 */
  __pyx_v_iv = (__pyx_v_count * 4);

  /* "kivy\graphics\vertex_instructions.pyx":459
 * 
 *         iv = count * 4
 *         indices[0] = iv             # <<<<<<<<<<<<<<
 *         indices[1] = iv + 1
 *         indices[2] = iv + 2
 */
  (__pyx_v_indices[0]) = __pyx_v_iv;

  /* "kivy\graphics\vertex_instructions.pyx":460
 *         iv = count * 4
 *         indices[0] = iv
 *         indices[1] = iv + 1             # <<<<<<<<<<<<<<
 *         indices[2] = iv + 2
 *         indices[3] = iv + 2
 */
  (__pyx_v_indices[1]) = (__pyx_v_iv + 1);

  /* "kivy\graphics\vertex_instructions.pyx":461
 *         indices[0] = iv
 *         indices[1] = iv + 1
 *         indices[2] = iv + 2             # <<<<<<<<<<<<<<
 *         indices[3] = iv + 2
 *         indices[4] = iv + 3
 */
  (__pyx_v_indices[2]) = (__pyx_v_iv + 2);

  /* "kivy\graphics\vertex_instructions.pyx":462
 *         indices[1] = iv + 1
 *         indices[2] = iv + 2
 *         indices[3] = iv + 2             # <<<<<<<<<<<<<<
 *         indices[4] = iv + 3
 *         indices[5] = iv
 */
  (__pyx_v_indices[3]) = (__pyx_v_iv + 2);

  /* "kivy\graphics\vertex_instructions.pyx":463
 *         indices[2] = iv + 2
 *         indices[3] = iv + 2
 *         indices[4] = iv + 3             # <<<<<<<<<<<<<<
 *         indices[5] = iv
 * 
 */
  (__pyx_v_indices[4]) = (__pyx_v_iv + 3);

  /* "kivy\graphics\vertex_instructions.pyx":464
 *         indices[3] = iv + 2
 *         indices[4] = iv + 3
 *         indices[5] = iv             # <<<<<<<<<<<<<<
 * 
 *         # append the vertices / indices to current vertex batch
 */
  (__pyx_v_indices[5]) = __pyx_v_iv;

  /* "kivy\graphics\vertex_instructions.pyx":467
 * 
 *         # append the vertices / indices to current vertex batch
 *         self.batch.append_data(vertices, 4, indices, 6)             # <<<<<<<<<<<<<<
 * 
 *         if self.parent is not None:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->append_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, 4, __pyx_v_indices, 6);

  /* "kivy\graphics\vertex_instructions.pyx":469
 *         self.batch.append_data(vertices, 4, indices, 6)
 * 
 *         if self.parent is not None:             # <<<<<<<<<<<<<<
 *             self.parent.flag_update()
 * 
 */
  __pyx_t_3 = (((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.parent) != Py_None);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":470
 * 
 *         if self.parent is not None:
 *             self.parent.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property points:
 */
    ((struct __pyx_vtabstruct_4kivy_8graphics_12instructions_InstructionGroup *)__pyx_v_self->__pyx_base.__pyx_base.parent->__pyx_base.__pyx_vtab)->__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self->__pyx_base.__pyx_base.parent), NULL);
    goto __pyx_L6;
  }
  __pyx_L6:;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_XDECREF(__pyx_t_11);
  __Pyx_XDECREF(__pyx_t_12);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Point.add_point", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_6points_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_6points_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_6points___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":475
 *         '''Property for getting/settings points of the triangle
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._points
 *         def __set__(self, points):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":476
 *         '''
 *         def __get__(self):
 *             return self._points             # <<<<<<<<<<<<<<
 *         def __set__(self, points):
 *             if self._points == points:
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_points));
  __pyx_r = ((PyObject *)__pyx_v_self->_points);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_6points_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self), ((PyObject *)__pyx_v_points));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":477
 *         def __get__(self):
 *             return self._points
 *         def __set__(self, points):             # <<<<<<<<<<<<<<
 *             if self._points == points:
 *                 return
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, PyObject *__pyx_v_points) {
  PyObject *__pyx_v__points = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  Py_ssize_t __pyx_t_4;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":478
 *             return self._points
 *         def __set__(self, points):
 *             if self._points == points:             # <<<<<<<<<<<<<<
 *                 return
 *             cdef list _points = list(points)
 */
  __pyx_t_1 = PyObject_RichCompare(((PyObject *)__pyx_v_self->_points), __pyx_v_points, Py_EQ); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 478; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 478; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (__pyx_t_2) {

    /* "kivy\graphics\vertex_instructions.pyx":479
 *         def __set__(self, points):
 *             if self._points == points:
 *                 return             # <<<<<<<<<<<<<<
 *             cdef list _points = list(points)
 *             if len(_points) > 2**15-2:
 */
    __pyx_r = 0;
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":480
 *             if self._points == points:
 *                 return
 *             cdef list _points = list(points)             # <<<<<<<<<<<<<<
 *             if len(_points) > 2**15-2:
 *                 raise GraphicException('Too many elements (limit is 2^15-2)')
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_points);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_points);
  __Pyx_GIVEREF(__pyx_v_points);
  __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __pyx_v__points = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":481
 *                 return
 *             cdef list _points = list(points)
 *             if len(_points) > 2**15-2:             # <<<<<<<<<<<<<<
 *                 raise GraphicException('Too many elements (limit is 2^15-2)')
 *             self._points = list(points)
 */
  __pyx_t_4 = PyList_GET_SIZE(((PyObject *)__pyx_v__points)); 
  __pyx_t_2 = (__pyx_t_4 > 32766);
  if (__pyx_t_2) {

    /* "kivy\graphics\vertex_instructions.pyx":482
 *             cdef list _points = list(points)
 *             if len(_points) > 2**15-2:
 *                 raise GraphicException('Too many elements (limit is 2^15-2)')             # <<<<<<<<<<<<<<
 *             self._points = list(points)
 *             self.flag_update()
 */
    __pyx_t_3 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 482; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_1 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_k_tuple_39), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 482; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 482; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "kivy\graphics\vertex_instructions.pyx":483
 *             if len(_points) > 2**15-2:
 *                 raise GraphicException('Too many elements (limit is 2^15-2)')
 *             self._points = list(points)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 483; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_points);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_points);
  __Pyx_GIVEREF(__pyx_v_points);
  __pyx_t_3 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 483; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_3);
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":484
 *                 raise GraphicException('Too many elements (limit is 2^15-2)')
 *             self._points = list(points)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property pointsize:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Point.points.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v__points);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_9pointsize___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":489
 *         '''Property for getting/setting point size
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._pointsize
 *         def __set__(self, float pointsize):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_9pointsize___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":490
 *         '''
 *         def __get__(self):
 *             return self._pointsize             # <<<<<<<<<<<<<<
 *         def __set__(self, float pointsize):
 *             if self._pointsize == pointsize:
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->_pointsize); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 490; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Point.pointsize.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_arg_pointsize); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_arg_pointsize) {
  float __pyx_v_pointsize;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  assert(__pyx_arg_pointsize); {
    __pyx_v_pointsize = __pyx_PyFloat_AsFloat(__pyx_arg_pointsize); if (unlikely((__pyx_v_pointsize == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 491; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L3_error:;
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Point.pointsize.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return -1;
  __pyx_L4_argument_unpacking_done:;
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self), ((float)__pyx_v_pointsize));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":491
 *         def __get__(self):
 *             return self._pointsize
 *         def __set__(self, float pointsize):             # <<<<<<<<<<<<<<
 *             if self._pointsize == pointsize:
 *                 return
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *__pyx_v_self, float __pyx_v_pointsize) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":492
 *             return self._pointsize
 *         def __set__(self, float pointsize):
 *             if self._pointsize == pointsize:             # <<<<<<<<<<<<<<
 *                 return
 *             self._pointsize = pointsize
 */
  __pyx_t_1 = (__pyx_v_self->_pointsize == __pyx_v_pointsize);
  if (__pyx_t_1) {

    /* "kivy\graphics\vertex_instructions.pyx":493
 *         def __set__(self, float pointsize):
 *             if self._pointsize == pointsize:
 *                 return             # <<<<<<<<<<<<<<
 *             self._pointsize = pointsize
 *             self.flag_update()
 */
    __pyx_r = 0;
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":494
 *             if self._pointsize == pointsize:
 *                 return
 *             self._pointsize = pointsize             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_v_self->_pointsize = __pyx_v_pointsize;

  /* "kivy\graphics\vertex_instructions.pyx":495
 *                 return
 *             self._pointsize = pointsize
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Point *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":508
 *     cdef list _points
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":509
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else (0.0,0.0, 100.0,0.0, 50.0,100.0)
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 509; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 509; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 509; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":510
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')             # <<<<<<<<<<<<<<
 *         self.points = v if v is not None else (0.0,0.0, 100.0,0.0, 50.0,100.0)
 * 
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__points), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 510; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":511
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else (0.0,0.0, 100.0,0.0, 50.0,100.0)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __pyx_t_3 = PyFloat_FromDouble(0.0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_2 = PyFloat_FromDouble(0.0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_1 = PyFloat_FromDouble(100.0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_6 = PyFloat_FromDouble(0.0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_7 = PyFloat_FromDouble(50.0); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_8 = PyFloat_FromDouble(100.0); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_8);
    __pyx_t_9 = PyTuple_New(6); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_9);
    PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_3);
    __Pyx_GIVEREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_t_2);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_9, 2, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_9, 3, __pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_9, 4, __pyx_t_7);
    __Pyx_GIVEREF(__pyx_t_7);
    PyTuple_SET_ITEM(__pyx_t_9, 5, __pyx_t_8);
    __Pyx_GIVEREF(__pyx_t_8);
    __pyx_t_3 = 0;
    __pyx_t_2 = 0;
    __pyx_t_1 = 0;
    __pyx_t_6 = 0;
    __pyx_t_7 = 0;
    __pyx_t_8 = 0;
    __pyx_t_4 = ((PyObject *)__pyx_t_9);
    __pyx_t_9 = 0;
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Triangle.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":513
 *         self.points = v if v is not None else (0.0,0.0, 100.0,0.0, 50.0,100.0)
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef list vc, tc
 *         cdef vertex_t vertices[3]
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_8Triangle_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self) {
  PyObject *__pyx_v_vc = 0;
  PyObject *__pyx_v_tc = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t __pyx_v_vertices[3];
  unsigned short *__pyx_v_indices;
  __Pyx_RefNannyDeclarations
  unsigned short __pyx_t_1[3];
  PyObject *__pyx_t_2 = NULL;
  float __pyx_t_3;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":516
 *         cdef list vc, tc
 *         cdef vertex_t vertices[3]
 *         cdef unsigned short *indices = [0, 1, 2]             # <<<<<<<<<<<<<<
 * 
 *         vc = self.points;
 */
  __pyx_t_1[0] = 0;
  __pyx_t_1[1] = 1;
  __pyx_t_1[2] = 2;
  __pyx_v_indices = __pyx_t_1;

  /* "kivy\graphics\vertex_instructions.pyx":518
 *         cdef unsigned short *indices = [0, 1, 2]
 * 
 *         vc = self.points;             # <<<<<<<<<<<<<<
 *         tc = self._tex_coords
 * 
 */
  __pyx_t_2 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  if (!(likely(PyList_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_2)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_vc = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":519
 * 
 *         vc = self.points;
 *         tc = self._tex_coords             # <<<<<<<<<<<<<<
 * 
 *         vertices[0].x = vc[0]
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base._tex_coords));
  __pyx_v_tc = __pyx_v_self->__pyx_base._tex_coords;

  /* "kivy\graphics\vertex_instructions.pyx":521
 *         tc = self._tex_coords
 * 
 *         vertices[0].x = vc[0]             # <<<<<<<<<<<<<<
 *         vertices[0].y = vc[1]
 *         vertices[0].s0 = tc[0]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":522
 * 
 *         vertices[0].x = vc[0]
 *         vertices[0].y = vc[1]             # <<<<<<<<<<<<<<
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 522; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 522; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 522; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":523
 *         vertices[0].x = vc[0]
 *         vertices[0].y = vc[1]
 *         vertices[0].s0 = tc[0]             # <<<<<<<<<<<<<<
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = vc[2]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":524
 *         vertices[0].y = vc[1]
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]             # <<<<<<<<<<<<<<
 *         vertices[1].x = vc[2]
 *         vertices[1].y = vc[3]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 524; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 524; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 524; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":525
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = vc[2]             # <<<<<<<<<<<<<<
 *         vertices[1].y = vc[3]
 *         vertices[1].s0 = tc[2]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 2, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":526
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = vc[2]
 *         vertices[1].y = vc[3]             # <<<<<<<<<<<<<<
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 3, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":527
 *         vertices[1].x = vc[2]
 *         vertices[1].y = vc[3]
 *         vertices[1].s0 = tc[2]             # <<<<<<<<<<<<<<
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = vc[4]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 527; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 2, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 527; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 527; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":528
 *         vertices[1].y = vc[3]
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]             # <<<<<<<<<<<<<<
 *         vertices[2].x = vc[4]
 *         vertices[2].y = vc[5]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 528; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 3, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 528; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 528; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":529
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = vc[4]             # <<<<<<<<<<<<<<
 *         vertices[2].y = vc[5]
 *         vertices[2].s0 = tc[4]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 529; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 4, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 529; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 529; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":530
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = vc[4]
 *         vertices[2].y = vc[5]             # <<<<<<<<<<<<<<
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 530; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 5, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 530; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 530; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":531
 *         vertices[2].x = vc[4]
 *         vertices[2].y = vc[5]
 *         vertices[2].s0 = tc[4]             # <<<<<<<<<<<<<<
 *         vertices[2].t0 = tc[5]
 * 
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 4, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":532
 *         vertices[2].y = vc[5]
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, 3, indices, 3)
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 532; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 5, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 532; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 532; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":534
 *         vertices[2].t0 = tc[5]
 * 
 *         self.batch.set_data(vertices, 3, indices, 3)             # <<<<<<<<<<<<<<
 * 
 *     property points:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, 3, __pyx_v_indices, 3);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Triangle.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_vc);
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_6points_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_6points_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle_6points___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":539
 *         '''Property for getting/settings points of the triangle
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._points
 *         def __set__(self, points):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":540
 *         '''
 *         def __get__(self):
 *             return self._points             # <<<<<<<<<<<<<<
 *         def __set__(self, points):
 *             self._points = list(points)
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_points));
  __pyx_r = ((PyObject *)__pyx_v_self->_points);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle_6points_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)__pyx_v_self), ((PyObject *)__pyx_v_points));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":541
 *         def __get__(self):
 *             return self._points
 *         def __set__(self, points):             # <<<<<<<<<<<<<<
 *             self._points = list(points)
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_8Triangle_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":542
 *             return self._points
 *         def __set__(self, points):
 *             self._points = list(points)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 542; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_points);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_points);
  __Pyx_GIVEREF(__pyx_v_points);
  __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 542; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_2);
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":543
 *         def __set__(self, points):
 *             self._points = list(points)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Triangle *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Triangle.points.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":555
 *     cdef list _points
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  PyObject *__pyx_t_11 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":556
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else \
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 556; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 556; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 556; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":557
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')             # <<<<<<<<<<<<<<
 *         self.points = v if v is not None else \
 *                (  0.0,  50.0,   50.0,   0.0,
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__points), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 557; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":558
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else \             # <<<<<<<<<<<<<<
 *                (  0.0,  50.0,   50.0,   0.0,
 *                 100.0,  50.0,   50.0, 100.0 )
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {

    /* "kivy\graphics\vertex_instructions.pyx":559
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else \
 *                (  0.0,  50.0,   50.0,   0.0,             # <<<<<<<<<<<<<<
 *                 100.0,  50.0,   50.0, 100.0 )
 * 
 */
    __pyx_t_3 = PyFloat_FromDouble(0.0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_2 = PyFloat_FromDouble(50.0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_1 = PyFloat_FromDouble(50.0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_6 = PyFloat_FromDouble(0.0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_6);

    /* "kivy\graphics\vertex_instructions.pyx":560
 *         self.points = v if v is not None else \
 *                (  0.0,  50.0,   50.0,   0.0,
 *                 100.0,  50.0,   50.0, 100.0 )             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
    __pyx_t_7 = PyFloat_FromDouble(100.0); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_8 = PyFloat_FromDouble(50.0); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_8);
    __pyx_t_9 = PyFloat_FromDouble(50.0); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_9);
    __pyx_t_10 = PyFloat_FromDouble(100.0); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 560; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_10);
    __pyx_t_11 = PyTuple_New(8); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 559; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_11);
    PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_3);
    __Pyx_GIVEREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_11, 1, __pyx_t_2);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_11, 2, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_11, 3, __pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_11, 4, __pyx_t_7);
    __Pyx_GIVEREF(__pyx_t_7);
    PyTuple_SET_ITEM(__pyx_t_11, 5, __pyx_t_8);
    __Pyx_GIVEREF(__pyx_t_8);
    PyTuple_SET_ITEM(__pyx_t_11, 6, __pyx_t_9);
    __Pyx_GIVEREF(__pyx_t_9);
    PyTuple_SET_ITEM(__pyx_t_11, 7, __pyx_t_10);
    __Pyx_GIVEREF(__pyx_t_10);
    __pyx_t_3 = 0;
    __pyx_t_2 = 0;
    __pyx_t_1 = 0;
    __pyx_t_6 = 0;
    __pyx_t_7 = 0;
    __pyx_t_8 = 0;
    __pyx_t_9 = 0;
    __pyx_t_10 = 0;
    __pyx_t_4 = ((PyObject *)__pyx_t_11);
    __pyx_t_11 = 0;
  }

  /* "kivy\graphics\vertex_instructions.pyx":558
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('points')
 *         self.points = v if v is not None else \             # <<<<<<<<<<<<<<
 *                (  0.0,  50.0,   50.0,   0.0,
 *                 100.0,  50.0,   50.0, 100.0 )
 */
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 558; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_XDECREF(__pyx_t_11);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Quad.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":562
 *                 100.0,  50.0,   50.0, 100.0 )
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef list vc, tc
 *         cdef vertex_t vertices[4]
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_4Quad_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self) {
  PyObject *__pyx_v_vc = 0;
  PyObject *__pyx_v_tc = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t __pyx_v_vertices[4];
  unsigned short *__pyx_v_indices;
  __Pyx_RefNannyDeclarations
  unsigned short __pyx_t_1[6];
  PyObject *__pyx_t_2 = NULL;
  float __pyx_t_3;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":565
 *         cdef list vc, tc
 *         cdef vertex_t vertices[4]
 *         cdef unsigned short *indices = [0, 1, 2, 2, 3, 0]             # <<<<<<<<<<<<<<
 * 
 *         vc = self.points
 */
  __pyx_t_1[0] = 0;
  __pyx_t_1[1] = 1;
  __pyx_t_1[2] = 2;
  __pyx_t_1[3] = 2;
  __pyx_t_1[4] = 3;
  __pyx_t_1[5] = 0;
  __pyx_v_indices = __pyx_t_1;

  /* "kivy\graphics\vertex_instructions.pyx":567
 *         cdef unsigned short *indices = [0, 1, 2, 2, 3, 0]
 * 
 *         vc = self.points             # <<<<<<<<<<<<<<
 *         tc = self._tex_coords
 * 
 */
  __pyx_t_2 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__points); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 567; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  if (!(likely(PyList_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_2)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 567; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_vc = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":568
 * 
 *         vc = self.points
 *         tc = self._tex_coords             # <<<<<<<<<<<<<<
 * 
 *         vertices[0].x = vc[0]
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base._tex_coords));
  __pyx_v_tc = __pyx_v_self->__pyx_base._tex_coords;

  /* "kivy\graphics\vertex_instructions.pyx":570
 *         tc = self._tex_coords
 * 
 *         vertices[0].x = vc[0]             # <<<<<<<<<<<<<<
 *         vertices[0].y = vc[1]
 *         vertices[0].s0 = tc[0]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 570; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 570; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 570; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":571
 * 
 *         vertices[0].x = vc[0]
 *         vertices[0].y = vc[1]             # <<<<<<<<<<<<<<
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 571; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 571; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 571; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":572
 *         vertices[0].x = vc[0]
 *         vertices[0].y = vc[1]
 *         vertices[0].s0 = tc[0]             # <<<<<<<<<<<<<<
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = vc[2]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 572; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 572; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 572; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":573
 *         vertices[0].y = vc[1]
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]             # <<<<<<<<<<<<<<
 *         vertices[1].x = vc[2]
 *         vertices[1].y = vc[3]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 573; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 573; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 573; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[0]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":574
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = vc[2]             # <<<<<<<<<<<<<<
 *         vertices[1].y = vc[3]
 *         vertices[1].s0 = tc[2]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 2, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":575
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = vc[2]
 *         vertices[1].y = vc[3]             # <<<<<<<<<<<<<<
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 3, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":576
 *         vertices[1].x = vc[2]
 *         vertices[1].y = vc[3]
 *         vertices[1].s0 = tc[2]             # <<<<<<<<<<<<<<
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = vc[4]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 576; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 2, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 576; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 576; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":577
 *         vertices[1].y = vc[3]
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]             # <<<<<<<<<<<<<<
 *         vertices[2].x = vc[4]
 *         vertices[2].y = vc[5]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 3, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[1]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":578
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = vc[4]             # <<<<<<<<<<<<<<
 *         vertices[2].y = vc[5]
 *         vertices[2].s0 = tc[4]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 578; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 4, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 578; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 578; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":579
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = vc[4]
 *         vertices[2].y = vc[5]             # <<<<<<<<<<<<<<
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 579; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 5, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 579; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 579; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":580
 *         vertices[2].x = vc[4]
 *         vertices[2].y = vc[5]
 *         vertices[2].s0 = tc[4]             # <<<<<<<<<<<<<<
 *         vertices[2].t0 = tc[5]
 *         vertices[3].x = vc[6]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 580; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 4, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 580; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 580; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":581
 *         vertices[2].y = vc[5]
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]             # <<<<<<<<<<<<<<
 *         vertices[3].x = vc[6]
 *         vertices[3].y = vc[7]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 581; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 5, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 581; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 581; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[2]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":582
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]
 *         vertices[3].x = vc[6]             # <<<<<<<<<<<<<<
 *         vertices[3].y = vc[7]
 *         vertices[3].s0 = tc[6]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 582; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 6, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 582; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 582; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[3]).x = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":583
 *         vertices[2].t0 = tc[5]
 *         vertices[3].x = vc[6]
 *         vertices[3].y = vc[7]             # <<<<<<<<<<<<<<
 *         vertices[3].s0 = tc[6]
 *         vertices[3].t0 = tc[7]
 */
  if (unlikely(((PyObject *)__pyx_v_vc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_vc), 7, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[3]).y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":584
 *         vertices[3].x = vc[6]
 *         vertices[3].y = vc[7]
 *         vertices[3].s0 = tc[6]             # <<<<<<<<<<<<<<
 *         vertices[3].t0 = tc[7]
 * 
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 6, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[3]).s0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":585
 *         vertices[3].y = vc[7]
 *         vertices[3].s0 = tc[6]
 *         vertices[3].t0 = tc[7]             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, 4, indices, 6)
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 7, sizeof(long), PyInt_FromLong); if (!__pyx_t_2) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_3 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  (__pyx_v_vertices[3]).t0 = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":587
 *         vertices[3].t0 = tc[7]
 * 
 *         self.batch.set_data(vertices, 4, indices, 6)             # <<<<<<<<<<<<<<
 * 
 *     property points:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, 4, __pyx_v_indices, 6);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Quad.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_vc);
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_6points_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_6points_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad_6points___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":592
 *         '''Property for getting/settings points of the quads
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._points
 *         def __set__(self, points):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad_6points___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":593
 *         '''
 *         def __get__(self):
 *             return self._points             # <<<<<<<<<<<<<<
 *         def __set__(self, points):
 *             self._points = list(points)
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_points));
  __pyx_r = ((PyObject *)__pyx_v_self->_points);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_6points_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad_6points_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)__pyx_v_self), ((PyObject *)__pyx_v_points));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":594
 *         def __get__(self):
 *             return self._points
 *         def __set__(self, points):             # <<<<<<<<<<<<<<
 *             self._points = list(points)
 *             if len(self._points) != 8:
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_4Quad_6points_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *__pyx_v_self, PyObject *__pyx_v_points) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  Py_ssize_t __pyx_t_3;
  int __pyx_t_4;
  PyObject *__pyx_t_5 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":595
 *             return self._points
 *         def __set__(self, points):
 *             self._points = list(points)             # <<<<<<<<<<<<<<
 *             if len(self._points) != 8:
 *                 raise GraphicException(
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_points);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_points);
  __Pyx_GIVEREF(__pyx_v_points);
  __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_2);
  __Pyx_GOTREF(__pyx_v_self->_points);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_points));
  __pyx_v_self->_points = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":596
 *         def __set__(self, points):
 *             self._points = list(points)
 *             if len(self._points) != 8:             # <<<<<<<<<<<<<<
 *                 raise GraphicException(
 *                     'Quad: invalid number of points (%d instead of 8)' % len(
 */
  __pyx_t_2 = ((PyObject *)__pyx_v_self->_points);
  __Pyx_INCREF(__pyx_t_2);
  if (unlikely(__pyx_t_2 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 596; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_3 = PyList_GET_SIZE(__pyx_t_2); 
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_4 = (__pyx_t_3 != 8);
  if (__pyx_t_4) {

    /* "kivy\graphics\vertex_instructions.pyx":597
 *             self._points = list(points)
 *             if len(self._points) != 8:
 *                 raise GraphicException(             # <<<<<<<<<<<<<<
 *                     'Quad: invalid number of points (%d instead of 8)' % len(
 *                     self._points))
 */
    __pyx_t_2 = __Pyx_GetName(__pyx_m, __pyx_n_s__GraphicException); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 597; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_2);

    /* "kivy\graphics\vertex_instructions.pyx":599
 *                 raise GraphicException(
 *                     'Quad: invalid number of points (%d instead of 8)' % len(
 *                     self._points))             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
    __pyx_t_1 = ((PyObject *)__pyx_v_self->_points);
    __Pyx_INCREF(__pyx_t_1);
    if (unlikely(__pyx_t_1 == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 599; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_t_3 = PyList_GET_SIZE(__pyx_t_1); 
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_5 = PyNumber_Remainder(((PyObject *)__pyx_kp_s_40), __pyx_t_1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(((PyObject *)__pyx_t_5));
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 597; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_t_5));
    __Pyx_GIVEREF(((PyObject *)__pyx_t_5));
    __pyx_t_5 = 0;
    __pyx_t_5 = PyObject_Call(__pyx_t_2, ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 597; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
    __Pyx_Raise(__pyx_t_5, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 597; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":600
 *                     'Quad: invalid number of points (%d instead of 8)' % len(
 *                     self._points))
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Quad *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Quad.points.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":614
 *     cdef float x,y,w,h
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('pos')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":615
 * 
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('pos')
 *         self.pos = v if v is not None else (0, 0)
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":616
 *     def __init__(self, **kwargs):
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('pos')             # <<<<<<<<<<<<<<
 *         self.pos = v if v is not None else (0, 0)
 *         v = kwargs.get('size')
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__pos), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":617
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('pos')
 *         self.pos = v if v is not None else (0, 0)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('size')
 *         self.size = v if v is not None else (100, 100)
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __Pyx_INCREF(((PyObject *)__pyx_k_tuple_41));
    __pyx_t_4 = ((PyObject *)__pyx_k_tuple_41);
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__pos, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":618
 *         v = kwargs.get('pos')
 *         self.pos = v if v is not None else (0, 0)
 *         v = kwargs.get('size')             # <<<<<<<<<<<<<<
 *         self.size = v if v is not None else (100, 100)
 * 
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__size), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_v_v);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":619
 *         self.pos = v if v is not None else (0, 0)
 *         v = kwargs.get('size')
 *         self.size = v if v is not None else (100, 100)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __Pyx_INCREF(((PyObject *)__pyx_k_tuple_42));
    __pyx_t_4 = ((PyObject *)__pyx_k_tuple_42);
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__size, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Rectangle.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":621
 *         self.size = v if v is not None else (100, 100)
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef float x, y, w, h
 *         cdef list tc = self._tex_coords
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_9Rectangle_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self) {
  float __pyx_v_x;
  float __pyx_v_y;
  float __pyx_v_w;
  float __pyx_v_h;
  PyObject *__pyx_v_tc = 0;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t __pyx_v_vertices[4];
  unsigned short *__pyx_v_indices;
  __Pyx_RefNannyDeclarations
  unsigned short __pyx_t_1[6];
  float __pyx_t_2;
  float __pyx_t_3;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":623
 *     cdef void build(self):
 *         cdef float x, y, w, h
 *         cdef list tc = self._tex_coords             # <<<<<<<<<<<<<<
 *         cdef vertex_t vertices[4]
 *         cdef unsigned short *indices = [0, 1, 2, 2, 3, 0]
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base._tex_coords));
  __pyx_v_tc = __pyx_v_self->__pyx_base._tex_coords;

  /* "kivy\graphics\vertex_instructions.pyx":625
 *         cdef list tc = self._tex_coords
 *         cdef vertex_t vertices[4]
 *         cdef unsigned short *indices = [0, 1, 2, 2, 3, 0]             # <<<<<<<<<<<<<<
 * 
 *         x, y = self.x, self.y
 */
  __pyx_t_1[0] = 0;
  __pyx_t_1[1] = 1;
  __pyx_t_1[2] = 2;
  __pyx_t_1[3] = 2;
  __pyx_t_1[4] = 3;
  __pyx_t_1[5] = 0;
  __pyx_v_indices = __pyx_t_1;

  /* "kivy\graphics\vertex_instructions.pyx":627
 *         cdef unsigned short *indices = [0, 1, 2, 2, 3, 0]
 * 
 *         x, y = self.x, self.y             # <<<<<<<<<<<<<<
 *         w, h = self.w, self.h
 * 
 */
  __pyx_t_2 = __pyx_v_self->x;
  __pyx_t_3 = __pyx_v_self->y;
  __pyx_v_x = __pyx_t_2;
  __pyx_v_y = __pyx_t_3;

  /* "kivy\graphics\vertex_instructions.pyx":628
 * 
 *         x, y = self.x, self.y
 *         w, h = self.w, self.h             # <<<<<<<<<<<<<<
 * 
 *         vertices[0].x = x
 */
  __pyx_t_3 = __pyx_v_self->w;
  __pyx_t_2 = __pyx_v_self->h;
  __pyx_v_w = __pyx_t_3;
  __pyx_v_h = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":630
 *         w, h = self.w, self.h
 * 
 *         vertices[0].x = x             # <<<<<<<<<<<<<<
 *         vertices[0].y = y
 *         vertices[0].s0 = tc[0]
 */
  (__pyx_v_vertices[0]).x = __pyx_v_x;

  /* "kivy\graphics\vertex_instructions.pyx":631
 * 
 *         vertices[0].x = x
 *         vertices[0].y = y             # <<<<<<<<<<<<<<
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]
 */
  (__pyx_v_vertices[0]).y = __pyx_v_y;

  /* "kivy\graphics\vertex_instructions.pyx":632
 *         vertices[0].x = x
 *         vertices[0].y = y
 *         vertices[0].s0 = tc[0]             # <<<<<<<<<<<<<<
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = x + w
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 632; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 632; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 632; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[0]).s0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":633
 *         vertices[0].y = y
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]             # <<<<<<<<<<<<<<
 *         vertices[1].x = x + w
 *         vertices[1].y = y
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[0]).t0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":634
 *         vertices[0].s0 = tc[0]
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = x + w             # <<<<<<<<<<<<<<
 *         vertices[1].y = y
 *         vertices[1].s0 = tc[2]
 */
  (__pyx_v_vertices[1]).x = (__pyx_v_x + __pyx_v_w);

  /* "kivy\graphics\vertex_instructions.pyx":635
 *         vertices[0].t0 = tc[1]
 *         vertices[1].x = x + w
 *         vertices[1].y = y             # <<<<<<<<<<<<<<
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]
 */
  (__pyx_v_vertices[1]).y = __pyx_v_y;

  /* "kivy\graphics\vertex_instructions.pyx":636
 *         vertices[1].x = x + w
 *         vertices[1].y = y
 *         vertices[1].s0 = tc[2]             # <<<<<<<<<<<<<<
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = x + w
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 636; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 2, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 636; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 636; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[1]).s0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":637
 *         vertices[1].y = y
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]             # <<<<<<<<<<<<<<
 *         vertices[2].x = x + w
 *         vertices[2].y = y + h
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 637; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 3, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 637; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 637; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[1]).t0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":638
 *         vertices[1].s0 = tc[2]
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = x + w             # <<<<<<<<<<<<<<
 *         vertices[2].y = y + h
 *         vertices[2].s0 = tc[4]
 */
  (__pyx_v_vertices[2]).x = (__pyx_v_x + __pyx_v_w);

  /* "kivy\graphics\vertex_instructions.pyx":639
 *         vertices[1].t0 = tc[3]
 *         vertices[2].x = x + w
 *         vertices[2].y = y + h             # <<<<<<<<<<<<<<
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]
 */
  (__pyx_v_vertices[2]).y = (__pyx_v_y + __pyx_v_h);

  /* "kivy\graphics\vertex_instructions.pyx":640
 *         vertices[2].x = x + w
 *         vertices[2].y = y + h
 *         vertices[2].s0 = tc[4]             # <<<<<<<<<<<<<<
 *         vertices[2].t0 = tc[5]
 *         vertices[3].x = x
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 640; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 4, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 640; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 640; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[2]).s0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":641
 *         vertices[2].y = y + h
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]             # <<<<<<<<<<<<<<
 *         vertices[3].x = x
 *         vertices[3].y = y + h
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 641; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 5, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 641; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 641; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[2]).t0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":642
 *         vertices[2].s0 = tc[4]
 *         vertices[2].t0 = tc[5]
 *         vertices[3].x = x             # <<<<<<<<<<<<<<
 *         vertices[3].y = y + h
 *         vertices[3].s0 = tc[6]
 */
  (__pyx_v_vertices[3]).x = __pyx_v_x;

  /* "kivy\graphics\vertex_instructions.pyx":643
 *         vertices[2].t0 = tc[5]
 *         vertices[3].x = x
 *         vertices[3].y = y + h             # <<<<<<<<<<<<<<
 *         vertices[3].s0 = tc[6]
 *         vertices[3].t0 = tc[7]
 */
  (__pyx_v_vertices[3]).y = (__pyx_v_y + __pyx_v_h);

  /* "kivy\graphics\vertex_instructions.pyx":644
 *         vertices[3].x = x
 *         vertices[3].y = y + h
 *         vertices[3].s0 = tc[6]             # <<<<<<<<<<<<<<
 *         vertices[3].t0 = tc[7]
 * 
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 644; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 6, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 644; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 644; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[3]).s0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":645
 *         vertices[3].y = y + h
 *         vertices[3].s0 = tc[6]
 *         vertices[3].t0 = tc[7]             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, 4, indices, 6)
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 645; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 7, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 645; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 645; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  (__pyx_v_vertices[3]).t0 = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":647
 *         vertices[3].t0 = tc[7]
 * 
 *         self.batch.set_data(vertices, 4, indices, 6)             # <<<<<<<<<<<<<<
 * 
 *     property pos:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.batch, __pyx_v_vertices, 4, __pyx_v_indices, 6);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Rectangle.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":652
 *         '''Property for getting/settings the position of the rectangle
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return (self.x, self.y)
 *         def __set__(self, pos):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":653
 *         '''
 *         def __get__(self):
 *             return (self.x, self.y)             # <<<<<<<<<<<<<<
 *         def __set__(self, pos):
 *             cdef float x, y
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->x); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 653; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyFloat_FromDouble(__pyx_v_self->y); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 653; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 653; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_2);
  __pyx_t_1 = 0;
  __pyx_t_2 = 0;
  __pyx_r = ((PyObject *)__pyx_t_3);
  __pyx_t_3 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Rectangle.pos.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_pos); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_pos) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self), ((PyObject *)__pyx_v_pos));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":654
 *         def __get__(self):
 *             return (self.x, self.y)
 *         def __set__(self, pos):             # <<<<<<<<<<<<<<
 *             cdef float x, y
 *             x, y = pos
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self, PyObject *__pyx_v_pos) {
  float __pyx_v_x;
  float __pyx_v_y;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *(*__pyx_t_4)(PyObject *);
  float __pyx_t_5;
  float __pyx_t_6;
  int __pyx_t_7;
  int __pyx_t_8;
  int __pyx_t_9;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":656
 *         def __set__(self, pos):
 *             cdef float x, y
 *             x, y = pos             # <<<<<<<<<<<<<<
 *             if self.x == x and self.y == y:
 *                 return
 */
  #if CYTHON_COMPILING_IN_CPYTHON
  if ((likely(PyTuple_CheckExact(__pyx_v_pos))) || (PyList_CheckExact(__pyx_v_pos))) {
    PyObject* sequence = __pyx_v_pos;
    if (likely(PyTuple_CheckExact(sequence))) {
      if (unlikely(PyTuple_GET_SIZE(sequence) != 2)) {
        if (PyTuple_GET_SIZE(sequence) > 2) __Pyx_RaiseTooManyValuesError(2);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_1 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_2 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_2);
    } else {
      if (unlikely(PyList_GET_SIZE(sequence) != 2)) {
        if (PyList_GET_SIZE(sequence) > 2) __Pyx_RaiseTooManyValuesError(2);
        else __Pyx_RaiseNeedMoreValuesError(PyList_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_1 = PyList_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_2 = PyList_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_2);
    }
  } else
  #endif
  {
    Py_ssize_t index = -1;
    __pyx_t_3 = PyObject_GetIter(__pyx_v_pos); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = Py_TYPE(__pyx_t_3)->tp_iternext;
    index = 0; __pyx_t_1 = __pyx_t_4(__pyx_t_3); if (unlikely(!__pyx_t_1)) goto __pyx_L3_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_1);
    index = 1; __pyx_t_2 = __pyx_t_4(__pyx_t_3); if (unlikely(!__pyx_t_2)) goto __pyx_L3_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_2);
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_3), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_4 = NULL;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    goto __pyx_L4_unpacking_done;
    __pyx_L3_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_4 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_L4_unpacking_done:;
  }
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_6 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_6 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_x = __pyx_t_5;
  __pyx_v_y = __pyx_t_6;

  /* "kivy\graphics\vertex_instructions.pyx":657
 *             cdef float x, y
 *             x, y = pos
 *             if self.x == x and self.y == y:             # <<<<<<<<<<<<<<
 *                 return
 *             self.x = x
 */
  __pyx_t_7 = (__pyx_v_self->x == __pyx_v_x);
  if (__pyx_t_7) {
    __pyx_t_8 = (__pyx_v_self->y == __pyx_v_y);
    __pyx_t_9 = __pyx_t_8;
  } else {
    __pyx_t_9 = __pyx_t_7;
  }
  if (__pyx_t_9) {

    /* "kivy\graphics\vertex_instructions.pyx":658
 *             x, y = pos
 *             if self.x == x and self.y == y:
 *                 return             # <<<<<<<<<<<<<<
 *             self.x = x
 *             self.y = y
 */
    __pyx_r = 0;
    goto __pyx_L0;
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "kivy\graphics\vertex_instructions.pyx":659
 *             if self.x == x and self.y == y:
 *                 return
 *             self.x = x             # <<<<<<<<<<<<<<
 *             self.y = y
 *             self.flag_update()
 */
  __pyx_v_self->x = __pyx_v_x;

  /* "kivy\graphics\vertex_instructions.pyx":660
 *                 return
 *             self.x = x
 *             self.y = y             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_v_self->y = __pyx_v_y;

  /* "kivy\graphics\vertex_instructions.pyx":661
 *             self.x = x
 *             self.y = y
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property size:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Rectangle.pos.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_4size___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":666
 *         '''Property for getting/settings the size of the rectangle
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return (self.w, self.h)
 *         def __set__(self, size):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_4size___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":667
 *         '''
 *         def __get__(self):
 *             return (self.w, self.h)             # <<<<<<<<<<<<<<
 *         def __set__(self, size):
 *             cdef float w, h
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->w); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 667; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyFloat_FromDouble(__pyx_v_self->h); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 667; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 667; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_2);
  __pyx_t_1 = 0;
  __pyx_t_2 = 0;
  __pyx_r = ((PyObject *)__pyx_t_3);
  __pyx_t_3 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Rectangle.size.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_size); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_size) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self), ((PyObject *)__pyx_v_size));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":668
 *         def __get__(self):
 *             return (self.w, self.h)
 *         def __set__(self, size):             # <<<<<<<<<<<<<<
 *             cdef float w, h
 *             w, h = size
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *__pyx_v_self, PyObject *__pyx_v_size) {
  float __pyx_v_w;
  float __pyx_v_h;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *(*__pyx_t_4)(PyObject *);
  float __pyx_t_5;
  float __pyx_t_6;
  int __pyx_t_7;
  int __pyx_t_8;
  int __pyx_t_9;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":670
 *         def __set__(self, size):
 *             cdef float w, h
 *             w, h = size             # <<<<<<<<<<<<<<
 *             if self.w == w and self.h == h:
 *                 return
 */
  #if CYTHON_COMPILING_IN_CPYTHON
  if ((likely(PyTuple_CheckExact(__pyx_v_size))) || (PyList_CheckExact(__pyx_v_size))) {
    PyObject* sequence = __pyx_v_size;
    if (likely(PyTuple_CheckExact(sequence))) {
      if (unlikely(PyTuple_GET_SIZE(sequence) != 2)) {
        if (PyTuple_GET_SIZE(sequence) > 2) __Pyx_RaiseTooManyValuesError(2);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_1 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_2 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_2);
    } else {
      if (unlikely(PyList_GET_SIZE(sequence) != 2)) {
        if (PyList_GET_SIZE(sequence) > 2) __Pyx_RaiseTooManyValuesError(2);
        else __Pyx_RaiseNeedMoreValuesError(PyList_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_1 = PyList_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_2 = PyList_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_2);
    }
  } else
  #endif
  {
    Py_ssize_t index = -1;
    __pyx_t_3 = PyObject_GetIter(__pyx_v_size); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = Py_TYPE(__pyx_t_3)->tp_iternext;
    index = 0; __pyx_t_1 = __pyx_t_4(__pyx_t_3); if (unlikely(!__pyx_t_1)) goto __pyx_L3_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_1);
    index = 1; __pyx_t_2 = __pyx_t_4(__pyx_t_3); if (unlikely(!__pyx_t_2)) goto __pyx_L3_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_2);
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_4(__pyx_t_3), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_4 = NULL;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    goto __pyx_L4_unpacking_done;
    __pyx_L3_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_4 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_L4_unpacking_done:;
  }
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_6 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_6 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_w = __pyx_t_5;
  __pyx_v_h = __pyx_t_6;

  /* "kivy\graphics\vertex_instructions.pyx":671
 *             cdef float w, h
 *             w, h = size
 *             if self.w == w and self.h == h:             # <<<<<<<<<<<<<<
 *                 return
 *             self.w = w
 */
  __pyx_t_7 = (__pyx_v_self->w == __pyx_v_w);
  if (__pyx_t_7) {
    __pyx_t_8 = (__pyx_v_self->h == __pyx_v_h);
    __pyx_t_9 = __pyx_t_8;
  } else {
    __pyx_t_9 = __pyx_t_7;
  }
  if (__pyx_t_9) {

    /* "kivy\graphics\vertex_instructions.pyx":672
 *             w, h = size
 *             if self.w == w and self.h == h:
 *                 return             # <<<<<<<<<<<<<<
 *             self.w = w
 *             self.h = h
 */
    __pyx_r = 0;
    goto __pyx_L0;
    goto __pyx_L5;
  }
  __pyx_L5:;

  /* "kivy\graphics\vertex_instructions.pyx":673
 *             if self.w == w and self.h == h:
 *                 return
 *             self.w = w             # <<<<<<<<<<<<<<
 *             self.h = h
 *             self.flag_update()
 */
  __pyx_v_self->w = __pyx_v_w;

  /* "kivy\graphics\vertex_instructions.pyx":674
 *                 return
 *             self.w = w
 *             self.h = h             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_v_self->h = __pyx_v_h;

  /* "kivy\graphics\vertex_instructions.pyx":675
 *             self.w = w
 *             self.h = h
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Rectangle.size.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
    __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;}
  if (__pyx_kwds && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)__pyx_v_self), __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":690
 *     cdef list _border
 * 
 *     def __init__(self, **kwargs):             # <<<<<<<<<<<<<<
 *         Rectangle.__init__(self, **kwargs)
 *         v = kwargs.get('border')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self, PyObject *__pyx_v_kwargs) {
  PyObject *__pyx_v_v = NULL;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":691
 * 
 *     def __init__(self, **kwargs):
 *         Rectangle.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('border')
 *         self.border = v if v is not None else (10, 10, 10, 10)
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":692
 *     def __init__(self, **kwargs):
 *         Rectangle.__init__(self, **kwargs)
 *         v = kwargs.get('border')             # <<<<<<<<<<<<<<
 *         self.border = v if v is not None else (10, 10, 10, 10)
 * 
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__border), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 692; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_v_v = __pyx_t_4;
  __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":693
 *         Rectangle.__init__(self, **kwargs)
 *         v = kwargs.get('border')
 *         self.border = v if v is not None else (10, 10, 10, 10)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_5 = (__pyx_v_v != Py_None);
  if (__pyx_t_5) {
    __Pyx_INCREF(__pyx_v_v);
    __pyx_t_4 = __pyx_v_v;
  } else {
    __Pyx_INCREF(((PyObject *)__pyx_k_tuple_43));
    __pyx_t_4 = ((PyObject *)__pyx_k_tuple_43);
  }
  if (PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__border, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 693; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.BorderImage.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_v);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":695
 *         self.border = v if v is not None else (10, 10, 10, 10)
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         if not self.texture:
 *             Logger.trace('GBorderImage: texture missing')
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_11BorderImage_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self) {
  float __pyx_v_x;
  float __pyx_v_y;
  float __pyx_v_w;
  float __pyx_v_h;
  float __pyx_v_tw;
  float __pyx_v_th;
  float __pyx_v_tcw;
  float __pyx_v_tch;
  PyObject *__pyx_v_tc = 0;
  float __pyx_v_tc0;
  float __pyx_v_tc1;
  float __pyx_v_tc2;
  float __pyx_v_tc7;
  PyObject *__pyx_v_b = 0;
  float __pyx_v_b0;
  float __pyx_v_b1;
  float __pyx_v_b2;
  float __pyx_v_b3;
  float __pyx_v_tb[4];
  float __pyx_v_hs[4];
  float __pyx_v_vs[4];
  float __pyx_v_ths[4];
  float __pyx_v_tvs[4];
  float *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  int __pyx_t_3;
  PyObject *__pyx_t_4 = NULL;
  float __pyx_t_5;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *(*__pyx_t_8)(PyObject *);
  float __pyx_t_9;
  Py_ssize_t __pyx_t_10;
  PyObject *__pyx_t_11 = NULL;
  float __pyx_t_12;
  float __pyx_t_13;
  float __pyx_t_14[64];
  unsigned short __pyx_t_15[54];
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":696
 * 
 *     cdef void build(self):
 *         if not self.texture:             # <<<<<<<<<<<<<<
 *             Logger.trace('GBorderImage: texture missing')
 *             return
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 696; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 696; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_3 = (!__pyx_t_2);
  if (__pyx_t_3) {

    /* "kivy\graphics\vertex_instructions.pyx":697
 *     cdef void build(self):
 *         if not self.texture:
 *             Logger.trace('GBorderImage: texture missing')             # <<<<<<<<<<<<<<
 *             return
 * 
 */
    __pyx_t_1 = __Pyx_GetName(__pyx_m, __pyx_n_s__Logger); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 697; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_4 = PyObject_GetAttr(__pyx_t_1, __pyx_n_s__trace); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 697; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __pyx_t_1 = PyObject_Call(__pyx_t_4, ((PyObject *)__pyx_k_tuple_45), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 697; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "kivy\graphics\vertex_instructions.pyx":698
 *         if not self.texture:
 *             Logger.trace('GBorderImage: texture missing')
 *             return             # <<<<<<<<<<<<<<
 * 
 *         # pos and size of border rectangle
 */
    goto __pyx_L0;
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":702
 *         # pos and size of border rectangle
 *         cdef float x, y, w, h
 *         x = self.x             # <<<<<<<<<<<<<<
 *         y = self.y
 *         w = self.w
 */
  __pyx_v_x = __pyx_v_self->__pyx_base.x;

  /* "kivy\graphics\vertex_instructions.pyx":703
 *         cdef float x, y, w, h
 *         x = self.x
 *         y = self.y             # <<<<<<<<<<<<<<
 *         w = self.w
 *         h = self.h
 */
  __pyx_v_y = __pyx_v_self->__pyx_base.y;

  /* "kivy\graphics\vertex_instructions.pyx":704
 *         x = self.x
 *         y = self.y
 *         w = self.w             # <<<<<<<<<<<<<<
 *         h = self.h
 * 
 */
  __pyx_v_w = __pyx_v_self->__pyx_base.w;

  /* "kivy\graphics\vertex_instructions.pyx":705
 *         y = self.y
 *         w = self.w
 *         h = self.h             # <<<<<<<<<<<<<<
 * 
 *         # width and heigth of texture in pixels, and tex coord space
 */
  __pyx_v_h = __pyx_v_self->__pyx_base.h;

  /* "kivy\graphics\vertex_instructions.pyx":709
 *         # width and heigth of texture in pixels, and tex coord space
 *         cdef float tw, th, tcw, tch
 *         cdef list tc = self._tex_coords             # <<<<<<<<<<<<<<
 *         cdef float tc0, tc1, tc2, tc7
 *         tc0 = tc[0]
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->__pyx_base.__pyx_base._tex_coords));
  __pyx_v_tc = __pyx_v_self->__pyx_base.__pyx_base._tex_coords;

  /* "kivy\graphics\vertex_instructions.pyx":711
 *         cdef list tc = self._tex_coords
 *         cdef float tc0, tc1, tc2, tc7
 *         tc0 = tc[0]             # <<<<<<<<<<<<<<
 *         tc1 = tc[1]
 *         tc2 = tc[2]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_tc0 = __pyx_t_5;

  /* "kivy\graphics\vertex_instructions.pyx":712
 *         cdef float tc0, tc1, tc2, tc7
 *         tc0 = tc[0]
 *         tc1 = tc[1]             # <<<<<<<<<<<<<<
 *         tc2 = tc[2]
 *         tc7 = tc[7]
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_tc1 = __pyx_t_5;

  /* "kivy\graphics\vertex_instructions.pyx":713
 *         tc0 = tc[0]
 *         tc1 = tc[1]
 *         tc2 = tc[2]             # <<<<<<<<<<<<<<
 *         tc7 = tc[7]
 *         tw, th  = self.texture.size
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 713; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 2, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 713; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 713; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_tc2 = __pyx_t_5;

  /* "kivy\graphics\vertex_instructions.pyx":714
 *         tc1 = tc[1]
 *         tc2 = tc[2]
 *         tc7 = tc[7]             # <<<<<<<<<<<<<<
 *         tw, th  = self.texture.size
 *         tcw = tc2 - tc0  #right - left
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 7, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_tc7 = __pyx_t_5;

  /* "kivy\graphics\vertex_instructions.pyx":715
 *         tc2 = tc[2]
 *         tc7 = tc[7]
 *         tw, th  = self.texture.size             # <<<<<<<<<<<<<<
 *         tcw = tc2 - tc0  #right - left
 *         tch = tc7 - tc1  #top - bottom
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__texture); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = PyObject_GetAttr(__pyx_t_1, __pyx_n_s__size); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  #if CYTHON_COMPILING_IN_CPYTHON
  if ((likely(PyTuple_CheckExact(__pyx_t_4))) || (PyList_CheckExact(__pyx_t_4))) {
    PyObject* sequence = __pyx_t_4;
    if (likely(PyTuple_CheckExact(sequence))) {
      if (unlikely(PyTuple_GET_SIZE(sequence) != 2)) {
        if (PyTuple_GET_SIZE(sequence) > 2) __Pyx_RaiseTooManyValuesError(2);
        else __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_1 = PyTuple_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_6);
    } else {
      if (unlikely(PyList_GET_SIZE(sequence) != 2)) {
        if (PyList_GET_SIZE(sequence) > 2) __Pyx_RaiseTooManyValuesError(2);
        else __Pyx_RaiseNeedMoreValuesError(PyList_GET_SIZE(sequence));
        {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
      }
      __pyx_t_1 = PyList_GET_ITEM(sequence, 0); 
      __Pyx_INCREF(__pyx_t_1);
      __pyx_t_6 = PyList_GET_ITEM(sequence, 1); 
      __Pyx_INCREF(__pyx_t_6);
    }
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  } else
  #endif
  {
    Py_ssize_t index = -1;
    __pyx_t_7 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext;
    index = 0; __pyx_t_1 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_1)) goto __pyx_L4_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_1);
    index = 1; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L4_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_6);
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_8 = NULL;
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    goto __pyx_L5_unpacking_done;
    __pyx_L4_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __pyx_t_8 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_L5_unpacking_done:;
  }
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_9 = __pyx_PyFloat_AsFloat(__pyx_t_6); if (unlikely((__pyx_t_9 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  __pyx_v_tw = __pyx_t_5;
  __pyx_v_th = __pyx_t_9;

  /* "kivy\graphics\vertex_instructions.pyx":716
 *         tc7 = tc[7]
 *         tw, th  = self.texture.size
 *         tcw = tc2 - tc0  #right - left             # <<<<<<<<<<<<<<
 *         tch = tc7 - tc1  #top - bottom
 * 
 */
  __pyx_v_tcw = (__pyx_v_tc2 - __pyx_v_tc0);

  /* "kivy\graphics\vertex_instructions.pyx":717
 *         tw, th  = self.texture.size
 *         tcw = tc2 - tc0  #right - left
 *         tch = tc7 - tc1  #top - bottom             # <<<<<<<<<<<<<<
 * 
 *         # calculate border offset in texture coord space
 */
  __pyx_v_tch = (__pyx_v_tc7 - __pyx_v_tc1);

  /* "kivy\graphics\vertex_instructions.pyx":721
 *         # calculate border offset in texture coord space
 *         # border width(px)/texture width(px) *  tcoord width
 *         cdef list b = self._border             # <<<<<<<<<<<<<<
 *         cdef float b0, b1, b2, b3
 *         cdef float tb[4] # border offset in texture coordinate space
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_border));
  __pyx_v_b = __pyx_v_self->_border;

  /* "kivy\graphics\vertex_instructions.pyx":724
 *         cdef float b0, b1, b2, b3
 *         cdef float tb[4] # border offset in texture coordinate space
 *         b0, b1, b2, b3 = b             # <<<<<<<<<<<<<<
 *         tb[0] = b0 / th * tch
 *         tb[1] = b1 / tw * tcw
 */
  #if CYTHON_COMPILING_IN_CPYTHON
  if (PyList_CheckExact(((PyObject *)__pyx_v_b))) {
    PyObject* sequence = ((PyObject *)__pyx_v_b);
    PyObject** temps[4] = {&__pyx_t_4,&__pyx_t_6,&__pyx_t_1,&__pyx_t_7};
    if (unlikely(PyList_GET_SIZE(sequence) != 4)) {
      if (PyList_GET_SIZE(sequence) > 4) __Pyx_RaiseTooManyValuesError(4);
      else __Pyx_RaiseNeedMoreValuesError(PyList_GET_SIZE(sequence));
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    for (__pyx_t_10=0; __pyx_t_10 < 4; __pyx_t_10++) {
      PyObject* item = PyList_GET_ITEM(sequence, __pyx_t_10);
      *(temps[__pyx_t_10]) = item;
      __Pyx_INCREF(item);
    }
  } else
  #endif
  {
    Py_ssize_t index = -1;
    PyObject** temps[4] = {&__pyx_t_4,&__pyx_t_6,&__pyx_t_1,&__pyx_t_7};
    __pyx_t_11 = PyObject_GetIter(((PyObject *)__pyx_v_b)); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_11);
    __pyx_t_8 = Py_TYPE(__pyx_t_11)->tp_iternext;
    for (index=0; index < 4; index++) {
      PyObject* item = __pyx_t_8(__pyx_t_11); if (unlikely(!item)) goto __pyx_L6_unpacking_failed;
      __Pyx_GOTREF(item);
      *(temps[index]) = item;
    }
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_11), 4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_t_8 = NULL;
    __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
    goto __pyx_L7_unpacking_done;
    __pyx_L6_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
    __pyx_t_8 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __pyx_L7_unpacking_done:;
  }
  __pyx_t_9 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_9 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_6); if (unlikely((__pyx_t_5 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  __pyx_t_12 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_12 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_13 = __pyx_PyFloat_AsFloat(__pyx_t_7); if (unlikely((__pyx_t_13 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  __pyx_v_b0 = __pyx_t_9;
  __pyx_v_b1 = __pyx_t_5;
  __pyx_v_b2 = __pyx_t_12;
  __pyx_v_b3 = __pyx_t_13;

  /* "kivy\graphics\vertex_instructions.pyx":725
 *         cdef float tb[4] # border offset in texture coordinate space
 *         b0, b1, b2, b3 = b
 *         tb[0] = b0 / th * tch             # <<<<<<<<<<<<<<
 *         tb[1] = b1 / tw * tcw
 *         tb[2] = b2 / th * tch
 */
  if (unlikely(__pyx_v_th == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 725; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  (__pyx_v_tb[0]) = ((__pyx_v_b0 / __pyx_v_th) * __pyx_v_tch);

  /* "kivy\graphics\vertex_instructions.pyx":726
 *         b0, b1, b2, b3 = b
 *         tb[0] = b0 / th * tch
 *         tb[1] = b1 / tw * tcw             # <<<<<<<<<<<<<<
 *         tb[2] = b2 / th * tch
 *         tb[3] = b3 / tw * tcw
 */
  if (unlikely(__pyx_v_tw == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 726; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  (__pyx_v_tb[1]) = ((__pyx_v_b1 / __pyx_v_tw) * __pyx_v_tcw);

  /* "kivy\graphics\vertex_instructions.pyx":727
 *         tb[0] = b0 / th * tch
 *         tb[1] = b1 / tw * tcw
 *         tb[2] = b2 / th * tch             # <<<<<<<<<<<<<<
 *         tb[3] = b3 / tw * tcw
 * 
 */
  if (unlikely(__pyx_v_th == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  (__pyx_v_tb[2]) = ((__pyx_v_b2 / __pyx_v_th) * __pyx_v_tch);

  /* "kivy\graphics\vertex_instructions.pyx":728
 *         tb[1] = b1 / tw * tcw
 *         tb[2] = b2 / th * tch
 *         tb[3] = b3 / tw * tcw             # <<<<<<<<<<<<<<
 * 
 * 
 */
  if (unlikely(__pyx_v_tw == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 728; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  (__pyx_v_tb[3]) = ((__pyx_v_b3 / __pyx_v_tw) * __pyx_v_tcw);

  /* "kivy\graphics\vertex_instructions.pyx":734
 *         cdef float hs[4]
 *         cdef float vs[4]
 *         hs[0] = x;            vs[0] = y             # <<<<<<<<<<<<<<
 *         hs[1] = x + b3;       vs[1] = y + b0
 *         hs[2] = x + w - b1;   vs[2] = y + h - b2
 */
  (__pyx_v_hs[0]) = __pyx_v_x;
  (__pyx_v_vs[0]) = __pyx_v_y;

  /* "kivy\graphics\vertex_instructions.pyx":735
 *         cdef float vs[4]
 *         hs[0] = x;            vs[0] = y
 *         hs[1] = x + b3;       vs[1] = y + b0             # <<<<<<<<<<<<<<
 *         hs[2] = x + w - b1;   vs[2] = y + h - b2
 *         hs[3] = x + w;        vs[3] = y + h
 */
  (__pyx_v_hs[1]) = (__pyx_v_x + __pyx_v_b3);
  (__pyx_v_vs[1]) = (__pyx_v_y + __pyx_v_b0);

  /* "kivy\graphics\vertex_instructions.pyx":736
 *         hs[0] = x;            vs[0] = y
 *         hs[1] = x + b3;       vs[1] = y + b0
 *         hs[2] = x + w - b1;   vs[2] = y + h - b2             # <<<<<<<<<<<<<<
 *         hs[3] = x + w;        vs[3] = y + h
 * 
 */
  (__pyx_v_hs[2]) = ((__pyx_v_x + __pyx_v_w) - __pyx_v_b1);
  (__pyx_v_vs[2]) = ((__pyx_v_y + __pyx_v_h) - __pyx_v_b2);

  /* "kivy\graphics\vertex_instructions.pyx":737
 *         hs[1] = x + b3;       vs[1] = y + b0
 *         hs[2] = x + w - b1;   vs[2] = y + h - b2
 *         hs[3] = x + w;        vs[3] = y + h             # <<<<<<<<<<<<<<
 * 
 *         cdef float ths[4]
 */
  (__pyx_v_hs[3]) = (__pyx_v_x + __pyx_v_w);
  (__pyx_v_vs[3]) = (__pyx_v_y + __pyx_v_h);

  /* "kivy\graphics\vertex_instructions.pyx":741
 *         cdef float ths[4]
 *         cdef float tvs[4]
 *         ths[0] = tc0;              tvs[0] = tc1             # <<<<<<<<<<<<<<
 *         ths[1] = tc0 + tb[3];      tvs[1] = tc1 + tb[0]
 *         ths[2] = tc0 + tcw-tb[1];  tvs[2] = tc1 + tch - tb[2]
 */
  (__pyx_v_ths[0]) = __pyx_v_tc0;
  (__pyx_v_tvs[0]) = __pyx_v_tc1;

  /* "kivy\graphics\vertex_instructions.pyx":742
 *         cdef float tvs[4]
 *         ths[0] = tc0;              tvs[0] = tc1
 *         ths[1] = tc0 + tb[3];      tvs[1] = tc1 + tb[0]             # <<<<<<<<<<<<<<
 *         ths[2] = tc0 + tcw-tb[1];  tvs[2] = tc1 + tch - tb[2]
 *         ths[3] = tc0 + tcw;        tvs[3] = tc1 + tch
 */
  (__pyx_v_ths[1]) = (__pyx_v_tc0 + (__pyx_v_tb[3]));
  (__pyx_v_tvs[1]) = (__pyx_v_tc1 + (__pyx_v_tb[0]));

  /* "kivy\graphics\vertex_instructions.pyx":743
 *         ths[0] = tc0;              tvs[0] = tc1
 *         ths[1] = tc0 + tb[3];      tvs[1] = tc1 + tb[0]
 *         ths[2] = tc0 + tcw-tb[1];  tvs[2] = tc1 + tch - tb[2]             # <<<<<<<<<<<<<<
 *         ths[3] = tc0 + tcw;        tvs[3] = tc1 + tch
 * 
 */
  (__pyx_v_ths[2]) = ((__pyx_v_tc0 + __pyx_v_tcw) - (__pyx_v_tb[1]));
  (__pyx_v_tvs[2]) = ((__pyx_v_tc1 + __pyx_v_tch) - (__pyx_v_tb[2]));

  /* "kivy\graphics\vertex_instructions.pyx":744
 *         ths[1] = tc0 + tb[3];      tvs[1] = tc1 + tb[0]
 *         ths[2] = tc0 + tcw-tb[1];  tvs[2] = tc1 + tch - tb[2]
 *         ths[3] = tc0 + tcw;        tvs[3] = tc1 + tch             # <<<<<<<<<<<<<<
 * 
 *         '''
 */
  (__pyx_v_ths[3]) = (__pyx_v_tc0 + __pyx_v_tcw);
  (__pyx_v_tvs[3]) = (__pyx_v_tc1 + __pyx_v_tch);

  /* "kivy\graphics\vertex_instructions.pyx":761
 *         # WARNING we are allocating the vertices as a float
 *         # because we know exactly the format.
 *         assert(sizeof(vertex_t) == 4 * sizeof(float))             # <<<<<<<<<<<<<<
 *         cdef float *vertices = [
 *             hs[0], vs[0], ths[0], tvs[0], #v0
 */
  #ifndef CYTHON_WITHOUT_ASSERTIONS
  if (unlikely(!((sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)) == (4 * (sizeof(float)))))) {
    PyErr_SetNone(PyExc_AssertionError);
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 761; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  #endif

  /* "kivy\graphics\vertex_instructions.pyx":778
 *             hs[2], vs[1], ths[2], tvs[1], #v13
 *             hs[2], vs[2], ths[2], tvs[2], #v14
 *             hs[1], vs[2], ths[1], tvs[2]] #v15             # <<<<<<<<<<<<<<
 * 
 *         cdef unsigned short *indices = [
 */
  __pyx_t_14[0] = (__pyx_v_hs[0]);
  __pyx_t_14[1] = (__pyx_v_vs[0]);
  __pyx_t_14[2] = (__pyx_v_ths[0]);
  __pyx_t_14[3] = (__pyx_v_tvs[0]);
  __pyx_t_14[4] = (__pyx_v_hs[1]);
  __pyx_t_14[5] = (__pyx_v_vs[0]);
  __pyx_t_14[6] = (__pyx_v_ths[1]);
  __pyx_t_14[7] = (__pyx_v_tvs[0]);
  __pyx_t_14[8] = (__pyx_v_hs[2]);
  __pyx_t_14[9] = (__pyx_v_vs[0]);
  __pyx_t_14[10] = (__pyx_v_ths[2]);
  __pyx_t_14[11] = (__pyx_v_tvs[0]);
  __pyx_t_14[12] = (__pyx_v_hs[3]);
  __pyx_t_14[13] = (__pyx_v_vs[0]);
  __pyx_t_14[14] = (__pyx_v_ths[3]);
  __pyx_t_14[15] = (__pyx_v_tvs[0]);
  __pyx_t_14[16] = (__pyx_v_hs[3]);
  __pyx_t_14[17] = (__pyx_v_vs[1]);
  __pyx_t_14[18] = (__pyx_v_ths[3]);
  __pyx_t_14[19] = (__pyx_v_tvs[1]);
  __pyx_t_14[20] = (__pyx_v_hs[3]);
  __pyx_t_14[21] = (__pyx_v_vs[2]);
  __pyx_t_14[22] = (__pyx_v_ths[3]);
  __pyx_t_14[23] = (__pyx_v_tvs[2]);
  __pyx_t_14[24] = (__pyx_v_hs[3]);
  __pyx_t_14[25] = (__pyx_v_vs[3]);
  __pyx_t_14[26] = (__pyx_v_ths[3]);
  __pyx_t_14[27] = (__pyx_v_tvs[3]);
  __pyx_t_14[28] = (__pyx_v_hs[2]);
  __pyx_t_14[29] = (__pyx_v_vs[3]);
  __pyx_t_14[30] = (__pyx_v_ths[2]);
  __pyx_t_14[31] = (__pyx_v_tvs[3]);
  __pyx_t_14[32] = (__pyx_v_hs[1]);
  __pyx_t_14[33] = (__pyx_v_vs[3]);
  __pyx_t_14[34] = (__pyx_v_ths[1]);
  __pyx_t_14[35] = (__pyx_v_tvs[3]);
  __pyx_t_14[36] = (__pyx_v_hs[0]);
  __pyx_t_14[37] = (__pyx_v_vs[3]);
  __pyx_t_14[38] = (__pyx_v_ths[0]);
  __pyx_t_14[39] = (__pyx_v_tvs[3]);
  __pyx_t_14[40] = (__pyx_v_hs[0]);
  __pyx_t_14[41] = (__pyx_v_vs[2]);
  __pyx_t_14[42] = (__pyx_v_ths[0]);
  __pyx_t_14[43] = (__pyx_v_tvs[2]);
  __pyx_t_14[44] = (__pyx_v_hs[0]);
  __pyx_t_14[45] = (__pyx_v_vs[1]);
  __pyx_t_14[46] = (__pyx_v_ths[0]);
  __pyx_t_14[47] = (__pyx_v_tvs[1]);
  __pyx_t_14[48] = (__pyx_v_hs[1]);
  __pyx_t_14[49] = (__pyx_v_vs[1]);
  __pyx_t_14[50] = (__pyx_v_ths[1]);
  __pyx_t_14[51] = (__pyx_v_tvs[1]);
  __pyx_t_14[52] = (__pyx_v_hs[2]);
  __pyx_t_14[53] = (__pyx_v_vs[1]);
  __pyx_t_14[54] = (__pyx_v_ths[2]);
  __pyx_t_14[55] = (__pyx_v_tvs[1]);
  __pyx_t_14[56] = (__pyx_v_hs[2]);
  __pyx_t_14[57] = (__pyx_v_vs[2]);
  __pyx_t_14[58] = (__pyx_v_ths[2]);
  __pyx_t_14[59] = (__pyx_v_tvs[2]);
  __pyx_t_14[60] = (__pyx_v_hs[1]);
  __pyx_t_14[61] = (__pyx_v_vs[2]);
  __pyx_t_14[62] = (__pyx_v_ths[1]);
  __pyx_t_14[63] = (__pyx_v_tvs[2]);
  __pyx_v_vertices = __pyx_t_14;

  /* "kivy\graphics\vertex_instructions.pyx":780
 *             hs[1], vs[2], ths[1], tvs[2]] #v15
 * 
 *         cdef unsigned short *indices = [             # <<<<<<<<<<<<<<
 *              0,  1, 12,    12, 11,  0,  # bottom left
 *              1,  2, 13,    13, 12,  1,  # bottom middle
 */
  __pyx_t_15[0] = 0;
  __pyx_t_15[1] = 1;
  __pyx_t_15[2] = 12;
  __pyx_t_15[3] = 12;
  __pyx_t_15[4] = 11;
  __pyx_t_15[5] = 0;
  __pyx_t_15[6] = 1;
  __pyx_t_15[7] = 2;
  __pyx_t_15[8] = 13;
  __pyx_t_15[9] = 13;
  __pyx_t_15[10] = 12;
  __pyx_t_15[11] = 1;
  __pyx_t_15[12] = 2;
  __pyx_t_15[13] = 3;
  __pyx_t_15[14] = 4;
  __pyx_t_15[15] = 4;
  __pyx_t_15[16] = 13;
  __pyx_t_15[17] = 2;
  __pyx_t_15[18] = 13;
  __pyx_t_15[19] = 4;
  __pyx_t_15[20] = 5;
  __pyx_t_15[21] = 5;
  __pyx_t_15[22] = 14;
  __pyx_t_15[23] = 13;
  __pyx_t_15[24] = 14;
  __pyx_t_15[25] = 5;
  __pyx_t_15[26] = 6;
  __pyx_t_15[27] = 6;
  __pyx_t_15[28] = 7;
  __pyx_t_15[29] = 14;
  __pyx_t_15[30] = 15;
  __pyx_t_15[31] = 14;
  __pyx_t_15[32] = 7;
  __pyx_t_15[33] = 7;
  __pyx_t_15[34] = 8;
  __pyx_t_15[35] = 15;
  __pyx_t_15[36] = 10;
  __pyx_t_15[37] = 15;
  __pyx_t_15[38] = 8;
  __pyx_t_15[39] = 8;
  __pyx_t_15[40] = 9;
  __pyx_t_15[41] = 10;
  __pyx_t_15[42] = 11;
  __pyx_t_15[43] = 12;
  __pyx_t_15[44] = 15;
  __pyx_t_15[45] = 15;
  __pyx_t_15[46] = 10;
  __pyx_t_15[47] = 11;
  __pyx_t_15[48] = 12;
  __pyx_t_15[49] = 13;
  __pyx_t_15[50] = 14;
  __pyx_t_15[51] = 14;
  __pyx_t_15[52] = 15;
  __pyx_t_15[53] = 12;
  __pyx_v_indices = __pyx_t_15;

  /* "kivy\graphics\vertex_instructions.pyx":791
 *             12, 13, 14,    14, 15, 12]  # center middel
 * 
 *         self.batch.set_data(<vertex_t *>vertices, 16, indices, 54)             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.__pyx_base.batch, ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)__pyx_v_vertices), 16, __pyx_v_indices, 54);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_11);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.BorderImage.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_XDECREF(__pyx_v_b);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage_6border___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":797
 *         '''Property for getting/setting the border of the class
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._border
 *         def __set__(self, b):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage_6border___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":798
 *         '''
 *         def __get__(self):
 *             return self._border             # <<<<<<<<<<<<<<
 *         def __set__(self, b):
 *             self._border = list(b)
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->_border));
  __pyx_r = ((PyObject *)__pyx_v_self->_border);
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_b); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_b) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)__pyx_v_self), ((PyObject *)__pyx_v_b));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":799
 *         def __get__(self):
 *             return self._border
 *         def __set__(self, b):             # <<<<<<<<<<<<<<
 *             self._border = list(b)
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *__pyx_v_self, PyObject *__pyx_v_b) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":800
 *             return self._border
 *         def __set__(self, b):
 *             self._border = list(b)             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_v_b);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_b);
  __Pyx_GIVEREF(__pyx_v_b);
  __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)(&PyList_Type))), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
  __Pyx_GIVEREF(__pyx_t_2);
  __Pyx_GOTREF(__pyx_v_self->_border);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->_border));
  __pyx_v_self->_border = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":801
 *         def __set__(self, b):
 *             self._border = list(b)
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_BorderImage *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.BorderImage.border.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  CYTHON_UNUSED PyObject *__pyx_v_args = 0;
  PyObject *__pyx_v_kwargs = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  if (unlikely(__pyx_kwds) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 1))) return -1;
  __pyx_v_kwargs = (__pyx_kwds) ? PyDict_Copy(__pyx_kwds) : PyDict_New();
  if (unlikely(!__pyx_v_kwargs)) return -1;
  __Pyx_GOTREF(__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_args);
  __pyx_v_args = __pyx_args;
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse___init__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self), __pyx_v_args, __pyx_v_kwargs);
  __Pyx_XDECREF(__pyx_v_args);
  __Pyx_XDECREF(__pyx_v_kwargs);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":822
 *     cdef float _angle_end
 * 
 *     def __init__(self, *args, **kwargs):             # <<<<<<<<<<<<<<
 *         Rectangle.__init__(self, **kwargs)
 *         self.batch.set_mode('triangle_fan')
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse___init__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_args, PyObject *__pyx_v_kwargs) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  int __pyx_t_6;
  float __pyx_t_7;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":823
 * 
 *     def __init__(self, *args, **kwargs):
 *         Rectangle.__init__(self, **kwargs)             # <<<<<<<<<<<<<<
 *         self.batch.set_mode('triangle_fan')
 *         self._segments = kwargs.get('segments') or 180
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)((PyObject*)__pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle)), __pyx_n_s____init__); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_v_self));
  PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
  __pyx_t_3 = ((PyObject *)__pyx_v_kwargs);
  __Pyx_INCREF(__pyx_t_3);
  __pyx_t_4 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":824
 *     def __init__(self, *args, **kwargs):
 *         Rectangle.__init__(self, **kwargs)
 *         self.batch.set_mode('triangle_fan')             # <<<<<<<<<<<<<<
 *         self._segments = kwargs.get('segments') or 180
 *         self._angle_start = kwargs.get('angle_start') or 0
 */
  __pyx_t_4 = ((PyObject *)__pyx_n_s__triangle_fan);
  __Pyx_INCREF(__pyx_t_4);
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.__pyx_base.batch->__pyx_vtab)->set_mode(__pyx_v_self->__pyx_base.__pyx_base.batch, ((PyObject*)__pyx_t_4));
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":825
 *         Rectangle.__init__(self, **kwargs)
 *         self.batch.set_mode('triangle_fan')
 *         self._segments = kwargs.get('segments') or 180             # <<<<<<<<<<<<<<
 *         self._angle_start = kwargs.get('angle_start') or 0
 *         self._angle_end = kwargs.get('angle_end') or 360
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__segments), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 825; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 825; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(__pyx_int_180);
    __pyx_t_3 = __pyx_int_180;
  } else {
    __pyx_t_3 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_6 = __Pyx_PyInt_AsInt(__pyx_t_3); if (unlikely((__pyx_t_6 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 825; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_v_self->_segments = __pyx_t_6;

  /* "kivy\graphics\vertex_instructions.pyx":826
 *         self.batch.set_mode('triangle_fan')
 *         self._segments = kwargs.get('segments') or 180
 *         self._angle_start = kwargs.get('angle_start') or 0             # <<<<<<<<<<<<<<
 *         self._angle_end = kwargs.get('angle_end') or 360
 * 
 */
  __pyx_t_3 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__angle_start), Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 826; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 826; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_INCREF(__pyx_int_0);
    __pyx_t_4 = __pyx_int_0;
  } else {
    __pyx_t_4 = __pyx_t_3;
    __pyx_t_3 = 0;
  }
  __pyx_t_7 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_7 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 826; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_v_self->_angle_start = __pyx_t_7;

  /* "kivy\graphics\vertex_instructions.pyx":827
 *         self._segments = kwargs.get('segments') or 180
 *         self._angle_start = kwargs.get('angle_start') or 0
 *         self._angle_end = kwargs.get('angle_end') or 360             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_t_4 = __Pyx_PyDict_GetItemDefault(((PyObject *)__pyx_v_kwargs), ((PyObject *)__pyx_n_s__angle_end), Py_None); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (!__pyx_t_5) {
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_INCREF(__pyx_int_360);
    __pyx_t_3 = __pyx_int_360;
  } else {
    __pyx_t_3 = __pyx_t_4;
    __pyx_t_4 = 0;
  }
  __pyx_t_7 = __pyx_PyFloat_AsFloat(__pyx_t_3); if (unlikely((__pyx_t_7 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_v_self->_angle_end = __pyx_t_7;

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":829
 *         self._angle_end = kwargs.get('angle_end') or 360
 * 
 *     cdef void build(self):             # <<<<<<<<<<<<<<
 *         cdef list tc = self.tex_coords
 *         cdef int i, angle_dir
 */

static void __pyx_f_4kivy_8graphics_19vertex_instructions_7Ellipse_build(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self) {
  PyObject *__pyx_v_tc = 0;
  int __pyx_v_i;
  int __pyx_v_angle_dir;
  float __pyx_v_angle_start;
  float __pyx_v_angle_end;
  float __pyx_v_angle_range;
  float __pyx_v_x;
  float __pyx_v_y;
  float __pyx_v_angle;
  float __pyx_v_rx;
  float __pyx_v_ry;
  float __pyx_v_ttx;
  float __pyx_v_tty;
  float __pyx_v_tx;
  float __pyx_v_ty;
  float __pyx_v_tw;
  float __pyx_v_th;
  struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *__pyx_v_vertices;
  unsigned short *__pyx_v_indices;
  int __pyx_v_count;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  float __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  long __pyx_t_6;
  int __pyx_t_7;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("build", 0);

  /* "kivy\graphics\vertex_instructions.pyx":830
 * 
 *     cdef void build(self):
 *         cdef list tc = self.tex_coords             # <<<<<<<<<<<<<<
 *         cdef int i, angle_dir
 *         cdef float angle_start, angle_end, angle_range
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__tex_coords); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 830; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyList_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected list, got %.200s", Py_TYPE(__pyx_t_1)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 830; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_tc = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":834
 *         cdef float angle_start, angle_end, angle_range
 *         cdef float x, y, angle, rx, ry, ttx, tty, tx, ty, tw, th
 *         cdef vertex_t *vertices = NULL             # <<<<<<<<<<<<<<
 *         cdef unsigned short *indices = NULL
 *         cdef int count = self._segments
 */
  __pyx_v_vertices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":835
 *         cdef float x, y, angle, rx, ry, ttx, tty, tx, ty, tw, th
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL             # <<<<<<<<<<<<<<
 *         cdef int count = self._segments
 * 
 */
  __pyx_v_indices = NULL;

  /* "kivy\graphics\vertex_instructions.pyx":836
 *         cdef vertex_t *vertices = NULL
 *         cdef unsigned short *indices = NULL
 *         cdef int count = self._segments             # <<<<<<<<<<<<<<
 * 
 *         tx = tc[0]
 */
  __pyx_v_count = __pyx_v_self->_segments;

  /* "kivy\graphics\vertex_instructions.pyx":838
 *         cdef int count = self._segments
 * 
 *         tx = tc[0]             # <<<<<<<<<<<<<<
 *         ty = tc[1]
 *         tw = tc[4] - tx
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 0, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_tx = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":839
 * 
 *         tx = tc[0]
 *         ty = tc[1]             # <<<<<<<<<<<<<<
 *         tw = tc[4] - tx
 *         th = tc[5] - ty
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 1, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_ty = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":840
 *         tx = tc[0]
 *         ty = tc[1]
 *         tw = tc[4] - tx             # <<<<<<<<<<<<<<
 *         th = tc[5] - ty
 *         angle = 0.0
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 4, sizeof(long), PyInt_FromLong); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = PyFloat_FromDouble(__pyx_v_tx); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_4 = PyNumber_Subtract(__pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_4); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_v_tw = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":841
 *         ty = tc[1]
 *         tw = tc[4] - tx
 *         th = tc[5] - ty             # <<<<<<<<<<<<<<
 *         angle = 0.0
 *         rx = 0.5 * self.w
 */
  if (unlikely(((PyObject *)__pyx_v_tc) == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_t_4 = __Pyx_GetItemInt_List(((PyObject *)__pyx_v_tc), 5, sizeof(long), PyInt_FromLong); if (!__pyx_t_4) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_3 = PyFloat_FromDouble(__pyx_v_ty); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_1 = PyNumber_Subtract(__pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_2 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_2 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_th = __pyx_t_2;

  /* "kivy\graphics\vertex_instructions.pyx":842
 *         tw = tc[4] - tx
 *         th = tc[5] - ty
 *         angle = 0.0             # <<<<<<<<<<<<<<
 *         rx = 0.5 * self.w
 *         ry = 0.5 * self.h
 */
  __pyx_v_angle = 0.0;

  /* "kivy\graphics\vertex_instructions.pyx":843
 *         th = tc[5] - ty
 *         angle = 0.0
 *         rx = 0.5 * self.w             # <<<<<<<<<<<<<<
 *         ry = 0.5 * self.h
 * 
 */
  __pyx_v_rx = (0.5 * __pyx_v_self->__pyx_base.w);

  /* "kivy\graphics\vertex_instructions.pyx":844
 *         angle = 0.0
 *         rx = 0.5 * self.w
 *         ry = 0.5 * self.h             # <<<<<<<<<<<<<<
 * 
 *         vertices = <vertex_t *>malloc((count + 2) * sizeof(vertex_t))
 */
  __pyx_v_ry = (0.5 * __pyx_v_self->__pyx_base.h);

  /* "kivy\graphics\vertex_instructions.pyx":846
 *         ry = 0.5 * self.h
 * 
 *         vertices = <vertex_t *>malloc((count + 2) * sizeof(vertex_t))             # <<<<<<<<<<<<<<
 *         if vertices == NULL:
 *             raise MemoryError('vertices')
 */
  __pyx_v_vertices = ((struct __pyx_t_4kivy_8graphics_6vertex_vertex_t *)malloc(((__pyx_v_count + 2) * (sizeof(struct __pyx_t_4kivy_8graphics_6vertex_vertex_t)))));

  /* "kivy\graphics\vertex_instructions.pyx":847
 * 
 *         vertices = <vertex_t *>malloc((count + 2) * sizeof(vertex_t))
 *         if vertices == NULL:             # <<<<<<<<<<<<<<
 *             raise MemoryError('vertices')
 * 
 */
  __pyx_t_5 = (__pyx_v_vertices == NULL);
  if (__pyx_t_5) {

    /* "kivy\graphics\vertex_instructions.pyx":848
 *         vertices = <vertex_t *>malloc((count + 2) * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc((count + 2) * sizeof(unsigned short))
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_46), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L3;
  }
  __pyx_L3:;

  /* "kivy\graphics\vertex_instructions.pyx":850
 *             raise MemoryError('vertices')
 * 
 *         indices = <unsigned short *>malloc((count + 2) * sizeof(unsigned short))             # <<<<<<<<<<<<<<
 *         if indices == NULL:
 *             free(vertices)
 */
  __pyx_v_indices = ((unsigned short *)malloc(((__pyx_v_count + 2) * (sizeof(unsigned short)))));

  /* "kivy\graphics\vertex_instructions.pyx":851
 * 
 *         indices = <unsigned short *>malloc((count + 2) * sizeof(unsigned short))
 *         if indices == NULL:             # <<<<<<<<<<<<<<
 *             free(vertices)
 *             raise MemoryError('indices')
 */
  __pyx_t_5 = (__pyx_v_indices == NULL);
  if (__pyx_t_5) {

    /* "kivy\graphics\vertex_instructions.pyx":852
 *         indices = <unsigned short *>malloc((count + 2) * sizeof(unsigned short))
 *         if indices == NULL:
 *             free(vertices)             # <<<<<<<<<<<<<<
 *             raise MemoryError('indices')
 * 
 */
    free(__pyx_v_vertices);

    /* "kivy\graphics\vertex_instructions.pyx":853
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         # calculate the start/end angle in radians, and adapt the range
 */
    __pyx_t_1 = PyObject_Call(__pyx_builtin_MemoryError, ((PyObject *)__pyx_k_tuple_47), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_Raise(__pyx_t_1, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    goto __pyx_L4;
  }
  __pyx_L4:;

  /* "kivy\graphics\vertex_instructions.pyx":856
 * 
 *         # calculate the start/end angle in radians, and adapt the range
 *         if self.angle_end > self.angle_start:             # <<<<<<<<<<<<<<
 *             angle_dir = 1
 *         else:
 */
  __pyx_t_1 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__angle_end); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = PyObject_GetAttr(((PyObject *)__pyx_v_self), __pyx_n_s__angle_start); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_4 = PyObject_RichCompare(__pyx_t_1, __pyx_t_3, Py_GT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  if (__pyx_t_5) {

    /* "kivy\graphics\vertex_instructions.pyx":857
 *         # calculate the start/end angle in radians, and adapt the range
 *         if self.angle_end > self.angle_start:
 *             angle_dir = 1             # <<<<<<<<<<<<<<
 *         else:
 *             angle_dir = -1
 */
    __pyx_v_angle_dir = 1;
    goto __pyx_L5;
  }
  /*else*/ {

    /* "kivy\graphics\vertex_instructions.pyx":859
 *             angle_dir = 1
 *         else:
 *             angle_dir = -1             # <<<<<<<<<<<<<<
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = self._angle_start * 0.017453292519943295
 */
    __pyx_v_angle_dir = -1;
  }
  __pyx_L5:;

  /* "kivy\graphics\vertex_instructions.pyx":861
 *             angle_dir = -1
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = self._angle_start * 0.017453292519943295             # <<<<<<<<<<<<<<
 *         angle_end = self._angle_end * 0.017453292519943295
 *         angle_range = abs(angle_end - angle_start) / self._segments
 */
  __pyx_v_angle_start = (__pyx_v_self->_angle_start * 0.017453292519943295);

  /* "kivy\graphics\vertex_instructions.pyx":862
 *         # rad = deg * (pi / 180), where pi/180 = 0.0174...
 *         angle_start = self._angle_start * 0.017453292519943295
 *         angle_end = self._angle_end * 0.017453292519943295             # <<<<<<<<<<<<<<
 *         angle_range = abs(angle_end - angle_start) / self._segments
 * 
 */
  __pyx_v_angle_end = (__pyx_v_self->_angle_end * 0.017453292519943295);

  /* "kivy\graphics\vertex_instructions.pyx":863
 *         angle_start = self._angle_start * 0.017453292519943295
 *         angle_end = self._angle_end * 0.017453292519943295
 *         angle_range = abs(angle_end - angle_start) / self._segments             # <<<<<<<<<<<<<<
 * 
 *         # add start vertice in the middle
 */
  __pyx_t_2 = fabsf((__pyx_v_angle_end - __pyx_v_angle_start));
  if (unlikely(__pyx_v_self->_segments == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 863; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_v_angle_range = (__pyx_t_2 / __pyx_v_self->_segments);

  /* "kivy\graphics\vertex_instructions.pyx":866
 * 
 *         # add start vertice in the middle
 *         x = self.x + rx             # <<<<<<<<<<<<<<
 *         y = self.y + ry
 *         ttx = ((x - self.x) / self.w) * tw + tx
 */
  __pyx_v_x = (__pyx_v_self->__pyx_base.x + __pyx_v_rx);

  /* "kivy\graphics\vertex_instructions.pyx":867
 *         # add start vertice in the middle
 *         x = self.x + rx
 *         y = self.y + ry             # <<<<<<<<<<<<<<
 *         ttx = ((x - self.x) / self.w) * tw + tx
 *         tty = ((y - self.y) / self.h) * th + ty
 */
  __pyx_v_y = (__pyx_v_self->__pyx_base.y + __pyx_v_ry);

  /* "kivy\graphics\vertex_instructions.pyx":868
 *         x = self.x + rx
 *         y = self.y + ry
 *         ttx = ((x - self.x) / self.w) * tw + tx             # <<<<<<<<<<<<<<
 *         tty = ((y - self.y) / self.h) * th + ty
 *         vertices[0].x = self.x + rx
 */
  __pyx_t_2 = (__pyx_v_x - __pyx_v_self->__pyx_base.x);
  if (unlikely(__pyx_v_self->__pyx_base.w == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_v_ttx = (((__pyx_t_2 / __pyx_v_self->__pyx_base.w) * __pyx_v_tw) + __pyx_v_tx);

  /* "kivy\graphics\vertex_instructions.pyx":869
 *         y = self.y + ry
 *         ttx = ((x - self.x) / self.w) * tw + tx
 *         tty = ((y - self.y) / self.h) * th + ty             # <<<<<<<<<<<<<<
 *         vertices[0].x = self.x + rx
 *         vertices[0].y = self.y + ry
 */
  __pyx_t_2 = (__pyx_v_y - __pyx_v_self->__pyx_base.y);
  if (unlikely(__pyx_v_self->__pyx_base.h == 0)) {
    PyErr_Format(PyExc_ZeroDivisionError, "float division");
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __pyx_v_tty = (((__pyx_t_2 / __pyx_v_self->__pyx_base.h) * __pyx_v_th) + __pyx_v_ty);

  /* "kivy\graphics\vertex_instructions.pyx":870
 *         ttx = ((x - self.x) / self.w) * tw + tx
 *         tty = ((y - self.y) / self.h) * th + ty
 *         vertices[0].x = self.x + rx             # <<<<<<<<<<<<<<
 *         vertices[0].y = self.y + ry
 *         vertices[0].s0 = ttx
 */
  (__pyx_v_vertices[0]).x = (__pyx_v_self->__pyx_base.x + __pyx_v_rx);

  /* "kivy\graphics\vertex_instructions.pyx":871
 *         tty = ((y - self.y) / self.h) * th + ty
 *         vertices[0].x = self.x + rx
 *         vertices[0].y = self.y + ry             # <<<<<<<<<<<<<<
 *         vertices[0].s0 = ttx
 *         vertices[0].t0 = tty
 */
  (__pyx_v_vertices[0]).y = (__pyx_v_self->__pyx_base.y + __pyx_v_ry);

  /* "kivy\graphics\vertex_instructions.pyx":872
 *         vertices[0].x = self.x + rx
 *         vertices[0].y = self.y + ry
 *         vertices[0].s0 = ttx             # <<<<<<<<<<<<<<
 *         vertices[0].t0 = tty
 *         indices[0] = 0
 */
  (__pyx_v_vertices[0]).s0 = __pyx_v_ttx;

  /* "kivy\graphics\vertex_instructions.pyx":873
 *         vertices[0].y = self.y + ry
 *         vertices[0].s0 = ttx
 *         vertices[0].t0 = tty             # <<<<<<<<<<<<<<
 *         indices[0] = 0
 * 
 */
  (__pyx_v_vertices[0]).t0 = __pyx_v_tty;

  /* "kivy\graphics\vertex_instructions.pyx":874
 *         vertices[0].s0 = ttx
 *         vertices[0].t0 = tty
 *         indices[0] = 0             # <<<<<<<<<<<<<<
 * 
 *         for i in xrange(1, count + 2):
 */
  (__pyx_v_indices[0]) = 0;

  /* "kivy\graphics\vertex_instructions.pyx":876
 *         indices[0] = 0
 * 
 *         for i in xrange(1, count + 2):             # <<<<<<<<<<<<<<
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             x = (self.x+rx)+ (rx*sin(angle))
 */
  __pyx_t_6 = (__pyx_v_count + 2);
  for (__pyx_t_7 = 1; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) {
    __pyx_v_i = __pyx_t_7;

    /* "kivy\graphics\vertex_instructions.pyx":877
 * 
 *         for i in xrange(1, count + 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)             # <<<<<<<<<<<<<<
 *             x = (self.x+rx)+ (rx*sin(angle))
 *             y = (self.y+ry)+ (ry*cos(angle))
 */
    __pyx_v_angle = (__pyx_v_angle_start + ((__pyx_v_angle_dir * (__pyx_v_i - 1)) * __pyx_v_angle_range));

    /* "kivy\graphics\vertex_instructions.pyx":878
 *         for i in xrange(1, count + 2):
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             x = (self.x+rx)+ (rx*sin(angle))             # <<<<<<<<<<<<<<
 *             y = (self.y+ry)+ (ry*cos(angle))
 *             ttx = ((x-self.x)/self.w)*tw + tx
 */
    __pyx_v_x = ((__pyx_v_self->__pyx_base.x + __pyx_v_rx) + (__pyx_v_rx * sin(__pyx_v_angle)));

    /* "kivy\graphics\vertex_instructions.pyx":879
 *             angle = angle_start + (angle_dir * (i - 1) * angle_range)
 *             x = (self.x+rx)+ (rx*sin(angle))
 *             y = (self.y+ry)+ (ry*cos(angle))             # <<<<<<<<<<<<<<
 *             ttx = ((x-self.x)/self.w)*tw + tx
 *             tty = ((y-self.y)/self.h)*th + ty
 */
    __pyx_v_y = ((__pyx_v_self->__pyx_base.y + __pyx_v_ry) + (__pyx_v_ry * cos(__pyx_v_angle)));

    /* "kivy\graphics\vertex_instructions.pyx":880
 *             x = (self.x+rx)+ (rx*sin(angle))
 *             y = (self.y+ry)+ (ry*cos(angle))
 *             ttx = ((x-self.x)/self.w)*tw + tx             # <<<<<<<<<<<<<<
 *             tty = ((y-self.y)/self.h)*th + ty
 *             vertices[i].x = x
 */
    __pyx_t_2 = (__pyx_v_x - __pyx_v_self->__pyx_base.x);
    if (unlikely(__pyx_v_self->__pyx_base.w == 0)) {
      PyErr_Format(PyExc_ZeroDivisionError, "float division");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 880; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_v_ttx = (((__pyx_t_2 / __pyx_v_self->__pyx_base.w) * __pyx_v_tw) + __pyx_v_tx);

    /* "kivy\graphics\vertex_instructions.pyx":881
 *             y = (self.y+ry)+ (ry*cos(angle))
 *             ttx = ((x-self.x)/self.w)*tw + tx
 *             tty = ((y-self.y)/self.h)*th + ty             # <<<<<<<<<<<<<<
 *             vertices[i].x = x
 *             vertices[i].y = y
 */
    __pyx_t_2 = (__pyx_v_y - __pyx_v_self->__pyx_base.y);
    if (unlikely(__pyx_v_self->__pyx_base.h == 0)) {
      PyErr_Format(PyExc_ZeroDivisionError, "float division");
      {__pyx_filename = __pyx_f[0]; __pyx_lineno = 881; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
    }
    __pyx_v_tty = (((__pyx_t_2 / __pyx_v_self->__pyx_base.h) * __pyx_v_th) + __pyx_v_ty);

    /* "kivy\graphics\vertex_instructions.pyx":882
 *             ttx = ((x-self.x)/self.w)*tw + tx
 *             tty = ((y-self.y)/self.h)*th + ty
 *             vertices[i].x = x             # <<<<<<<<<<<<<<
 *             vertices[i].y = y
 *             vertices[i].s0 = ttx
 */
    (__pyx_v_vertices[__pyx_v_i]).x = __pyx_v_x;

    /* "kivy\graphics\vertex_instructions.pyx":883
 *             tty = ((y-self.y)/self.h)*th + ty
 *             vertices[i].x = x
 *             vertices[i].y = y             # <<<<<<<<<<<<<<
 *             vertices[i].s0 = ttx
 *             vertices[i].t0 = tty
 */
    (__pyx_v_vertices[__pyx_v_i]).y = __pyx_v_y;

    /* "kivy\graphics\vertex_instructions.pyx":884
 *             vertices[i].x = x
 *             vertices[i].y = y
 *             vertices[i].s0 = ttx             # <<<<<<<<<<<<<<
 *             vertices[i].t0 = tty
 *             indices[i] = i
 */
    (__pyx_v_vertices[__pyx_v_i]).s0 = __pyx_v_ttx;

    /* "kivy\graphics\vertex_instructions.pyx":885
 *             vertices[i].y = y
 *             vertices[i].s0 = ttx
 *             vertices[i].t0 = tty             # <<<<<<<<<<<<<<
 *             indices[i] = i
 * 
 */
    (__pyx_v_vertices[__pyx_v_i]).t0 = __pyx_v_tty;

    /* "kivy\graphics\vertex_instructions.pyx":886
 *             vertices[i].s0 = ttx
 *             vertices[i].t0 = tty
 *             indices[i] = i             # <<<<<<<<<<<<<<
 * 
 *         self.batch.set_data(vertices, count + 2, indices, count + 2)
 */
    (__pyx_v_indices[__pyx_v_i]) = __pyx_v_i;
  }

  /* "kivy\graphics\vertex_instructions.pyx":888
 *             indices[i] = i
 * 
 *         self.batch.set_data(vertices, count + 2, indices, count + 2)             # <<<<<<<<<<<<<<
 * 
 *         free(vertices)
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch *)__pyx_v_self->__pyx_base.__pyx_base.batch->__pyx_vtab)->set_data(__pyx_v_self->__pyx_base.__pyx_base.batch, __pyx_v_vertices, (__pyx_v_count + 2), __pyx_v_indices, (__pyx_v_count + 2));

  /* "kivy\graphics\vertex_instructions.pyx":890
 *         self.batch.set_data(vertices, count + 2, indices, count + 2)
 * 
 *         free(vertices)             # <<<<<<<<<<<<<<
 *         free(indices)
 * 
 */
  free(__pyx_v_vertices);

  /* "kivy\graphics\vertex_instructions.pyx":891
 * 
 *         free(vertices)
 *         free(indices)             # <<<<<<<<<<<<<<
 * 
 *     property segments:
 */
  free(__pyx_v_indices);

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_WriteUnraisable("kivy.graphics.vertex_instructions.Ellipse.build", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_tc);
  __Pyx_RefNannyFinishContext();
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":896
 *         '''Property for getting/setting the number of segments of the ellipse
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._segments
 *         def __set__(self, value):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":897
 *         '''
 *         def __get__(self):
 *             return self._segments             # <<<<<<<<<<<<<<
 *         def __set__(self, value):
 *             self._segments = value
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyInt_FromLong(__pyx_v_self->_segments); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 897; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.segments.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":898
 *         def __get__(self):
 *             return self._segments
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             self._segments = value
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":899
 *             return self._segments
 *         def __set__(self, value):
 *             self._segments = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = __Pyx_PyInt_AsInt(__pyx_v_value); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_segments = __pyx_t_1;

  /* "kivy\graphics\vertex_instructions.pyx":900
 *         def __set__(self, value):
 *             self._segments = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property angle_start:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.segments.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":905
 *         '''Angle start of the ellipse in degrees, default to 0
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._angle_start
 *         def __set__(self, value):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":906
 *         '''
 *         def __get__(self):
 *             return self._angle_start             # <<<<<<<<<<<<<<
 *         def __set__(self, value):
 *             self._angle_start = value
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->_angle_start); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 906; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.angle_start.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":907
 *         def __get__(self):
 *             return self._angle_start
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             self._angle_start = value
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  float __pyx_t_1;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":908
 *             return self._angle_start
 *         def __set__(self, value):
 *             self._angle_start = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = __pyx_PyFloat_AsFloat(__pyx_v_value); if (unlikely((__pyx_t_1 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 908; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_angle_start = __pyx_t_1;

  /* "kivy\graphics\vertex_instructions.pyx":909
 *         def __set__(self, value):
 *             self._angle_start = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 *     property angle_end:
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.angle_start.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end___get__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":914
 *         '''Angle end of the ellipse in degrees, default to 360
 *         '''
 *         def __get__(self):             # <<<<<<<<<<<<<<
 *             return self._angle_end
 *         def __set__(self, value):
 */

static PyObject *__pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end___get__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__get__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":915
 *         '''
 *         def __get__(self):
 *             return self._angle_end             # <<<<<<<<<<<<<<
 *         def __set__(self, value):
 *             self._angle_end = value
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->_angle_end); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.angle_end.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_2__set__(((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self), ((PyObject *)__pyx_v_value));
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "kivy\graphics\vertex_instructions.pyx":916
 *         def __get__(self):
 *             return self._angle_end
 *         def __set__(self, value):             # <<<<<<<<<<<<<<
 *             self._angle_end = value
 *             self.flag_update()
 */

static int __pyx_pf_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_2__set__(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  float __pyx_t_1;
  int __pyx_lineno = 0;
  const char *__pyx_filename = NULL;
  int __pyx_clineno = 0;
  __Pyx_RefNannySetupContext("__set__", 0);

  /* "kivy\graphics\vertex_instructions.pyx":917
 *             return self._angle_end
 *         def __set__(self, value):
 *             self._angle_end = value             # <<<<<<<<<<<<<<
 *             self.flag_update()
 * 
 */
  __pyx_t_1 = __pyx_PyFloat_AsFloat(__pyx_v_value); if (unlikely((__pyx_t_1 == (float)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_v_self->_angle_end = __pyx_t_1;

  /* "kivy\graphics\vertex_instructions.pyx":918
 *         def __set__(self, value):
 *             self._angle_end = value
 *             self.flag_update()             # <<<<<<<<<<<<<<
 * 
 */
  ((struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Ellipse *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.__pyx_base.flag_update(((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)__pyx_v_self), NULL);

  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("kivy.graphics.vertex_instructions.Ellipse.angle_end.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Line __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Line(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Line;
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->_stencil_rect = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  p->_stencil_push = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  p->_stencil_use = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  p->_stencil_unuse = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  p->_stencil_pop = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  p->_mode_args = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Line(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)o;
  Py_XDECREF(((PyObject *)p->_points));
  Py_XDECREF(((PyObject *)p->_stencil_rect));
  Py_XDECREF(((PyObject *)p->_stencil_push));
  Py_XDECREF(((PyObject *)p->_stencil_use));
  Py_XDECREF(((PyObject *)p->_stencil_unuse));
  Py_XDECREF(((PyObject *)p->_stencil_pop));
  Py_XDECREF(((PyObject *)p->_mode_args));
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Line(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)o;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  if (p->_points) {
    e = (*v)(p->_points, a); if (e) return e;
  }
  if (p->_stencil_rect) {
    e = (*v)(((PyObject*)p->_stencil_rect), a); if (e) return e;
  }
  if (p->_stencil_push) {
    e = (*v)(((PyObject*)p->_stencil_push), a); if (e) return e;
  }
  if (p->_stencil_use) {
    e = (*v)(((PyObject*)p->_stencil_use), a); if (e) return e;
  }
  if (p->_stencil_unuse) {
    e = (*v)(((PyObject*)p->_stencil_unuse), a); if (e) return e;
  }
  if (p->_stencil_pop) {
    e = (*v)(((PyObject*)p->_stencil_pop), a); if (e) return e;
  }
  if (p->_mode_args) {
    e = (*v)(p->_mode_args, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Line(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *)o;
  PyObject* tmp;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  tmp = ((PyObject*)p->_points);
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_stencil_rect);
  p->_stencil_rect = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_stencil_push);
  p->_stencil_push = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_stencil_use);
  p->_stencil_use = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_stencil_unuse);
  p->_stencil_unuse = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_stencil_pop);
  p->_stencil_pop = ((struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_mode_args);
  p->_mode_args = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_points(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6points_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_points(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6points_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_dash_length(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_dash_length(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_length_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_dash_offset(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_dash_offset(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_11dash_offset_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_width(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5width_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_width(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5width_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_cap(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_3cap_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_cap(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_3cap_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_joint(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5joint_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_joint(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5joint_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_cap_precision(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_cap_precision(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_13cap_precision_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_joint_precision(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_joint_precision(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_15joint_precision_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_close(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5close_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_close(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_5close_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_ellipse(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_7ellipse_1__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_circle(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_6circle_1__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_rectangle(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_9rectangle_1__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Line[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Line[] = {
  {(char *)"points", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_points, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_points, __Pyx_DOCSTR(__pyx_k_48), 0},
  {(char *)"dash_length", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_dash_length, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_dash_length, __Pyx_DOCSTR(__pyx_k_49), 0},
  {(char *)"dash_offset", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_dash_offset, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_dash_offset, __Pyx_DOCSTR(__pyx_k_50), 0},
  {(char *)"width", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_width, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_width, __Pyx_DOCSTR(__pyx_k_51), 0},
  {(char *)"cap", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_cap, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_cap, __Pyx_DOCSTR(__pyx_k_52), 0},
  {(char *)"joint", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_joint, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_joint, __Pyx_DOCSTR(__pyx_k_53), 0},
  {(char *)"cap_precision", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_cap_precision, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_cap_precision, __Pyx_DOCSTR(__pyx_k_54), 0},
  {(char *)"joint_precision", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_joint_precision, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_joint_precision, __Pyx_DOCSTR(__pyx_k_55), 0},
  {(char *)"close", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Line_close, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_close, __Pyx_DOCSTR(__pyx_k_56), 0},
  {(char *)"ellipse", 0, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_ellipse, __Pyx_DOCSTR(__pyx_k_57), 0},
  {(char *)"circle", 0, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_circle, __Pyx_DOCSTR(__pyx_k_58), 0},
  {(char *)"rectangle", 0, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Line_rectangle, __Pyx_DOCSTR(__pyx_k_59), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Line = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Line = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Line = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Line = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Line = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Line"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Line, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Line, /*tp_as_number*/
  &__pyx_tp_as_sequence_Line, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Line, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Line, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d line.\n\n    Drawing a line can be done easily::\n\n        with self.canvas:\n            Line(points=[100, 100, 200, 100, 100, 200], width=10)\n\n    Actually, the line have 3 internal drawing mode that you should know about\n    if you want to get the best performance of it:\n\n    #. If the :data:`width` is 1.0, then we will use standard GL_LINE drawing\n       from OpenGL. :data:`dash_length` and :data:`dash_offset` works, while\n       properties for cap and joint have no sense for this.\n    #. If the :data:`width` is > 1.0, then we will use a custom drawing method,\n       based on triangles. :data:`dash_length` and :data:`dash_offset` is not\n       working on that mode.\n       Additionally, if the current color have an alpha < 1.0, stencil will be\n       used internally to draw the line.\n\n    .. image:: images/line-instruction.png\n        :align: center\n\n    :Parameters:\n        `points`: list\n            List of points in the format (x1, y1, x2, y2...)\n        `dash_length`: int\n            Length of a segment (if dashed), default 1\n        `dash_offset`: int\n            Offset between the end of a segments and the begining of the\n            next one, default 0, changing this makes it dashed.\n        `width`: float\n            Width of the line, default 1.0\n        `cap`: str, default to 'round'\n            See :data:`cap` for more information.\n        `joint`: str, default to 'round'\n            See :data:`joint` for more information.\n        `cap_precision`: int, default to 10\n            See :data:`cap_precision` for more information\n        `joint_precision`: int, default to 10\n            See :data:`joint_precision` for more information\n        `close`: bool, default to False\n            If True, the line will be closed.\n        `circle`: list\n            If set, the :data:`points` will be set to build a circle. Check\n            :data:`circle` for more information.\n        `ellipse`: list\n            If set, the :data:`points` will be set to build an ellipse. Check\n            :data:`ellipse` for more information.\n        `rectangle`: list\n            If set, the :data:`points` will be set to build a rectangle. Check\n            :data:`rectangle` for more information.\n\n    .. versionadded:: 1.0.8\n        `dash_offset` and `dash_length` have been added\n\n    .. versionadded:: 1.4.1\n        `width`, `cap`, `joint`, `cap_precision`, `joint_precision`, `close`,\n        `ellipse`, `rectangle` have been added.\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Line, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Line, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Line, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Line, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_4Line_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Line, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Bezier __pyx_vtable_4kivy_8graphics_19vertex_instructions_Bezier;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Bezier(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Bezier;
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Bezier(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)o;
  Py_XDECREF(((PyObject *)p->_points));
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Bezier(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)o;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  if (p->_points) {
    e = (*v)(p->_points, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Bezier(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier *)o;
  PyObject* tmp;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  tmp = ((PyObject*)p->_points);
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_points(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_6points_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_points(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_6points_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_segments(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_segments(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_8segments_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_length(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_length(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_length_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_offset(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_offset(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_11dash_offset_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Bezier[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Bezier[] = {
  {(char *)"points", __pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_points, __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_points, __Pyx_DOCSTR(__pyx_k_60), 0},
  {(char *)"segments", __pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_segments, __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_segments, __Pyx_DOCSTR(__pyx_k_61), 0},
  {(char *)"dash_length", __pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_length, __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_length, __Pyx_DOCSTR(__pyx_k_62), 0},
  {(char *)"dash_offset", __pyx_getprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_offset, __pyx_setprop_4kivy_8graphics_19vertex_instructions_6Bezier_dash_offset, __Pyx_DOCSTR(__pyx_k_63), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Bezier = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Bezier = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Bezier = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Bezier = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Bezier = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Bezier"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Bezier), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Bezier, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Bezier, /*tp_as_number*/
  &__pyx_tp_as_sequence_Bezier, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Bezier, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Bezier, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d Bezier curve.\n\n    .. versionadded:: 1.0.8\n\n    :Parameters:\n        `points`: list\n            List of points in the format (x1, y1, x2, y2...)\n        `segments`: int, default to 180\n            Define how much segment is needed for drawing the ellipse.\n            The drawing will be smoother if you have lot of segment.\n        `loop`: bool, default to False\n            Set the bezier curve to join last point to first.\n        `dash_length`: int\n            length of a segment (if dashed), default 1\n        `dash_offset`: int\n            distance between the end of a segment and the start of the\n            next one, default 0, changing this makes it dashed.\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Bezier, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Bezier, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Bezier, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Bezier, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_6Bezier_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Bezier, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Mesh __pyx_vtable_4kivy_8graphics_19vertex_instructions_Mesh;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Mesh(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Mesh;
  p->_vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->_indices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Mesh(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)o;
  Py_XDECREF(((PyObject *)p->_vertices));
  Py_XDECREF(((PyObject *)p->_indices));
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Mesh(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)o;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  if (p->_vertices) {
    e = (*v)(p->_vertices, a); if (e) return e;
  }
  if (p->_indices) {
    e = (*v)(p->_indices, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Mesh(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh *)o;
  PyObject* tmp;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  tmp = ((PyObject*)p->_vertices);
  p->_vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->_indices);
  p->_indices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Mesh_vertices(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Mesh_vertices(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_8vertices_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Mesh_indices(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Mesh_indices(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_7indices_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Mesh_mode(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Mesh_mode(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_4mode_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Mesh[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Mesh[] = {
  {(char *)"vertices", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Mesh_vertices, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Mesh_vertices, __Pyx_DOCSTR(__pyx_k_64), 0},
  {(char *)"indices", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Mesh_indices, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Mesh_indices, __Pyx_DOCSTR(__pyx_k_65), 0},
  {(char *)"mode", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Mesh_mode, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Mesh_mode, __Pyx_DOCSTR(__pyx_k_66), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Mesh = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Mesh = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Mesh = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Mesh = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Mesh = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Mesh"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Mesh), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Mesh, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Mesh, /*tp_as_number*/
  &__pyx_tp_as_sequence_Mesh, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Mesh, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Mesh, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d mesh.\n\n    The format of vertices are actually fixed, this might change in a future\n    release. Right now, each vertex is described with 2D coordinates (x, y) and\n    a 2D texture coordinate (u, v).\n\n    In OpenGL ES 2.0 and in our graphics implementation, you cannot have more\n    than 65535 indices.\n\n    A list of vertices is described as::\n\n        vertices = [x1, y1, u1, v1, x2, y2, u2, v2, ...]\n                    |            |  |            |\n                    +---- i1 ----+  +---- i2 ----+\n\n    If you want to draw a triangles, put 3 vertices, then you can make an\n    indices list as:\n\n        indices = [0, 1, 2]\n\n    .. versionadded:: 1.1.0\n\n    :Parameters:\n        `vertices`: list\n            List of vertices in the format (x1, y1, u1, v1, x2, y2, u2, v2...)\n        `indices`: list\n            List of indices in the format (i1, i2, i3...)\n        `mode`: str\n            Mode of the vbo. Check :data:`mode` for more information. Default to\n            'points'.\n\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Mesh, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Mesh, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Mesh, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Mesh, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_4Mesh_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Mesh, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Point __pyx_vtable_4kivy_8graphics_19vertex_instructions_Point;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Point(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Point;
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Point(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)o;
  Py_XDECREF(((PyObject *)p->_points));
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Point(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)o;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  if (p->_points) {
    e = (*v)(p->_points, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Point(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point *)o;
  PyObject* tmp;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  tmp = ((PyObject*)p->_points);
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_5Point_points(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_6points_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_5Point_points(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_6points_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_5Point_pointsize(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_5Point_pointsize(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_9pointsize_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Point[] = {
  {__Pyx_NAMESTR("add_point"), (PyCFunction)__pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_3add_point, METH_VARARGS|METH_KEYWORDS, __Pyx_DOCSTR(__pyx_doc_4kivy_8graphics_19vertex_instructions_5Point_2add_point)},
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Point[] = {
  {(char *)"points", __pyx_getprop_4kivy_8graphics_19vertex_instructions_5Point_points, __pyx_setprop_4kivy_8graphics_19vertex_instructions_5Point_points, __Pyx_DOCSTR(__pyx_k_67), 0},
  {(char *)"pointsize", __pyx_getprop_4kivy_8graphics_19vertex_instructions_5Point_pointsize, __pyx_setprop_4kivy_8graphics_19vertex_instructions_5Point_pointsize, __Pyx_DOCSTR(__pyx_k_68), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Point = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Point = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Point = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Point = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Point = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Point"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Point), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Point, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Point, /*tp_as_number*/
  &__pyx_tp_as_sequence_Point, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Point, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Point, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d line.\n\n    :Parameters:\n        `points`: list\n            List of points in the format (x1, y1, x2, y2...)\n        `pointsize`: float, default to 1.\n            Size of the point (1. mean the real size will be 2)\n\n    .. warning::\n\n        Starting from version 1.0.7, vertex instruction have a limit of 65535\n        vertices (indices of vertex to be accurate).\n        2 entry in the list (x + y) will be converted to 4 vertices. So the\n        limit inside Point() class is 2^15-2.\n\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Point, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Point, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Point, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Point, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_5Point_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Point, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Triangle __pyx_vtable_4kivy_8graphics_19vertex_instructions_Triangle;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Triangle(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Triangle;
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Triangle(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)o;
  Py_XDECREF(((PyObject *)p->_points));
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Triangle(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)o;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  if (p->_points) {
    e = (*v)(p->_points, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Triangle(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle *)o;
  PyObject* tmp;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  tmp = ((PyObject*)p->_points);
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_8Triangle_points(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_6points_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_8Triangle_points(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_6points_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Triangle[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Triangle[] = {
  {(char *)"points", __pyx_getprop_4kivy_8graphics_19vertex_instructions_8Triangle_points, __pyx_setprop_4kivy_8graphics_19vertex_instructions_8Triangle_points, __Pyx_DOCSTR(__pyx_k_67), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Triangle = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Triangle = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Triangle = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Triangle = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Triangle = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Triangle"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Triangle), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Triangle, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Triangle, /*tp_as_number*/
  &__pyx_tp_as_sequence_Triangle, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Triangle, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Triangle, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d triangle.\n\n    :Parameters:\n        `points`: list\n            List of point in the format (x1, y1, x2, y2, x3, y3)\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Triangle, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Triangle, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Triangle, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Triangle, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_8Triangle_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Triangle, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Quad __pyx_vtable_4kivy_8graphics_19vertex_instructions_Quad;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Quad(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Quad;
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Quad(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)o;
  Py_XDECREF(((PyObject *)p->_points));
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Quad(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)o;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  if (p->_points) {
    e = (*v)(p->_points, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Quad(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad *)o;
  PyObject* tmp;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  tmp = ((PyObject*)p->_points);
  p->_points = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_4Quad_points(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_6points_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Quad_points(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_6points_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Quad[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Quad[] = {
  {(char *)"points", __pyx_getprop_4kivy_8graphics_19vertex_instructions_4Quad_points, __pyx_setprop_4kivy_8graphics_19vertex_instructions_4Quad_points, __Pyx_DOCSTR(__pyx_k_69), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Quad = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Quad = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Quad = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Quad = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Quad = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Quad"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Quad), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Quad, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Quad, /*tp_as_number*/
  &__pyx_tp_as_sequence_Quad, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Quad, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Quad, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d quad.\n\n    :Parameters:\n        `points`: list\n            List of point in the format (x1, y1, x2, y2, x3, y3, x4, y4)\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Quad, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Quad, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Quad, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Quad, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_4Quad_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Quad, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Rectangle __pyx_vtable_4kivy_8graphics_19vertex_instructions_Rectangle;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Rectangle(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *p;
  PyObject *o = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_new(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle *)o);
  p->__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Rectangle;
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Rectangle(PyObject *o) {
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dealloc(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Rectangle(PyObject *o, visitproc v, void *a) {
  int e;
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse) {
    e = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_traverse(o, v, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Rectangle(PyObject *o) {
  if (__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear) {
    __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_clear(o);
  }
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_9Rectangle_pos(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_9Rectangle_pos(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_3pos_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_9Rectangle_size(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_9Rectangle_size(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_4size_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Rectangle[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Rectangle[] = {
  {(char *)"pos", __pyx_getprop_4kivy_8graphics_19vertex_instructions_9Rectangle_pos, __pyx_setprop_4kivy_8graphics_19vertex_instructions_9Rectangle_pos, __Pyx_DOCSTR(__pyx_k_70), 0},
  {(char *)"size", __pyx_getprop_4kivy_8graphics_19vertex_instructions_9Rectangle_size, __pyx_setprop_4kivy_8graphics_19vertex_instructions_9Rectangle_size, __Pyx_DOCSTR(__pyx_k_71), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Rectangle = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Rectangle = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Rectangle = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Rectangle = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Rectangle = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Rectangle"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Rectangle), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Rectangle, /*tp_as_number*/
  &__pyx_tp_as_sequence_Rectangle, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Rectangle, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Rectangle, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d rectangle.\n\n    :Parameters:\n        `pos`: list\n            Position of the rectangle, in the format (x, y)\n        `size`: list\n            Size of the rectangle, in the format (width, height)\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_9Rectangle_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_BorderImage __pyx_vtable_4kivy_8graphics_19vertex_instructions_BorderImage;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_BorderImage(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *p;
  PyObject *o = __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Rectangle(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)o);
  p->__pyx_base.__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_BorderImage;
  p->_border = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_BorderImage(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)o;
  Py_XDECREF(((PyObject *)p->_border));
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Rectangle(o);
}

static int __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_BorderImage(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)o;
  e = __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Rectangle(o, v, a); if (e) return e;
  if (p->_border) {
    e = (*v)(p->_border, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_BorderImage(PyObject *o) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *p = (struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage *)o;
  PyObject* tmp;
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Rectangle(o);
  tmp = ((PyObject*)p->_border);
  p->_border = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_11BorderImage_border(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_11BorderImage_border(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_6border_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_BorderImage[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_BorderImage[] = {
  {(char *)"border", __pyx_getprop_4kivy_8graphics_19vertex_instructions_11BorderImage_border, __pyx_setprop_4kivy_8graphics_19vertex_instructions_11BorderImage_border, __Pyx_DOCSTR(__pyx_k_72), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_BorderImage = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_BorderImage = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_BorderImage = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_BorderImage = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_BorderImage = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.BorderImage"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_BorderImage), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_BorderImage, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_BorderImage, /*tp_as_number*/
  &__pyx_tp_as_sequence_BorderImage, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_BorderImage, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_BorderImage, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2d border image. The behavior of the border image is similar to the\n    concept of CSS3 border-image.\n\n    :Parameters:\n        `border`: list\n            Border information in the format (top, right, bottom, left).\n            Each value is in pixels.\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_BorderImage, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_BorderImage, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_BorderImage, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_BorderImage, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_11BorderImage_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_BorderImage, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};
static struct __pyx_vtabstruct_4kivy_8graphics_19vertex_instructions_Ellipse __pyx_vtable_4kivy_8graphics_19vertex_instructions_Ellipse;

static PyObject *__pyx_tp_new_4kivy_8graphics_19vertex_instructions_Ellipse(PyTypeObject *t, PyObject *a, PyObject *k) {
  struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *p;
  PyObject *o = __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Rectangle(t, a, k);
  if (!o) return 0;
  p = ((struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse *)o);
  p->__pyx_base.__pyx_base.__pyx_base.__pyx_vtab = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Ellipse;
  return o;
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_7Ellipse_segments(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_7Ellipse_segments(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_8segments_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_start(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_start(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_11angle_start_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_end(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_1__get__(o);
}

static int __pyx_setprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_end(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_9angle_end_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_4kivy_8graphics_19vertex_instructions_Ellipse[] = {
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_4kivy_8graphics_19vertex_instructions_Ellipse[] = {
  {(char *)"segments", __pyx_getprop_4kivy_8graphics_19vertex_instructions_7Ellipse_segments, __pyx_setprop_4kivy_8graphics_19vertex_instructions_7Ellipse_segments, __Pyx_DOCSTR(__pyx_k_73), 0},
  {(char *)"angle_start", __pyx_getprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_start, __pyx_setprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_start, __Pyx_DOCSTR(__pyx_k_74), 0},
  {(char *)"angle_end", __pyx_getprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_end, __pyx_setprop_4kivy_8graphics_19vertex_instructions_7Ellipse_angle_end, __Pyx_DOCSTR(__pyx_k_75), 0},
  {0, 0, 0, 0, 0}
};

static PyNumberMethods __pyx_tp_as_number_Ellipse = {
  0, /*nb_add*/
  0, /*nb_subtract*/
  0, /*nb_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_divide*/
  #endif
  0, /*nb_remainder*/
  0, /*nb_divmod*/
  0, /*nb_power*/
  0, /*nb_negative*/
  0, /*nb_positive*/
  0, /*nb_absolute*/
  0, /*nb_nonzero*/
  0, /*nb_invert*/
  0, /*nb_lshift*/
  0, /*nb_rshift*/
  0, /*nb_and*/
  0, /*nb_xor*/
  0, /*nb_or*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_coerce*/
  #endif
  0, /*nb_int*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_long*/
  #else
  0, /*reserved*/
  #endif
  0, /*nb_float*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_oct*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*nb_hex*/
  #endif
  0, /*nb_inplace_add*/
  0, /*nb_inplace_subtract*/
  0, /*nb_inplace_multiply*/
  #if PY_MAJOR_VERSION < 3
  0, /*nb_inplace_divide*/
  #endif
  0, /*nb_inplace_remainder*/
  0, /*nb_inplace_power*/
  0, /*nb_inplace_lshift*/
  0, /*nb_inplace_rshift*/
  0, /*nb_inplace_and*/
  0, /*nb_inplace_xor*/
  0, /*nb_inplace_or*/
  0, /*nb_floor_divide*/
  0, /*nb_true_divide*/
  0, /*nb_inplace_floor_divide*/
  0, /*nb_inplace_true_divide*/
  #if PY_VERSION_HEX >= 0x02050000
  0, /*nb_index*/
  #endif
};

static PySequenceMethods __pyx_tp_as_sequence_Ellipse = {
  0, /*sq_length*/
  0, /*sq_concat*/
  0, /*sq_repeat*/
  0, /*sq_item*/
  0, /*sq_slice*/
  0, /*sq_ass_item*/
  0, /*sq_ass_slice*/
  0, /*sq_contains*/
  0, /*sq_inplace_concat*/
  0, /*sq_inplace_repeat*/
};

static PyMappingMethods __pyx_tp_as_mapping_Ellipse = {
  0, /*mp_length*/
  0, /*mp_subscript*/
  0, /*mp_ass_subscript*/
};

static PyBufferProcs __pyx_tp_as_buffer_Ellipse = {
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getreadbuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getwritebuffer*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getsegcount*/
  #endif
  #if PY_MAJOR_VERSION < 3
  0, /*bf_getcharbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_getbuffer*/
  #endif
  #if PY_VERSION_HEX >= 0x02060000
  0, /*bf_releasebuffer*/
  #endif
};

static PyTypeObject __pyx_type_4kivy_8graphics_19vertex_instructions_Ellipse = {
  PyVarObject_HEAD_INIT(0, 0)
  __Pyx_NAMESTR("kivy.graphics.vertex_instructions.Ellipse"), /*tp_name*/
  sizeof(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Ellipse), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #else
  0, /*reserved*/
  #endif
  0, /*tp_repr*/
  &__pyx_tp_as_number_Ellipse, /*tp_as_number*/
  &__pyx_tp_as_sequence_Ellipse, /*tp_as_sequence*/
  &__pyx_tp_as_mapping_Ellipse, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  &__pyx_tp_as_buffer_Ellipse, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  __Pyx_DOCSTR("A 2D ellipse.\n\n    .. versionadded:: 1.0.7 added angle_start + angle_end\n\n    :Parameters:\n        `segments`: int, default to 180\n            Define how much segment is needed for drawing the ellipse.\n            The drawing will be smoother if you have lot of segment.\n        `angle_start`: int default to 0\n            Specifies the starting angle, in degrees, of the disk portion\n        `angle_end`: int default to 360\n            Specifies the ending angle, in degrees, of the disk portion\n    "), /*tp_doc*/
  __pyx_tp_traverse_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_traverse*/
  __pyx_tp_clear_4kivy_8graphics_19vertex_instructions_Rectangle, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_4kivy_8graphics_19vertex_instructions_Ellipse, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_4kivy_8graphics_19vertex_instructions_Ellipse, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_4kivy_8graphics_19vertex_instructions_7Ellipse_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_4kivy_8graphics_19vertex_instructions_Ellipse, /*tp_new*/
  0, /*tp_free*/
  0, /*tp_is_gc*/
  0, /*tp_bases*/
  0, /*tp_mro*/
  0, /*tp_cache*/
  0, /*tp_subclasses*/
  0, /*tp_weaklist*/
  0, /*tp_del*/
  #if PY_VERSION_HEX >= 0x02060000
  0, /*tp_version_tag*/
  #endif
};

static PyMethodDef __pyx_methods[] = {
  {0, 0, 0, 0}
};

#if PY_MAJOR_VERSION >= 3
static struct PyModuleDef __pyx_moduledef = {
    PyModuleDef_HEAD_INIT,
    __Pyx_NAMESTR("vertex_instructions"),
    __Pyx_DOCSTR(__pyx_k_76), /* m_doc */
    -1, /* m_size */
    __pyx_methods /* m_methods */,
    NULL, /* m_reload */
    NULL, /* m_traverse */
    NULL, /* m_clear */
    NULL /* m_free */
};
#endif

static __Pyx_StringTabEntry __pyx_string_tab[] = {
  {&__pyx_kp_s_11, __pyx_k_11, sizeof(__pyx_k_11), 0, 0, 1, 0},
  {&__pyx_kp_s_13, __pyx_k_13, sizeof(__pyx_k_13), 0, 0, 1, 0},
  {&__pyx_kp_s_15, __pyx_k_15, sizeof(__pyx_k_15), 0, 0, 1, 0},
  {&__pyx_kp_s_18, __pyx_k_18, sizeof(__pyx_k_18), 0, 0, 1, 0},
  {&__pyx_kp_s_19, __pyx_k_19, sizeof(__pyx_k_19), 0, 0, 1, 0},
  {&__pyx_kp_s_20, __pyx_k_20, sizeof(__pyx_k_20), 0, 0, 1, 0},
  {&__pyx_kp_s_21, __pyx_k_21, sizeof(__pyx_k_21), 0, 0, 1, 0},
  {&__pyx_kp_s_22, __pyx_k_22, sizeof(__pyx_k_22), 0, 0, 1, 0},
  {&__pyx_kp_s_23, __pyx_k_23, sizeof(__pyx_k_23), 0, 0, 1, 0},
  {&__pyx_kp_s_26, __pyx_k_26, sizeof(__pyx_k_26), 0, 0, 1, 0},
  {&__pyx_kp_s_32, __pyx_k_32, sizeof(__pyx_k_32), 0, 0, 1, 0},
  {&__pyx_kp_s_36, __pyx_k_36, sizeof(__pyx_k_36), 0, 0, 1, 0},
  {&__pyx_kp_s_38, __pyx_k_38, sizeof(__pyx_k_38), 0, 0, 1, 0},
  {&__pyx_kp_s_40, __pyx_k_40, sizeof(__pyx_k_40), 0, 0, 1, 0},
  {&__pyx_kp_s_44, __pyx_k_44, sizeof(__pyx_k_44), 0, 0, 1, 0},
  {&__pyx_kp_s_5, __pyx_k_5, sizeof(__pyx_k_5), 0, 0, 1, 0},
  {&__pyx_kp_s_7, __pyx_k_7, sizeof(__pyx_k_7), 0, 0, 1, 0},
  {&__pyx_n_s_78, __pyx_k_78, sizeof(__pyx_k_78), 0, 0, 1, 1},
  {&__pyx_kp_s_79, __pyx_k_79, sizeof(__pyx_k_79), 0, 0, 1, 0},
  {&__pyx_n_s_80, __pyx_k_80, sizeof(__pyx_k_80), 0, 0, 1, 1},
  {&__pyx_kp_s_9, __pyx_k_9, sizeof(__pyx_k_9), 0, 0, 1, 0},
  {&__pyx_n_s__Bezier, __pyx_k__Bezier, sizeof(__pyx_k__Bezier), 0, 0, 1, 1},
  {&__pyx_n_s__BorderImage, __pyx_k__BorderImage, sizeof(__pyx_k__BorderImage), 0, 0, 1, 1},
  {&__pyx_n_s__Ellipse, __pyx_k__Ellipse, sizeof(__pyx_k__Ellipse), 0, 0, 1, 1},
  {&__pyx_n_s__Exception, __pyx_k__Exception, sizeof(__pyx_k__Exception), 0, 0, 1, 1},
  {&__pyx_n_s__GraphicException, __pyx_k__GraphicException, sizeof(__pyx_k__GraphicException), 0, 0, 1, 1},
  {&__pyx_n_s__Line, __pyx_k__Line, sizeof(__pyx_k__Line), 0, 0, 1, 1},
  {&__pyx_n_s__Logger, __pyx_k__Logger, sizeof(__pyx_k__Logger), 0, 0, 1, 1},
  {&__pyx_n_s__MemoryError, __pyx_k__MemoryError, sizeof(__pyx_k__MemoryError), 0, 0, 1, 1},
  {&__pyx_n_s__Mesh, __pyx_k__Mesh, sizeof(__pyx_k__Mesh), 0, 0, 1, 1},
  {&__pyx_n_s__Point, __pyx_k__Point, sizeof(__pyx_k__Point), 0, 0, 1, 1},
  {&__pyx_n_s__Quad, __pyx_k__Quad, sizeof(__pyx_k__Quad), 0, 0, 1, 1},
  {&__pyx_n_s__Rectangle, __pyx_k__Rectangle, sizeof(__pyx_k__Rectangle), 0, 0, 1, 1},
  {&__pyx_n_s__Triangle, __pyx_k__Triangle, sizeof(__pyx_k__Triangle), 0, 0, 1, 1},
  {&__pyx_n_s____all__, __pyx_k____all__, sizeof(__pyx_k____all__), 0, 0, 1, 1},
  {&__pyx_n_s____init__, __pyx_k____init__, sizeof(__pyx_k____init__), 0, 0, 1, 1},
  {&__pyx_n_s____main__, __pyx_k____main__, sizeof(__pyx_k____main__), 0, 0, 1, 1},
  {&__pyx_n_s____test__, __pyx_k____test__, sizeof(__pyx_k____test__), 0, 0, 1, 1},
  {&__pyx_n_s__angle_end, __pyx_k__angle_end, sizeof(__pyx_k__angle_end), 0, 0, 1, 1},
  {&__pyx_n_s__angle_start, __pyx_k__angle_start, sizeof(__pyx_k__angle_start), 0, 0, 1, 1},
  {&__pyx_n_s__bevel, __pyx_k__bevel, sizeof(__pyx_k__bevel), 0, 0, 1, 1},
  {&__pyx_n_s__blit_buffer, __pyx_k__blit_buffer, sizeof(__pyx_k__blit_buffer), 0, 0, 1, 1},
  {&__pyx_n_s__border, __pyx_k__border, sizeof(__pyx_k__border), 0, 0, 1, 1},
  {&__pyx_n_s__bufferfmt, __pyx_k__bufferfmt, sizeof(__pyx_k__bufferfmt), 0, 0, 1, 1},
  {&__pyx_n_s__cap, __pyx_k__cap, sizeof(__pyx_k__cap), 0, 0, 1, 1},
  {&__pyx_n_s__cap_precision, __pyx_k__cap_precision, sizeof(__pyx_k__cap_precision), 0, 0, 1, 1},
  {&__pyx_n_s__close, __pyx_k__close, sizeof(__pyx_k__close), 0, 0, 1, 1},
  {&__pyx_n_s__color, __pyx_k__color, sizeof(__pyx_k__color), 0, 0, 1, 1},
  {&__pyx_n_s__colorfmt, __pyx_k__colorfmt, sizeof(__pyx_k__colorfmt), 0, 0, 1, 1},
  {&__pyx_n_s__create, __pyx_k__create, sizeof(__pyx_k__create), 0, 0, 1, 1},
  {&__pyx_n_s__dash_length, __pyx_k__dash_length, sizeof(__pyx_k__dash_length), 0, 0, 1, 1},
  {&__pyx_n_s__dash_offset, __pyx_k__dash_offset, sizeof(__pyx_k__dash_offset), 0, 0, 1, 1},
  {&__pyx_n_s__extend, __pyx_k__extend, sizeof(__pyx_k__extend), 0, 0, 1, 1},
  {&__pyx_n_s__format, __pyx_k__format, sizeof(__pyx_k__format), 0, 0, 1, 1},
  {&__pyx_n_s__indices, __pyx_k__indices, sizeof(__pyx_k__indices), 0, 0, 1, 1},
  {&__pyx_n_s__joint, __pyx_k__joint, sizeof(__pyx_k__joint), 0, 0, 1, 1},
  {&__pyx_n_s__joint_precision, __pyx_k__joint_precision, sizeof(__pyx_k__joint_precision), 0, 0, 1, 1},
  {&__pyx_n_s__line_strip, __pyx_k__line_strip, sizeof(__pyx_k__line_strip), 0, 0, 1, 1},
  {&__pyx_n_s__loop, __pyx_k__loop, sizeof(__pyx_k__loop), 0, 0, 1, 1},
  {&__pyx_n_s__miter, __pyx_k__miter, sizeof(__pyx_k__miter), 0, 0, 1, 1},
  {&__pyx_n_s__mode, __pyx_k__mode, sizeof(__pyx_k__mode), 0, 0, 1, 1},
  {&__pyx_n_s__none, __pyx_k__none, sizeof(__pyx_k__none), 0, 0, 1, 1},
  {&__pyx_n_s__op, __pyx_k__op, sizeof(__pyx_k__op), 0, 0, 1, 1},
  {&__pyx_n_s__points, __pyx_k__points, sizeof(__pyx_k__points), 0, 0, 1, 1},
  {&__pyx_n_s__pointsize, __pyx_k__pointsize, sizeof(__pyx_k__pointsize), 0, 0, 1, 1},
  {&__pyx_n_s__pos, __pyx_k__pos, sizeof(__pyx_k__pos), 0, 0, 1, 1},
  {&__pyx_n_s__range, __pyx_k__range, sizeof(__pyx_k__range), 0, 0, 1, 1},
  {&__pyx_n_s__repeat, __pyx_k__repeat, sizeof(__pyx_k__repeat), 0, 0, 1, 1},
  {&__pyx_n_s__rgba, __pyx_k__rgba, sizeof(__pyx_k__rgba), 0, 0, 1, 1},
  {&__pyx_n_s__round, __pyx_k__round, sizeof(__pyx_k__round), 0, 0, 1, 1},
  {&__pyx_n_s__segments, __pyx_k__segments, sizeof(__pyx_k__segments), 0, 0, 1, 1},
  {&__pyx_n_s__size, __pyx_k__size, sizeof(__pyx_k__size), 0, 0, 1, 1},
  {&__pyx_n_s__square, __pyx_k__square, sizeof(__pyx_k__square), 0, 0, 1, 1},
  {&__pyx_n_s__tex_coords, __pyx_k__tex_coords, sizeof(__pyx_k__tex_coords), 0, 0, 1, 1},
  {&__pyx_n_s__texture, __pyx_k__texture, sizeof(__pyx_k__texture), 0, 0, 1, 1},
  {&__pyx_n_s__trace, __pyx_k__trace, sizeof(__pyx_k__trace), 0, 0, 1, 1},
  {&__pyx_n_s__triangle_fan, __pyx_k__triangle_fan, sizeof(__pyx_k__triangle_fan), 0, 0, 1, 1},
  {&__pyx_n_s__triangles, __pyx_k__triangles, sizeof(__pyx_k__triangles), 0, 0, 1, 1},
  {&__pyx_n_s__ubyte, __pyx_k__ubyte, sizeof(__pyx_k__ubyte), 0, 0, 1, 1},
  {&__pyx_n_s__vertices, __pyx_k__vertices, sizeof(__pyx_k__vertices), 0, 0, 1, 1},
  {&__pyx_n_s__width, __pyx_k__width, sizeof(__pyx_k__width), 0, 0, 1, 1},
  {&__pyx_n_s__wrap, __pyx_k__wrap, sizeof(__pyx_k__wrap), 0, 0, 1, 1},
  {&__pyx_n_s__x, __pyx_k__x, sizeof(__pyx_k__x), 0, 0, 1, 1},
  {&__pyx_n_s__xrange, __pyx_k__xrange, sizeof(__pyx_k__xrange), 0, 0, 1, 1},
  {&__pyx_n_s__y, __pyx_k__y, sizeof(__pyx_k__y), 0, 0, 1, 1},
  {0, 0, 0, 0, 0, 0, 0}
};
static int __Pyx_InitCachedBuiltins(void) {
  __pyx_builtin_Exception = __Pyx_GetName(__pyx_b, __pyx_n_s__Exception); if (!__pyx_builtin_Exception) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_builtin_MemoryError = __Pyx_GetName(__pyx_b, __pyx_n_s__MemoryError); if (!__pyx_builtin_MemoryError) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 209; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #if PY_MAJOR_VERSION >= 3
  __pyx_builtin_xrange = __Pyx_GetName(__pyx_b, __pyx_n_s__range); if (!__pyx_builtin_xrange) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 217; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #else
  __pyx_builtin_xrange = __Pyx_GetName(__pyx_b, __pyx_n_s__xrange); if (!__pyx_builtin_xrange) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 217; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #endif
  __pyx_builtin_range = __Pyx_GetName(__pyx_b, __pyx_n_s__range); if (!__pyx_builtin_range) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  return 0;
  __pyx_L1_error:;
  return -1;
}

static int __Pyx_InitCachedConstants(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":209
 *         vertices = <vertex_t *>malloc(count * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(count * sizeof(unsigned short))
 */
  __pyx_k_tuple_1 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_1)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 209; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_1);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__vertices));
  PyTuple_SET_ITEM(__pyx_k_tuple_1, 0, ((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_1));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":214
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         tex_x = 0
 */
  __pyx_k_tuple_2 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_2)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_2);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__indices));
  PyTuple_SET_ITEM(__pyx_k_tuple_2, 0, ((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_2));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":285
 *         vertices = <vertex_t *>malloc(vertices_count * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(indices_count * sizeof(unsigned short))
 */
  __pyx_k_tuple_3 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_3)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 285; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_3);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__vertices));
  PyTuple_SET_ITEM(__pyx_k_tuple_3, 0, ((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_3));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":290
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         cdef double ax, ay, bx, by, cx, cy, angle, a1, a2
 */
  __pyx_k_tuple_4 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_4)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 290; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_4);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__indices));
  PyTuple_SET_ITEM(__pyx_k_tuple_4, 0, ((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_4));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":655
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_length = value
 *             self.flag_update()
 */
  __pyx_k_tuple_6 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_6)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_6);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_5));
  PyTuple_SET_ITEM(__pyx_k_tuple_6, 0, ((PyObject *)__pyx_kp_s_5));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_5));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_6));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":669
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_offset = value
 *             self.flag_update()
 */
  __pyx_k_tuple_8 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_8)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_8);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_7));
  PyTuple_SET_ITEM(__pyx_k_tuple_8, 0, ((PyObject *)__pyx_kp_s_7));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_7));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_8));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":683
 *         def __set__(self, value):
 *             if value <= 0:
 *                 raise GraphicException('Invalid width value, must be > 0')             # <<<<<<<<<<<<<<
 *             self._width = value
 *             self.flag_update()
 */
  __pyx_k_tuple_10 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_10)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_10);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_9));
  PyTuple_SET_ITEM(__pyx_k_tuple_10, 0, ((PyObject *)__pyx_kp_s_9));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_9));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_10));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":702
 *         def __set__(self, value):
 *             if value not in ('none', 'square', 'round'):
 *                 raise GraphicException('Invalid cap, must be one of '             # <<<<<<<<<<<<<<
 *                         '"none", "square", "round"')
 *             if value == 'square':
 */
  __pyx_k_tuple_12 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_12)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_12);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_11));
  PyTuple_SET_ITEM(__pyx_k_tuple_12, 0, ((PyObject *)__pyx_kp_s_11));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_11));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_12));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":730
 *         def __set__(self, value):
 *             if value not in ('none', 'miter', 'bevel', 'round'):
 *                 raise GraphicException('Invalid joint, must be one of '             # <<<<<<<<<<<<<<
 *                     '"none", "miter", "bevel", "round"')
 *             if value == 'round':
 */
  __pyx_k_tuple_14 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_14)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 730; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_14);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_13));
  PyTuple_SET_ITEM(__pyx_k_tuple_14, 0, ((PyObject *)__pyx_kp_s_13));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_13));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_14));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":754
 *         def __set__(self, value):
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')             # <<<<<<<<<<<<<<
 *             self._cap_precision = int(value)
 *             self.flag_update()
 */
  __pyx_k_tuple_16 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_16)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 754; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_16);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_15));
  PyTuple_SET_ITEM(__pyx_k_tuple_16, 0, ((PyObject *)__pyx_kp_s_15));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_15));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_16));

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\vertex_instructions_line.pxi":770
 *         def __set__(self, value):
 *             if value < 1:
 *                 raise GraphicException('Invalid cap_precision value, must be >= 1')             # <<<<<<<<<<<<<<
 *             self._joint_precision = int(value)
 *             self.flag_update()
 */
  __pyx_k_tuple_17 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_17)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 770; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_17);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_15));
  PyTuple_SET_ITEM(__pyx_k_tuple_17, 0, ((PyObject *)__pyx_kp_s_15));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_15));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_17));

  /* "kivy\graphics\vertex_instructions.pyx":111
 *         vertices = <vertex_t *>malloc((self._segments + 1) * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(
 */
  __pyx_k_tuple_24 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_24)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_24);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__vertices));
  PyTuple_SET_ITEM(__pyx_k_tuple_24, 0, ((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_24));

  /* "kivy\graphics\vertex_instructions.pyx":117
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         tex_x = x = 0
 */
  __pyx_k_tuple_25 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_25)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_25);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__indices));
  PyTuple_SET_ITEM(__pyx_k_tuple_25, 0, ((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_25));

  /* "kivy\graphics\vertex_instructions.pyx":190
 *         def __set__(self, value):
 *             if value <= 1:
 *                 raise GraphicException('Invalid segments value, must be >= 2')             # <<<<<<<<<<<<<<
 *             self._segments = value
 *             self.flag_update()
 */
  __pyx_k_tuple_27 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_27)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 190; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_27);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_26));
  PyTuple_SET_ITEM(__pyx_k_tuple_27, 0, ((PyObject *)__pyx_kp_s_26));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_26));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_27));

  /* "kivy\graphics\vertex_instructions.pyx":202
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_length value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_length = value
 *             self.flag_update()
 */
  __pyx_k_tuple_28 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_28)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_28);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_5));
  PyTuple_SET_ITEM(__pyx_k_tuple_28, 0, ((PyObject *)__pyx_kp_s_5));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_5));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_28));

  /* "kivy\graphics\vertex_instructions.pyx":214
 *         def __set__(self, value):
 *             if value < 0:
 *                 raise GraphicException('Invalid dash_offset value, must be >= 0')             # <<<<<<<<<<<<<<
 *             self._dash_offset = value
 *             self.flag_update()
 */
  __pyx_k_tuple_29 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_29)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_29);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_7));
  PyTuple_SET_ITEM(__pyx_k_tuple_29, 0, ((PyObject *)__pyx_kp_s_7));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_7));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_29));

  /* "kivy\graphics\vertex_instructions.pyx":277
 *         vertices = <vertex_t *>malloc(vcount * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(icount * sizeof(unsigned short))
 */
  __pyx_k_tuple_30 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_30)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 277; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_30);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__vertices));
  PyTuple_SET_ITEM(__pyx_k_tuple_30, 0, ((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_30));

  /* "kivy\graphics\vertex_instructions.pyx":282
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         for i in xrange(vcount):
 */
  __pyx_k_tuple_31 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_31)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_31);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__indices));
  PyTuple_SET_ITEM(__pyx_k_tuple_31, 0, ((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_31));

  /* "kivy\graphics\vertex_instructions.pyx":317
 *         def __set__(self, value):
 *             if len(value) > 65535:
 *                 raise GraphicException(             # <<<<<<<<<<<<<<
 *                     'Cannot upload more than 65535 indices'
 *                     '(OpenGL ES 2 limitation)')
 */
  __pyx_k_tuple_33 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_33)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_33);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_32));
  PyTuple_SET_ITEM(__pyx_k_tuple_33, 0, ((PyObject *)__pyx_kp_s_32));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_32));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_33));

  /* "kivy\graphics\vertex_instructions.pyx":376
 *         vertices = <vertex_t *>malloc(count * 4 * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc(count * 6 * sizeof(unsigned short))
 */
  __pyx_k_tuple_34 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_34)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 376; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_34);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__vertices));
  PyTuple_SET_ITEM(__pyx_k_tuple_34, 0, ((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_34));

  /* "kivy\graphics\vertex_instructions.pyx":381
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         t0, t1, t2, t3, t4, t5, t6, t7 = tc
 */
  __pyx_k_tuple_35 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_35)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_35);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__indices));
  PyTuple_SET_ITEM(__pyx_k_tuple_35, 0, ((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_35));

  /* "kivy\graphics\vertex_instructions.pyx":435
 * 
 *         if len(self._points) > 2**15 - 2:
 *             raise GraphicException('Cannot add elements (limit is 2^15-2)')             # <<<<<<<<<<<<<<
 * 
 *         self._points.append(x)
 */
  __pyx_k_tuple_37 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_37)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_37);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_36));
  PyTuple_SET_ITEM(__pyx_k_tuple_37, 0, ((PyObject *)__pyx_kp_s_36));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_36));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_37));

  /* "kivy\graphics\vertex_instructions.pyx":482
 *             cdef list _points = list(points)
 *             if len(_points) > 2**15-2:
 *                 raise GraphicException('Too many elements (limit is 2^15-2)')             # <<<<<<<<<<<<<<
 *             self._points = list(points)
 *             self.flag_update()
 */
  __pyx_k_tuple_39 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_39)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 482; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_39);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_38));
  PyTuple_SET_ITEM(__pyx_k_tuple_39, 0, ((PyObject *)__pyx_kp_s_38));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_38));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_39));

  /* "kivy\graphics\vertex_instructions.pyx":617
 *         VertexInstruction.__init__(self, **kwargs)
 *         v = kwargs.get('pos')
 *         self.pos = v if v is not None else (0, 0)             # <<<<<<<<<<<<<<
 *         v = kwargs.get('size')
 *         self.size = v if v is not None else (100, 100)
 */
  __pyx_k_tuple_41 = PyTuple_New(2); if (unlikely(!__pyx_k_tuple_41)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_41);
  __Pyx_INCREF(__pyx_int_0);
  PyTuple_SET_ITEM(__pyx_k_tuple_41, 0, __pyx_int_0);
  __Pyx_GIVEREF(__pyx_int_0);
  __Pyx_INCREF(__pyx_int_0);
  PyTuple_SET_ITEM(__pyx_k_tuple_41, 1, __pyx_int_0);
  __Pyx_GIVEREF(__pyx_int_0);
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_41));

  /* "kivy\graphics\vertex_instructions.pyx":619
 *         self.pos = v if v is not None else (0, 0)
 *         v = kwargs.get('size')
 *         self.size = v if v is not None else (100, 100)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_k_tuple_42 = PyTuple_New(2); if (unlikely(!__pyx_k_tuple_42)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_42);
  __Pyx_INCREF(__pyx_int_100);
  PyTuple_SET_ITEM(__pyx_k_tuple_42, 0, __pyx_int_100);
  __Pyx_GIVEREF(__pyx_int_100);
  __Pyx_INCREF(__pyx_int_100);
  PyTuple_SET_ITEM(__pyx_k_tuple_42, 1, __pyx_int_100);
  __Pyx_GIVEREF(__pyx_int_100);
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_42));

  /* "kivy\graphics\vertex_instructions.pyx":693
 *         Rectangle.__init__(self, **kwargs)
 *         v = kwargs.get('border')
 *         self.border = v if v is not None else (10, 10, 10, 10)             # <<<<<<<<<<<<<<
 * 
 *     cdef void build(self):
 */
  __pyx_k_tuple_43 = PyTuple_New(4); if (unlikely(!__pyx_k_tuple_43)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 693; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_43);
  __Pyx_INCREF(__pyx_int_10);
  PyTuple_SET_ITEM(__pyx_k_tuple_43, 0, __pyx_int_10);
  __Pyx_GIVEREF(__pyx_int_10);
  __Pyx_INCREF(__pyx_int_10);
  PyTuple_SET_ITEM(__pyx_k_tuple_43, 1, __pyx_int_10);
  __Pyx_GIVEREF(__pyx_int_10);
  __Pyx_INCREF(__pyx_int_10);
  PyTuple_SET_ITEM(__pyx_k_tuple_43, 2, __pyx_int_10);
  __Pyx_GIVEREF(__pyx_int_10);
  __Pyx_INCREF(__pyx_int_10);
  PyTuple_SET_ITEM(__pyx_k_tuple_43, 3, __pyx_int_10);
  __Pyx_GIVEREF(__pyx_int_10);
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_43));

  /* "kivy\graphics\vertex_instructions.pyx":697
 *     cdef void build(self):
 *         if not self.texture:
 *             Logger.trace('GBorderImage: texture missing')             # <<<<<<<<<<<<<<
 *             return
 * 
 */
  __pyx_k_tuple_45 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_45)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 697; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_45);
  __Pyx_INCREF(((PyObject *)__pyx_kp_s_44));
  PyTuple_SET_ITEM(__pyx_k_tuple_45, 0, ((PyObject *)__pyx_kp_s_44));
  __Pyx_GIVEREF(((PyObject *)__pyx_kp_s_44));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_45));

  /* "kivy\graphics\vertex_instructions.pyx":848
 *         vertices = <vertex_t *>malloc((count + 2) * sizeof(vertex_t))
 *         if vertices == NULL:
 *             raise MemoryError('vertices')             # <<<<<<<<<<<<<<
 * 
 *         indices = <unsigned short *>malloc((count + 2) * sizeof(unsigned short))
 */
  __pyx_k_tuple_46 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_46)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_46);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__vertices));
  PyTuple_SET_ITEM(__pyx_k_tuple_46, 0, ((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__vertices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_46));

  /* "kivy\graphics\vertex_instructions.pyx":853
 *         if indices == NULL:
 *             free(vertices)
 *             raise MemoryError('indices')             # <<<<<<<<<<<<<<
 * 
 *         # calculate the start/end angle in radians, and adapt the range
 */
  __pyx_k_tuple_47 = PyTuple_New(1); if (unlikely(!__pyx_k_tuple_47)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_47);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__indices));
  PyTuple_SET_ITEM(__pyx_k_tuple_47, 0, ((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__indices));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_47));

  /* "kivy\graphics\vertex_instructions.pyx":8
 * '''
 * 
 * __all__ = ('Triangle', 'Quad', 'Rectangle', 'BorderImage', 'Ellipse', 'Line',             # <<<<<<<<<<<<<<
 *            'Point', 'Mesh', 'GraphicException', 'Bezier')
 * 
 */
  __pyx_k_tuple_77 = PyTuple_New(10); if (unlikely(!__pyx_k_tuple_77)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 8; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_k_tuple_77);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Triangle));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 0, ((PyObject *)__pyx_n_s__Triangle));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Triangle));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Quad));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 1, ((PyObject *)__pyx_n_s__Quad));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Quad));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Rectangle));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 2, ((PyObject *)__pyx_n_s__Rectangle));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Rectangle));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__BorderImage));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 3, ((PyObject *)__pyx_n_s__BorderImage));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__BorderImage));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Ellipse));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 4, ((PyObject *)__pyx_n_s__Ellipse));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Ellipse));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Line));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 5, ((PyObject *)__pyx_n_s__Line));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Line));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Point));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 6, ((PyObject *)__pyx_n_s__Point));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Point));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Mesh));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 7, ((PyObject *)__pyx_n_s__Mesh));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Mesh));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__GraphicException));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 8, ((PyObject *)__pyx_n_s__GraphicException));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__GraphicException));
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Bezier));
  PyTuple_SET_ITEM(__pyx_k_tuple_77, 9, ((PyObject *)__pyx_n_s__Bezier));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Bezier));
  __Pyx_GIVEREF(((PyObject *)__pyx_k_tuple_77));
  __Pyx_RefNannyFinishContext();
  return 0;
  __pyx_L1_error:;
  __Pyx_RefNannyFinishContext();
  return -1;
}

static int __Pyx_InitGlobals(void) {
  if (__Pyx_InitStrings(__pyx_string_tab) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_2 = PyInt_FromLong(2); if (unlikely(!__pyx_int_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_3 = PyInt_FromLong(3); if (unlikely(!__pyx_int_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_10 = PyInt_FromLong(10); if (unlikely(!__pyx_int_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_100 = PyInt_FromLong(100); if (unlikely(!__pyx_int_100)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_180 = PyInt_FromLong(180); if (unlikely(!__pyx_int_180)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  __pyx_int_360 = PyInt_FromLong(360); if (unlikely(!__pyx_int_360)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  return 0;
  __pyx_L1_error:;
  return -1;
}

#if PY_MAJOR_VERSION < 3
PyMODINIT_FUNC initvertex_instructions(void); /*proto*/
PyMODINIT_FUNC initvertex_instructions(void)
#else
PyMODINIT_FUNC PyInit_vertex_instructions(void); /*proto*/
PyMODINIT_FUNC PyInit_vertex_instructions(void)
#endif
{
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  __Pyx_RefNannyDeclarations
  #if CYTHON_REFNANNY
  __Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny");
  if (!__Pyx_RefNanny) {
      PyErr_Clear();
      __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny");
      if (!__Pyx_RefNanny)
          Py_FatalError("failed to import 'refnanny' module");
  }
  #endif
  __Pyx_RefNannySetupContext("PyMODINIT_FUNC PyInit_vertex_instructions(void)", 0);
  if ( __Pyx_check_binary_version() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #ifdef __Pyx_CyFunction_USED
  if (__Pyx_CyFunction_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #endif
  #ifdef __Pyx_FusedFunction_USED
  if (__pyx_FusedFunction_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #endif
  #ifdef __Pyx_Generator_USED
  if (__pyx_Generator_init() < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  #endif
  /*--- Library function declarations ---*/
  /*--- Threads initialization code ---*/
  #if defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
  #ifdef WITH_THREAD /* Python build with threading support? */
  PyEval_InitThreads();
  #endif
  #endif
  /*--- Module creation code ---*/
  #if PY_MAJOR_VERSION < 3
  __pyx_m = Py_InitModule4(__Pyx_NAMESTR("vertex_instructions"), __pyx_methods, __Pyx_DOCSTR(__pyx_k_76), 0, PYTHON_API_VERSION);
  #else
  __pyx_m = PyModule_Create(&__pyx_moduledef);
  #endif
  if (!__pyx_m) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  #if PY_MAJOR_VERSION < 3
  Py_INCREF(__pyx_m);
  #endif
  __pyx_b = PyImport_AddModule(__Pyx_NAMESTR(__Pyx_BUILTIN_MODULE_NAME));
  if (!__pyx_b) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  #if CYTHON_COMPILING_IN_PYPY
  Py_INCREF(__pyx_b);
  #endif
  if (__Pyx_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  /*--- Initialize various global constants etc. ---*/
  if (unlikely(__Pyx_InitGlobals() < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__pyx_module_is_main_kivy__graphics__vertex_instructions) {
    if (__Pyx_SetAttrString(__pyx_m, "__name__", __pyx_n_s____main__) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
  }
  /*--- Builtin init code ---*/
  if (unlikely(__Pyx_InitCachedBuiltins() < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  /*--- Constants init code ---*/
  if (unlikely(__Pyx_InitCachedConstants() < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  /*--- Global init code ---*/
  /*--- Variable export code ---*/
  /*--- Function export code ---*/
  /*--- Type init code ---*/
  __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction = __Pyx_ImportType("kivy.graphics.instructions", "VertexInstruction", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_VertexInstruction*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Line = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Line;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.__pyx_base.__pyx_base.apply = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_apply;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_build;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.ensure_stencil = (void (*)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_ensure_stencil;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.build_legacy = (void (*)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_build_legacy;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.build_extended = (void (*)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_build_extended;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.prebuild_ellipse = (void (*)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_prebuild_ellipse;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.prebuild_circle = (void (*)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_prebuild_circle;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Line.prebuild_rectangle = (void (*)(struct __pyx_obj_4kivy_8graphics_19vertex_instructions_Line *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Line_prebuild_rectangle;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Line.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Line) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Line.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Line) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Line", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Line) < 0) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Line = &__pyx_type_4kivy_8graphics_19vertex_instructions_Line;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Bezier = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Bezier;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Bezier.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Bezier.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_6Bezier_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Bezier.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Bezier) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Bezier.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Bezier) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Bezier", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Bezier) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Bezier = &__pyx_type_4kivy_8graphics_19vertex_instructions_Bezier;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Mesh = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Mesh;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Mesh.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Mesh.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Mesh_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Mesh.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Mesh) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 219; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Mesh.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Mesh) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 219; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Mesh", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Mesh) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 219; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Mesh = &__pyx_type_4kivy_8graphics_19vertex_instructions_Mesh;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Point = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Point;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Point.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Point.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_5Point_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Point.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Point) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 334; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Point.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Point) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 334; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Point", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Point) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 334; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Point = &__pyx_type_4kivy_8graphics_19vertex_instructions_Point;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Triangle = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Triangle;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Triangle.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Triangle.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_8Triangle_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Triangle.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Triangle) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 498; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Triangle.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Triangle) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 498; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Triangle", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Triangle) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 498; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Triangle = &__pyx_type_4kivy_8graphics_19vertex_instructions_Triangle;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Quad = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Quad;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Quad.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Quad.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_4Quad_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Quad.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Quad) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 546; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Quad.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Quad) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 546; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Quad", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Quad) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 546; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Quad = &__pyx_type_4kivy_8graphics_19vertex_instructions_Quad;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Rectangle = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Rectangle;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Rectangle.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_12instructions_VertexInstruction;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Rectangle.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_9Rectangle_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Rectangle.tp_base = __pyx_ptype_4kivy_8graphics_12instructions_VertexInstruction;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Rectangle) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Rectangle.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Rectangle) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Rectangle", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Rectangle) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle = &__pyx_type_4kivy_8graphics_19vertex_instructions_Rectangle;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_BorderImage = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_BorderImage;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_BorderImage.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Rectangle;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_BorderImage.__pyx_base.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_11BorderImage_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_BorderImage.tp_base = __pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_BorderImage) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_BorderImage.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_BorderImage) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "BorderImage", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_BorderImage) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_BorderImage = &__pyx_type_4kivy_8graphics_19vertex_instructions_BorderImage;
  __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Ellipse = &__pyx_vtable_4kivy_8graphics_19vertex_instructions_Ellipse;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Ellipse.__pyx_base = *__pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Rectangle;
  __pyx_vtable_4kivy_8graphics_19vertex_instructions_Ellipse.__pyx_base.__pyx_base.build = (void (*)(struct __pyx_obj_4kivy_8graphics_12instructions_VertexInstruction *))__pyx_f_4kivy_8graphics_19vertex_instructions_7Ellipse_build;
  __pyx_type_4kivy_8graphics_19vertex_instructions_Ellipse.tp_base = __pyx_ptype_4kivy_8graphics_19vertex_instructions_Rectangle;
  if (PyType_Ready(&__pyx_type_4kivy_8graphics_19vertex_instructions_Ellipse) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetVtable(__pyx_type_4kivy_8graphics_19vertex_instructions_Ellipse.tp_dict, __pyx_vtabptr_4kivy_8graphics_19vertex_instructions_Ellipse) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_SetAttrString(__pyx_m, "Ellipse", (PyObject *)&__pyx_type_4kivy_8graphics_19vertex_instructions_Ellipse) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_19vertex_instructions_Ellipse = &__pyx_type_4kivy_8graphics_19vertex_instructions_Ellipse;
  /*--- Type import code ---*/
  __pyx_ptype_4kivy_8graphics_6buffer_Buffer = __Pyx_ImportType("kivy.graphics.buffer", "Buffer", sizeof(struct __pyx_obj_4kivy_8graphics_6buffer_Buffer), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_6buffer_Buffer)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_6buffer_Buffer = (struct __pyx_vtabstruct_4kivy_8graphics_6buffer_Buffer*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_6buffer_Buffer->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_6buffer_Buffer)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_3vbo_VBO = __Pyx_ImportType("kivy.graphics.vbo", "VBO", sizeof(struct __pyx_obj_4kivy_8graphics_3vbo_VBO), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_3vbo_VBO)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 8; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_3vbo_VBO = (struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VBO*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_3vbo_VBO->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_3vbo_VBO)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 8; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_3vbo_VertexBatch = __Pyx_ImportType("kivy.graphics.vbo", "VertexBatch", sizeof(struct __pyx_obj_4kivy_8graphics_3vbo_VertexBatch), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_3vbo_VertexBatch)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 30; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_3vbo_VertexBatch = (struct __pyx_vtabstruct_4kivy_8graphics_3vbo_VertexBatch*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_3vbo_VertexBatch->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_3vbo_VertexBatch)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 30; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_14transformation_Matrix = __Pyx_ImportType("kivy.graphics.transformation", "Matrix", sizeof(struct __pyx_obj_4kivy_8graphics_14transformation_Matrix), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_14transformation_Matrix)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_14transformation_Matrix = (struct __pyx_vtabstruct_4kivy_8graphics_14transformation_Matrix*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_14transformation_Matrix->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_14transformation_Matrix)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_7texture_Texture = __Pyx_ImportType("kivy.graphics.texture", "Texture", sizeof(struct __pyx_obj_4kivy_8graphics_7texture_Texture), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_7texture_Texture)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_7texture_Texture = (struct __pyx_vtabstruct_4kivy_8graphics_7texture_Texture*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_7texture_Texture->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_7texture_Texture)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_7texture_TextureRegion = __Pyx_ImportType("kivy.graphics.texture", "TextureRegion", sizeof(struct __pyx_obj_4kivy_8graphics_7texture_TextureRegion), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_7texture_TextureRegion)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 37; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_7texture_TextureRegion = (struct __pyx_vtabstruct_4kivy_8graphics_7texture_TextureRegion*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_7texture_TextureRegion->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_7texture_TextureRegion)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 37; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_LineWidth = __Pyx_ImportType("kivy.graphics.context_instructions", "LineWidth", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_LineWidth), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_LineWidth)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_LineWidth = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_LineWidth*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_LineWidth->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_LineWidth)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_Color = __Pyx_ImportType("kivy.graphics.context_instructions", "Color", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_Color), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_Color)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 2; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_Color = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Color*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_Color->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_Color)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 2; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_BindTexture = __Pyx_ImportType("kivy.graphics.context_instructions", "BindTexture", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_BindTexture), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_BindTexture)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_BindTexture = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_BindTexture*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_BindTexture->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_BindTexture)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_PushMatrix = __Pyx_ImportType("kivy.graphics.context_instructions", "PushMatrix", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_PushMatrix), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_PushMatrix)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_PushMatrix = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_PushMatrix*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_PushMatrix->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_PushMatrix)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_PopMatrix = __Pyx_ImportType("kivy.graphics.context_instructions", "PopMatrix", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_PopMatrix), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_PopMatrix)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_PopMatrix = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_PopMatrix*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_PopMatrix->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_PopMatrix)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_MatrixInstruction = __Pyx_ImportType("kivy.graphics.context_instructions", "MatrixInstruction", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_MatrixInstruction), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_MatrixInstruction)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 27; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_MatrixInstruction = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_MatrixInstruction*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_MatrixInstruction->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_MatrixInstruction)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 27; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_Transform = __Pyx_ImportType("kivy.graphics.context_instructions", "Transform", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_Transform), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_Transform)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_Transform = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Transform*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_Transform->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_Transform)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_Rotate = __Pyx_ImportType("kivy.graphics.context_instructions", "Rotate", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_Rotate), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_Rotate)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 39; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_Rotate = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Rotate*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_Rotate->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_Rotate)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 39; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_Scale = __Pyx_ImportType("kivy.graphics.context_instructions", "Scale", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_Scale), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_Scale)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 44; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_Scale = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Scale*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_Scale->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_Scale)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 44; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20context_instructions_Translate = __Pyx_ImportType("kivy.graphics.context_instructions", "Translate", sizeof(struct __pyx_obj_4kivy_8graphics_20context_instructions_Translate), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20context_instructions_Translate)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20context_instructions_Translate = (struct __pyx_vtabstruct_4kivy_8graphics_20context_instructions_Translate*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20context_instructions_Translate->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20context_instructions_Translate)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_8compiler_GraphicsCompiler = __Pyx_ImportType("kivy.graphics.compiler", "GraphicsCompiler", sizeof(struct __pyx_obj_4kivy_8graphics_8compiler_GraphicsCompiler), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_8compiler_GraphicsCompiler)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_8compiler_GraphicsCompiler = (struct __pyx_vtabstruct_4kivy_8graphics_8compiler_GraphicsCompiler*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_8compiler_GraphicsCompiler->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_8compiler_GraphicsCompiler)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_6shader_ShaderSource = __Pyx_ImportType("kivy.graphics.shader", "ShaderSource", sizeof(struct __pyx_obj_4kivy_8graphics_6shader_ShaderSource), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_6shader_ShaderSource)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 5; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_6shader_ShaderSource = (struct __pyx_vtabstruct_4kivy_8graphics_6shader_ShaderSource*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_6shader_ShaderSource->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_6shader_ShaderSource)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 5; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_6shader_Shader = __Pyx_ImportType("kivy.graphics.shader", "Shader", sizeof(struct __pyx_obj_4kivy_8graphics_6shader_Shader), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_6shader_Shader)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 13; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_6shader_Shader = (struct __pyx_vtabstruct_4kivy_8graphics_6shader_Shader*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_6shader_Shader->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_6shader_Shader)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 13; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_Instruction = __Pyx_ImportType("kivy.graphics.instructions", "Instruction", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_Instruction), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_Instruction)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_Instruction = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Instruction*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_Instruction->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_Instruction)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_InstructionGroup = __Pyx_ImportType("kivy.graphics.instructions", "InstructionGroup", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_InstructionGroup), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_InstructionGroup)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 2; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_InstructionGroup = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_InstructionGroup*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_InstructionGroup->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_InstructionGroup)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 2; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_ContextInstruction = __Pyx_ImportType("kivy.graphics.instructions", "ContextInstruction", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_ContextInstruction), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_ContextInstruction)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_ContextInstruction = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_ContextInstruction*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_ContextInstruction->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_ContextInstruction)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_CanvasBase = __Pyx_ImportType("kivy.graphics.instructions", "CanvasBase", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_CanvasBase), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_CanvasBase)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 5; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_CanvasBase = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_CanvasBase*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_CanvasBase->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_CanvasBase)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 5; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_Canvas = __Pyx_ImportType("kivy.graphics.instructions", "Canvas", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_Canvas), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_Canvas)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 6; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_Canvas = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Canvas*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_Canvas->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_Canvas)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 6; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_RenderContext = __Pyx_ImportType("kivy.graphics.instructions", "RenderContext", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_RenderContext)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 7; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_RenderContext = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_RenderContext*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_RenderContext->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_RenderContext)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 7; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_12instructions_Callback = __Pyx_ImportType("kivy.graphics.instructions", "Callback", sizeof(struct __pyx_obj_4kivy_8graphics_12instructions_Callback), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_12instructions_Callback)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 69; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_12instructions_Callback = (struct __pyx_vtabstruct_4kivy_8graphics_12instructions_Callback*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_12instructions_Callback->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_12instructions_Callback)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 69; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPush = __Pyx_ImportType("kivy.graphics.stencil_instructions", "StencilPush", sizeof(struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilPush), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPush)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilPush = (struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilPush*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPush->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilPush)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPop = __Pyx_ImportType("kivy.graphics.stencil_instructions", "StencilPop", sizeof(struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilPop), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPop)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 5; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilPop = (struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilPop*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilPop->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilPop)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 5; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUse = __Pyx_ImportType("kivy.graphics.stencil_instructions", "StencilUse", sizeof(struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilUse), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUse)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 7; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilUse = (struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilUse*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUse->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilUse)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 7; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUnUse = __Pyx_ImportType("kivy.graphics.stencil_instructions", "StencilUnUse", sizeof(struct __pyx_obj_4kivy_8graphics_20stencil_instructions_StencilUnUse), 1); if (unlikely(!__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUnUse)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilUnUse = (struct __pyx_vtabstruct_4kivy_8graphics_20stencil_instructions_StencilUnUse*)__Pyx_GetVtable(__pyx_ptype_4kivy_8graphics_20stencil_instructions_StencilUnUse->tp_dict); if (unlikely(!__pyx_vtabptr_4kivy_8graphics_20stencil_instructions_StencilUnUse)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  /*--- Variable import code ---*/
  /*--- Function import code ---*/
  __pyx_t_1 = __Pyx_ImportModule("kivy.graphics.instructions"); if (!__pyx_t_1) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  if (__Pyx_ImportFunction(__pyx_t_1, "getActiveContext", (void (**)(void))&__pyx_f_4kivy_8graphics_12instructions_getActiveContext, "struct __pyx_obj_4kivy_8graphics_12instructions_RenderContext *(void)") < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  Py_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  /*--- Execution code ---*/

  /* "kivy\graphics\vertex_instructions.pyx":8
 * '''
 * 
 * __all__ = ('Triangle', 'Quad', 'Rectangle', 'BorderImage', 'Ellipse', 'Line',             # <<<<<<<<<<<<<<
 *            'Point', 'Mesh', 'GraphicException', 'Bezier')
 * 
 */
  if (PyObject_SetAttr(__pyx_m, __pyx_n_s____all__, ((PyObject *)__pyx_k_tuple_77)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 8; __pyx_clineno = __LINE__; goto __pyx_L1_error;}

  /* "c:\Users\tito\Desktop\Kivy-1.4.0-w32\kivy\Kivy-1.4.1-w32\Kivy-1.4.1\kivy\graphics\common.pxi":11
 *     ctypedef char* const_char_ptr "const char*"
 * 
 * cdef double pi = PI             # <<<<<<<<<<<<<<
 * cdef extern from "math.h":
 *     double cos(double) nogil
 */
  __pyx_v_4kivy_8graphics_19vertex_instructions_pi = 3.141592653589793;

  /* "kivy\graphics\vertex_instructions.pyx":21
 * IF USE_OPENGL_DEBUG == 1:
 *     from kivy.graphics.c_opengl_debug cimport *
 * from kivy.logger import Logger             # <<<<<<<<<<<<<<
 * from kivy.graphics.texture cimport Texture
 * 
 */
  __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(((PyObject *)__pyx_n_s__Logger));
  PyList_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_n_s__Logger));
  __Pyx_GIVEREF(((PyObject *)__pyx_n_s__Logger));
  __pyx_t_3 = __Pyx_Import(((PyObject *)__pyx_n_s_78), ((PyObject *)__pyx_t_2), -1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  __pyx_t_2 = PyObject_GetAttr(__pyx_t_3, __pyx_n_s__Logger);
  if (__pyx_t_2 == NULL) {
    if (PyErr_ExceptionMatches(PyExc_AttributeError)) __Pyx_RaiseImportError(__pyx_n_s__Logger);
    if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  }
  __Pyx_GOTREF(__pyx_t_2);
  if (PyObject_SetAttr(__pyx_m, __pyx_n_s__Logger, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":25
 * 
 * 
 * class GraphicException(Exception):             # <<<<<<<<<<<<<<
 *     '''Exception fired when a graphic error is fired.
 *     '''
 */
  __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(((PyObject *)__pyx_t_3));
  __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(__pyx_builtin_Exception);
  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_builtin_Exception);
  __Pyx_GIVEREF(__pyx_builtin_Exception);
  if (PyDict_SetItemString(((PyObject *)__pyx_t_3), "__doc__", ((PyObject *)__pyx_kp_s_79)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __pyx_t_4 = __Pyx_CreateClass(((PyObject *)__pyx_t_2), ((PyObject *)__pyx_t_3), __pyx_n_s__GraphicException, __pyx_n_s_80); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
  if (PyObject_SetAttr(__pyx_m, __pyx_n_s__GraphicException, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 25; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;

  /* "kivy\graphics\vertex_instructions.pyx":1
 * '''             # <<<<<<<<<<<<<<
 * Vertex Instructions
 * ===================
 */
  __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_GOTREF(((PyObject *)__pyx_t_3));
  if (PyObject_SetAttr(__pyx_m, __pyx_n_s____test__, ((PyObject *)__pyx_t_3)) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
  __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  if (__pyx_m) {
    __Pyx_AddTraceback("init kivy.graphics.vertex_instructions", __pyx_clineno, __pyx_lineno, __pyx_filename);
    Py_DECREF(__pyx_m); __pyx_m = 0;
  } else if (!PyErr_Occurred()) {
    PyErr_SetString(PyExc_ImportError, "init kivy.graphics.vertex_instructions");
  }
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  #if PY_MAJOR_VERSION < 3
  return;
  #else
  return __pyx_m;
  #endif
}

/* Runtime support code */
#if CYTHON_REFNANNY
static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) {
    PyObject *m = NULL, *p = NULL;
    void *r = NULL;
    m = PyImport_ImportModule((char *)modname);
    if (!m) goto end;
    p = PyObject_GetAttrString(m, (char *)"RefNannyAPI");
    if (!p) goto end;
    r = PyLong_AsVoidPtr(p);
end:
    Py_XDECREF(p);
    Py_XDECREF(m);
    return (__Pyx_RefNannyAPIStruct *)r;
}
#endif /* CYTHON_REFNANNY */

static PyObject *__Pyx_GetName(PyObject *dict, PyObject *name) {
    PyObject *result;
    result = PyObject_GetAttr(dict, name);
    if (!result) {
        if (dict != __pyx_b) {
            PyErr_Clear();
            result = PyObject_GetAttr(__pyx_b, name);
        }
        if (!result) {
            PyErr_SetObject(PyExc_NameError, name);
        }
    }
    return result;
}

static void __Pyx_RaiseArgtupleInvalid(
    const char* func_name,
    int exact,
    Py_ssize_t num_min,
    Py_ssize_t num_max,
    Py_ssize_t num_found)
{
    Py_ssize_t num_expected;
    const char *more_or_less;
    if (num_found < num_min) {
        num_expected = num_min;
        more_or_less = "at least";
    } else {
        num_expected = num_max;
        more_or_less = "at most";
    }
    if (exact) {
        more_or_less = "exactly";
    }
    PyErr_Format(PyExc_TypeError,
                 "%s() takes %s %" PY_FORMAT_SIZE_T "d positional argument%s (%" PY_FORMAT_SIZE_T "d given)",
                 func_name, more_or_less, num_expected,
                 (num_expected == 1) ? "" : "s", num_found);
}

static CYTHON_INLINE int __Pyx_CheckKeywordStrings(
    PyObject *kwdict,
    const char* function_name,
    int kw_allowed)
{
    PyObject* key = 0;
    Py_ssize_t pos = 0;
#if CPYTHON_COMPILING_IN_PYPY
    if (!kw_allowed && PyDict_Next(kwdict, &pos, &key, 0))
        goto invalid_keyword;
    return 1;
#else
    while (PyDict_Next(kwdict, &pos, &key, 0)) {
        #if PY_MAJOR_VERSION < 3
        if (unlikely(!PyString_CheckExact(key)) && unlikely(!PyString_Check(key)))
        #else
        if (unlikely(!PyUnicode_Check(key)))
        #endif
            goto invalid_keyword_type;
    }
    if ((!kw_allowed) && unlikely(key))
        goto invalid_keyword;
    return 1;
invalid_keyword_type:
    PyErr_Format(PyExc_TypeError,
        "%s() keywords must be strings", function_name);
    return 0;
#endif
invalid_keyword:
    PyErr_Format(PyExc_TypeError,
    #if PY_MAJOR_VERSION < 3
        "%s() got an unexpected keyword argument '%s'",
        function_name, PyString_AsString(key));
    #else
        "%s() got an unexpected keyword argument '%U'",
        function_name, key);
    #endif
    return 0;
}

static CYTHON_INLINE Py_ssize_t __Pyx_div_Py_ssize_t(Py_ssize_t a, Py_ssize_t b) {
    Py_ssize_t q = a / b;
    Py_ssize_t r = a - q*b;
    q -= ((r != 0) & ((r ^ b) < 0));
    return q;
}

static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type) {
    if (unlikely(!type)) {
        PyErr_Format(PyExc_SystemError, "Missing type object");
        return 0;
    }
    if (likely(PyObject_TypeCheck(obj, type)))
        return 1;
    PyErr_Format(PyExc_TypeError, "Cannot convert %.200s to %.200s",
                 Py_TYPE(obj)->tp_name, type->tp_name);
    return 0;
}

static CYTHON_INLINE void __Pyx_ErrRestore(PyObject *type, PyObject *value, PyObject *tb) {
#if CYTHON_COMPILING_IN_CPYTHON
    PyObject *tmp_type, *tmp_value, *tmp_tb;
    PyThreadState *tstate = PyThreadState_GET();
    tmp_type = tstate->curexc_type;
    tmp_value = tstate->curexc_value;
    tmp_tb = tstate->curexc_traceback;
    tstate->curexc_type = type;
    tstate->curexc_value = value;
    tstate->curexc_traceback = tb;
    Py_XDECREF(tmp_type);
    Py_XDECREF(tmp_value);
    Py_XDECREF(tmp_tb);
#else
    PyErr_Restore(type, value, tb);
#endif
}
static CYTHON_INLINE void __Pyx_ErrFetch(PyObject **type, PyObject **value, PyObject **tb) {
#if CYTHON_COMPILING_IN_CPYTHON
    PyThreadState *tstate = PyThreadState_GET();
    *type = tstate->curexc_type;
    *value = tstate->curexc_value;
    *tb = tstate->curexc_traceback;
    tstate->curexc_type = 0;
    tstate->curexc_value = 0;
    tstate->curexc_traceback = 0;
#else
    PyErr_Fetch(type, value, tb);
#endif
}

#if PY_MAJOR_VERSION < 3
static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb,
                        CYTHON_UNUSED PyObject *cause) {
    Py_XINCREF(type);
    Py_XINCREF(value);
    Py_XINCREF(tb);
    if (tb == Py_None) {
        Py_DECREF(tb);
        tb = 0;
    }
    else if (tb != NULL && !PyTraceBack_Check(tb)) {
        PyErr_SetString(PyExc_TypeError,
            "raise: arg 3 must be a traceback or None");
        goto raise_error;
    }
    if (value == NULL) {
        value = Py_None;
        Py_INCREF(value);
    }
    #if PY_VERSION_HEX < 0x02050000
    if (!PyClass_Check(type))
    #else
    if (!PyType_Check(type))
    #endif
    {
        if (value != Py_None) {
            PyErr_SetString(PyExc_TypeError,
                "instance exception may not have a separate value");
            goto raise_error;
        }
        Py_DECREF(value);
        value = type;
        #if PY_VERSION_HEX < 0x02050000
            if (PyInstance_Check(type)) {
                type = (PyObject*) ((PyInstanceObject*)type)->in_class;
                Py_INCREF(type);
            }
            else {
                type = 0;
                PyErr_SetString(PyExc_TypeError,
                    "raise: exception must be an old-style class or instance");
                goto raise_error;
            }
        #else
            type = (PyObject*) Py_TYPE(type);
            Py_INCREF(type);
            if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) {
                PyErr_SetString(PyExc_TypeError,
                    "raise: exception class must be a subclass of BaseException");
                goto raise_error;
            }
        #endif
    }
    __Pyx_ErrRestore(type, value, tb);
    return;
raise_error:
    Py_XDECREF(value);
    Py_XDECREF(type);
    Py_XDECREF(tb);
    return;
}
#else /* Python 3+ */
static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
    if (tb == Py_None) {
        tb = 0;
    } else if (tb && !PyTraceBack_Check(tb)) {
        PyErr_SetString(PyExc_TypeError,
            "raise: arg 3 must be a traceback or None");
        goto bad;
    }
    if (value == Py_None)
        value = 0;
    if (PyExceptionInstance_Check(type)) {
        if (value) {
            PyErr_SetString(PyExc_TypeError,
                "instance exception may not have a separate value");
            goto bad;
        }
        value = type;
        type = (PyObject*) Py_TYPE(value);
    } else if (!PyExceptionClass_Check(type)) {
        PyErr_SetString(PyExc_TypeError,
            "raise: exception class must be a subclass of BaseException");
        goto bad;
    }
    if (cause) {
        PyObject *fixed_cause;
        if (PyExceptionClass_Check(cause)) {
            fixed_cause = PyObject_CallObject(cause, NULL);
            if (fixed_cause == NULL)
                goto bad;
        }
        else if (PyExceptionInstance_Check(cause)) {
            fixed_cause = cause;
            Py_INCREF(fixed_cause);
        }
        else {
            PyErr_SetString(PyExc_TypeError,
                            "exception causes must derive from "
                            "BaseException");
            goto bad;
        }
        if (!value) {
            value = PyObject_CallObject(type, NULL);
        }
        PyException_SetCause(value, fixed_cause);
    }
    PyErr_SetObject(type, value);
    if (tb) {
        PyThreadState *tstate = PyThreadState_GET();
        PyObject* tmp_tb = tstate->curexc_traceback;
        if (tb != tmp_tb) {
            Py_INCREF(tb);
            tstate->curexc_traceback = tb;
            Py_XDECREF(tmp_tb);
        }
    }
bad:
    return;
}
#endif

static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
    PyErr_Format(PyExc_ValueError,
                 "need more than %" PY_FORMAT_SIZE_T "d value%s to unpack",
                 index, (index == 1) ? "" : "s");
}

static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
    PyErr_Format(PyExc_ValueError,
                 "too many values to unpack (expected %" PY_FORMAT_SIZE_T "d)", expected);
}

static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
}

static void __Pyx_UnpackTupleError(PyObject *t, Py_ssize_t index) {
    if (t == Py_None) {
      __Pyx_RaiseNoneNotIterableError();
    } else if (PyTuple_GET_SIZE(t) < index) {
      __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(t));
    } else {
      __Pyx_RaiseTooManyValuesError(index);
    }
}

static CYTHON_INLINE int __Pyx_IterFinish(void) {
#if CYTHON_COMPILING_IN_CPYTHON
    PyThreadState *tstate = PyThreadState_GET();
    PyObject* exc_type = tstate->curexc_type;
    if (unlikely(exc_type)) {
        if (likely(exc_type == PyExc_StopIteration) || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration)) {
            PyObject *exc_value, *exc_tb;
            exc_value = tstate->curexc_value;
            exc_tb = tstate->curexc_traceback;
            tstate->curexc_type = 0;
            tstate->curexc_value = 0;
            tstate->curexc_traceback = 0;
            Py_DECREF(exc_type);
            Py_XDECREF(exc_value);
            Py_XDECREF(exc_tb);
            return 0;
        } else {
            return -1;
        }
    }
    return 0;
#else
    if (unlikely(PyErr_Occurred())) {
        if (likely(PyErr_ExceptionMatches(PyExc_StopIteration))) {
            PyErr_Clear();
            return 0;
        } else {
            return -1;
        }
    }
    return 0;
#endif
}

static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected) {
    if (unlikely(retval)) {
        Py_DECREF(retval);
        __Pyx_RaiseTooManyValuesError(expected);
        return -1;
    } else {
        return __Pyx_IterFinish();
    }
    return 0;
}



static void __Pyx_RaiseDoubleKeywordsError(
    const char* func_name,
    PyObject* kw_name)
{
    PyErr_Format(PyExc_TypeError,
        #if PY_MAJOR_VERSION >= 3
        "%s() got multiple values for keyword argument '%U'", func_name, kw_name);
        #else
        "%s() got multiple values for keyword argument '%s'", func_name,
        PyString_AS_STRING(kw_name));
        #endif
}

static int __Pyx_ParseOptionalKeywords(
    PyObject *kwds,
    PyObject **argnames[],
    PyObject *kwds2,
    PyObject *values[],
    Py_ssize_t num_pos_args,
    const char* function_name)
{
    PyObject *key = 0, *value = 0;
    Py_ssize_t pos = 0;
    PyObject*** name;
    PyObject*** first_kw_arg = argnames + num_pos_args;
    while (PyDict_Next(kwds, &pos, &key, &value)) {
        name = first_kw_arg;
        while (*name && (**name != key)) name++;
        if (*name) {
            values[name-argnames] = value;
        } else {
            #if PY_MAJOR_VERSION < 3
            if (unlikely(!PyString_CheckExact(key)) && unlikely(!PyString_Check(key))) {
            #else
            if (unlikely(!PyUnicode_Check(key))) {
            #endif
                goto invalid_keyword_type;
            } else {
                for (name = first_kw_arg; *name; name++) {
                    #if PY_MAJOR_VERSION >= 3
                    if (PyUnicode_GET_SIZE(**name) == PyUnicode_GET_SIZE(key) &&
                        PyUnicode_Compare(**name, key) == 0) break;
                    #else
                    if (PyString_GET_SIZE(**name) == PyString_GET_SIZE(key) &&
                        _PyString_Eq(**name, key)) break;
                    #endif
                }
                if (*name) {
                    values[name-argnames] = value;
                } else {
                    for (name=argnames; name != first_kw_arg; name++) {
                        if (**name == key) goto arg_passed_twice;
                        #if PY_MAJOR_VERSION >= 3
                        if (PyUnicode_GET_SIZE(**name) == PyUnicode_GET_SIZE(key) &&
                            PyUnicode_Compare(**name, key) == 0) goto arg_passed_twice;
                        #else
                        if (PyString_GET_SIZE(**name) == PyString_GET_SIZE(key) &&
                            _PyString_Eq(**name, key)) goto arg_passed_twice;
                        #endif
                    }
                    if (kwds2) {
                        if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad;
                    } else {
                        goto invalid_keyword;
                    }
                }
            }
        }
    }
    return 0;
arg_passed_twice:
    __Pyx_RaiseDoubleKeywordsError(function_name, **name);
    goto bad;
invalid_keyword_type:
    PyErr_Format(PyExc_TypeError,
        "%s() keywords must be strings", function_name);
    goto bad;
invalid_keyword:
    PyErr_Format(PyExc_TypeError,
    #if PY_MAJOR_VERSION < 3
        "%s() got an unexpected keyword argument '%s'",
        function_name, PyString_AsString(key));
    #else
        "%s() got an unexpected keyword argument '%U'",
        function_name, key);
    #endif
bad:
    return -1;
}

static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, long level) {
    PyObject *py_import = 0;
    PyObject *empty_list = 0;
    PyObject *module = 0;
    PyObject *global_dict = 0;
    PyObject *empty_dict = 0;
    PyObject *list;
    py_import = __Pyx_GetAttrString(__pyx_b, "__import__");
    if (!py_import)
        goto bad;
    if (from_list)
        list = from_list;
    else {
        empty_list = PyList_New(0);
        if (!empty_list)
            goto bad;
        list = empty_list;
    }
    global_dict = PyModule_GetDict(__pyx_m);
    if (!global_dict)
        goto bad;
    empty_dict = PyDict_New();
    if (!empty_dict)
        goto bad;
    #if PY_VERSION_HEX >= 0x02050000
    {
        #if PY_MAJOR_VERSION >= 3
        if (level == -1) {
            if (strchr(__Pyx_MODULE_NAME, '.')) {
                /* try package relative import first */
                PyObject *py_level = PyInt_FromLong(1);
                if (!py_level)
                    goto bad;
                module = PyObject_CallFunctionObjArgs(py_import,
                    name, global_dict, empty_dict, list, py_level, NULL);
                Py_DECREF(py_level);
                if (!module) {
                    if (!PyErr_ExceptionMatches(PyExc_ImportError))
                        goto bad;
                    PyErr_Clear();
                }
            }
            level = 0; /* try absolute import on failure */
        }
        #endif
        if (!module) {
            PyObject *py_level = PyInt_FromLong(level);
            if (!py_level)
                goto bad;
            module = PyObject_CallFunctionObjArgs(py_import,
                name, global_dict, empty_dict, list, py_level, NULL);
            Py_DECREF(py_level);
        }
    }
    #else
    if (level>0) {
        PyErr_SetString(PyExc_RuntimeError, "Relative import is not supported for Python <=2.4.");
        goto bad;
    }
    module = PyObject_CallFunctionObjArgs(py_import,
        name, global_dict, empty_dict, list, NULL);
    #endif
bad:
    Py_XDECREF(empty_list);
    Py_XDECREF(py_import);
    Py_XDECREF(empty_dict);
    return module;
}

static CYTHON_INLINE void __Pyx_RaiseImportError(PyObject *name) {
#if PY_MAJOR_VERSION < 3
    PyErr_Format(PyExc_ImportError, "cannot import name %.230s",
                 PyString_AsString(name));
#else
    PyErr_Format(PyExc_ImportError, "cannot import name %S", name);
#endif
}

static PyObject *__Pyx_FindPy2Metaclass(PyObject *bases) {
    PyObject *metaclass;
#if PY_MAJOR_VERSION < 3
    if (PyTuple_Check(bases) && PyTuple_GET_SIZE(bases) > 0) {
        PyObject *base = PyTuple_GET_ITEM(bases, 0);
        metaclass = PyObject_GetAttrString(base, (char *)"__class__");
        if (!metaclass) {
            PyErr_Clear();
            metaclass = (PyObject*) Py_TYPE(base);
        }
    } else {
        metaclass = (PyObject *) &PyClass_Type;
    }
#else
    if (PyTuple_Check(bases) && PyTuple_GET_SIZE(bases) > 0) {
        PyObject *base = PyTuple_GET_ITEM(bases, 0);
        metaclass = (PyObject*) Py_TYPE(base);
    } else {
        metaclass = (PyObject *) &PyType_Type;
    }
#endif
    Py_INCREF(metaclass);
    return metaclass;
}

static PyObject *__Pyx_CreateClass(PyObject *bases, PyObject *dict, PyObject *name,
                                   PyObject *modname) {
    PyObject *result;
    PyObject *metaclass;
    if (PyDict_SetItemString(dict, "__module__", modname) < 0)
        return NULL;
    metaclass = PyDict_GetItemString(dict, "__metaclass__");
    if (metaclass) {
        Py_INCREF(metaclass);
    } else {
        metaclass = __Pyx_FindPy2Metaclass(bases);
    }
    result = PyObject_CallFunctionObjArgs(metaclass, name, bases, dict, NULL);
    Py_DECREF(metaclass);
    return result;
}

static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals) {
#if CYTHON_COMPILING_IN_PYPY
    return PyObject_RichCompareBool(s1, s2, equals);
#else
    if (s1 == s2) {
        return (equals == Py_EQ);
    } else if (PyBytes_CheckExact(s1) & PyBytes_CheckExact(s2)) {
        if (PyBytes_GET_SIZE(s1) != PyBytes_GET_SIZE(s2)) {
            return (equals == Py_NE);
        } else if (PyBytes_GET_SIZE(s1) == 1) {
            if (equals == Py_EQ)
                return (PyBytes_AS_STRING(s1)[0] == PyBytes_AS_STRING(s2)[0]);
            else
                return (PyBytes_AS_STRING(s1)[0] != PyBytes_AS_STRING(s2)[0]);
        } else {
            int result = memcmp(PyBytes_AS_STRING(s1), PyBytes_AS_STRING(s2), (size_t)PyBytes_GET_SIZE(s1));
            return (equals == Py_EQ) ? (result == 0) : (result != 0);
        }
    } else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
        return (equals == Py_NE);
    } else if ((s2 == Py_None) & PyBytes_CheckExact(s1)) {
        return (equals == Py_NE);
    } else {
        int result;
        PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
        if (!py_result)
            return -1;
        result = __Pyx_PyObject_IsTrue(py_result);
        Py_DECREF(py_result);
        return result;
    }
#endif
}

static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
#if CYTHON_COMPILING_IN_PYPY
    return PyObject_RichCompareBool(s1, s2, equals);
#else
    if (s1 == s2) {
        return (equals == Py_EQ);
    } else if (PyUnicode_CheckExact(s1) & PyUnicode_CheckExact(s2)) {
        #if CYTHON_PEP393_ENABLED
        if ((PyUnicode_READY(s1) < 0) || (PyUnicode_READY(s2) < 0))
            return -1;
        if (PyUnicode_GET_LENGTH(s1) != PyUnicode_GET_LENGTH(s2)) {
            return (equals == Py_NE);
        } else if (PyUnicode_GET_LENGTH(s1) == 1) {
            Py_UCS4 ch1 = PyUnicode_READ_CHAR(s1, 0);
            Py_UCS4 ch2 = PyUnicode_READ_CHAR(s2, 0);
            return (equals == Py_EQ) ? (ch1 == ch2) : (ch1 != ch2);
        #else
        if (PyUnicode_GET_SIZE(s1) != PyUnicode_GET_SIZE(s2)) {
            return (equals == Py_NE);
        } else if (PyUnicode_GET_SIZE(s1) == 1) {
            Py_UNICODE ch1 = PyUnicode_AS_UNICODE(s1)[0];
            Py_UNICODE ch2 = PyUnicode_AS_UNICODE(s2)[0];
            return (equals == Py_EQ) ? (ch1 == ch2) : (ch1 != ch2);
        #endif
        } else {
            int result = PyUnicode_Compare(s1, s2);
            if ((result == -1) && unlikely(PyErr_Occurred()))
                return -1;
            return (equals == Py_EQ) ? (result == 0) : (result != 0);
        }
    } else if ((s1 == Py_None) & PyUnicode_CheckExact(s2)) {
        return (equals == Py_NE);
    } else if ((s2 == Py_None) & PyUnicode_CheckExact(s1)) {
        return (equals == Py_NE);
    } else {
        int result;
        PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
        if (!py_result)
            return -1;
        result = __Pyx_PyObject_IsTrue(py_result);
        Py_DECREF(py_result);
        return result;
    }
#endif
}

static CYTHON_INLINE unsigned char __Pyx_PyInt_AsUnsignedChar(PyObject* x) {
    const unsigned char neg_one = (unsigned char)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(unsigned char) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(unsigned char)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to unsigned char" :
                    "value too large to convert to unsigned char");
            }
            return (unsigned char)-1;
        }
        return (unsigned char)val;
    }
    return (unsigned char)__Pyx_PyInt_AsUnsignedLong(x);
}

static CYTHON_INLINE unsigned short __Pyx_PyInt_AsUnsignedShort(PyObject* x) {
    const unsigned short neg_one = (unsigned short)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(unsigned short) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(unsigned short)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to unsigned short" :
                    "value too large to convert to unsigned short");
            }
            return (unsigned short)-1;
        }
        return (unsigned short)val;
    }
    return (unsigned short)__Pyx_PyInt_AsUnsignedLong(x);
}

static CYTHON_INLINE unsigned int __Pyx_PyInt_AsUnsignedInt(PyObject* x) {
    const unsigned int neg_one = (unsigned int)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(unsigned int) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(unsigned int)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to unsigned int" :
                    "value too large to convert to unsigned int");
            }
            return (unsigned int)-1;
        }
        return (unsigned int)val;
    }
    return (unsigned int)__Pyx_PyInt_AsUnsignedLong(x);
}

static CYTHON_INLINE char __Pyx_PyInt_AsChar(PyObject* x) {
    const char neg_one = (char)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(char) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(char)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to char" :
                    "value too large to convert to char");
            }
            return (char)-1;
        }
        return (char)val;
    }
    return (char)__Pyx_PyInt_AsLong(x);
}

static CYTHON_INLINE short __Pyx_PyInt_AsShort(PyObject* x) {
    const short neg_one = (short)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(short) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(short)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to short" :
                    "value too large to convert to short");
            }
            return (short)-1;
        }
        return (short)val;
    }
    return (short)__Pyx_PyInt_AsLong(x);
}

static CYTHON_INLINE int __Pyx_PyInt_AsInt(PyObject* x) {
    const int neg_one = (int)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(int) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(int)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to int" :
                    "value too large to convert to int");
            }
            return (int)-1;
        }
        return (int)val;
    }
    return (int)__Pyx_PyInt_AsLong(x);
}

static CYTHON_INLINE signed char __Pyx_PyInt_AsSignedChar(PyObject* x) {
    const signed char neg_one = (signed char)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(signed char) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(signed char)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to signed char" :
                    "value too large to convert to signed char");
            }
            return (signed char)-1;
        }
        return (signed char)val;
    }
    return (signed char)__Pyx_PyInt_AsSignedLong(x);
}

static CYTHON_INLINE signed short __Pyx_PyInt_AsSignedShort(PyObject* x) {
    const signed short neg_one = (signed short)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(signed short) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(signed short)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to signed short" :
                    "value too large to convert to signed short");
            }
            return (signed short)-1;
        }
        return (signed short)val;
    }
    return (signed short)__Pyx_PyInt_AsSignedLong(x);
}

static CYTHON_INLINE signed int __Pyx_PyInt_AsSignedInt(PyObject* x) {
    const signed int neg_one = (signed int)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(signed int) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(signed int)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to signed int" :
                    "value too large to convert to signed int");
            }
            return (signed int)-1;
        }
        return (signed int)val;
    }
    return (signed int)__Pyx_PyInt_AsSignedLong(x);
}

static CYTHON_INLINE int __Pyx_PyInt_AsLongDouble(PyObject* x) {
    const int neg_one = (int)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
    if (sizeof(int) < sizeof(long)) {
        long val = __Pyx_PyInt_AsLong(x);
        if (unlikely(val != (long)(int)val)) {
            if (!unlikely(val == -1 && PyErr_Occurred())) {
                PyErr_SetString(PyExc_OverflowError,
                    (is_unsigned && unlikely(val < 0)) ?
                    "can't convert negative value to int" :
                    "value too large to convert to int");
            }
            return (int)-1;
        }
        return (int)val;
    }
    return (int)__Pyx_PyInt_AsLong(x);
}

static CYTHON_INLINE unsigned long __Pyx_PyInt_AsUnsignedLong(PyObject* x) {
    const unsigned long neg_one = (unsigned long)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_VERSION_HEX < 0x03000000
    if (likely(PyInt_Check(x))) {
        long val = PyInt_AS_LONG(x);
        if (is_unsigned && unlikely(val < 0)) {
            PyErr_SetString(PyExc_OverflowError,
                            "can't convert negative value to unsigned long");
            return (unsigned long)-1;
        }
        return (unsigned long)val;
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
            if (unlikely(Py_SIZE(x) < 0)) {
                PyErr_SetString(PyExc_OverflowError,
                                "can't convert negative value to unsigned long");
                return (unsigned long)-1;
            }
            return (unsigned long)PyLong_AsUnsignedLong(x);
        } else {
            return (unsigned long)PyLong_AsLong(x);
        }
    } else {
        unsigned long val;
        PyObject *tmp = __Pyx_PyNumber_Int(x);
        if (!tmp) return (unsigned long)-1;
        val = __Pyx_PyInt_AsUnsignedLong(tmp);
        Py_DECREF(tmp);
        return val;
    }
}

static CYTHON_INLINE unsigned PY_LONG_LONG __Pyx_PyInt_AsUnsignedLongLong(PyObject* x) {
    const unsigned PY_LONG_LONG neg_one = (unsigned PY_LONG_LONG)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_VERSION_HEX < 0x03000000
    if (likely(PyInt_Check(x))) {
        long val = PyInt_AS_LONG(x);
        if (is_unsigned && unlikely(val < 0)) {
            PyErr_SetString(PyExc_OverflowError,
                            "can't convert negative value to unsigned PY_LONG_LONG");
            return (unsigned PY_LONG_LONG)-1;
        }
        return (unsigned PY_LONG_LONG)val;
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
            if (unlikely(Py_SIZE(x) < 0)) {
                PyErr_SetString(PyExc_OverflowError,
                                "can't convert negative value to unsigned PY_LONG_LONG");
                return (unsigned PY_LONG_LONG)-1;
            }
            return (unsigned PY_LONG_LONG)PyLong_AsUnsignedLongLong(x);
        } else {
            return (unsigned PY_LONG_LONG)PyLong_AsLongLong(x);
        }
    } else {
        unsigned PY_LONG_LONG val;
        PyObject *tmp = __Pyx_PyNumber_Int(x);
        if (!tmp) return (unsigned PY_LONG_LONG)-1;
        val = __Pyx_PyInt_AsUnsignedLongLong(tmp);
        Py_DECREF(tmp);
        return val;
    }
}

static CYTHON_INLINE long __Pyx_PyInt_AsLong(PyObject* x) {
    const long neg_one = (long)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_VERSION_HEX < 0x03000000
    if (likely(PyInt_Check(x))) {
        long val = PyInt_AS_LONG(x);
        if (is_unsigned && unlikely(val < 0)) {
            PyErr_SetString(PyExc_OverflowError,
                            "can't convert negative value to long");
            return (long)-1;
        }
        return (long)val;
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
            if (unlikely(Py_SIZE(x) < 0)) {
                PyErr_SetString(PyExc_OverflowError,
                                "can't convert negative value to long");
                return (long)-1;
            }
            return (long)PyLong_AsUnsignedLong(x);
        } else {
            return (long)PyLong_AsLong(x);
        }
    } else {
        long val;
        PyObject *tmp = __Pyx_PyNumber_Int(x);
        if (!tmp) return (long)-1;
        val = __Pyx_PyInt_AsLong(tmp);
        Py_DECREF(tmp);
        return val;
    }
}

static CYTHON_INLINE PY_LONG_LONG __Pyx_PyInt_AsLongLong(PyObject* x) {
    const PY_LONG_LONG neg_one = (PY_LONG_LONG)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_VERSION_HEX < 0x03000000
    if (likely(PyInt_Check(x))) {
        long val = PyInt_AS_LONG(x);
        if (is_unsigned && unlikely(val < 0)) {
            PyErr_SetString(PyExc_OverflowError,
                            "can't convert negative value to PY_LONG_LONG");
            return (PY_LONG_LONG)-1;
        }
        return (PY_LONG_LONG)val;
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
            if (unlikely(Py_SIZE(x) < 0)) {
                PyErr_SetString(PyExc_OverflowError,
                                "can't convert negative value to PY_LONG_LONG");
                return (PY_LONG_LONG)-1;
            }
            return (PY_LONG_LONG)PyLong_AsUnsignedLongLong(x);
        } else {
            return (PY_LONG_LONG)PyLong_AsLongLong(x);
        }
    } else {
        PY_LONG_LONG val;
        PyObject *tmp = __Pyx_PyNumber_Int(x);
        if (!tmp) return (PY_LONG_LONG)-1;
        val = __Pyx_PyInt_AsLongLong(tmp);
        Py_DECREF(tmp);
        return val;
    }
}

static CYTHON_INLINE signed long __Pyx_PyInt_AsSignedLong(PyObject* x) {
    const signed long neg_one = (signed long)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_VERSION_HEX < 0x03000000
    if (likely(PyInt_Check(x))) {
        long val = PyInt_AS_LONG(x);
        if (is_unsigned && unlikely(val < 0)) {
            PyErr_SetString(PyExc_OverflowError,
                            "can't convert negative value to signed long");
            return (signed long)-1;
        }
        return (signed long)val;
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
            if (unlikely(Py_SIZE(x) < 0)) {
                PyErr_SetString(PyExc_OverflowError,
                                "can't convert negative value to signed long");
                return (signed long)-1;
            }
            return (signed long)PyLong_AsUnsignedLong(x);
        } else {
            return (signed long)PyLong_AsLong(x);
        }
    } else {
        signed long val;
        PyObject *tmp = __Pyx_PyNumber_Int(x);
        if (!tmp) return (signed long)-1;
        val = __Pyx_PyInt_AsSignedLong(tmp);
        Py_DECREF(tmp);
        return val;
    }
}

static CYTHON_INLINE signed PY_LONG_LONG __Pyx_PyInt_AsSignedLongLong(PyObject* x) {
    const signed PY_LONG_LONG neg_one = (signed PY_LONG_LONG)-1, const_zero = 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_VERSION_HEX < 0x03000000
    if (likely(PyInt_Check(x))) {
        long val = PyInt_AS_LONG(x);
        if (is_unsigned && unlikely(val < 0)) {
            PyErr_SetString(PyExc_OverflowError,
                            "can't convert negative value to signed PY_LONG_LONG");
            return (signed PY_LONG_LONG)-1;
        }
        return (signed PY_LONG_LONG)val;
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
            if (unlikely(Py_SIZE(x) < 0)) {
                PyErr_SetString(PyExc_OverflowError,
                                "can't convert negative value to signed PY_LONG_LONG");
                return (signed PY_LONG_LONG)-1;
            }
            return (signed PY_LONG_LONG)PyLong_AsUnsignedLongLong(x);
        } else {
            return (signed PY_LONG_LONG)PyLong_AsLongLong(x);
        }
    } else {
        signed PY_LONG_LONG val;
        PyObject *tmp = __Pyx_PyNumber_Int(x);
        if (!tmp) return (signed PY_LONG_LONG)-1;
        val = __Pyx_PyInt_AsSignedLongLong(tmp);
        Py_DECREF(tmp);
        return val;
    }
}

static void __Pyx_WriteUnraisable(const char *name, CYTHON_UNUSED int clineno,
                                  CYTHON_UNUSED int lineno, CYTHON_UNUSED const char *filename) {
    PyObject *old_exc, *old_val, *old_tb;
    PyObject *ctx;
    __Pyx_ErrFetch(&old_exc, &old_val, &old_tb);
    #if PY_MAJOR_VERSION < 3
    ctx = PyString_FromString(name);
    #else
    ctx = PyUnicode_FromString(name);
    #endif
    __Pyx_ErrRestore(old_exc, old_val, old_tb);
    if (!ctx) {
        PyErr_WriteUnraisable(Py_None);
    } else {
        PyErr_WriteUnraisable(ctx);
        Py_DECREF(ctx);
    }
}

static int __Pyx_check_binary_version(void) {
    char ctversion[4], rtversion[4];
    PyOS_snprintf(ctversion, 4, "%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION);
    PyOS_snprintf(rtversion, 4, "%s", Py_GetVersion());
    if (ctversion[0] != rtversion[0] || ctversion[2] != rtversion[2]) {
        char message[200];
        PyOS_snprintf(message, sizeof(message),
                      "compiletime version %s of module '%.100s' "
                      "does not match runtime version %s",
                      ctversion, __Pyx_MODULE_NAME, rtversion);
        #if PY_VERSION_HEX < 0x02050000
        return PyErr_Warn(NULL, message);
        #else
        return PyErr_WarnEx(NULL, message, 1);
        #endif
    }
    return 0;
}

#ifndef __PYX_HAVE_RT_ImportType
#define __PYX_HAVE_RT_ImportType
static PyTypeObject *__Pyx_ImportType(const char *module_name, const char *class_name,
    size_t size, int strict)
{
    PyObject *py_module = 0;
    PyObject *result = 0;
    PyObject *py_name = 0;
    char warning[200];
    py_module = __Pyx_ImportModule(module_name);
    if (!py_module)
        goto bad;
    py_name = __Pyx_PyIdentifier_FromString(class_name);
    if (!py_name)
        goto bad;
    result = PyObject_GetAttr(py_module, py_name);
    Py_DECREF(py_name);
    py_name = 0;
    Py_DECREF(py_module);
    py_module = 0;
    if (!result)
        goto bad;
    if (!PyType_Check(result)) {
        PyErr_Format(PyExc_TypeError,
            "%s.%s is not a type object",
            module_name, class_name);
        goto bad;
    }
    if (!strict && (size_t)((PyTypeObject *)result)->tp_basicsize > size) {
        PyOS_snprintf(warning, sizeof(warning),
            "%s.%s size changed, may indicate binary incompatibility",
            module_name, class_name);
        #if PY_VERSION_HEX < 0x02050000
        if (PyErr_Warn(NULL, warning) < 0) goto bad;
        #else
        if (PyErr_WarnEx(NULL, warning, 0) < 0) goto bad;
        #endif
    }
    else if ((size_t)((PyTypeObject *)result)->tp_basicsize != size) {
        PyErr_Format(PyExc_ValueError,
            "%s.%s has the wrong size, try recompiling",
            module_name, class_name);
        goto bad;
    }
    return (PyTypeObject *)result;
bad:
    Py_XDECREF(py_module);
    Py_XDECREF(result);
    return NULL;
}
#endif

#ifndef __PYX_HAVE_RT_ImportModule
#define __PYX_HAVE_RT_ImportModule
static PyObject *__Pyx_ImportModule(const char *name) {
    PyObject *py_name = 0;
    PyObject *py_module = 0;
    py_name = __Pyx_PyIdentifier_FromString(name);
    if (!py_name)
        goto bad;
    py_module = PyImport_Import(py_name);
    Py_DECREF(py_name);
    return py_module;
bad:
    Py_XDECREF(py_name);
    return 0;
}
#endif

static void* __Pyx_GetVtable(PyObject *dict) {
    void* ptr;
    PyObject *ob = PyMapping_GetItemString(dict, (char *)"__pyx_vtable__");
    if (!ob)
        goto bad;
#if PY_VERSION_HEX >= 0x02070000 && !(PY_MAJOR_VERSION==3&&PY_MINOR_VERSION==0)
    ptr = PyCapsule_GetPointer(ob, 0);
#else
    ptr = PyCObject_AsVoidPtr(ob);
#endif
    if (!ptr && !PyErr_Occurred())
        PyErr_SetString(PyExc_RuntimeError, "invalid vtable found for imported type");
    Py_DECREF(ob);
    return ptr;
bad:
    Py_XDECREF(ob);
    return NULL;
}

static int __Pyx_SetVtable(PyObject *dict, void *vtable) {
#if PY_VERSION_HEX >= 0x02070000 && !(PY_MAJOR_VERSION==3&&PY_MINOR_VERSION==0)
    PyObject *ob = PyCapsule_New(vtable, 0, 0);
#else
    PyObject *ob = PyCObject_FromVoidPtr(vtable, 0);
#endif
    if (!ob)
        goto bad;
    if (PyDict_SetItemString(dict, "__pyx_vtable__", ob) < 0)
        goto bad;
    Py_DECREF(ob);
    return 0;
bad:
    Py_XDECREF(ob);
    return -1;
}

#ifndef __PYX_HAVE_RT_ImportFunction
#define __PYX_HAVE_RT_ImportFunction
static int __Pyx_ImportFunction(PyObject *module, const char *funcname, void (**f)(void), const char *sig) {
    PyObject *d = 0;
    PyObject *cobj = 0;
    union {
        void (*fp)(void);
        void *p;
    } tmp;
    d = PyObject_GetAttrString(module, (char *)"__pyx_capi__");
    if (!d)
        goto bad;
    cobj = PyDict_GetItemString(d, funcname);
    if (!cobj) {
        PyErr_Format(PyExc_ImportError,
            "%s does not export expected C function %s",
                PyModule_GetName(module), funcname);
        goto bad;
    }
#if PY_VERSION_HEX >= 0x02070000 && !(PY_MAJOR_VERSION==3&&PY_MINOR_VERSION==0)
    if (!PyCapsule_IsValid(cobj, sig)) {
        PyErr_Format(PyExc_TypeError,
            "C function %s.%s has wrong signature (expected %s, got %s)",
             PyModule_GetName(module), funcname, sig, PyCapsule_GetName(cobj));
        goto bad;
    }
    tmp.p = PyCapsule_GetPointer(cobj, sig);
#else
    {const char *desc, *s1, *s2;
    desc = (const char *)PyCObject_GetDesc(cobj);
    if (!desc)
        goto bad;
    s1 = desc; s2 = sig;
    while (*s1 != '\0' && *s1 == *s2) { s1++; s2++; }
    if (*s1 != *s2) {
        PyErr_Format(PyExc_TypeError,
            "C function %s.%s has wrong signature (expected %s, got %s)",
             PyModule_GetName(module), funcname, sig, desc);
        goto bad;
    }
    tmp.p = PyCObject_AsVoidPtr(cobj);}
#endif
    *f = tmp.fp;
    if (!(*f))
        goto bad;
    Py_DECREF(d);
    return 0;
bad:
    Py_XDECREF(d);
    return -1;
}
#endif

static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) {
    int start = 0, mid = 0, end = count - 1;
    if (end >= 0 && code_line > entries[end].code_line) {
        return count;
    }
    while (start < end) {
        mid = (start + end) / 2;
        if (code_line < entries[mid].code_line) {
            end = mid;
        } else if (code_line > entries[mid].code_line) {
             start = mid + 1;
        } else {
            return mid;
        }
    }
    if (code_line <= entries[mid].code_line) {
        return mid;
    } else {
        return mid + 1;
    }
}
static PyCodeObject *__pyx_find_code_object(int code_line) {
    PyCodeObject* code_object;
    int pos;
    if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
        return NULL;
    }
    pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
    if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) {
        return NULL;
    }
    code_object = __pyx_code_cache.entries[pos].code_object;
    Py_INCREF(code_object);
    return code_object;
}
static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) {
    int pos, i;
    __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
    if (unlikely(!code_line)) {
        return;
    }
    if (unlikely(!entries)) {
        entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry));
        if (likely(entries)) {
            __pyx_code_cache.entries = entries;
            __pyx_code_cache.max_count = 64;
            __pyx_code_cache.count = 1;
            entries[0].code_line = code_line;
            entries[0].code_object = code_object;
            Py_INCREF(code_object);
        }
        return;
    }
    pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
    if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) {
        PyCodeObject* tmp = entries[pos].code_object;
        entries[pos].code_object = code_object;
        Py_DECREF(tmp);
        return;
    }
    if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
        int new_max = __pyx_code_cache.max_count + 64;
        entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
            __pyx_code_cache.entries, new_max*sizeof(__Pyx_CodeObjectCacheEntry));
        if (unlikely(!entries)) {
            return;
        }
        __pyx_code_cache.entries = entries;
        __pyx_code_cache.max_count = new_max;
    }
    for (i=__pyx_code_cache.count; i>pos; i--) {
        entries[i] = entries[i-1];
    }
    entries[pos].code_line = code_line;
    entries[pos].code_object = code_object;
    __pyx_code_cache.count++;
    Py_INCREF(code_object);
}

#include "compile.h"
#include "frameobject.h"
#include "traceback.h"
static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
            const char *funcname, int c_line,
            int py_line, const char *filename) {
    PyCodeObject *py_code = 0;
    PyObject *py_srcfile = 0;
    PyObject *py_funcname = 0;
    #if PY_MAJOR_VERSION < 3
    py_srcfile = PyString_FromString(filename);
    #else
    py_srcfile = PyUnicode_FromString(filename);
    #endif
    if (!py_srcfile) goto bad;
    if (c_line) {
        #if PY_MAJOR_VERSION < 3
        py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
        #else
        py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
        #endif
    }
    else {
        #if PY_MAJOR_VERSION < 3
        py_funcname = PyString_FromString(funcname);
        #else
        py_funcname = PyUnicode_FromString(funcname);
        #endif
    }
    if (!py_funcname) goto bad;
    py_code = __Pyx_PyCode_New(
        0,            /*int argcount,*/
        0,            /*int kwonlyargcount,*/
        0,            /*int nlocals,*/
        0,            /*int stacksize,*/
        0,            /*int flags,*/
        __pyx_empty_bytes, /*PyObject *code,*/
        __pyx_empty_tuple, /*PyObject *consts,*/
        __pyx_empty_tuple, /*PyObject *names,*/
        __pyx_empty_tuple, /*PyObject *varnames,*/
        __pyx_empty_tuple, /*PyObject *freevars,*/
        __pyx_empty_tuple, /*PyObject *cellvars,*/
        py_srcfile,   /*PyObject *filename,*/
        py_funcname,  /*PyObject *name,*/
        py_line,      /*int firstlineno,*/
        __pyx_empty_bytes  /*PyObject *lnotab*/
    );
    Py_DECREF(py_srcfile);
    Py_DECREF(py_funcname);
    return py_code;
bad:
    Py_XDECREF(py_srcfile);
    Py_XDECREF(py_funcname);
    return NULL;
}
static void __Pyx_AddTraceback(const char *funcname, int c_line,
                               int py_line, const char *filename) {
    PyCodeObject *py_code = 0;
    PyObject *py_globals = 0;
    PyFrameObject *py_frame = 0;
    py_code = __pyx_find_code_object(c_line ? c_line : py_line);
    if (!py_code) {
        py_code = __Pyx_CreateCodeObjectForTraceback(
            funcname, c_line, py_line, filename);
        if (!py_code) goto bad;
        __pyx_insert_code_object(c_line ? c_line : py_line, py_code);
    }
    py_globals = PyModule_GetDict(__pyx_m);
    if (!py_globals) goto bad;
    py_frame = PyFrame_New(
        PyThreadState_GET(), /*PyThreadState *tstate,*/
        py_code,             /*PyCodeObject *code,*/
        py_globals,          /*PyObject *globals,*/
        0                    /*PyObject *locals*/
    );
    if (!py_frame) goto bad;
    py_frame->f_lineno = py_line;
    PyTraceBack_Here(py_frame);
bad:
    Py_XDECREF(py_code);
    Py_XDECREF(py_frame);
}

static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
    while (t->p) {
        #if PY_MAJOR_VERSION < 3
        if (t->is_unicode) {
            *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
        } else if (t->intern) {
            *t->p = PyString_InternFromString(t->s);
        } else {
            *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
        }
        #else  /* Python 3+ has unicode identifiers */
        if (t->is_unicode | t->is_str) {
            if (t->intern) {
                *t->p = PyUnicode_InternFromString(t->s);
            } else if (t->encoding) {
                *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL);
            } else {
                *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1);
            }
        } else {
            *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1);
        }
        #endif
        if (!*t->p)
            return -1;
        ++t;
    }
    return 0;
}


/* Type Conversion Functions */

static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) {
   int is_true = x == Py_True;
   if (is_true | (x == Py_False) | (x == Py_None)) return is_true;
   else return PyObject_IsTrue(x);
}

static CYTHON_INLINE PyObject* __Pyx_PyNumber_Int(PyObject* x) {
  PyNumberMethods *m;
  const char *name = NULL;
  PyObject *res = NULL;
#if PY_VERSION_HEX < 0x03000000
  if (PyInt_Check(x) || PyLong_Check(x))
#else
  if (PyLong_Check(x))
#endif
    return Py_INCREF(x), x;
  m = Py_TYPE(x)->tp_as_number;
#if PY_VERSION_HEX < 0x03000000
  if (m && m->nb_int) {
    name = "int";
    res = PyNumber_Int(x);
  }
  else if (m && m->nb_long) {
    name = "long";
    res = PyNumber_Long(x);
  }
#else
  if (m && m->nb_int) {
    name = "int";
    res = PyNumber_Long(x);
  }
#endif
  if (res) {
#if PY_VERSION_HEX < 0x03000000
    if (!PyInt_Check(res) && !PyLong_Check(res)) {
#else
    if (!PyLong_Check(res)) {
#endif
      PyErr_Format(PyExc_TypeError,
                   "__%s__ returned non-%s (type %.200s)",
                   name, name, Py_TYPE(res)->tp_name);
      Py_DECREF(res);
      return NULL;
    }
  }
  else if (!PyErr_Occurred()) {
    PyErr_SetString(PyExc_TypeError,
                    "an integer is required");
  }
  return res;
}

static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
  Py_ssize_t ival;
  PyObject* x = PyNumber_Index(b);
  if (!x) return -1;
  ival = PyInt_AsSsize_t(x);
  Py_DECREF(x);
  return ival;
}

static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
#if PY_VERSION_HEX < 0x02050000
   if (ival <= LONG_MAX)
       return PyInt_FromLong((long)ival);
   else {
       unsigned char *bytes = (unsigned char *) &ival;
       int one = 1; int little = (int)*(unsigned char*)&one;
       return _PyLong_FromByteArray(bytes, sizeof(size_t), little, 0);
   }
#else
   return PyInt_FromSize_t(ival);
#endif
}

static CYTHON_INLINE size_t __Pyx_PyInt_AsSize_t(PyObject* x) {
   unsigned PY_LONG_LONG val = __Pyx_PyInt_AsUnsignedLongLong(x);
   if (unlikely(val == (unsigned PY_LONG_LONG)-1 && PyErr_Occurred())) {
       return (size_t)-1;
   } else if (unlikely(val != (unsigned PY_LONG_LONG)(size_t)val)) {
       PyErr_SetString(PyExc_OverflowError,
                       "value too large to convert to size_t");
       return (size_t)-1;
   }
   return (size_t)val;
}


#endif /* Py_PYTHON_H */
