/* Generated by Cython 0.28.5 */

/* BEGIN: Cython Metadata
{
    "distutils": {
        "depends": [], 
        "name": "punyverse._model", 
        "sources": [
            "punyverse/_model.pyx"
        ]
    }, 
    "module_name": "punyverse._model"
}
END: Cython Metadata */

#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 < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
    #error Cython requires Python 2.6+ or Python 3.3+.
#else
#define CYTHON_ABI "0_28_5"
#define CYTHON_FUTURE_DIVISION 0
#include <stddef.h>
#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
#define __PYX_COMMA ,
#ifndef HAVE_LONG_LONG
  #if PY_VERSION_HEX >= 0x02070000
    #define HAVE_LONG_LONG
  #endif
#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_PYSTON 0
  #define CYTHON_COMPILING_IN_CPYTHON 0
  #undef CYTHON_USE_TYPE_SLOTS
  #define CYTHON_USE_TYPE_SLOTS 0
  #undef CYTHON_USE_PYTYPE_LOOKUP
  #define CYTHON_USE_PYTYPE_LOOKUP 0
  #if PY_VERSION_HEX < 0x03050000
    #undef CYTHON_USE_ASYNC_SLOTS
    #define CYTHON_USE_ASYNC_SLOTS 0
  #elif !defined(CYTHON_USE_ASYNC_SLOTS)
    #define CYTHON_USE_ASYNC_SLOTS 1
  #endif
  #undef CYTHON_USE_PYLIST_INTERNALS
  #define CYTHON_USE_PYLIST_INTERNALS 0
  #undef CYTHON_USE_UNICODE_INTERNALS
  #define CYTHON_USE_UNICODE_INTERNALS 0
  #undef CYTHON_USE_UNICODE_WRITER
  #define CYTHON_USE_UNICODE_WRITER 0
  #undef CYTHON_USE_PYLONG_INTERNALS
  #define CYTHON_USE_PYLONG_INTERNALS 0
  #undef CYTHON_AVOID_BORROWED_REFS
  #define CYTHON_AVOID_BORROWED_REFS 1
  #undef CYTHON_ASSUME_SAFE_MACROS
  #define CYTHON_ASSUME_SAFE_MACROS 0
  #undef CYTHON_UNPACK_METHODS
  #define CYTHON_UNPACK_METHODS 0
  #undef CYTHON_FAST_THREAD_STATE
  #define CYTHON_FAST_THREAD_STATE 0
  #undef CYTHON_FAST_PYCALL
  #define CYTHON_FAST_PYCALL 0
  #undef CYTHON_PEP489_MULTI_PHASE_INIT
  #define CYTHON_PEP489_MULTI_PHASE_INIT 0
  #undef CYTHON_USE_TP_FINALIZE
  #define CYTHON_USE_TP_FINALIZE 0
#elif defined(PYSTON_VERSION)
  #define CYTHON_COMPILING_IN_PYPY 0
  #define CYTHON_COMPILING_IN_PYSTON 1
  #define CYTHON_COMPILING_IN_CPYTHON 0
  #ifndef CYTHON_USE_TYPE_SLOTS
    #define CYTHON_USE_TYPE_SLOTS 1
  #endif
  #undef CYTHON_USE_PYTYPE_LOOKUP
  #define CYTHON_USE_PYTYPE_LOOKUP 0
  #undef CYTHON_USE_ASYNC_SLOTS
  #define CYTHON_USE_ASYNC_SLOTS 0
  #undef CYTHON_USE_PYLIST_INTERNALS
  #define CYTHON_USE_PYLIST_INTERNALS 0
  #ifndef CYTHON_USE_UNICODE_INTERNALS
    #define CYTHON_USE_UNICODE_INTERNALS 1
  #endif
  #undef CYTHON_USE_UNICODE_WRITER
  #define CYTHON_USE_UNICODE_WRITER 0
  #undef CYTHON_USE_PYLONG_INTERNALS
  #define CYTHON_USE_PYLONG_INTERNALS 0
  #ifndef CYTHON_AVOID_BORROWED_REFS
    #define CYTHON_AVOID_BORROWED_REFS 0
  #endif
  #ifndef CYTHON_ASSUME_SAFE_MACROS
    #define CYTHON_ASSUME_SAFE_MACROS 1
  #endif
  #ifndef CYTHON_UNPACK_METHODS
    #define CYTHON_UNPACK_METHODS 1
  #endif
  #undef CYTHON_FAST_THREAD_STATE
  #define CYTHON_FAST_THREAD_STATE 0
  #undef CYTHON_FAST_PYCALL
  #define CYTHON_FAST_PYCALL 0
  #undef CYTHON_PEP489_MULTI_PHASE_INIT
  #define CYTHON_PEP489_MULTI_PHASE_INIT 0
  #undef CYTHON_USE_TP_FINALIZE
  #define CYTHON_USE_TP_FINALIZE 0
#else
  #define CYTHON_COMPILING_IN_PYPY 0
  #define CYTHON_COMPILING_IN_PYSTON 0
  #define CYTHON_COMPILING_IN_CPYTHON 1
  #ifndef CYTHON_USE_TYPE_SLOTS
    #define CYTHON_USE_TYPE_SLOTS 1
  #endif
  #if PY_VERSION_HEX < 0x02070000
    #undef CYTHON_USE_PYTYPE_LOOKUP
    #define CYTHON_USE_PYTYPE_LOOKUP 0
  #elif !defined(CYTHON_USE_PYTYPE_LOOKUP)
    #define CYTHON_USE_PYTYPE_LOOKUP 1
  #endif
  #if PY_MAJOR_VERSION < 3
    #undef CYTHON_USE_ASYNC_SLOTS
    #define CYTHON_USE_ASYNC_SLOTS 0
  #elif !defined(CYTHON_USE_ASYNC_SLOTS)
    #define CYTHON_USE_ASYNC_SLOTS 1
  #endif
  #if PY_VERSION_HEX < 0x02070000
    #undef CYTHON_USE_PYLONG_INTERNALS
    #define CYTHON_USE_PYLONG_INTERNALS 0
  #elif !defined(CYTHON_USE_PYLONG_INTERNALS)
    #define CYTHON_USE_PYLONG_INTERNALS 1
  #endif
  #ifndef CYTHON_USE_PYLIST_INTERNALS
    #define CYTHON_USE_PYLIST_INTERNALS 1
  #endif
  #ifndef CYTHON_USE_UNICODE_INTERNALS
    #define CYTHON_USE_UNICODE_INTERNALS 1
  #endif
  #if PY_VERSION_HEX < 0x030300F0
    #undef CYTHON_USE_UNICODE_WRITER
    #define CYTHON_USE_UNICODE_WRITER 0
  #elif !defined(CYTHON_USE_UNICODE_WRITER)
    #define CYTHON_USE_UNICODE_WRITER 1
  #endif
  #ifndef CYTHON_AVOID_BORROWED_REFS
    #define CYTHON_AVOID_BORROWED_REFS 0
  #endif
  #ifndef CYTHON_ASSUME_SAFE_MACROS
    #define CYTHON_ASSUME_SAFE_MACROS 1
  #endif
  #ifndef CYTHON_UNPACK_METHODS
    #define CYTHON_UNPACK_METHODS 1
  #endif
  #ifndef CYTHON_FAST_THREAD_STATE
    #define CYTHON_FAST_THREAD_STATE 1
  #endif
  #ifndef CYTHON_FAST_PYCALL
    #define CYTHON_FAST_PYCALL 1
  #endif
  #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
    #define CYTHON_PEP489_MULTI_PHASE_INIT (0 && PY_VERSION_HEX >= 0x03050000)
  #endif
  #ifndef CYTHON_USE_TP_FINALIZE
    #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1)
  #endif
#endif
#if !defined(CYTHON_FAST_PYCCALL)
#define CYTHON_FAST_PYCCALL  (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
#endif
#if CYTHON_USE_PYLONG_INTERNALS
  #include "longintrepr.h"
  #undef SHIFT
  #undef BASE
  #undef MASK
#endif
#ifndef __has_attribute
  #define __has_attribute(x) 0
#endif
#ifndef __has_cpp_attribute
  #define __has_cpp_attribute(x) 0
#endif
#ifndef CYTHON_RESTRICT
  #if defined(__GNUC__)
    #define CYTHON_RESTRICT __restrict__
  #elif defined(_MSC_VER) && _MSC_VER >= 1400
    #define CYTHON_RESTRICT __restrict
  #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
    #define CYTHON_RESTRICT restrict
  #else
    #define CYTHON_RESTRICT
  #endif
#endif
#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
#ifndef CYTHON_MAYBE_UNUSED_VAR
#  if defined(__cplusplus)
     template<class T> void CYTHON_MAYBE_UNUSED_VAR( const T& ) { }
#  else
#    define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x)
#  endif
#endif
#ifndef CYTHON_NCP_UNUSED
# if CYTHON_COMPILING_IN_CPYTHON
#  define CYTHON_NCP_UNUSED
# else
#  define CYTHON_NCP_UNUSED CYTHON_UNUSED
# endif
#endif
#define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
#ifdef _MSC_VER
    #ifndef _MSC_STDINT_H_
        #if _MSC_VER < 1300
           typedef unsigned char     uint8_t;
           typedef unsigned int      uint32_t;
        #else
           typedef unsigned __int8   uint8_t;
           typedef unsigned __int32  uint32_t;
        #endif
    #endif
#else
   #include <stdint.h>
#endif
#ifndef CYTHON_FALLTHROUGH
  #if defined(__cplusplus) && __cplusplus >= 201103L
    #if __has_cpp_attribute(fallthrough)
      #define CYTHON_FALLTHROUGH [[fallthrough]]
    #elif __has_cpp_attribute(clang::fallthrough)
      #define CYTHON_FALLTHROUGH [[clang::fallthrough]]
    #elif __has_cpp_attribute(gnu::fallthrough)
      #define CYTHON_FALLTHROUGH [[gnu::fallthrough]]
    #endif
  #endif
  #ifndef CYTHON_FALLTHROUGH
    #if __has_attribute(fallthrough)
      #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
    #else
      #define CYTHON_FALLTHROUGH
    #endif
  #endif
  #if defined(__clang__ ) && defined(__apple_build_version__)
    #if __apple_build_version__ < 7000000
      #undef  CYTHON_FALLTHROUGH
      #define CYTHON_FALLTHROUGH
    #endif
  #endif
#endif

#ifndef CYTHON_INLINE
  #if defined(__clang__)
    #define CYTHON_INLINE __inline__ __attribute__ ((__unused__))
  #elif 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

#if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
  #define Py_OptimizeFlag 0
#endif
#define __PYX_BUILD_PY_SSIZE_T "n"
#define CYTHON_FORMAT_SSIZE_T "z"
#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+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
  #define __Pyx_DefaultClassType PyClass_Type
#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)
  #define __Pyx_DefaultClassType PyType_Type
#endif
#ifndef Py_TPFLAGS_CHECKTYPES
  #define Py_TPFLAGS_CHECKTYPES 0
#endif
#ifndef Py_TPFLAGS_HAVE_INDEX
  #define Py_TPFLAGS_HAVE_INDEX 0
#endif
#ifndef Py_TPFLAGS_HAVE_NEWBUFFER
  #define Py_TPFLAGS_HAVE_NEWBUFFER 0
#endif
#ifndef Py_TPFLAGS_HAVE_FINALIZE
  #define Py_TPFLAGS_HAVE_FINALIZE 0
#endif
#if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
  #ifndef METH_FASTCALL
     #define METH_FASTCALL 0x80
  #endif
  typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *self, PyObject *const *args, Py_ssize_t nargs);
  typedef PyObject *(*__Pyx_PyCFunctionFastWithKeywords) (PyObject *self, PyObject *const *args,
                                                          Py_ssize_t nargs, PyObject *kwnames);
#else
  #define __Pyx_PyCFunctionFast _PyCFunctionFast
  #define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
#endif
#if CYTHON_FAST_PYCCALL
#define __Pyx_PyFastCFunction_Check(func)\
    ((PyCFunction_Check(func) && (METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS)))))
#else
#define __Pyx_PyFastCFunction_Check(func) 0
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc)
  #define PyObject_Malloc(s)   PyMem_Malloc(s)
  #define PyObject_Free(p)     PyMem_Free(p)
  #define PyObject_Realloc(p)  PyMem_Realloc(p)
#endif
#if CYTHON_COMPILING_IN_PYSTON
  #define __Pyx_PyCode_HasFreeVars(co)  PyCode_HasFreeVars(co)
  #define __Pyx_PyFrame_SetLineNumber(frame, lineno) PyFrame_SetLineNumber(frame, lineno)
#else
  #define __Pyx_PyCode_HasFreeVars(co)  (PyCode_GetNumFree(co) > 0)
  #define __Pyx_PyFrame_SetLineNumber(frame, lineno)  (frame)->f_lineno = (lineno)
#endif
#if !CYTHON_FAST_THREAD_STATE || PY_VERSION_HEX < 0x02070000
  #define __Pyx_PyThreadState_Current PyThreadState_GET()
#elif PY_VERSION_HEX >= 0x03060000
  #define __Pyx_PyThreadState_Current _PyThreadState_UncheckedGet()
#elif PY_VERSION_HEX >= 0x03000000
  #define __Pyx_PyThreadState_Current PyThreadState_GET()
#else
  #define __Pyx_PyThreadState_Current _PyThreadState_Current
#endif
#if PY_VERSION_HEX < 0x030700A2 && !defined(PyThread_tss_create) && !defined(Py_tss_NEEDS_INIT)
#include "pythread.h"
#define Py_tss_NEEDS_INIT 0
typedef int Py_tss_t;
static CYTHON_INLINE int PyThread_tss_create(Py_tss_t *key) {
  *key = PyThread_create_key();
  return 0; // PyThread_create_key reports success always
}
static CYTHON_INLINE Py_tss_t * PyThread_tss_alloc(void) {
  Py_tss_t *key = (Py_tss_t *)PyObject_Malloc(sizeof(Py_tss_t));
  *key = Py_tss_NEEDS_INIT;
  return key;
}
static CYTHON_INLINE void PyThread_tss_free(Py_tss_t *key) {
  PyObject_Free(key);
}
static CYTHON_INLINE int PyThread_tss_is_created(Py_tss_t *key) {
  return *key != Py_tss_NEEDS_INIT;
}
static CYTHON_INLINE void PyThread_tss_delete(Py_tss_t *key) {
  PyThread_delete_key(*key);
  *key = Py_tss_NEEDS_INIT;
}
static CYTHON_INLINE int PyThread_tss_set(Py_tss_t *key, void *value) {
  return PyThread_set_key_value(*key, value);
}
static CYTHON_INLINE void * PyThread_tss_get(Py_tss_t *key) {
  return PyThread_get_key_value(*key);
}
#endif // TSS (Thread Specific Storage) API
#if CYTHON_COMPILING_IN_CPYTHON || defined(_PyDict_NewPresized)
#define __Pyx_PyDict_NewPresized(n)  ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
#else
#define __Pyx_PyDict_NewPresized(n)  PyDict_New()
#endif
#if PY_MAJOR_VERSION >= 3 || CYTHON_FUTURE_DIVISION
  #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
#if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1 && CYTHON_USE_UNICODE_INTERNALS
#define __Pyx_PyDict_GetItemStr(dict, name)  _PyDict_GetItem_KnownHash(dict, name, ((PyASCIIObject *) name)->hash)
#else
#define __Pyx_PyDict_GetItemStr(dict, name)  PyDict_GetItem(dict, name)
#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_MAX_CHAR_VALUE(u)   PyUnicode_MAX_CHAR_VALUE(u)
  #define __Pyx_PyUnicode_KIND(u)         PyUnicode_KIND(u)
  #define __Pyx_PyUnicode_DATA(u)         PyUnicode_DATA(u)
  #define __Pyx_PyUnicode_READ(k, d, i)   PyUnicode_READ(k, d, i)
  #define __Pyx_PyUnicode_WRITE(k, d, i, ch)  PyUnicode_WRITE(k, d, i, ch)
  #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
#else
  #define CYTHON_PEP393_ENABLED 0
  #define PyUnicode_1BYTE_KIND  1
  #define PyUnicode_2BYTE_KIND  2
  #define PyUnicode_4BYTE_KIND  4
  #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_MAX_CHAR_VALUE(u)   ((sizeof(Py_UNICODE) == 2) ? 65535 : 1114111)
  #define __Pyx_PyUnicode_KIND(u)         (sizeof(Py_UNICODE))
  #define __Pyx_PyUnicode_DATA(u)         ((void*)PyUnicode_AS_UNICODE(u))
  #define __Pyx_PyUnicode_READ(k, d, i)   ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
  #define __Pyx_PyUnicode_WRITE(k, d, i, ch)  (((void)(k)), ((Py_UNICODE*)d)[i] = ch)
  #define __Pyx_PyUnicode_IS_TRUE(u)      (0 != PyUnicode_GET_SIZE(u))
#endif
#if CYTHON_COMPILING_IN_PYPY
  #define __Pyx_PyUnicode_Concat(a, b)      PyNumber_Add(a, b)
  #define __Pyx_PyUnicode_ConcatSafe(a, b)  PyNumber_Add(a, b)
#else
  #define __Pyx_PyUnicode_Concat(a, b)      PyUnicode_Concat(a, b)
  #define __Pyx_PyUnicode_ConcatSafe(a, b)  ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
      PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
  #define PyUnicode_Contains(u, s)  PySequence_Contains(u, s)
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check)
  #define PyByteArray_Check(obj)  PyObject_TypeCheck(obj, &PyByteArray_Type)
#endif
#if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format)
  #define PyObject_Format(obj, fmt)  PyObject_CallMethod(obj, "__format__", "O", fmt)
#endif
#define __Pyx_PyString_FormatSafe(a, b)   ((unlikely((a) == Py_None)) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
#define __Pyx_PyUnicode_FormatSafe(a, b)  ((unlikely((a) == Py_None)) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
#if PY_MAJOR_VERSION >= 3
  #define __Pyx_PyString_Format(a, b)  PyUnicode_Format(a, b)
#else
  #define __Pyx_PyString_Format(a, b)  PyString_Format(a, b)
#endif
#if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
  #define PyObject_ASCII(o)            PyObject_Repr(o)
#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
  #define PyObject_Unicode             PyObject_Str
#endif
#if PY_MAJOR_VERSION >= 3
  #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
  #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
#else
  #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
  #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
#endif
#ifndef PySet_CheckExact
  #define PySet_CheckExact(obj)        (Py_TYPE(obj) == &PySet_Type)
#endif
#if CYTHON_ASSUME_SAFE_MACROS
  #define __Pyx_PySequence_SIZE(seq)  Py_SIZE(seq)
#else
  #define __Pyx_PySequence_SIZE(seq)  PySequence_Size(seq)
#endif
#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
  #define PyNumber_Int                 PyNumber_Long
#endif
#if PY_MAJOR_VERSION >= 3
  #define PyBoolObject                 PyLongObject
#endif
#if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
  #ifndef PyUnicode_InternFromString
    #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
  #endif
#endif
#if PY_VERSION_HEX < 0x030200A4
  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
  #define __Pyx_PyMethod_New(func, self, klass) ((self) ? PyMethod_New(func, self) : (Py_INCREF(func), func))
#else
  #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
#endif
#if CYTHON_USE_ASYNC_SLOTS
  #if PY_VERSION_HEX >= 0x030500B1
    #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
    #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
  #else
    #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
  #endif
#else
  #define __Pyx_PyType_AsAsync(obj) NULL
#endif
#ifndef __Pyx_PyAsyncMethodsStruct
    typedef struct {
        unaryfunc am_await;
        unaryfunc am_aiter;
        unaryfunc am_anext;
    } __Pyx_PyAsyncMethodsStruct;
#endif

#if defined(WIN32) || defined(MS_WINDOWS)
  #define _USE_MATH_DEFINES
#endif
#include <math.h>
#ifdef NAN
#define __PYX_NAN() ((float) NAN)
#else
static CYTHON_INLINE float __PYX_NAN() {
  float value;
  memset(&value, 0xFF, sizeof(value));
  return value;
}
#endif
#if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
#define __Pyx_truncl trunc
#else
#define __Pyx_truncl truncl
#endif


#define __PYX_ERR(f_index, lineno, Ln_error) \
{ \
  __pyx_filename = __pyx_f[f_index]; __pyx_lineno = lineno; __pyx_clineno = __LINE__; goto Ln_error; \
}

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

#define __PYX_HAVE__punyverse___model
#define __PYX_HAVE_API__punyverse___model
/* Early includes */
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include "windows.h"
#include "GL/gl.h"
#include "stddef.h"
#include "GL/glu.h"
#ifdef _OPENMP
#include <omp.h>
#endif /* _OPENMP */

#if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
#define CYTHON_WITHOUT_ASSERTIONS
#endif

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

#define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
#define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT 0
#define __PYX_DEFAULT_STRING_ENCODING ""
#define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
#define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
#define __Pyx_uchar_cast(c) ((unsigned char)c)
#define __Pyx_long_cast(x) ((long)x)
#define __Pyx_fits_Py_ssize_t(v, type, is_signed)  (\
    (sizeof(type) < sizeof(Py_ssize_t))  ||\
    (sizeof(type) > sizeof(Py_ssize_t) &&\
          likely(v < (type)PY_SSIZE_T_MAX ||\
                 v == (type)PY_SSIZE_T_MAX)  &&\
          (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
                                v == (type)PY_SSIZE_T_MIN)))  ||\
    (sizeof(type) == sizeof(Py_ssize_t) &&\
          (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
                               v == (type)PY_SSIZE_T_MAX)))  )
#if defined (__cplusplus) && __cplusplus >= 201103L
    #include <cstdlib>
    #define __Pyx_sst_abs(value) std::abs(value)
#elif SIZEOF_INT >= SIZEOF_SIZE_T
    #define __Pyx_sst_abs(value) abs(value)
#elif SIZEOF_LONG >= SIZEOF_SIZE_T
    #define __Pyx_sst_abs(value) labs(value)
#elif defined (_MSC_VER)
    #define __Pyx_sst_abs(value) ((Py_ssize_t)_abs64(value))
#elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
    #define __Pyx_sst_abs(value) llabs(value)
#elif defined (__GNUC__)
    #define __Pyx_sst_abs(value) __builtin_llabs(value)
#else
    #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
#endif
static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject*);
static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
#define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s))
#define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
#define __Pyx_PyBytes_FromString        PyBytes_FromString
#define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char*);
#if PY_MAJOR_VERSION < 3
    #define __Pyx_PyStr_FromString        __Pyx_PyBytes_FromString
    #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
#else
    #define __Pyx_PyStr_FromString        __Pyx_PyUnicode_FromString
    #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
#endif
#define __Pyx_PyBytes_AsWritableString(s)     ((char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsWritableSString(s)    ((signed char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsWritableUString(s)    ((unsigned char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsString(s)     ((const char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsSString(s)    ((const signed char*) PyBytes_AS_STRING(s))
#define __Pyx_PyBytes_AsUString(s)    ((const unsigned char*) PyBytes_AS_STRING(s))
#define __Pyx_PyObject_AsWritableString(s)    ((char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsWritableSString(s)    ((signed char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsWritableUString(s)    ((unsigned char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsSString(s)    ((const signed char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_AsUString(s)    ((const unsigned char*) __Pyx_PyObject_AsString(s))
#define __Pyx_PyObject_FromCString(s)  __Pyx_PyObject_FromString((const char*)s)
#define __Pyx_PyBytes_FromCString(s)   __Pyx_PyBytes_FromString((const char*)s)
#define __Pyx_PyByteArray_FromCString(s)   __Pyx_PyByteArray_FromString((const char*)s)
#define __Pyx_PyStr_FromCString(s)     __Pyx_PyStr_FromString((const char*)s)
#define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u) {
    const Py_UNICODE *u_end = u;
    while (*u_end++) ;
    return (size_t)(u_end - u - 1);
}
#define __Pyx_PyUnicode_FromUnicode(u)       PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u))
#define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode
#define __Pyx_PyUnicode_AsUnicode            PyUnicode_AsUnicode
#define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
#define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b);
static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*);
static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x);
#define __Pyx_PySequence_Tuple(obj)\
    (likely(PyTuple_CheckExact(obj)) ? __Pyx_NewRef(obj) : PySequence_Tuple(obj))
static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t);
#if CYTHON_ASSUME_SAFE_MACROS
#define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
#else
#define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
#endif
#define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
#if PY_MAJOR_VERSION >= 3
#define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x))
#else
#define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
#endif
#define __Pyx_PyNumber_Float(x) (PyFloat_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Float(x))
#if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
static int __Pyx_sys_getdefaultencoding_not_ascii;
static int __Pyx_init_sys_getdefaultencoding_params(void) {
    PyObject* sys;
    PyObject* default_encoding = NULL;
    PyObject* ascii_chars_u = NULL;
    PyObject* ascii_chars_b = NULL;
    const char* default_encoding_c;
    sys = PyImport_ImportModule("sys");
    if (!sys) goto bad;
    default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL);
    Py_DECREF(sys);
    if (!default_encoding) goto bad;
    default_encoding_c = PyBytes_AsString(default_encoding);
    if (!default_encoding_c) goto bad;
    if (strcmp(default_encoding_c, "ascii") == 0) {
        __Pyx_sys_getdefaultencoding_not_ascii = 0;
    } else {
        char ascii_chars[128];
        int c;
        for (c = 0; c < 128; c++) {
            ascii_chars[c] = c;
        }
        __Pyx_sys_getdefaultencoding_not_ascii = 1;
        ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
        if (!ascii_chars_u) goto bad;
        ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
        if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
            PyErr_Format(
                PyExc_ValueError,
                "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
                default_encoding_c);
            goto bad;
        }
        Py_DECREF(ascii_chars_u);
        Py_DECREF(ascii_chars_b);
    }
    Py_DECREF(default_encoding);
    return 0;
bad:
    Py_XDECREF(default_encoding);
    Py_XDECREF(ascii_chars_u);
    Py_XDECREF(ascii_chars_b);
    return -1;
}
#endif
#if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
#define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
#else
#define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
#if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
static char* __PYX_DEFAULT_STRING_ENCODING;
static int __Pyx_init_sys_getdefaultencoding_params(void) {
    PyObject* sys;
    PyObject* default_encoding = NULL;
    char* default_encoding_c;
    sys = PyImport_ImportModule("sys");
    if (!sys) goto bad;
    default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL);
    Py_DECREF(sys);
    if (!default_encoding) goto bad;
    default_encoding_c = PyBytes_AsString(default_encoding);
    if (!default_encoding_c) goto bad;
    __PYX_DEFAULT_STRING_ENCODING = (char*) malloc(strlen(default_encoding_c));
    if (!__PYX_DEFAULT_STRING_ENCODING) goto bad;
    strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
    Py_DECREF(default_encoding);
    return 0;
bad:
    Py_XDECREF(default_encoding);
    return -1;
}
#endif
#endif


/* Test for GCC > 2.95 */
#if defined(__GNUC__)     && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
  #define likely(x)   __builtin_expect(!!(x), 1)
  #define unlikely(x) __builtin_expect(!!(x), 0)
#else /* !__GNUC__ or GCC < 2.95 */
  #define likely(x)   (x)
  #define unlikely(x) (x)
#endif /* __GNUC__ */
static CYTHON_INLINE void __Pyx_pretend_to_initialize(void* ptr) { (void)ptr; }

static PyObject *__pyx_m = NULL;
static PyObject *__pyx_d;
static PyObject *__pyx_b;
static PyObject *__pyx_cython_runtime = NULL;
static PyObject *__pyx_empty_tuple;
static PyObject *__pyx_empty_bytes;
static PyObject *__pyx_empty_unicode;
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[] = {
  "punyverse\\_model.pyx",
  "stringsource",
};

/*--- Type declarations ---*/
struct __pyx_obj_9punyverse_6_model_Face;
struct __pyx_obj_9punyverse_6_model_Material;
struct __pyx_obj_9punyverse_6_model_Group;
struct __pyx_obj_9punyverse_6_model_WavefrontObject;
struct __pyx_opt_args_9punyverse_6_model_model_list;

/* "punyverse/_cyopengl.pxi":458
 * 
 * 
 * cdef enum:             # <<<<<<<<<<<<<<
 *     GL_FALSE =                              0x0
 *     GL_TRUE =                               0x1
 */
enum  {
  __pyx_e_9punyverse_6_model_GL_FALSE = 0x0,
  __pyx_e_9punyverse_6_model_GL_TRUE = 0x1,
  __pyx_e_9punyverse_6_model_GL_BYTE = 0x1400,
  __pyx_e_9punyverse_6_model_GL_UNSIGNED_BYTE = 0x1401,
  __pyx_e_9punyverse_6_model_GL_SHORT = 0x1402,
  __pyx_e_9punyverse_6_model_GL_UNSIGNED_SHORT = 0x1403,
  __pyx_e_9punyverse_6_model_GL_INT = 0x1404,
  __pyx_e_9punyverse_6_model_GL_UNSIGNED_INT = 0x1405,
  __pyx_e_9punyverse_6_model_GL_FLOAT = 0x1406,
  __pyx_e_9punyverse_6_model_GL_DOUBLE = 0x140A,
  __pyx_e_9punyverse_6_model_GL_2_BYTES = 0x1407,
  __pyx_e_9punyverse_6_model_GL_3_BYTES = 0x1408,
  __pyx_e_9punyverse_6_model_GL_4_BYTES = 0x1409,
  __pyx_e_9punyverse_6_model_GL_POINTS = 0x0000,
  __pyx_e_9punyverse_6_model_GL_LINES = 0x0001,
  __pyx_e_9punyverse_6_model_GL_LINE_LOOP = 0x0002,
  __pyx_e_9punyverse_6_model_GL_LINE_STRIP = 0x0003,
  __pyx_e_9punyverse_6_model_GL_TRIANGLES = 0x0004,
  __pyx_e_9punyverse_6_model_GL_TRIANGLE_STRIP = 0x0005,
  __pyx_e_9punyverse_6_model_GL_TRIANGLE_FAN = 0x0006,
  __pyx_e_9punyverse_6_model_GL_QUADS = 0x0007,
  __pyx_e_9punyverse_6_model_GL_QUAD_STRIP = 0x0008,
  __pyx_e_9punyverse_6_model_GL_POLYGON = 0x0009,
  __pyx_e_9punyverse_6_model_GL_VERTEX_ARRAY = 0x8074,
  __pyx_e_9punyverse_6_model_GL_NORMAL_ARRAY = 0x8075,
  __pyx_e_9punyverse_6_model_GL_COLOR_ARRAY = 0x8076,
  __pyx_e_9punyverse_6_model_GL_INDEX_ARRAY = 0x8077,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_COORD_ARRAY = 0x8078,
  __pyx_e_9punyverse_6_model_GL_EDGE_FLAG_ARRAY = 0x8079,
  __pyx_e_9punyverse_6_model_GL_VERTEX_ARRAY_SIZE = 0x807A,
  __pyx_e_9punyverse_6_model_GL_VERTEX_ARRAY_TYPE = 0x807B,
  __pyx_e_9punyverse_6_model_GL_VERTEX_ARRAY_STRIDE = 0x807C,
  __pyx_e_9punyverse_6_model_GL_NORMAL_ARRAY_TYPE = 0x807E,
  __pyx_e_9punyverse_6_model_GL_NORMAL_ARRAY_STRIDE = 0x807F,
  __pyx_e_9punyverse_6_model_GL_COLOR_ARRAY_SIZE = 0x8081,
  __pyx_e_9punyverse_6_model_GL_COLOR_ARRAY_TYPE = 0x8082,
  __pyx_e_9punyverse_6_model_GL_COLOR_ARRAY_STRIDE = 0x8083,
  __pyx_e_9punyverse_6_model_GL_INDEX_ARRAY_TYPE = 0x8085,
  __pyx_e_9punyverse_6_model_GL_INDEX_ARRAY_STRIDE = 0x8086,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_COORD_ARRAY_SIZE = 0x8088,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_COORD_ARRAY_TYPE = 0x8089,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_COORD_ARRAY_STRIDE = 0x808A,
  __pyx_e_9punyverse_6_model_GL_EDGE_FLAG_ARRAY_STRIDE = 0x808C,
  __pyx_e_9punyverse_6_model_GL_VERTEX_ARRAY_POINTER = 0x808E,
  __pyx_e_9punyverse_6_model_GL_NORMAL_ARRAY_POINTER = 0x808F,
  __pyx_e_9punyverse_6_model_GL_COLOR_ARRAY_POINTER = 0x8090,
  __pyx_e_9punyverse_6_model_GL_INDEX_ARRAY_POINTER = 0x8091,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_COORD_ARRAY_POINTER = 0x8092,
  __pyx_e_9punyverse_6_model_GL_EDGE_FLAG_ARRAY_POINTER = 0x8093,
  __pyx_e_9punyverse_6_model_GL_V2F = 0x2A20,
  __pyx_e_9punyverse_6_model_GL_V3F = 0x2A21,
  __pyx_e_9punyverse_6_model_GL_C4UB_V2F = 0x2A22,
  __pyx_e_9punyverse_6_model_GL_C4UB_V3F = 0x2A23,
  __pyx_e_9punyverse_6_model_GL_C3F_V3F = 0x2A24,
  __pyx_e_9punyverse_6_model_GL_N3F_V3F = 0x2A25,
  __pyx_e_9punyverse_6_model_GL_C4F_N3F_V3F = 0x2A26,
  __pyx_e_9punyverse_6_model_GL_T2F_V3F = 0x2A27,
  __pyx_e_9punyverse_6_model_GL_T4F_V4F = 0x2A28,
  __pyx_e_9punyverse_6_model_GL_T2F_C4UB_V3F = 0x2A29,
  __pyx_e_9punyverse_6_model_GL_T2F_C3F_V3F = 0x2A2A,
  __pyx_e_9punyverse_6_model_GL_T2F_N3F_V3F = 0x2A2B,
  __pyx_e_9punyverse_6_model_GL_T2F_C4F_N3F_V3F = 0x2A2C,
  __pyx_e_9punyverse_6_model_GL_T4F_C4F_N3F_V4F = 0x2A2D,
  __pyx_e_9punyverse_6_model_GL_MATRIX_MODE = 0x0BA0,
  __pyx_e_9punyverse_6_model_GL_MODELVIEW = 0x1700,
  __pyx_e_9punyverse_6_model_GL_PROJECTION = 0x1701,
  __pyx_e_9punyverse_6_model_GL_TEXTURE = 0x1702,
  __pyx_e_9punyverse_6_model_GL_POINT_SMOOTH = 0x0B10,
  __pyx_e_9punyverse_6_model_GL_POINT_SIZE = 0x0B11,
  __pyx_e_9punyverse_6_model_GL_POINT_SIZE_GRANULARITY = 0x0B13,
  __pyx_e_9punyverse_6_model_GL_POINT_SIZE_RANGE = 0x0B12,
  __pyx_e_9punyverse_6_model_GL_LINE_SMOOTH = 0x0B20,
  __pyx_e_9punyverse_6_model_GL_LINE_STIPPLE = 0x0B24,
  __pyx_e_9punyverse_6_model_GL_LINE_STIPPLE_PATTERN = 0x0B25,
  __pyx_e_9punyverse_6_model_GL_LINE_STIPPLE_REPEAT = 0x0B26,
  __pyx_e_9punyverse_6_model_GL_LINE_WIDTH = 0x0B21,
  __pyx_e_9punyverse_6_model_GL_LINE_WIDTH_GRANULARITY = 0x0B23,
  __pyx_e_9punyverse_6_model_GL_LINE_WIDTH_RANGE = 0x0B22,
  __pyx_e_9punyverse_6_model_GL_POINT = 0x1B00,
  __pyx_e_9punyverse_6_model_GL_LINE = 0x1B01,
  __pyx_e_9punyverse_6_model_GL_FILL = 0x1B02,
  __pyx_e_9punyverse_6_model_GL_CW = 0x0900,
  __pyx_e_9punyverse_6_model_GL_CCW = 0x0901,
  __pyx_e_9punyverse_6_model_GL_FRONT = 0x0404,
  __pyx_e_9punyverse_6_model_GL_BACK = 0x0405,
  __pyx_e_9punyverse_6_model_GL_POLYGON_MODE = 0x0B40,
  __pyx_e_9punyverse_6_model_GL_POLYGON_SMOOTH = 0x0B41,
  __pyx_e_9punyverse_6_model_GL_POLYGON_STIPPLE = 0x0B42,
  __pyx_e_9punyverse_6_model_GL_EDGE_FLAG = 0x0B43,
  __pyx_e_9punyverse_6_model_GL_CULL_FACE = 0x0B44,
  __pyx_e_9punyverse_6_model_GL_CULL_FACE_MODE = 0x0B45,
  __pyx_e_9punyverse_6_model_GL_FRONT_FACE = 0x0B46,
  __pyx_e_9punyverse_6_model_GL_POLYGON_OFFSET_FACTOR = 0x8038,
  __pyx_e_9punyverse_6_model_GL_POLYGON_OFFSET_UNITS = 0x2A00,
  __pyx_e_9punyverse_6_model_GL_POLYGON_OFFSET_POINT = 0x2A01,
  __pyx_e_9punyverse_6_model_GL_POLYGON_OFFSET_LINE = 0x2A02,
  __pyx_e_9punyverse_6_model_GL_POLYGON_OFFSET_FILL = 0x8037,
  __pyx_e_9punyverse_6_model_GL_COMPILE = 0x1300,
  __pyx_e_9punyverse_6_model_GL_COMPILE_AND_EXECUTE = 0x1301,
  __pyx_e_9punyverse_6_model_GL_LIST_BASE = 0x0B32,
  __pyx_e_9punyverse_6_model_GL_LIST_INDEX = 0x0B33,
  __pyx_e_9punyverse_6_model_GL_LIST_MODE = 0x0B30,
  __pyx_e_9punyverse_6_model_GL_NEVER = 0x0200,
  __pyx_e_9punyverse_6_model_GL_LESS = 0x0201,
  __pyx_e_9punyverse_6_model_GL_EQUAL = 0x0202,
  __pyx_e_9punyverse_6_model_GL_LEQUAL = 0x0203,
  __pyx_e_9punyverse_6_model_GL_GREATER = 0x0204,
  __pyx_e_9punyverse_6_model_GL_NOTEQUAL = 0x0205,
  __pyx_e_9punyverse_6_model_GL_GEQUAL = 0x0206,
  __pyx_e_9punyverse_6_model_GL_ALWAYS = 0x0207,
  __pyx_e_9punyverse_6_model_GL_DEPTH_TEST = 0x0B71,
  __pyx_e_9punyverse_6_model_GL_DEPTH_BITS = 0x0D56,
  __pyx_e_9punyverse_6_model_GL_DEPTH_CLEAR_VALUE = 0x0B73,
  __pyx_e_9punyverse_6_model_GL_DEPTH_FUNC = 0x0B74,
  __pyx_e_9punyverse_6_model_GL_DEPTH_RANGE = 0x0B70,
  __pyx_e_9punyverse_6_model_GL_DEPTH_WRITEMASK = 0x0B72,
  __pyx_e_9punyverse_6_model_GL_DEPTH_COMPONENT = 0x1902,
  __pyx_e_9punyverse_6_model_GL_LIGHTING = 0x0B50,
  __pyx_e_9punyverse_6_model_GL_LIGHT0 = 0x4000,
  __pyx_e_9punyverse_6_model_GL_LIGHT1 = 0x4001,
  __pyx_e_9punyverse_6_model_GL_LIGHT2 = 0x4002,
  __pyx_e_9punyverse_6_model_GL_LIGHT3 = 0x4003,
  __pyx_e_9punyverse_6_model_GL_LIGHT4 = 0x4004,
  __pyx_e_9punyverse_6_model_GL_LIGHT5 = 0x4005,
  __pyx_e_9punyverse_6_model_GL_LIGHT6 = 0x4006,
  __pyx_e_9punyverse_6_model_GL_LIGHT7 = 0x4007,
  __pyx_e_9punyverse_6_model_GL_SPOT_EXPONENT = 0x1205,
  __pyx_e_9punyverse_6_model_GL_SPOT_CUTOFF = 0x1206,
  __pyx_e_9punyverse_6_model_GL_CONSTANT_ATTENUATION = 0x1207,
  __pyx_e_9punyverse_6_model_GL_LINEAR_ATTENUATION = 0x1208,
  __pyx_e_9punyverse_6_model_GL_QUADRATIC_ATTENUATION = 0x1209,
  __pyx_e_9punyverse_6_model_GL_AMBIENT = 0x1200,
  __pyx_e_9punyverse_6_model_GL_DIFFUSE = 0x1201,
  __pyx_e_9punyverse_6_model_GL_SPECULAR = 0x1202,
  __pyx_e_9punyverse_6_model_GL_SHININESS = 0x1601,
  __pyx_e_9punyverse_6_model_GL_EMISSION = 0x1600,
  __pyx_e_9punyverse_6_model_GL_POSITION = 0x1203,
  __pyx_e_9punyverse_6_model_GL_SPOT_DIRECTION = 0x1204,
  __pyx_e_9punyverse_6_model_GL_AMBIENT_AND_DIFFUSE = 0x1602,
  __pyx_e_9punyverse_6_model_GL_COLOR_INDEXES = 0x1603,
  __pyx_e_9punyverse_6_model_GL_LIGHT_MODEL_TWO_SIDE = 0x0B52,
  __pyx_e_9punyverse_6_model_GL_LIGHT_MODEL_LOCAL_VIEWER = 0x0B51,
  __pyx_e_9punyverse_6_model_GL_LIGHT_MODEL_AMBIENT = 0x0B53,
  __pyx_e_9punyverse_6_model_GL_FRONT_AND_BACK = 0x0408,
  __pyx_e_9punyverse_6_model_GL_SHADE_MODEL = 0x0B54,
  __pyx_e_9punyverse_6_model_GL_FLAT = 0x1D00,
  __pyx_e_9punyverse_6_model_GL_SMOOTH = 0x1D01,
  __pyx_e_9punyverse_6_model_GL_COLOR_MATERIAL = 0x0B57,
  __pyx_e_9punyverse_6_model_GL_COLOR_MATERIAL_FACE = 0x0B55,
  __pyx_e_9punyverse_6_model_GL_COLOR_MATERIAL_PARAMETER = 0x0B56,
  __pyx_e_9punyverse_6_model_GL_NORMALIZE = 0x0BA1,
  __pyx_e_9punyverse_6_model_GL_CLIP_PLANE0 = 0x3000,
  __pyx_e_9punyverse_6_model_GL_CLIP_PLANE1 = 0x3001,
  __pyx_e_9punyverse_6_model_GL_CLIP_PLANE2 = 0x3002,
  __pyx_e_9punyverse_6_model_GL_CLIP_PLANE3 = 0x3003,
  __pyx_e_9punyverse_6_model_GL_CLIP_PLANE4 = 0x3004,
  __pyx_e_9punyverse_6_model_GL_CLIP_PLANE5 = 0x3005,
  __pyx_e_9punyverse_6_model_GL_ACCUM_RED_BITS = 0x0D58,
  __pyx_e_9punyverse_6_model_GL_ACCUM_GREEN_BITS = 0x0D59,
  __pyx_e_9punyverse_6_model_GL_ACCUM_BLUE_BITS = 0x0D5A,
  __pyx_e_9punyverse_6_model_GL_ACCUM_ALPHA_BITS = 0x0D5B,
  __pyx_e_9punyverse_6_model_GL_ACCUM_CLEAR_VALUE = 0x0B80,
  __pyx_e_9punyverse_6_model_GL_ACCUM = 0x0100,
  __pyx_e_9punyverse_6_model_GL_ADD = 0x0104,
  __pyx_e_9punyverse_6_model_GL_LOAD = 0x0101,
  __pyx_e_9punyverse_6_model_GL_MULT = 0x0103,
  __pyx_e_9punyverse_6_model_GL_RETURN = 0x0102,
  __pyx_e_9punyverse_6_model_GL_ALPHA_TEST = 0x0BC0,
  __pyx_e_9punyverse_6_model_GL_ALPHA_TEST_REF = 0x0BC2,
  __pyx_e_9punyverse_6_model_GL_ALPHA_TEST_FUNC = 0x0BC1,
  __pyx_e_9punyverse_6_model_GL_BLEND = 0x0BE2,
  __pyx_e_9punyverse_6_model_GL_BLEND_SRC = 0x0BE1,
  __pyx_e_9punyverse_6_model_GL_BLEND_DST = 0x0BE0,
  __pyx_e_9punyverse_6_model_GL_ZERO = 0x0,
  __pyx_e_9punyverse_6_model_GL_ONE = 0x1,
  __pyx_e_9punyverse_6_model_GL_SRC_COLOR = 0x0300,
  __pyx_e_9punyverse_6_model_GL_ONE_MINUS_SRC_COLOR = 0x0301,
  __pyx_e_9punyverse_6_model_GL_SRC_ALPHA = 0x0302,
  __pyx_e_9punyverse_6_model_GL_ONE_MINUS_SRC_ALPHA = 0x0303,
  __pyx_e_9punyverse_6_model_GL_DST_ALPHA = 0x0304,
  __pyx_e_9punyverse_6_model_GL_ONE_MINUS_DST_ALPHA = 0x0305,
  __pyx_e_9punyverse_6_model_GL_DST_COLOR = 0x0306,
  __pyx_e_9punyverse_6_model_GL_ONE_MINUS_DST_COLOR = 0x0307,
  __pyx_e_9punyverse_6_model_GL_SRC_ALPHA_SATURATE = 0x0308,
  __pyx_e_9punyverse_6_model_GL_CONSTANT_COLOR = 0x8001,
  __pyx_e_9punyverse_6_model_GL_ONE_MINUS_CONSTANT_COLOR = 0x8002,
  __pyx_e_9punyverse_6_model_GL_CONSTANT_ALPHA = 0x8003,
  __pyx_e_9punyverse_6_model_GL_ONE_MINUS_CONSTANT_ALPHA = 0x8004,
  __pyx_e_9punyverse_6_model_GL_FEEDBACK = 0x1C01,
  __pyx_e_9punyverse_6_model_GL_RENDER = 0x1C00,
  __pyx_e_9punyverse_6_model_GL_SELECT = 0x1C02,
  __pyx_e_9punyverse_6_model_GL_2D = 0x0600,
  __pyx_e_9punyverse_6_model_GL_3D = 0x0601,
  __pyx_e_9punyverse_6_model_GL_3D_COLOR = 0x0602,
  __pyx_e_9punyverse_6_model_GL_3D_COLOR_TEXTURE = 0x0603,
  __pyx_e_9punyverse_6_model_GL_4D_COLOR_TEXTURE = 0x0604,
  __pyx_e_9punyverse_6_model_GL_POINT_TOKEN = 0x0701,
  __pyx_e_9punyverse_6_model_GL_LINE_TOKEN = 0x0702,
  __pyx_e_9punyverse_6_model_GL_LINE_RESET_TOKEN = 0x0707,
  __pyx_e_9punyverse_6_model_GL_POLYGON_TOKEN = 0x0703,
  __pyx_e_9punyverse_6_model_GL_BITMAP_TOKEN = 0x0704,
  __pyx_e_9punyverse_6_model_GL_DRAW_PIXEL_TOKEN = 0x0705,
  __pyx_e_9punyverse_6_model_GL_COPY_PIXEL_TOKEN = 0x0706,
  __pyx_e_9punyverse_6_model_GL_PASS_THROUGH_TOKEN = 0x0700,
  __pyx_e_9punyverse_6_model_GL_FEEDBACK_BUFFER_POINTER = 0x0DF0,
  __pyx_e_9punyverse_6_model_GL_FEEDBACK_BUFFER_SIZE = 0x0DF1,
  __pyx_e_9punyverse_6_model_GL_FEEDBACK_BUFFER_TYPE = 0x0DF2,
  __pyx_e_9punyverse_6_model_GL_SELECTION_BUFFER_POINTER = 0x0DF3,
  __pyx_e_9punyverse_6_model_GL_SELECTION_BUFFER_SIZE = 0x0DF4,
  __pyx_e_9punyverse_6_model_GL_FOG = 0x0B60,
  __pyx_e_9punyverse_6_model_GL_FOG_MODE = 0x0B65,
  __pyx_e_9punyverse_6_model_GL_FOG_DENSITY = 0x0B62,
  __pyx_e_9punyverse_6_model_GL_FOG_COLOR = 0x0B66,
  __pyx_e_9punyverse_6_model_GL_FOG_INDEX = 0x0B61,
  __pyx_e_9punyverse_6_model_GL_FOG_START = 0x0B63,
  __pyx_e_9punyverse_6_model_GL_FOG_END = 0x0B64,
  __pyx_e_9punyverse_6_model_GL_LINEAR = 0x2601,
  __pyx_e_9punyverse_6_model_GL_EXP = 0x0800,
  __pyx_e_9punyverse_6_model_GL_EXP2 = 0x0801,
  __pyx_e_9punyverse_6_model_GL_LOGIC_OP = 0x0BF1,
  __pyx_e_9punyverse_6_model_GL_INDEX_LOGIC_OP = 0x0BF1,
  __pyx_e_9punyverse_6_model_GL_COLOR_LOGIC_OP = 0x0BF2,
  __pyx_e_9punyverse_6_model_GL_LOGIC_OP_MODE = 0x0BF0,
  __pyx_e_9punyverse_6_model_GL_CLEAR = 0x1500,
  __pyx_e_9punyverse_6_model_GL_SET = 0x150F,
  __pyx_e_9punyverse_6_model_GL_COPY = 0x1503,
  __pyx_e_9punyverse_6_model_GL_COPY_INVERTED = 0x150C,
  __pyx_e_9punyverse_6_model_GL_NOOP = 0x1505,
  __pyx_e_9punyverse_6_model_GL_INVERT = 0x150A,
  __pyx_e_9punyverse_6_model_GL_AND = 0x1501,
  __pyx_e_9punyverse_6_model_GL_NAND = 0x150E,
  __pyx_e_9punyverse_6_model_GL_OR = 0x1507,
  __pyx_e_9punyverse_6_model_GL_NOR = 0x1508,
  __pyx_e_9punyverse_6_model_GL_XOR = 0x1506,
  __pyx_e_9punyverse_6_model_GL_EQUIV = 0x1509,
  __pyx_e_9punyverse_6_model_GL_AND_REVERSE = 0x1502,
  __pyx_e_9punyverse_6_model_GL_AND_INVERTED = 0x1504,
  __pyx_e_9punyverse_6_model_GL_OR_REVERSE = 0x150B,
  __pyx_e_9punyverse_6_model_GL_OR_INVERTED = 0x150D,
  __pyx_e_9punyverse_6_model_GL_STENCIL_TEST = 0x0B90,
  __pyx_e_9punyverse_6_model_GL_STENCIL_WRITEMASK = 0x0B98,
  __pyx_e_9punyverse_6_model_GL_STENCIL_BITS = 0x0D57,
  __pyx_e_9punyverse_6_model_GL_STENCIL_FUNC = 0x0B92,
  __pyx_e_9punyverse_6_model_GL_STENCIL_VALUE_MASK = 0x0B93,
  __pyx_e_9punyverse_6_model_GL_STENCIL_REF = 0x0B97,
  __pyx_e_9punyverse_6_model_GL_STENCIL_FAIL = 0x0B94,
  __pyx_e_9punyverse_6_model_GL_STENCIL_PASS_DEPTH_PASS = 0x0B96,
  __pyx_e_9punyverse_6_model_GL_STENCIL_PASS_DEPTH_FAIL = 0x0B95,
  __pyx_e_9punyverse_6_model_GL_STENCIL_CLEAR_VALUE = 0x0B91,
  __pyx_e_9punyverse_6_model_GL_STENCIL_INDEX = 0x1901,
  __pyx_e_9punyverse_6_model_GL_KEEP = 0x1E00,
  __pyx_e_9punyverse_6_model_GL_REPLACE = 0x1E01,
  __pyx_e_9punyverse_6_model_GL_INCR = 0x1E02,
  __pyx_e_9punyverse_6_model_GL_DECR = 0x1E03,
  __pyx_e_9punyverse_6_model_GL_NONE = 0x0,
  __pyx_e_9punyverse_6_model_GL_LEFT = 0x0406,
  __pyx_e_9punyverse_6_model_GL_RIGHT = 0x0407,
  __pyx_e_9punyverse_6_model_GL_FRONT_LEFT = 0x0400,
  __pyx_e_9punyverse_6_model_GL_FRONT_RIGHT = 0x0401,
  __pyx_e_9punyverse_6_model_GL_BACK_LEFT = 0x0402,
  __pyx_e_9punyverse_6_model_GL_BACK_RIGHT = 0x0403,
  __pyx_e_9punyverse_6_model_GL_AUX0 = 0x0409,
  __pyx_e_9punyverse_6_model_GL_AUX1 = 0x040A,
  __pyx_e_9punyverse_6_model_GL_AUX2 = 0x040B,
  __pyx_e_9punyverse_6_model_GL_AUX3 = 0x040C,
  __pyx_e_9punyverse_6_model_GL_COLOR_INDEX = 0x1900,
  __pyx_e_9punyverse_6_model_GL_RED = 0x1903,
  __pyx_e_9punyverse_6_model_GL_GREEN = 0x1904,
  __pyx_e_9punyverse_6_model_GL_BLUE = 0x1905,
  __pyx_e_9punyverse_6_model_GL_ALPHA = 0x1906,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE = 0x1909,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE_ALPHA = 0x190A,
  __pyx_e_9punyverse_6_model_GL_ALPHA_BITS = 0x0D55,
  __pyx_e_9punyverse_6_model_GL_RED_BITS = 0x0D52,
  __pyx_e_9punyverse_6_model_GL_GREEN_BITS = 0x0D53,
  __pyx_e_9punyverse_6_model_GL_BLUE_BITS = 0x0D54,
  __pyx_e_9punyverse_6_model_GL_INDEX_BITS = 0x0D51,
  __pyx_e_9punyverse_6_model_GL_SUBPIXEL_BITS = 0x0D50,
  __pyx_e_9punyverse_6_model_GL_AUX_BUFFERS = 0x0C00,
  __pyx_e_9punyverse_6_model_GL_READ_BUFFER = 0x0C02,
  __pyx_e_9punyverse_6_model_GL_DRAW_BUFFER = 0x0C01,
  __pyx_e_9punyverse_6_model_GL_DOUBLEBUFFER = 0x0C32,
  __pyx_e_9punyverse_6_model_GL_STEREO = 0x0C33,
  __pyx_e_9punyverse_6_model_GL_BITMAP = 0x1A00,
  __pyx_e_9punyverse_6_model_GL_COLOR = 0x1800,
  __pyx_e_9punyverse_6_model_GL_DEPTH = 0x1801,
  __pyx_e_9punyverse_6_model_GL_STENCIL = 0x1802,
  __pyx_e_9punyverse_6_model_GL_DITHER = 0x0BD0,
  __pyx_e_9punyverse_6_model_GL_RGB = 0x1907,
  __pyx_e_9punyverse_6_model_GL_RGBA = 0x1908,
  __pyx_e_9punyverse_6_model_GL_MAX_LIST_NESTING = 0x0B31,
  __pyx_e_9punyverse_6_model_GL_MAX_ATTRIB_STACK_DEPTH = 0x0D35,
  __pyx_e_9punyverse_6_model_GL_MAX_MODELVIEW_STACK_DEPTH = 0x0D36,
  __pyx_e_9punyverse_6_model_GL_MAX_NAME_STACK_DEPTH = 0x0D37,
  __pyx_e_9punyverse_6_model_GL_MAX_PROJECTION_STACK_DEPTH = 0x0D38,
  __pyx_e_9punyverse_6_model_GL_MAX_TEXTURE_STACK_DEPTH = 0x0D39,
  __pyx_e_9punyverse_6_model_GL_MAX_EVAL_ORDER = 0x0D30,
  __pyx_e_9punyverse_6_model_GL_MAX_LIGHTS = 0x0D31,
  __pyx_e_9punyverse_6_model_GL_MAX_CLIP_PLANES = 0x0D32,
  __pyx_e_9punyverse_6_model_GL_MAX_TEXTURE_SIZE = 0x0D33,
  __pyx_e_9punyverse_6_model_GL_MAX_PIXEL_MAP_TABLE = 0x0D34,
  __pyx_e_9punyverse_6_model_GL_MAX_VIEWPORT_DIMS = 0x0D3A,
  __pyx_e_9punyverse_6_model_GL_MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B,
  __pyx_e_9punyverse_6_model_GL_ATTRIB_STACK_DEPTH = 0x0BB0,
  __pyx_e_9punyverse_6_model_GL_CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1,
  __pyx_e_9punyverse_6_model_GL_COLOR_CLEAR_VALUE = 0x0C22,
  __pyx_e_9punyverse_6_model_GL_COLOR_WRITEMASK = 0x0C23,
  __pyx_e_9punyverse_6_model_GL_CURRENT_INDEX = 0x0B01,
  __pyx_e_9punyverse_6_model_GL_CURRENT_COLOR = 0x0B00,
  __pyx_e_9punyverse_6_model_GL_CURRENT_NORMAL = 0x0B02,
  __pyx_e_9punyverse_6_model_GL_CURRENT_RASTER_COLOR = 0x0B04,
  __pyx_e_9punyverse_6_model_GL_CURRENT_RASTER_DISTANCE = 0x0B09,
  __pyx_e_9punyverse_6_model_GL_CURRENT_RASTER_INDEX = 0x0B05,
  __pyx_e_9punyverse_6_model_GL_CURRENT_RASTER_POSITION = 0x0B07,
  __pyx_e_9punyverse_6_model_GL_CURRENT_RASTER_TEXTURE_COORDS = 0x0B06,
  __pyx_e_9punyverse_6_model_GL_CURRENT_RASTER_POSITION_VALID = 0x0B08,
  __pyx_e_9punyverse_6_model_GL_CURRENT_TEXTURE_COORDS = 0x0B03,
  __pyx_e_9punyverse_6_model_GL_INDEX_CLEAR_VALUE = 0x0C20,
  __pyx_e_9punyverse_6_model_GL_INDEX_MODE = 0x0C30,
  __pyx_e_9punyverse_6_model_GL_INDEX_WRITEMASK = 0x0C21,
  __pyx_e_9punyverse_6_model_GL_MODELVIEW_MATRIX = 0x0BA6,
  __pyx_e_9punyverse_6_model_GL_MODELVIEW_STACK_DEPTH = 0x0BA3,
  __pyx_e_9punyverse_6_model_GL_NAME_STACK_DEPTH = 0x0D70,
  __pyx_e_9punyverse_6_model_GL_PROJECTION_MATRIX = 0x0BA7,
  __pyx_e_9punyverse_6_model_GL_PROJECTION_STACK_DEPTH = 0x0BA4,
  __pyx_e_9punyverse_6_model_GL_RENDER_MODE = 0x0C40,
  __pyx_e_9punyverse_6_model_GL_RGBA_MODE = 0x0C31,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_MATRIX = 0x0BA8,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_STACK_DEPTH = 0x0BA5,
  __pyx_e_9punyverse_6_model_GL_VIEWPORT = 0x0BA2,
  __pyx_e_9punyverse_6_model_GL_AUTO_NORMAL = 0x0D80,
  __pyx_e_9punyverse_6_model_GL_MAP1_COLOR_4 = 0x0D90,
  __pyx_e_9punyverse_6_model_GL_MAP1_GRID_DOMAIN = 0x0DD0,
  __pyx_e_9punyverse_6_model_GL_MAP1_GRID_SEGMENTS = 0x0DD1,
  __pyx_e_9punyverse_6_model_GL_MAP1_INDEX = 0x0D91,
  __pyx_e_9punyverse_6_model_GL_MAP1_NORMAL = 0x0D92,
  __pyx_e_9punyverse_6_model_GL_MAP1_TEXTURE_COORD_1 = 0x0D93,
  __pyx_e_9punyverse_6_model_GL_MAP1_TEXTURE_COORD_2 = 0x0D94,
  __pyx_e_9punyverse_6_model_GL_MAP1_TEXTURE_COORD_3 = 0x0D95,
  __pyx_e_9punyverse_6_model_GL_MAP1_TEXTURE_COORD_4 = 0x0D96,
  __pyx_e_9punyverse_6_model_GL_MAP1_VERTEX_3 = 0x0D97,
  __pyx_e_9punyverse_6_model_GL_MAP1_VERTEX_4 = 0x0D98,
  __pyx_e_9punyverse_6_model_GL_MAP2_COLOR_4 = 0x0DB0,
  __pyx_e_9punyverse_6_model_GL_MAP2_GRID_DOMAIN = 0x0DD2,
  __pyx_e_9punyverse_6_model_GL_MAP2_GRID_SEGMENTS = 0x0DD3,
  __pyx_e_9punyverse_6_model_GL_MAP2_INDEX = 0x0DB1,
  __pyx_e_9punyverse_6_model_GL_MAP2_NORMAL = 0x0DB2,
  __pyx_e_9punyverse_6_model_GL_MAP2_TEXTURE_COORD_1 = 0x0DB3,
  __pyx_e_9punyverse_6_model_GL_MAP2_TEXTURE_COORD_2 = 0x0DB4,
  __pyx_e_9punyverse_6_model_GL_MAP2_TEXTURE_COORD_3 = 0x0DB5,
  __pyx_e_9punyverse_6_model_GL_MAP2_TEXTURE_COORD_4 = 0x0DB6,
  __pyx_e_9punyverse_6_model_GL_MAP2_VERTEX_3 = 0x0DB7,
  __pyx_e_9punyverse_6_model_GL_MAP2_VERTEX_4 = 0x0DB8,
  __pyx_e_9punyverse_6_model_GL_COEFF = 0x0A00,
  __pyx_e_9punyverse_6_model_GL_DOMAIN = 0x0A02,
  __pyx_e_9punyverse_6_model_GL_ORDER = 0x0A01,
  __pyx_e_9punyverse_6_model_GL_FOG_HINT = 0x0C54,
  __pyx_e_9punyverse_6_model_GL_LINE_SMOOTH_HINT = 0x0C52,
  __pyx_e_9punyverse_6_model_GL_PERSPECTIVE_CORRECTION_HINT = 0x0C50,
  __pyx_e_9punyverse_6_model_GL_POINT_SMOOTH_HINT = 0x0C51,
  __pyx_e_9punyverse_6_model_GL_POLYGON_SMOOTH_HINT = 0x0C53,
  __pyx_e_9punyverse_6_model_GL_DONT_CARE = 0x1100,
  __pyx_e_9punyverse_6_model_GL_FASTEST = 0x1101,
  __pyx_e_9punyverse_6_model_GL_NICEST = 0x1102,
  __pyx_e_9punyverse_6_model_GL_SCISSOR_TEST = 0x0C11,
  __pyx_e_9punyverse_6_model_GL_SCISSOR_BOX = 0x0C10,
  __pyx_e_9punyverse_6_model_GL_MAP_COLOR = 0x0D10,
  __pyx_e_9punyverse_6_model_GL_MAP_STENCIL = 0x0D11,
  __pyx_e_9punyverse_6_model_GL_INDEX_SHIFT = 0x0D12,
  __pyx_e_9punyverse_6_model_GL_INDEX_OFFSET = 0x0D13,
  __pyx_e_9punyverse_6_model_GL_RED_SCALE = 0x0D14,
  __pyx_e_9punyverse_6_model_GL_RED_BIAS = 0x0D15,
  __pyx_e_9punyverse_6_model_GL_GREEN_SCALE = 0x0D18,
  __pyx_e_9punyverse_6_model_GL_GREEN_BIAS = 0x0D19,
  __pyx_e_9punyverse_6_model_GL_BLUE_SCALE = 0x0D1A,
  __pyx_e_9punyverse_6_model_GL_BLUE_BIAS = 0x0D1B,
  __pyx_e_9punyverse_6_model_GL_ALPHA_SCALE = 0x0D1C,
  __pyx_e_9punyverse_6_model_GL_ALPHA_BIAS = 0x0D1D,
  __pyx_e_9punyverse_6_model_GL_DEPTH_SCALE = 0x0D1E,
  __pyx_e_9punyverse_6_model_GL_DEPTH_BIAS = 0x0D1F,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_S_TO_S_SIZE = 0x0CB1,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_I_SIZE = 0x0CB0,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_R_SIZE = 0x0CB2,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_G_SIZE = 0x0CB3,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_B_SIZE = 0x0CB4,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_A_SIZE = 0x0CB5,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_R_TO_R_SIZE = 0x0CB6,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_G_TO_G_SIZE = 0x0CB7,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_B_TO_B_SIZE = 0x0CB8,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_A_TO_A_SIZE = 0x0CB9,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_S_TO_S = 0x0C71,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_I = 0x0C70,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_R = 0x0C72,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_G = 0x0C73,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_B = 0x0C74,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_I_TO_A = 0x0C75,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_R_TO_R = 0x0C76,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_G_TO_G = 0x0C77,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_B_TO_B = 0x0C78,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MAP_A_TO_A = 0x0C79,
  __pyx_e_9punyverse_6_model_GL_PACK_ALIGNMENT = 0x0D05,
  __pyx_e_9punyverse_6_model_GL_PACK_LSB_FIRST = 0x0D01,
  __pyx_e_9punyverse_6_model_GL_PACK_ROW_LENGTH = 0x0D02,
  __pyx_e_9punyverse_6_model_GL_PACK_SKIP_PIXELS = 0x0D04,
  __pyx_e_9punyverse_6_model_GL_PACK_SKIP_ROWS = 0x0D03,
  __pyx_e_9punyverse_6_model_GL_PACK_SWAP_BYTES = 0x0D00,
  __pyx_e_9punyverse_6_model_GL_UNPACK_ALIGNMENT = 0x0CF5,
  __pyx_e_9punyverse_6_model_GL_UNPACK_LSB_FIRST = 0x0CF1,
  __pyx_e_9punyverse_6_model_GL_UNPACK_ROW_LENGTH = 0x0CF2,
  __pyx_e_9punyverse_6_model_GL_UNPACK_SKIP_PIXELS = 0x0CF4,
  __pyx_e_9punyverse_6_model_GL_UNPACK_SKIP_ROWS = 0x0CF3,
  __pyx_e_9punyverse_6_model_GL_UNPACK_SWAP_BYTES = 0x0CF0,
  __pyx_e_9punyverse_6_model_GL_ZOOM_X = 0x0D16,
  __pyx_e_9punyverse_6_model_GL_ZOOM_Y = 0x0D17,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_ENV = 0x2300,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_ENV_MODE = 0x2200,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_1D = 0x0DE0,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_2D = 0x0DE1,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_WRAP_S = 0x2802,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_WRAP_T = 0x2803,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_MAG_FILTER = 0x2800,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_MIN_FILTER = 0x2801,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_ENV_COLOR = 0x2201,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_GEN_S = 0x0C60,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_GEN_T = 0x0C61,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_GEN_MODE = 0x2500,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_BORDER_COLOR = 0x1004,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_WIDTH = 0x1000,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_HEIGHT = 0x1001,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_BORDER = 0x1005,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_COMPONENTS = 0x1003,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_RED_SIZE = 0x805C,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_GREEN_SIZE = 0x805D,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_BLUE_SIZE = 0x805E,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_ALPHA_SIZE = 0x805F,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_LUMINANCE_SIZE = 0x8060,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_INTENSITY_SIZE = 0x8061,
  __pyx_e_9punyverse_6_model_GL_NEAREST_MIPMAP_NEAREST = 0x2700,
  __pyx_e_9punyverse_6_model_GL_NEAREST_MIPMAP_LINEAR = 0x2702,
  __pyx_e_9punyverse_6_model_GL_LINEAR_MIPMAP_NEAREST = 0x2701,
  __pyx_e_9punyverse_6_model_GL_LINEAR_MIPMAP_LINEAR = 0x2703,
  __pyx_e_9punyverse_6_model_GL_OBJECT_LINEAR = 0x2401,
  __pyx_e_9punyverse_6_model_GL_OBJECT_PLANE = 0x2501,
  __pyx_e_9punyverse_6_model_GL_EYE_LINEAR = 0x2400,
  __pyx_e_9punyverse_6_model_GL_EYE_PLANE = 0x2502,
  __pyx_e_9punyverse_6_model_GL_SPHERE_MAP = 0x2402,
  __pyx_e_9punyverse_6_model_GL_DECAL = 0x2101,
  __pyx_e_9punyverse_6_model_GL_MODULATE = 0x2100,
  __pyx_e_9punyverse_6_model_GL_NEAREST = 0x2600,
  __pyx_e_9punyverse_6_model_GL_REPEAT = 0x2901,
  __pyx_e_9punyverse_6_model_GL_CLAMP = 0x2900,
  __pyx_e_9punyverse_6_model_GL_S = 0x2000,
  __pyx_e_9punyverse_6_model_GL_T = 0x2001,
  __pyx_e_9punyverse_6_model_GL_R = 0x2002,
  __pyx_e_9punyverse_6_model_GL_Q = 0x2003,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_GEN_R = 0x0C62,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_GEN_Q = 0x0C63,
  __pyx_e_9punyverse_6_model_GL_VENDOR = 0x1F00,
  __pyx_e_9punyverse_6_model_GL_RENDERER = 0x1F01,
  __pyx_e_9punyverse_6_model_GL_VERSION = 0x1F02,
  __pyx_e_9punyverse_6_model_GL_EXTENSIONS = 0x1F03,
  __pyx_e_9punyverse_6_model_GL_NO_ERROR = 0x0,
  __pyx_e_9punyverse_6_model_GL_INVALID_VALUE = 0x0501,
  __pyx_e_9punyverse_6_model_GL_INVALID_ENUM = 0x0500,
  __pyx_e_9punyverse_6_model_GL_INVALID_OPERATION = 0x0502,
  __pyx_e_9punyverse_6_model_GL_STACK_OVERFLOW = 0x0503,
  __pyx_e_9punyverse_6_model_GL_STACK_UNDERFLOW = 0x0504,
  __pyx_e_9punyverse_6_model_GL_OUT_OF_MEMORY = 0x0505,
  __pyx_e_9punyverse_6_model_GL_CURRENT_BIT = 0x00000001,
  __pyx_e_9punyverse_6_model_GL_POINT_BIT = 0x00000002,
  __pyx_e_9punyverse_6_model_GL_LINE_BIT = 0x00000004,
  __pyx_e_9punyverse_6_model_GL_POLYGON_BIT = 0x00000008,
  __pyx_e_9punyverse_6_model_GL_POLYGON_STIPPLE_BIT = 0x00000010,
  __pyx_e_9punyverse_6_model_GL_PIXEL_MODE_BIT = 0x00000020,
  __pyx_e_9punyverse_6_model_GL_LIGHTING_BIT = 0x00000040,
  __pyx_e_9punyverse_6_model_GL_FOG_BIT = 0x00000080,
  __pyx_e_9punyverse_6_model_GL_DEPTH_BUFFER_BIT = 0x00000100,
  __pyx_e_9punyverse_6_model_GL_ACCUM_BUFFER_BIT = 0x00000200,
  __pyx_e_9punyverse_6_model_GL_STENCIL_BUFFER_BIT = 0x00000400,
  __pyx_e_9punyverse_6_model_GL_VIEWPORT_BIT = 0x00000800,
  __pyx_e_9punyverse_6_model_GL_TRANSFORM_BIT = 0x00001000,
  __pyx_e_9punyverse_6_model_GL_ENABLE_BIT = 0x00002000,
  __pyx_e_9punyverse_6_model_GL_COLOR_BUFFER_BIT = 0x00004000,
  __pyx_e_9punyverse_6_model_GL_HINT_BIT = 0x00008000,
  __pyx_e_9punyverse_6_model_GL_EVAL_BIT = 0x00010000,
  __pyx_e_9punyverse_6_model_GL_LIST_BIT = 0x00020000,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_BIT = 0x00040000,
  __pyx_e_9punyverse_6_model_GL_SCISSOR_BIT = 0x00080000,
  __pyx_e_9punyverse_6_model_GL_ALL_ATTRIB_BITS = 0x000FFFFF,
  __pyx_e_9punyverse_6_model_GL_PROXY_TEXTURE_1D = 0x8063,
  __pyx_e_9punyverse_6_model_GL_PROXY_TEXTURE_2D = 0x8064,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_PRIORITY = 0x8066,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_RESIDENT = 0x8067,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_BINDING_1D = 0x8068,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_BINDING_2D = 0x8069,
  __pyx_e_9punyverse_6_model_GL_TEXTURE_INTERNAL_FORMAT = 0x1003,
  __pyx_e_9punyverse_6_model_GL_ALPHA4 = 0x803B,
  __pyx_e_9punyverse_6_model_GL_ALPHA8 = 0x803C,
  __pyx_e_9punyverse_6_model_GL_ALPHA12 = 0x803D,
  __pyx_e_9punyverse_6_model_GL_ALPHA16 = 0x803E,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE4 = 0x803F,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE8 = 0x8040,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE12 = 0x8041,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE16 = 0x8042,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE4_ALPHA4 = 0x8043,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE6_ALPHA2 = 0x8044,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE8_ALPHA8 = 0x8045,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE12_ALPHA4 = 0x8046,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE12_ALPHA12 = 0x8047,
  __pyx_e_9punyverse_6_model_GL_LUMINANCE16_ALPHA16 = 0x8048,
  __pyx_e_9punyverse_6_model_GL_INTENSITY = 0x8049,
  __pyx_e_9punyverse_6_model_GL_INTENSITY4 = 0x804A,
  __pyx_e_9punyverse_6_model_GL_INTENSITY8 = 0x804B,
  __pyx_e_9punyverse_6_model_GL_INTENSITY12 = 0x804C,
  __pyx_e_9punyverse_6_model_GL_INTENSITY16 = 0x804D,
  __pyx_e_9punyverse_6_model_GL_R3_G3_B2 = 0x2A10,
  __pyx_e_9punyverse_6_model_GL_RGB4 = 0x804F,
  __pyx_e_9punyverse_6_model_GL_RGB5 = 0x8050,
  __pyx_e_9punyverse_6_model_GL_RGB8 = 0x8051,
  __pyx_e_9punyverse_6_model_GL_RGB10 = 0x8052,
  __pyx_e_9punyverse_6_model_GL_RGB12 = 0x8053,
  __pyx_e_9punyverse_6_model_GL_RGB16 = 0x8054,
  __pyx_e_9punyverse_6_model_GL_RGBA2 = 0x8055,
  __pyx_e_9punyverse_6_model_GL_RGBA4 = 0x8056,
  __pyx_e_9punyverse_6_model_GL_RGB5_A1 = 0x8057,
  __pyx_e_9punyverse_6_model_GL_RGBA8 = 0x8058,
  __pyx_e_9punyverse_6_model_GL_RGB10_A2 = 0x8059,
  __pyx_e_9punyverse_6_model_GL_RGBA12 = 0x805A,
  __pyx_e_9punyverse_6_model_GL_RGBA16 = 0x805B,
  __pyx_e_9punyverse_6_model_GL_CLIENT_PIXEL_STORE_BIT = 0x00000001,
  __pyx_e_9punyverse_6_model_GL_CLIENT_VERTEX_ARRAY_BIT = 0x00000002,
  __pyx_e_9punyverse_6_model_GL_ALL_CLIENT_ATTRIB_BITS = 0xFFFFFFFF,
  __pyx_e_9punyverse_6_model_GL_CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF,
  __pyx_e_9punyverse_6_model_GLU_FALSE = 0,
  __pyx_e_9punyverse_6_model_GLU_TRUE = 1,
  __pyx_e_9punyverse_6_model_GLU_VERSION = 0x189C0,
  __pyx_e_9punyverse_6_model_GLU_EXTENSIONS = 0x189C1,
  __pyx_e_9punyverse_6_model_GLU_INVALID_ENUM = 0x18A24,
  __pyx_e_9punyverse_6_model_GLU_INVALID_VALUE = 0x18A25,
  __pyx_e_9punyverse_6_model_GLU_OUT_OF_MEMORY = 0x18A26,
  __pyx_e_9punyverse_6_model_GLU_INVALID_OPERATION = 0x18A28,
  __pyx_e_9punyverse_6_model_GLU_OUTLINE_POLYGON = 0x18790,
  __pyx_e_9punyverse_6_model_GLU_OUTLINE_PATCH = 0x18791,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR1 = 0x1879B,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR2 = 0x1879C,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR3 = 0x1879D,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR4 = 0x1879E,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR5 = 0x1879F,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR6 = 0x187A0,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR7 = 0x187A1,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR8 = 0x187A2,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR9 = 0x187A3,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR10 = 0x187A4,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR11 = 0x187A5,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR12 = 0x187A6,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR13 = 0x187A7,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR14 = 0x187A8,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR15 = 0x187A9,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR16 = 0x187AA,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR17 = 0x187AB,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR18 = 0x187AC,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR19 = 0x187AD,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR20 = 0x187AE,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR21 = 0x187AF,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR22 = 0x187B0,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR23 = 0x187B1,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR24 = 0x187B2,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR25 = 0x187B3,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR26 = 0x187B4,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR27 = 0x187B5,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR28 = 0x187B6,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR29 = 0x187B7,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR30 = 0x187B8,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR31 = 0x187B9,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR32 = 0x187BA,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR33 = 0x187BB,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR34 = 0x187BC,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR35 = 0x187BD,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR36 = 0x187BE,
  __pyx_e_9punyverse_6_model_GLU_NURBS_ERROR37 = 0x187BF,
  __pyx_e_9punyverse_6_model_GLU_AUTO_LOAD_MATRIX = 0x18768,
  __pyx_e_9punyverse_6_model_GLU_CULLING = 0x18769,
  __pyx_e_9punyverse_6_model_GLU_SAMPLING_TOLERANCE = 0x1876B,
  __pyx_e_9punyverse_6_model_GLU_DISPLAY_MODE = 0x1876C,
  __pyx_e_9punyverse_6_model_GLU_PARAMETRIC_TOLERANCE = 0x1876A,
  __pyx_e_9punyverse_6_model_GLU_SAMPLING_METHOD = 0x1876D,
  __pyx_e_9punyverse_6_model_GLU_U_STEP = 0x1876E,
  __pyx_e_9punyverse_6_model_GLU_V_STEP = 0x1876F,
  __pyx_e_9punyverse_6_model_GLU_PATH_LENGTH = 0x18777,
  __pyx_e_9punyverse_6_model_GLU_PARAMETRIC_ERROR = 0x18778,
  __pyx_e_9punyverse_6_model_GLU_DOMAIN_DISTANCE = 0x18779,
  __pyx_e_9punyverse_6_model_GLU_MAP1_TRIM_2 = 0x18772,
  __pyx_e_9punyverse_6_model_GLU_MAP1_TRIM_3 = 0x18773,
  __pyx_e_9punyverse_6_model_GLU_POINT = 0x186AA,
  __pyx_e_9punyverse_6_model_GLU_LINE = 0x186AB,
  __pyx_e_9punyverse_6_model_GLU_FILL = 0x186AC,
  __pyx_e_9punyverse_6_model_GLU_SILHOUETTE = 0x186AD,
  __pyx_e_9punyverse_6_model_GLU_ERROR = 0x18707,
  __pyx_e_9punyverse_6_model_GLU_SMOOTH = 0x186A0,
  __pyx_e_9punyverse_6_model_GLU_FLAT = 0x186A1,
  __pyx_e_9punyverse_6_model_GLU_NONE = 0x186A2,
  __pyx_e_9punyverse_6_model_GLU_OUTSIDE = 0x186B4,
  __pyx_e_9punyverse_6_model_GLU_INSIDE = 0x186B5,
  __pyx_e_9punyverse_6_model_GLU_TESS_BEGIN = 0x18704,
  __pyx_e_9punyverse_6_model_GLU_BEGIN = 0x18704,
  __pyx_e_9punyverse_6_model_GLU_TESS_VERTEX = 0x18705,
  __pyx_e_9punyverse_6_model_GLU_VERTEX = 0x18705,
  __pyx_e_9punyverse_6_model_GLU_TESS_END = 0x18706,
  __pyx_e_9punyverse_6_model_GLU_END = 0x18706,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR = 0x18707,
  __pyx_e_9punyverse_6_model_GLU_TESS_EDGE_FLAG = 0x18708,
  __pyx_e_9punyverse_6_model_GLU_EDGE_FLAG = 0x18708,
  __pyx_e_9punyverse_6_model_GLU_TESS_COMBINE = 0x18709,
  __pyx_e_9punyverse_6_model_GLU_TESS_BEGIN_DATA = 0x1870A,
  __pyx_e_9punyverse_6_model_GLU_TESS_VERTEX_DATA = 0x1870B,
  __pyx_e_9punyverse_6_model_GLU_TESS_END_DATA = 0x1870C,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR_DATA = 0x1870D,
  __pyx_e_9punyverse_6_model_GLU_TESS_EDGE_FLAG_DATA = 0x1870E,
  __pyx_e_9punyverse_6_model_GLU_TESS_COMBINE_DATA = 0x1870F,
  __pyx_e_9punyverse_6_model_GLU_CW = 0x18718,
  __pyx_e_9punyverse_6_model_GLU_CCW = 0x18719,
  __pyx_e_9punyverse_6_model_GLU_INTERIOR = 0x1871A,
  __pyx_e_9punyverse_6_model_GLU_EXTERIOR = 0x1871B,
  __pyx_e_9punyverse_6_model_GLU_UNKNOWN = 0x1871C,
  __pyx_e_9punyverse_6_model_GLU_TESS_WINDING_RULE = 0x1872C,
  __pyx_e_9punyverse_6_model_GLU_TESS_BOUNDARY_ONLY = 0x1872D,
  __pyx_e_9punyverse_6_model_GLU_TESS_TOLERANCE = 0x1872E,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR1 = 0x18737,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR2 = 0x18738,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR3 = 0x18739,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR4 = 0x1873A,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR5 = 0x1873B,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR6 = 0x1873C,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR7 = 0x1873D,
  __pyx_e_9punyverse_6_model_GLU_TESS_ERROR8 = 0x1873E,
  __pyx_e_9punyverse_6_model_GLU_TESS_MISSING_BEGIN_POLYGON = 0x18737,
  __pyx_e_9punyverse_6_model_GLU_TESS_MISSING_BEGIN_CONTOUR = 0x18738,
  __pyx_e_9punyverse_6_model_GLU_TESS_MISSING_END_POLYGON = 0x18739,
  __pyx_e_9punyverse_6_model_GLU_TESS_MISSING_END_CONTOUR = 0x1873A,
  __pyx_e_9punyverse_6_model_GLU_TESS_COORD_TOO_LARGE = 0x1873B,
  __pyx_e_9punyverse_6_model_GLU_TESS_NEED_COMBINE_CALLBACK = 0x1873C,
  __pyx_e_9punyverse_6_model_GLU_TESS_WINDING_ODD = 0x18722,
  __pyx_e_9punyverse_6_model_GLU_TESS_WINDING_NONZERO = 0x18723,
  __pyx_e_9punyverse_6_model_GLU_TESS_WINDING_POSITIVE = 0x18724,
  __pyx_e_9punyverse_6_model_GLU_TESS_WINDING_NEGATIVE = 0x18725,
  __pyx_e_9punyverse_6_model_GLU_TESS_WINDING_ABS_GEQ_TWO = 0x18726
};

/* "punyverse/_model.pyx":25
 * 
 * 
 * cdef enum:             # <<<<<<<<<<<<<<
 *     FACE_TRIANGLES
 *     FACE_QUADS
 */
enum  {
  __pyx_e_9punyverse_6_model_FACE_TRIANGLES,
  __pyx_e_9punyverse_6_model_FACE_QUADS
};

/* "punyverse/_model.pyx":295
 *     glVertex3f(x * sx, y * sy, z * sz)
 * 
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):             # <<<<<<<<<<<<<<
 *     for m, text in model.materials.iteritems():
 *         if text.texture:
 */
struct __pyx_opt_args_9punyverse_6_model_model_list {
  int __pyx_n;
  float sx;
  float sy;
  float sz;
  PyObject *rotation;
};

/* "punyverse/_model.pyx":29
 *     FACE_QUADS
 * 
 * cdef class Face(object):             # <<<<<<<<<<<<<<
 *     cdef public int type
 *     cdef public list verts, norms, texs, vertices, normals, textures
 */
struct __pyx_obj_9punyverse_6_model_Face {
  PyObject_HEAD
  int type;
  PyObject *verts;
  PyObject *norms;
  PyObject *texs;
  PyObject *vertices;
  PyObject *normals;
  PyObject *textures;
};


/* "punyverse/_model.pyx":43
 *         self.textures = textures
 * 
 * cdef class Material(object):             # <<<<<<<<<<<<<<
 *     cdef public str name, texture
 *     cdef public tuple Ka, Kd, Ks
 */
struct __pyx_obj_9punyverse_6_model_Material {
  PyObject_HEAD
  PyObject *name;
  PyObject *texture;
  PyObject *Ka;
  PyObject *Kd;
  PyObject *Ks;
  double shininess;
};


/* "punyverse/_model.pyx":57
 *         self.shininess = shininess
 * 
 * cdef class Group(object):             # <<<<<<<<<<<<<<
 *     cdef public str name
 *     cdef public tuple min
 */
struct __pyx_obj_9punyverse_6_model_Group {
  PyObject_HEAD
  PyObject *name;
  PyObject *min;
  struct __pyx_obj_9punyverse_6_model_Material *material;
  PyObject *faces;
  PyObject *indices;
  PyObject *vertices;
  PyObject *normals;
  PyObject *textures;
  int idx_count;
};


/* "punyverse/_model.pyx":87
 *         self.min = (min_x, min_y, min_z)
 * 
 * cdef class WavefrontObject(object):             # <<<<<<<<<<<<<<
 *     cdef unicode root
 *     cdef public list vertices, normals, textures, groups
 */
struct __pyx_obj_9punyverse_6_model_WavefrontObject {
  PyObject_HEAD
  struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *__pyx_vtab;
  PyObject *root;
  PyObject *vertices;
  PyObject *normals;
  PyObject *textures;
  PyObject *groups;
  PyObject *materials;
  PyObject *path;
  struct __pyx_obj_9punyverse_6_model_Material *current_material;
  struct __pyx_obj_9punyverse_6_model_Group *current_group;
};



struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject {
  void (*new_material)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*Ka)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*Kd)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*Ks)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*material_shininess)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*material_texture)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*vertex)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*normal)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*texture)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*face)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  int (*material)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*use_material)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  void (*group)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
  int (*perform_io)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);
};
static struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *__pyx_vtabptr_9punyverse_6_model_WavefrontObject;
static CYTHON_INLINE int __pyx_f_9punyverse_6_model_15WavefrontObject_perform_io(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *);

/* --- Runtime support code (head) --- */
/* Refnanny.proto */
#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);
  #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
#define __Pyx_XDECREF_SET(r, v) do {\
        PyObject *tmp = (PyObject *) r;\
        r = v; __Pyx_XDECREF(tmp);\
    } while (0)
#define __Pyx_DECREF_SET(r, v) do {\
        PyObject *tmp = (PyObject *) r;\
        r = v; __Pyx_DECREF(tmp);\
    } while (0)
#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)

/* PyObjectGetAttrStr.proto */
#if CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
#else
#define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
#endif

/* GetBuiltinName.proto */
static PyObject *__Pyx_GetBuiltinName(PyObject *name);

/* GetModuleGlobalName.proto */
static CYTHON_INLINE PyObject *__Pyx_GetModuleGlobalName(PyObject *name);

/* PyCFunctionFastCall.proto */
#if CYTHON_FAST_PYCCALL
static CYTHON_INLINE PyObject *__Pyx_PyCFunction_FastCall(PyObject *func, PyObject **args, Py_ssize_t nargs);
#else
#define __Pyx_PyCFunction_FastCall(func, args, nargs)  (assert(0), NULL)
#endif

/* PyFunctionFastCall.proto */
#if CYTHON_FAST_PYCALL
#define __Pyx_PyFunction_FastCall(func, args, nargs)\
    __Pyx_PyFunction_FastCallDict((func), (args), (nargs), NULL)
#if 1 || PY_VERSION_HEX < 0x030600B1
static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, int nargs, PyObject *kwargs);
#else
#define __Pyx_PyFunction_FastCallDict(func, args, nargs, kwargs) _PyFunction_FastCallDict(func, args, nargs, kwargs)
#endif
#endif

/* PyObjectCall.proto */
#if CYTHON_COMPILING_IN_CPYTHON
static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
#else
#define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
#endif

/* PyObjectCallMethO.proto */
#if CYTHON_COMPILING_IN_CPYTHON
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg);
#endif

/* PyObjectCallOneArg.proto */
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg);

/* PyObjectCallNoArg.proto */
#if CYTHON_COMPILING_IN_CPYTHON
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func);
#else
#define __Pyx_PyObject_CallNoArg(func) __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL)
#endif

/* GetItemInt.proto */
#define __Pyx_GetItemInt(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    __Pyx_GetItemInt_Fast(o, (Py_ssize_t)i, is_list, wraparound, boundscheck) :\
    (is_list ? (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL) :\
               __Pyx_GetItemInt_Generic(o, to_py_func(i))))
#define __Pyx_GetItemInt_List(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    __Pyx_GetItemInt_List_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
    (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL))
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
                                                              int wraparound, int boundscheck);
#define __Pyx_GetItemInt_Tuple(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
    (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
    __Pyx_GetItemInt_Tuple_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
    (PyErr_SetString(PyExc_IndexError, "tuple index out of range"), (PyObject*)NULL))
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
                                                              int wraparound, int boundscheck);
static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j);
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i,
                                                     int is_list, int wraparound, int boundscheck);

/* RaiseArgTupleInvalid.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);

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

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

/* ArgTypeTest.proto */
#define __Pyx_ArgTypeTest(obj, type, none_allowed, name, exact)\
    ((likely((Py_TYPE(obj) == type) | (none_allowed && (obj == Py_None)))) ? 1 :\
        __Pyx__ArgTypeTest(obj, type, name, exact))
static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type, const char *name, int exact);

/* PyErrExceptionMatches.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err)
static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err);
#else
#define __Pyx_PyErr_ExceptionMatches(err)  PyErr_ExceptionMatches(err)
#endif

/* PyThreadStateGet.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_PyThreadState_declare  PyThreadState *__pyx_tstate;
#define __Pyx_PyThreadState_assign  __pyx_tstate = __Pyx_PyThreadState_Current;
#define __Pyx_PyErr_Occurred()  __pyx_tstate->curexc_type
#else
#define __Pyx_PyThreadState_declare
#define __Pyx_PyThreadState_assign
#define __Pyx_PyErr_Occurred()  PyErr_Occurred()
#endif

/* PyErrFetchRestore.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
#define __Pyx_ErrRestoreWithState(type, value, tb)  __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
#define __Pyx_ErrFetchWithState(type, value, tb)    __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
#define __Pyx_ErrRestore(type, value, tb)  __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
#define __Pyx_ErrFetch(type, value, tb)    __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
#if CYTHON_COMPILING_IN_CPYTHON
#define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
#else
#define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
#endif
#else
#define __Pyx_PyErr_Clear() PyErr_Clear()
#define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
#define __Pyx_ErrRestoreWithState(type, value, tb)  PyErr_Restore(type, value, tb)
#define __Pyx_ErrFetchWithState(type, value, tb)  PyErr_Fetch(type, value, tb)
#define __Pyx_ErrRestoreInState(tstate, type, value, tb)  PyErr_Restore(type, value, tb)
#define __Pyx_ErrFetchInState(tstate, type, value, tb)  PyErr_Fetch(type, value, tb)
#define __Pyx_ErrRestore(type, value, tb)  PyErr_Restore(type, value, tb)
#define __Pyx_ErrFetch(type, value, tb)  PyErr_Fetch(type, value, tb)
#endif

/* GetAttr.proto */
static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *, PyObject *);

/* GetAttr3.proto */
static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *, PyObject *, PyObject *);

/* RaiseTooManyValuesToUnpack.proto */
static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected);

/* RaiseNeedMoreValuesToUnpack.proto */
static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index);

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

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

/* py_abs.proto */
#if CYTHON_USE_PYLONG_INTERNALS
static PyObject *__Pyx_PyLong_AbsNeg(PyObject *num);
#define __Pyx_PyNumber_Absolute(x)\
    ((likely(PyLong_CheckExact(x))) ?\
         (likely(Py_SIZE(x) >= 0) ? (Py_INCREF(x), (x)) : __Pyx_PyLong_AbsNeg(x)) :\
         PyNumber_Absolute(x))
#else
#define __Pyx_PyNumber_Absolute(x)  PyNumber_Absolute(x)
#endif

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

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

/* pyobject_as_double.proto */
static double __Pyx__PyObject_AsDouble(PyObject* obj);
#if CYTHON_COMPILING_IN_PYPY
#define __Pyx_PyObject_AsDouble(obj)\
(likely(PyFloat_CheckExact(obj)) ? PyFloat_AS_DOUBLE(obj) :\
 likely(PyInt_CheckExact(obj)) ?\
 PyFloat_AsDouble(obj) : __Pyx__PyObject_AsDouble(obj))
#else
#define __Pyx_PyObject_AsDouble(obj)\
((likely(PyFloat_CheckExact(obj))) ?\
 PyFloat_AS_DOUBLE(obj) : __Pyx__PyObject_AsDouble(obj))
#endif

/* ListAppend.proto */
#if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS
static CYTHON_INLINE int __Pyx_PyList_Append(PyObject* list, PyObject* x) {
    PyListObject* L = (PyListObject*) list;
    Py_ssize_t len = Py_SIZE(list);
    if (likely(L->allocated > len) & likely(len > (L->allocated >> 1))) {
        Py_INCREF(x);
        PyList_SET_ITEM(list, len, x);
        Py_SIZE(list) = len+1;
        return 0;
    }
    return PyList_Append(list, x);
}
#else
#define __Pyx_PyList_Append(L,x) PyList_Append(L,x)
#endif

/* PyIntBinop.proto */
#if !CYTHON_COMPILING_IN_PYPY
static PyObject* __Pyx_PyInt_AddObjC(PyObject *op1, PyObject *op2, long intval, int inplace);
#else
#define __Pyx_PyInt_AddObjC(op1, op2, intval, inplace)\
    (inplace ? PyNumber_InPlaceAdd(op1, op2) : PyNumber_Add(op1, op2))
#endif

/* DictGetItem.proto */
#if PY_MAJOR_VERSION >= 3 && !CYTHON_COMPILING_IN_PYPY
static PyObject *__Pyx_PyDict_GetItem(PyObject *d, PyObject* key);
#define __Pyx_PyObject_Dict_GetItem(obj, name)\
    (likely(PyDict_CheckExact(obj)) ?\
     __Pyx_PyDict_GetItem(obj, name) : PyObject_GetItem(obj, name))
#else
#define __Pyx_PyDict_GetItem(d, key) PyObject_GetItem(d, key)
#define __Pyx_PyObject_Dict_GetItem(obj, name)  PyObject_GetItem(obj, name)
#endif

/* SaveResetException.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_ExceptionSave(type, value, tb)  __Pyx__ExceptionSave(__pyx_tstate, type, value, tb)
static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
#define __Pyx_ExceptionReset(type, value, tb)  __Pyx__ExceptionReset(__pyx_tstate, type, value, tb)
static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
#else
#define __Pyx_ExceptionSave(type, value, tb)   PyErr_GetExcInfo(type, value, tb)
#define __Pyx_ExceptionReset(type, value, tb)  PyErr_SetExcInfo(type, value, tb)
#endif

/* GetException.proto */
#if CYTHON_FAST_THREAD_STATE
#define __Pyx_GetException(type, value, tb)  __Pyx__GetException(__pyx_tstate, type, value, tb)
static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
#else
static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
#endif

/* PyObjectLookupSpecial.proto */
#if CYTHON_USE_PYTYPE_LOOKUP && CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PyObject* __Pyx_PyObject_LookupSpecial(PyObject* obj, PyObject* attr_name) {
    PyObject *res;
    PyTypeObject *tp = Py_TYPE(obj);
#if PY_MAJOR_VERSION < 3
    if (unlikely(PyInstance_Check(obj)))
        return __Pyx_PyObject_GetAttrStr(obj, attr_name);
#endif
    res = _PyType_Lookup(tp, attr_name);
    if (likely(res)) {
        descrgetfunc f = Py_TYPE(res)->tp_descr_get;
        if (!f) {
            Py_INCREF(res);
        } else {
            res = f(res, obj, (PyObject *)tp);
        }
    } else {
        PyErr_SetObject(PyExc_AttributeError, attr_name);
    }
    return res;
}
#else
#define __Pyx_PyObject_LookupSpecial(o,n) __Pyx_PyObject_GetAttrStr(o,n)
#endif

/* Import.proto */
static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level);

/* HasAttr.proto */
static CYTHON_INLINE int __Pyx_HasAttr(PyObject *, PyObject *);

/* ObjectGetItem.proto */
#if CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key);
#else
#define __Pyx_PyObject_GetItem(obj, key)  PyObject_GetItem(obj, key)
#endif

/* PyObjectCallMethod0.proto */
static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name);

/* RaiseNoneIterError.proto */
static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void);

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

/* UnpackTuple2.proto */
#define __Pyx_unpack_tuple2(tuple, value1, value2, is_tuple, has_known_size, decref_tuple)\
    (likely(is_tuple || PyTuple_Check(tuple)) ?\
        (likely(has_known_size || PyTuple_GET_SIZE(tuple) == 2) ?\
            __Pyx_unpack_tuple2_exact(tuple, value1, value2, decref_tuple) :\
            (__Pyx_UnpackTupleError(tuple, 2), -1)) :\
        __Pyx_unpack_tuple2_generic(tuple, value1, value2, has_known_size, decref_tuple))
static CYTHON_INLINE int __Pyx_unpack_tuple2_exact(
    PyObject* tuple, PyObject** value1, PyObject** value2, int decref_tuple);
static int __Pyx_unpack_tuple2_generic(
    PyObject* tuple, PyObject** value1, PyObject** value2, int has_known_size, int decref_tuple);

/* dict_iter.proto */
static CYTHON_INLINE PyObject* __Pyx_dict_iterator(PyObject* dict, int is_dict, PyObject* method_name,
                                                   Py_ssize_t* p_orig_length, int* p_is_dict);
static CYTHON_INLINE int __Pyx_dict_iter_next(PyObject* dict_or_iter, Py_ssize_t orig_length, Py_ssize_t* ppos,
                                              PyObject** pkey, PyObject** pvalue, PyObject** pitem, int is_dict);

/* ImportFrom.proto */
static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name);

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

/* PyObject_GenericGetAttrNoDict.proto */
#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name);
#else
#define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr
#endif

/* PyObject_GenericGetAttr.proto */
#if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name);
#else
#define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr
#endif

/* SetupReduce.proto */
static int __Pyx_setup_reduce(PyObject* type_obj);

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

/* CLineInTraceback.proto */
#ifdef CYTHON_CLINE_IN_TRACEBACK
#define __Pyx_CLineForTraceback(tstate, c_line)  (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
#else
static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line);
#endif

/* CodeObjectCache.proto */
typedef struct {
    PyCodeObject* code_object;
    int code_line;
} __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);

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

/* CIntToPy.proto */
static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value);

/* CIntToPy.proto */
static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value);

/* Print.proto */
static int __Pyx_Print(PyObject*, PyObject *, int);
#if CYTHON_COMPILING_IN_PYPY || PY_MAJOR_VERSION >= 3
static PyObject* __pyx_print = 0;
static PyObject* __pyx_print_kwargs = 0;
#endif

/* CIntFromPy.proto */
static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *);

/* CIntFromPy.proto */
static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *);

/* PrintOne.proto */
static int __Pyx_PrintOne(PyObject* stream, PyObject *o);

/* FastTypeChecks.proto */
#if CYTHON_COMPILING_IN_CPYTHON
#define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
#else
#define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
#define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
#define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
#endif
#define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)

/* CheckBinaryVersion.proto */
static int __Pyx_check_binary_version(void);

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

static void __pyx_f_9punyverse_6_model_15WavefrontObject_new_material(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_Ka(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_Kd(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_Ks(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_material_shininess(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_material_texture(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_vertex(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_normal(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_texture(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_face(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static int __pyx_f_9punyverse_6_model_15WavefrontObject_material(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_use_material(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static void __pyx_f_9punyverse_6_model_15WavefrontObject_group(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words); /* proto*/
static CYTHON_INLINE int __pyx_f_9punyverse_6_model_15WavefrontObject_perform_io(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_file); /* proto*/

/* Module declarations from 'libc.string' */

/* Module declarations from 'libc.stdlib' */

/* Module declarations from 'libc.stdio' */

/* Module declarations from 'cython' */

/* Module declarations from 'punyverse._model' */
static PyTypeObject *__pyx_ptype_9punyverse_6_model_Face = 0;
static PyTypeObject *__pyx_ptype_9punyverse_6_model_Material = 0;
static PyTypeObject *__pyx_ptype_9punyverse_6_model_Group = 0;
static PyTypeObject *__pyx_ptype_9punyverse_6_model_WavefrontObject = 0;
static float __pyx_v_9punyverse_6_model_GLU_TESS_MAX_COORD;
static CYTHON_INLINE void __pyx_f_9punyverse_6_model_point(struct __pyx_obj_9punyverse_6_model_Face *, struct __pyx_obj_9punyverse_6_model_WavefrontObject *, int, float, float, float, int); /*proto*/
static int __pyx_f_9punyverse_6_model_model_list(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, int __pyx_skip_dispatch, struct __pyx_opt_args_9punyverse_6_model_model_list *__pyx_optional_args); /*proto*/
static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_Face__set_state(struct __pyx_obj_9punyverse_6_model_Face *, PyObject *); /*proto*/
static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_Material__set_state(struct __pyx_obj_9punyverse_6_model_Material *, PyObject *); /*proto*/
static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_Group__set_state(struct __pyx_obj_9punyverse_6_model_Group *, PyObject *); /*proto*/
static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_WavefrontObject__set_state(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *); /*proto*/
#define __Pyx_MODULE_NAME "punyverse._model"
extern int __pyx_module_is_main_punyverse___model;
int __pyx_module_is_main_punyverse___model = 0;

/* Implementation of 'punyverse._model' */
static PyObject *__pyx_builtin_xrange;
static PyObject *__pyx_builtin_KeyError;
static PyObject *__pyx_builtin_AttributeError;
static PyObject *__pyx_builtin_open;
static const char __pyx_k_Ka[] = "Ka";
static const char __pyx_k_Kd[] = "Kd";
static const char __pyx_k_Ks[] = "Ks";
static const char __pyx_k__4[] = "/";
static const char __pyx_k__6[] = ".";
static const char __pyx_k__8[] = "\r";
static const char __pyx_k__9[] = "\n";
static const char __pyx_k_gz[] = "gz";
static const char __pyx_k_os[] = "os";
static const char __pyx_k_sx[] = "sx";
static const char __pyx_k_sy[] = "sy";
static const char __pyx_k_sz[] = "sz";
static const char __pyx_k__10[] = "#";
static const char __pyx_k_bz2[] = "bz2";
static const char __pyx_k_end[] = "end";
static const char __pyx_k_get[] = "get";
static const char __pyx_k_new[] = "__new__";
static const char __pyx_k_sys[] = "sys";
static const char __pyx_k_zip[] = "zip";
static const char __pyx_k_dict[] = "__dict__";
static const char __pyx_k_exit[] = "__exit__";
static const char __pyx_k_file[] = "__file__";
static const char __pyx_k_gzip[] = "gzip";
static const char __pyx_k_join[] = "join";
static const char __pyx_k_main[] = "__main__";
static const char __pyx_k_mbcs[] = "mbcs";
static const char __pyx_k_name[] = "name";
static const char __pyx_k_open[] = "open";
static const char __pyx_k_pack[] = "pack";
static const char __pyx_k_path[] = "path";
static const char __pyx_k_test[] = "__test__";
static const char __pyx_k_texs[] = "texs";
static const char __pyx_k_type[] = "type";
static const char __pyx_k_uuid[] = "uuid";
static const char __pyx_k_enter[] = "__enter__";
static const char __pyx_k_isabs[] = "isabs";
static const char __pyx_k_model[] = "model";
static const char __pyx_k_norms[] = "norms";
static const char __pyx_k_print[] = "print";
static const char __pyx_k_range[] = "range";
static const char __pyx_k_split[] = "split";
static const char __pyx_k_uuid4[] = "uuid4";
static const char __pyx_k_verts[] = "verts";
static const char __pyx_k_assets[] = "assets";
static const char __pyx_k_decode[] = "decode";
static const char __pyx_k_file_2[] = "file";
static const char __pyx_k_frozen[] = "frozen";
static const char __pyx_k_import[] = "__import__";
static const char __pyx_k_lstrip[] = "lstrip";
static const char __pyx_k_models[] = "models";
static const char __pyx_k_name_2[] = "__name__";
static const char __pyx_k_pickle[] = "pickle";
static const char __pyx_k_reduce[] = "__reduce__";
static const char __pyx_k_update[] = "update";
static const char __pyx_k_xrange[] = "xrange";
static const char __pyx_k_BZ2File[] = "BZ2File";
static const char __pyx_k_ZipFile[] = "ZipFile";
static const char __pyx_k_abspath[] = "abspath";
static const char __pyx_k_dirname[] = "dirname";
static const char __pyx_k_normals[] = "normals";
static const char __pyx_k_openers[] = "openers";
static const char __pyx_k_texture[] = "texture";
static const char __pyx_k_zipfile[] = "zipfile";
static const char __pyx_k_KeyError[] = "KeyError";
static const char __pyx_k_getstate[] = "__getstate__";
static const char __pyx_k_namelist[] = "namelist";
static const char __pyx_k_pyx_type[] = "__pyx_type";
static const char __pyx_k_rotation[] = "rotation";
static const char __pyx_k_setstate[] = "__setstate__";
static const char __pyx_k_splitext[] = "splitext";
static const char __pyx_k_textures[] = "textures";
static const char __pyx_k_vertices[] = "vertices";
static const char __pyx_k_zip_open[] = "zip_open";
static const char __pyx_k_iteritems[] = "iteritems";
static const char __pyx_k_pyx_state[] = "__pyx_state";
static const char __pyx_k_reduce_ex[] = "__reduce_ex__";
static const char __pyx_k_shininess[] = "shininess";
static const char __pyx_k_executable[] = "executable";
static const char __pyx_k_load_model[] = "load_model";
static const char __pyx_k_model_base[] = "model_base";
static const char __pyx_k_pyx_result[] = "__pyx_result";
static const char __pyx_k_pyx_vtable[] = "__pyx_vtable__";
static const char __pyx_k_startswith[] = "startswith";
static const char __pyx_k_PickleError[] = "PickleError";
static const char __pyx_k_load_texture[] = "load_texture";
static const char __pyx_k_pyx_checksum[] = "__pyx_checksum";
static const char __pyx_k_stringsource[] = "stringsource";
static const char __pyx_k_reduce_cython[] = "__reduce_cython__";
static const char __pyx_k_AttributeError[] = "AttributeError";
static const char __pyx_k_pyx_PickleError[] = "__pyx_PickleError";
static const char __pyx_k_setstate_cython[] = "__setstate_cython__";
static const char __pyx_k_Warning_no_group[] = "Warning: no group";
static const char __pyx_k_punyverse__model[] = "punyverse._model";
static const char __pyx_k_punyverse_texture[] = "punyverse.texture";
static const char __pyx_k_pyx_unpickle_Face[] = "__pyx_unpickle_Face";
static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback";
static const char __pyx_k_pyx_unpickle_Group[] = "__pyx_unpickle_Group";
static const char __pyx_k_punyverse__model_pyx[] = "punyverse\\_model.pyx";
static const char __pyx_k_pyx_unpickle_Material[] = "__pyx_unpickle_Material";
static const char __pyx_k_pyx_unpickle_WavefrontObject[] = "__pyx_unpickle_WavefrontObject";
static const char __pyx_k_Incompatible_checksums_s_vs_0x1b[] = "Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))";
static const char __pyx_k_Incompatible_checksums_s_vs_0x87[] = "Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))";
static const char __pyx_k_Incompatible_checksums_s_vs_0xa5[] = "Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))";
static const char __pyx_k_Incompatible_checksums_s_vs_0xe7[] = "Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))";
static const char __pyx_k_Warning_material_s_undefined_onl[] = "Warning: material %s undefined, only %s defined.";
static PyObject *__pyx_n_s_AttributeError;
static PyObject *__pyx_n_s_BZ2File;
static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x1b;
static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x87;
static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xa5;
static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0xe7;
static PyObject *__pyx_n_s_Ka;
static PyObject *__pyx_n_s_Kd;
static PyObject *__pyx_n_s_KeyError;
static PyObject *__pyx_n_s_Ks;
static PyObject *__pyx_n_s_PickleError;
static PyObject *__pyx_kp_s_Warning_material_s_undefined_onl;
static PyObject *__pyx_kp_s_Warning_no_group;
static PyObject *__pyx_n_s_ZipFile;
static PyObject *__pyx_kp_s__10;
static PyObject *__pyx_kp_s__4;
static PyObject *__pyx_kp_s__6;
static PyObject *__pyx_kp_s__8;
static PyObject *__pyx_kp_s__9;
static PyObject *__pyx_n_s_abspath;
static PyObject *__pyx_n_s_assets;
static PyObject *__pyx_n_s_bz2;
static PyObject *__pyx_n_s_cline_in_traceback;
static PyObject *__pyx_n_s_decode;
static PyObject *__pyx_n_s_dict;
static PyObject *__pyx_n_s_dirname;
static PyObject *__pyx_n_s_end;
static PyObject *__pyx_n_s_enter;
static PyObject *__pyx_n_s_executable;
static PyObject *__pyx_n_s_exit;
static PyObject *__pyx_n_s_file;
static PyObject *__pyx_n_s_file_2;
static PyObject *__pyx_n_s_frozen;
static PyObject *__pyx_n_s_get;
static PyObject *__pyx_n_s_getstate;
static PyObject *__pyx_n_s_gz;
static PyObject *__pyx_n_s_gzip;
static PyObject *__pyx_n_s_import;
static PyObject *__pyx_n_s_isabs;
static PyObject *__pyx_n_s_iteritems;
static PyObject *__pyx_n_s_join;
static PyObject *__pyx_n_s_load_model;
static PyObject *__pyx_n_s_load_texture;
static PyObject *__pyx_n_s_lstrip;
static PyObject *__pyx_n_s_main;
static PyObject *__pyx_n_s_mbcs;
static PyObject *__pyx_n_s_model;
static PyObject *__pyx_n_s_model_base;
static PyObject *__pyx_n_s_models;
static PyObject *__pyx_n_s_name;
static PyObject *__pyx_n_s_name_2;
static PyObject *__pyx_n_s_namelist;
static PyObject *__pyx_n_s_new;
static PyObject *__pyx_n_s_normals;
static PyObject *__pyx_n_s_norms;
static PyObject *__pyx_n_s_open;
static PyObject *__pyx_n_s_openers;
static PyObject *__pyx_n_s_os;
static PyObject *__pyx_n_s_pack;
static PyObject *__pyx_n_s_path;
static PyObject *__pyx_n_s_pickle;
static PyObject *__pyx_n_s_print;
static PyObject *__pyx_n_s_punyverse__model;
static PyObject *__pyx_kp_s_punyverse__model_pyx;
static PyObject *__pyx_n_s_punyverse_texture;
static PyObject *__pyx_n_s_pyx_PickleError;
static PyObject *__pyx_n_s_pyx_checksum;
static PyObject *__pyx_n_s_pyx_result;
static PyObject *__pyx_n_s_pyx_state;
static PyObject *__pyx_n_s_pyx_type;
static PyObject *__pyx_n_s_pyx_unpickle_Face;
static PyObject *__pyx_n_s_pyx_unpickle_Group;
static PyObject *__pyx_n_s_pyx_unpickle_Material;
static PyObject *__pyx_n_s_pyx_unpickle_WavefrontObject;
static PyObject *__pyx_n_s_pyx_vtable;
static PyObject *__pyx_n_s_range;
static PyObject *__pyx_n_s_reduce;
static PyObject *__pyx_n_s_reduce_cython;
static PyObject *__pyx_n_s_reduce_ex;
static PyObject *__pyx_n_s_rotation;
static PyObject *__pyx_n_s_setstate;
static PyObject *__pyx_n_s_setstate_cython;
static PyObject *__pyx_n_s_shininess;
static PyObject *__pyx_n_s_split;
static PyObject *__pyx_n_s_splitext;
static PyObject *__pyx_n_s_startswith;
static PyObject *__pyx_kp_s_stringsource;
static PyObject *__pyx_n_s_sx;
static PyObject *__pyx_n_s_sy;
static PyObject *__pyx_n_s_sys;
static PyObject *__pyx_n_s_sz;
static PyObject *__pyx_n_s_test;
static PyObject *__pyx_n_s_texs;
static PyObject *__pyx_n_s_texture;
static PyObject *__pyx_n_s_textures;
static PyObject *__pyx_n_s_type;
static PyObject *__pyx_n_s_update;
static PyObject *__pyx_n_s_uuid;
static PyObject *__pyx_n_s_uuid4;
static PyObject *__pyx_n_s_vertices;
static PyObject *__pyx_n_s_verts;
static PyObject *__pyx_n_s_xrange;
static PyObject *__pyx_n_s_zip;
static PyObject *__pyx_n_s_zip_open;
static PyObject *__pyx_n_s_zipfile;
static PyObject *__pyx_pf_9punyverse_6_model_zip_open(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_file); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face___init__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, int __pyx_v_type, PyObject *__pyx_v_verts, PyObject *__pyx_v_norms, PyObject *__pyx_v_texs, PyObject *__pyx_v_vertices, PyObject *__pyx_v_normals, PyObject *__pyx_v_textures); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_4type___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_4type_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_5verts___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_5verts_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_5verts_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_5norms___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_5norms_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_5norms_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_4texs___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_4texs_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_4texs_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_8vertices___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_8vertices_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_8vertices_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_7normals___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_7normals_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_7normals_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_8textures___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_8textures_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_4Face_8textures_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_2__reduce_cython__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4Face_4__setstate_cython__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material___init__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_name, PyObject *__pyx_v_texture, PyObject *__pyx_v_Ka, PyObject *__pyx_v_Kd, PyObject *__pyx_v_Ks, double __pyx_v_shininess); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_4name___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_4name_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_4name_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_7texture___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_7texture_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_7texture_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_2Ka___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_2Ka_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_2Ka_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_2Kd___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_2Kd_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_2Kd_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_2Ks___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_2Ks_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_2Ks_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_9shininess___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_8Material_9shininess_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_2__reduce_cython__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8Material_4__setstate_cython__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group___init__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_name); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_2pack(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_4name___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_4name_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_4name_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_3min___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_3min_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_3min_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_8material___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_8material_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_8material_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_5faces___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_5faces_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_5faces_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_7indices___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_7indices_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_7indices_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_8vertices___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_8vertices_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_8vertices_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_7normals___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_7normals_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_7normals_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_8textures___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_8textures_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_8textures_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_9idx_count___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_5Group_9idx_count_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_4__reduce_cython__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_5Group_6__setstate_cython__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject___init__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_path); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_7normals___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_8textures___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_6groups___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_9materials___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value); /* proto */
static int __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_2__reduce_cython__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_4__setstate_cython__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_2load_model(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_4model_list(CYTHON_UNUSED PyObject *__pyx_self, struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_model, float __pyx_v_sx, float __pyx_v_sy, float __pyx_v_sz, PyObject *__pyx_v_rotation); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_6__pyx_unpickle_Face(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_8__pyx_unpickle_Material(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_10__pyx_unpickle_Group(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */
static PyObject *__pyx_pf_9punyverse_6_model_12__pyx_unpickle_WavefrontObject(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */
static PyObject *__pyx_tp_new_9punyverse_6_model_Face(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
static PyObject *__pyx_tp_new_9punyverse_6_model_Material(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
static PyObject *__pyx_tp_new_9punyverse_6_model_Group(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
static PyObject *__pyx_tp_new_9punyverse_6_model_WavefrontObject(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
static PyObject *__pyx_int_0;
static PyObject *__pyx_int_1;
static PyObject *__pyx_int_2;
static PyObject *__pyx_int_3;
static PyObject *__pyx_int_28589906;
static PyObject *__pyx_int_142230300;
static PyObject *__pyx_int_173792776;
static PyObject *__pyx_int_242544120;
static PyObject *__pyx_tuple_;
static PyObject *__pyx_tuple__2;
static PyObject *__pyx_tuple__3;
static PyObject *__pyx_tuple__5;
static PyObject *__pyx_tuple__7;
static PyObject *__pyx_tuple__11;
static PyObject *__pyx_tuple__12;
static PyObject *__pyx_tuple__13;
static PyObject *__pyx_tuple__14;
static PyObject *__pyx_tuple__15;
static PyObject *__pyx_tuple__16;
static PyObject *__pyx_tuple__17;
static PyObject *__pyx_tuple__19;
static PyObject *__pyx_tuple__21;
static PyObject *__pyx_tuple__23;
static PyObject *__pyx_tuple__25;
static PyObject *__pyx_tuple__27;
static PyObject *__pyx_codeobj__18;
static PyObject *__pyx_codeobj__20;
static PyObject *__pyx_codeobj__22;
static PyObject *__pyx_codeobj__24;
static PyObject *__pyx_codeobj__26;
static PyObject *__pyx_codeobj__28;
/* Late includes */

/* "punyverse/_model.pyx":14
 * import zipfile
 * 
 * def zip_open(file):             # <<<<<<<<<<<<<<
 *     zip = zipfile.ZipFile(file)
 *     return zip.open(zip.namelist()[0])
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_1zip_open(PyObject *__pyx_self, PyObject *__pyx_v_file); /*proto*/
static PyMethodDef __pyx_mdef_9punyverse_6_model_1zip_open = {"zip_open", (PyCFunction)__pyx_pw_9punyverse_6_model_1zip_open, METH_O, 0};
static PyObject *__pyx_pw_9punyverse_6_model_1zip_open(PyObject *__pyx_self, PyObject *__pyx_v_file) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("zip_open (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_zip_open(__pyx_self, ((PyObject *)__pyx_v_file));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_zip_open(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_file) {
  PyObject *__pyx_v_zip = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  __Pyx_RefNannySetupContext("zip_open", 0);

  /* "punyverse/_model.pyx":15
 * 
 * def zip_open(file):
 *     zip = zipfile.ZipFile(file)             # <<<<<<<<<<<<<<
 *     return zip.open(zip.namelist()[0])
 * 
 */
  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_zipfile); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 15, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ZipFile); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 15, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = NULL;
  if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
    __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3);
    if (likely(__pyx_t_2)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
      __Pyx_INCREF(__pyx_t_2);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_3, function);
    }
  }
  if (!__pyx_t_2) {
    __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_file); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_3)) {
      PyObject *__pyx_temp[2] = {__pyx_t_2, __pyx_v_file};
      __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
      PyObject *__pyx_temp[2] = {__pyx_t_2, __pyx_v_file};
      __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else
    #endif
    {
      __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 15, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_2); __pyx_t_2 = NULL;
      __Pyx_INCREF(__pyx_v_file);
      __Pyx_GIVEREF(__pyx_v_file);
      PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_file);
      __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __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_v_zip = __pyx_t_1;
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":16
 * def zip_open(file):
 *     zip = zipfile.ZipFile(file)
 *     return zip.open(zip.namelist()[0])             # <<<<<<<<<<<<<<
 * 
 * openers = {
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_zip, __pyx_n_s_open); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 16, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_zip, __pyx_n_s_namelist); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 16, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_5 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_5)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_5);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (__pyx_t_5) {
    __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 16, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  } else {
    __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 16, __pyx_L1_error)
  }
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_GetItemInt(__pyx_t_4, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 16, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_4 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) {
    __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
    if (likely(__pyx_t_4)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
      __Pyx_INCREF(__pyx_t_4);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_3, function);
    }
  }
  if (!__pyx_t_4) {
    __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_GOTREF(__pyx_t_1);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_3)) {
      PyObject *__pyx_temp[2] = {__pyx_t_4, __pyx_t_2};
      __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
      PyObject *__pyx_temp[2] = {__pyx_t_4, __pyx_t_2};
      __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    } else
    #endif
    {
      __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 16, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __pyx_t_4 = NULL;
      __Pyx_GIVEREF(__pyx_t_2);
      PyTuple_SET_ITEM(__pyx_t_5, 0+1, __pyx_t_2);
      __pyx_t_2 = 0;
      __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 16, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  /* "punyverse/_model.pyx":14
 * import zipfile
 * 
 * def zip_open(file):             # <<<<<<<<<<<<<<
 *     zip = zipfile.ZipFile(file)
 *     return zip.open(zip.namelist()[0])
 */

  /* function exit code */
  __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_5);
  __Pyx_AddTraceback("punyverse._model.zip_open", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_zip);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":33
 *     cdef public list verts, norms, texs, vertices, normals, textures
 * 
 *     def __init__(self, int type, list verts, list norms, list texs,             # <<<<<<<<<<<<<<
 *                  list vertices, list normals, list textures):
 *         self.type = type
 */

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  int __pyx_v_type;
  PyObject *__pyx_v_verts = 0;
  PyObject *__pyx_v_norms = 0;
  PyObject *__pyx_v_texs = 0;
  PyObject *__pyx_v_vertices = 0;
  PyObject *__pyx_v_normals = 0;
  PyObject *__pyx_v_textures = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_type,&__pyx_n_s_verts,&__pyx_n_s_norms,&__pyx_n_s_texs,&__pyx_n_s_vertices,&__pyx_n_s_normals,&__pyx_n_s_textures,0};
    PyObject* values[7] = {0,0,0,0,0,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  7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
        CYTHON_FALLTHROUGH;
        case  6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
        CYTHON_FALLTHROUGH;
        case  5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
        CYTHON_FALLTHROUGH;
        case  4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
        CYTHON_FALLTHROUGH;
        case  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_type)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_verts)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, 1); __PYX_ERR(0, 33, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_norms)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, 2); __PYX_ERR(0, 33, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  3:
        if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_texs)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, 3); __PYX_ERR(0, 33, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  4:
        if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_vertices)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, 4); __PYX_ERR(0, 33, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  5:
        if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_normals)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, 5); __PYX_ERR(0, 33, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  6:
        if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_textures)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, 6); __PYX_ERR(0, 33, __pyx_L3_error)
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 33, __pyx_L3_error)
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
      values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
      values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
      values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
      values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
      values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
      values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
    }
    __pyx_v_type = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_type == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 33, __pyx_L3_error)
    __pyx_v_verts = ((PyObject*)values[1]);
    __pyx_v_norms = ((PyObject*)values[2]);
    __pyx_v_texs = ((PyObject*)values[3]);
    __pyx_v_vertices = ((PyObject*)values[4]);
    __pyx_v_normals = ((PyObject*)values[5]);
    __pyx_v_textures = ((PyObject*)values[6]);
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__init__", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 33, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.Face.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return -1;
  __pyx_L4_argument_unpacking_done:;
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_verts), (&PyList_Type), 1, "verts", 1))) __PYX_ERR(0, 33, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_norms), (&PyList_Type), 1, "norms", 1))) __PYX_ERR(0, 33, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_texs), (&PyList_Type), 1, "texs", 1))) __PYX_ERR(0, 33, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vertices), (&PyList_Type), 1, "vertices", 1))) __PYX_ERR(0, 34, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_normals), (&PyList_Type), 1, "normals", 1))) __PYX_ERR(0, 34, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_textures), (&PyList_Type), 1, "textures", 1))) __PYX_ERR(0, 34, __pyx_L1_error)
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face___init__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), __pyx_v_type, __pyx_v_verts, __pyx_v_norms, __pyx_v_texs, __pyx_v_vertices, __pyx_v_normals, __pyx_v_textures);

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face___init__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, int __pyx_v_type, PyObject *__pyx_v_verts, PyObject *__pyx_v_norms, PyObject *__pyx_v_texs, PyObject *__pyx_v_vertices, PyObject *__pyx_v_normals, PyObject *__pyx_v_textures) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "punyverse/_model.pyx":35
 *     def __init__(self, int type, list verts, list norms, list texs,
 *                  list vertices, list normals, list textures):
 *         self.type = type             # <<<<<<<<<<<<<<
 *         self.verts = verts
 *         self.norms = norms
 */
  __pyx_v_self->type = __pyx_v_type;

  /* "punyverse/_model.pyx":36
 *                  list vertices, list normals, list textures):
 *         self.type = type
 *         self.verts = verts             # <<<<<<<<<<<<<<
 *         self.norms = norms
 *         self.texs = texs
 */
  __Pyx_INCREF(__pyx_v_verts);
  __Pyx_GIVEREF(__pyx_v_verts);
  __Pyx_GOTREF(__pyx_v_self->verts);
  __Pyx_DECREF(__pyx_v_self->verts);
  __pyx_v_self->verts = __pyx_v_verts;

  /* "punyverse/_model.pyx":37
 *         self.type = type
 *         self.verts = verts
 *         self.norms = norms             # <<<<<<<<<<<<<<
 *         self.texs = texs
 *         self.vertices = vertices
 */
  __Pyx_INCREF(__pyx_v_norms);
  __Pyx_GIVEREF(__pyx_v_norms);
  __Pyx_GOTREF(__pyx_v_self->norms);
  __Pyx_DECREF(__pyx_v_self->norms);
  __pyx_v_self->norms = __pyx_v_norms;

  /* "punyverse/_model.pyx":38
 *         self.verts = verts
 *         self.norms = norms
 *         self.texs = texs             # <<<<<<<<<<<<<<
 *         self.vertices = vertices
 *         self.normals = normals
 */
  __Pyx_INCREF(__pyx_v_texs);
  __Pyx_GIVEREF(__pyx_v_texs);
  __Pyx_GOTREF(__pyx_v_self->texs);
  __Pyx_DECREF(__pyx_v_self->texs);
  __pyx_v_self->texs = __pyx_v_texs;

  /* "punyverse/_model.pyx":39
 *         self.norms = norms
 *         self.texs = texs
 *         self.vertices = vertices             # <<<<<<<<<<<<<<
 *         self.normals = normals
 *         self.textures = textures
 */
  __Pyx_INCREF(__pyx_v_vertices);
  __Pyx_GIVEREF(__pyx_v_vertices);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = __pyx_v_vertices;

  /* "punyverse/_model.pyx":40
 *         self.texs = texs
 *         self.vertices = vertices
 *         self.normals = normals             # <<<<<<<<<<<<<<
 *         self.textures = textures
 * 
 */
  __Pyx_INCREF(__pyx_v_normals);
  __Pyx_GIVEREF(__pyx_v_normals);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = __pyx_v_normals;

  /* "punyverse/_model.pyx":41
 *         self.vertices = vertices
 *         self.normals = normals
 *         self.textures = textures             # <<<<<<<<<<<<<<
 * 
 * cdef class Material(object):
 */
  __Pyx_INCREF(__pyx_v_textures);
  __Pyx_GIVEREF(__pyx_v_textures);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = __pyx_v_textures;

  /* "punyverse/_model.pyx":33
 *     cdef public list verts, norms, texs, vertices, normals, textures
 * 
 *     def __init__(self, int type, list verts, list norms, list texs,             # <<<<<<<<<<<<<<
 *                  list vertices, list normals, list textures):
 *         self.type = type
 */

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":30
 * 
 * cdef class Face(object):
 *     cdef public int type             # <<<<<<<<<<<<<<
 *     cdef public list verts, norms, texs, vertices, normals, textures
 * 
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_4type_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_4type_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_4type___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_4type___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 30, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.type.__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_9punyverse_6_model_4Face_4type_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_4type_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_4type_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_4type_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  __Pyx_RefNannySetupContext("__set__", 0);
  __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 30, __pyx_L1_error)
  __pyx_v_self->type = __pyx_t_1;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("punyverse._model.Face.type.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":31
 * cdef class Face(object):
 *     cdef public int type
 *     cdef public list verts, norms, texs, vertices, normals, textures             # <<<<<<<<<<<<<<
 * 
 *     def __init__(self, int type, list verts, list norms, list texs,
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_5verts_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_5verts_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_5verts___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_5verts___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->verts);
  __pyx_r = __pyx_v_self->verts;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_5verts_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_5verts_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_5verts_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_5verts_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->verts);
  __Pyx_DECREF(__pyx_v_self->verts);
  __pyx_v_self->verts = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.verts.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_5verts_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_5verts_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_5verts_4__del__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_5verts_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->verts);
  __Pyx_DECREF(__pyx_v_self->verts);
  __pyx_v_self->verts = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_5norms_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_5norms_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_5norms___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_5norms___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->norms);
  __pyx_r = __pyx_v_self->norms;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_5norms_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_5norms_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_5norms_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_5norms_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->norms);
  __Pyx_DECREF(__pyx_v_self->norms);
  __pyx_v_self->norms = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.norms.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_5norms_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_5norms_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_5norms_4__del__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_5norms_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->norms);
  __Pyx_DECREF(__pyx_v_self->norms);
  __pyx_v_self->norms = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_4texs_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_4texs_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_4texs___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_4texs___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->texs);
  __pyx_r = __pyx_v_self->texs;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_4texs_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_4texs_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_4texs_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_4texs_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->texs);
  __Pyx_DECREF(__pyx_v_self->texs);
  __pyx_v_self->texs = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.texs.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_4texs_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_4texs_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_4texs_4__del__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_4texs_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->texs);
  __Pyx_DECREF(__pyx_v_self->texs);
  __pyx_v_self->texs = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_8vertices_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_8vertices_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_8vertices___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_8vertices___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->vertices);
  __pyx_r = __pyx_v_self->vertices;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_8vertices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_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_9punyverse_6_model_4Face_8vertices_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_8vertices_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.vertices.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_8vertices_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_8vertices_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_8vertices_4__del__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_8vertices_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_7normals_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_7normals_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_7normals___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_7normals___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->normals);
  __pyx_r = __pyx_v_self->normals;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_7normals_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_7normals_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_7normals_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_7normals_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.normals.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_7normals_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_7normals_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_7normals_4__del__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_7normals_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_8textures_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_8textures_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_8textures___get__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_8textures___get__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->textures);
  __pyx_r = __pyx_v_self->textures;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_8textures_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_8textures_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_8textures_2__set__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_8textures_2__set__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 31, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.textures.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_4Face_8textures_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_4Face_8textures_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_8textures_4__del__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_4Face_8textures_4__del__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.normals, self.norms, self.texs, self.textures, self.type, self.vertices, self.verts)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_3__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_3__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_2__reduce_cython__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_2__reduce_cython__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self) {
  int __pyx_v_use_setstate;
  PyObject *__pyx_v_state = NULL;
  PyObject *__pyx_v__dict = NULL;
  PyObject *__pyx_r = 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;
  PyObject *__pyx_t_6 = NULL;
  __Pyx_RefNannySetupContext("__reduce_cython__", 0);

  /* "(tree fragment)":3
 * def __reduce_cython__(self):
 *     cdef bint use_setstate
 *     state = (self.normals, self.norms, self.texs, self.textures, self.type, self.vertices, self.verts)             # <<<<<<<<<<<<<<
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 */
  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->type); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(__pyx_v_self->normals);
  __Pyx_GIVEREF(__pyx_v_self->normals);
  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->normals);
  __Pyx_INCREF(__pyx_v_self->norms);
  __Pyx_GIVEREF(__pyx_v_self->norms);
  PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->norms);
  __Pyx_INCREF(__pyx_v_self->texs);
  __Pyx_GIVEREF(__pyx_v_self->texs);
  PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->texs);
  __Pyx_INCREF(__pyx_v_self->textures);
  __Pyx_GIVEREF(__pyx_v_self->textures);
  PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->textures);
  __Pyx_GIVEREF(__pyx_t_1);
  PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_t_1);
  __Pyx_INCREF(__pyx_v_self->vertices);
  __Pyx_GIVEREF(__pyx_v_self->vertices);
  PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->vertices);
  __Pyx_INCREF(__pyx_v_self->verts);
  __Pyx_GIVEREF(__pyx_v_self->verts);
  PyTuple_SET_ITEM(__pyx_t_2, 6, __pyx_v_self->verts);
  __pyx_t_1 = 0;
  __pyx_v_state = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "(tree fragment)":4
 *     cdef bint use_setstate
 *     state = (self.normals, self.norms, self.texs, self.textures, self.type, self.vertices, self.verts)
 *     _dict = getattr(self, '__dict__', None)             # <<<<<<<<<<<<<<
 *     if _dict is not None:
 *         state += (_dict,)
 */
  __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v__dict = __pyx_t_2;
  __pyx_t_2 = 0;

  /* "(tree fragment)":5
 *     state = (self.normals, self.norms, self.texs, self.textures, self.type, self.vertices, self.verts)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
  __pyx_t_3 = (__pyx_v__dict != Py_None);
  __pyx_t_4 = (__pyx_t_3 != 0);
  if (__pyx_t_4) {

    /* "(tree fragment)":6
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 *         state += (_dict,)             # <<<<<<<<<<<<<<
 *         use_setstate = True
 *     else:
 */
    __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_v__dict);
    __Pyx_GIVEREF(__pyx_v__dict);
    PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict);
    __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1));
    __pyx_t_1 = 0;

    /* "(tree fragment)":7
 *     if _dict is not None:
 *         state += (_dict,)
 *         use_setstate = True             # <<<<<<<<<<<<<<
 *     else:
 *         use_setstate = self.normals is not None or self.norms is not None or self.texs is not None or self.textures is not None or self.vertices is not None or self.verts is not None
 */
    __pyx_v_use_setstate = 1;

    /* "(tree fragment)":5
 *     state = (self.normals, self.norms, self.texs, self.textures, self.type, self.vertices, self.verts)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
    goto __pyx_L3;
  }

  /* "(tree fragment)":9
 *         use_setstate = True
 *     else:
 *         use_setstate = self.normals is not None or self.norms is not None or self.texs is not None or self.textures is not None or self.vertices is not None or self.verts is not None             # <<<<<<<<<<<<<<
 *     if use_setstate:
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, None), state
 */
  /*else*/ {
    __pyx_t_3 = (__pyx_v_self->normals != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->norms != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (__pyx_v_self->texs != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->textures != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (__pyx_v_self->vertices != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->verts != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    __pyx_t_4 = __pyx_t_3;
    __pyx_L4_bool_binop_done:;
    __pyx_v_use_setstate = __pyx_t_4;
  }
  __pyx_L3:;

  /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.normals is not None or self.norms is not None or self.texs is not None or self.textures is not None or self.vertices is not None or self.verts is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, None), state
 *     else:
 */
  __pyx_t_4 = (__pyx_v_use_setstate != 0);
  if (__pyx_t_4) {

    /* "(tree fragment)":11
 *         use_setstate = self.normals is not None or self.norms is not None or self.texs is not None or self.textures is not None or self.vertices is not None or self.verts is not None
 *     if use_setstate:
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, None), state             # <<<<<<<<<<<<<<
 *     else:
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, state)
 */
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_Face); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_142230300);
    __Pyx_GIVEREF(__pyx_int_142230300);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_142230300);
    __Pyx_INCREF(Py_None);
    __Pyx_GIVEREF(Py_None);
    PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None);
    __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state);
    __pyx_t_1 = 0;
    __pyx_t_2 = 0;
    __pyx_r = __pyx_t_6;
    __pyx_t_6 = 0;
    goto __pyx_L0;

    /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.normals is not None or self.norms is not None or self.texs is not None or self.textures is not None or self.vertices is not None or self.verts is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, None), state
 *     else:
 */
  }

  /* "(tree fragment)":13
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, None), state
 *     else:
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, state)             # <<<<<<<<<<<<<<
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_Face__set_state(self, __pyx_state)
 */
  /*else*/ {
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_Face); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_142230300);
    __Pyx_GIVEREF(__pyx_int_142230300);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_142230300);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state);
    __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2);
    __pyx_t_6 = 0;
    __pyx_t_2 = 0;
    __pyx_r = __pyx_t_1;
    __pyx_t_1 = 0;
    goto __pyx_L0;
  }

  /* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.normals, self.norms, self.texs, self.textures, self.type, self.vertices, self.verts)
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.Face.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_state);
  __Pyx_XDECREF(__pyx_v__dict);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_Face__set_state(self, __pyx_state)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_4Face_5__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_4Face_5__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_4Face_4__setstate_cython__(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4Face_4__setstate_cython__(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__setstate_cython__", 0);

  /* "(tree fragment)":15
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, state)
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_Face__set_state(self, __pyx_state)             # <<<<<<<<<<<<<<
 */
  if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 15, __pyx_L1_error)
  __pyx_t_1 = __pyx_f_9punyverse_6_model___pyx_unpickle_Face__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 15, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_Face, (type(self), 0x87a431c, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_Face__set_state(self, __pyx_state)
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Face.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":48
 *     cdef public double shininess
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),             # <<<<<<<<<<<<<<
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):
 *         self.name = name
 */

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_name = 0;
  PyObject *__pyx_v_texture = 0;
  PyObject *__pyx_v_Ka = 0;
  PyObject *__pyx_v_Kd = 0;
  PyObject *__pyx_v_Ks = 0;
  double __pyx_v_shininess;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_name,&__pyx_n_s_texture,&__pyx_n_s_Ka,&__pyx_n_s_Kd,&__pyx_n_s_Ks,&__pyx_n_s_shininess,0};
    PyObject* values[6] = {0,0,0,0,0,0};
    values[1] = ((PyObject*)Py_None);
    values[2] = ((PyObject*)__pyx_tuple_);

    /* "punyverse/_model.pyx":49
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):             # <<<<<<<<<<<<<<
 *         self.name = name
 *         self.texture = texture
 */
    values[3] = ((PyObject*)__pyx_tuple__2);
    values[4] = ((PyObject*)__pyx_tuple__3);
    if (unlikely(__pyx_kwds)) {
      Py_ssize_t kw_args;
      const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
      switch (pos_args) {
        case  6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
        CYTHON_FALLTHROUGH;
        case  5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
        CYTHON_FALLTHROUGH;
        case  4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
        CYTHON_FALLTHROUGH;
        case  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_texture);
          if (value) { values[1] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Ka);
          if (value) { values[2] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  3:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Kd);
          if (value) { values[3] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  4:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Ks);
          if (value) { values[4] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  5:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_shininess);
          if (value) { values[5] = value; kw_args--; }
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 48, __pyx_L3_error)
      }
    } else {
      switch (PyTuple_GET_SIZE(__pyx_args)) {
        case  6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
        CYTHON_FALLTHROUGH;
        case  5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
        CYTHON_FALLTHROUGH;
        case  4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
        CYTHON_FALLTHROUGH;
        case  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        break;
        default: goto __pyx_L5_argtuple_error;
      }
    }
    __pyx_v_name = ((PyObject*)values[0]);
    __pyx_v_texture = ((PyObject*)values[1]);
    __pyx_v_Ka = ((PyObject*)values[2]);
    __pyx_v_Kd = ((PyObject*)values[3]);
    __pyx_v_Ks = ((PyObject*)values[4]);
    if (values[5]) {
      __pyx_v_shininess = __pyx_PyFloat_AsDouble(values[5]); if (unlikely((__pyx_v_shininess == (double)-1) && PyErr_Occurred())) __PYX_ERR(0, 49, __pyx_L3_error)
    } else {
      __pyx_v_shininess = ((double)0.0);
    }
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 48, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.Material.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return -1;
  __pyx_L4_argument_unpacking_done:;
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 48, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_texture), (&PyString_Type), 1, "texture", 1))) __PYX_ERR(0, 48, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_Ka), (&PyTuple_Type), 1, "Ka", 1))) __PYX_ERR(0, 48, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_Kd), (&PyTuple_Type), 1, "Kd", 1))) __PYX_ERR(0, 49, __pyx_L1_error)
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_Ks), (&PyTuple_Type), 1, "Ks", 1))) __PYX_ERR(0, 49, __pyx_L1_error)
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material___init__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), __pyx_v_name, __pyx_v_texture, __pyx_v_Ka, __pyx_v_Kd, __pyx_v_Ks, __pyx_v_shininess);

  /* "punyverse/_model.pyx":48
 *     cdef public double shininess
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),             # <<<<<<<<<<<<<<
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):
 *         self.name = name
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material___init__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_name, PyObject *__pyx_v_texture, PyObject *__pyx_v_Ka, PyObject *__pyx_v_Kd, PyObject *__pyx_v_Ks, double __pyx_v_shininess) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "punyverse/_model.pyx":50
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):
 *         self.name = name             # <<<<<<<<<<<<<<
 *         self.texture = texture
 *         self.Ka = Ka
 */
  __Pyx_INCREF(__pyx_v_name);
  __Pyx_GIVEREF(__pyx_v_name);
  __Pyx_GOTREF(__pyx_v_self->name);
  __Pyx_DECREF(__pyx_v_self->name);
  __pyx_v_self->name = __pyx_v_name;

  /* "punyverse/_model.pyx":51
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):
 *         self.name = name
 *         self.texture = texture             # <<<<<<<<<<<<<<
 *         self.Ka = Ka
 *         self.Kd = Kd
 */
  __Pyx_INCREF(__pyx_v_texture);
  __Pyx_GIVEREF(__pyx_v_texture);
  __Pyx_GOTREF(__pyx_v_self->texture);
  __Pyx_DECREF(__pyx_v_self->texture);
  __pyx_v_self->texture = __pyx_v_texture;

  /* "punyverse/_model.pyx":52
 *         self.name = name
 *         self.texture = texture
 *         self.Ka = Ka             # <<<<<<<<<<<<<<
 *         self.Kd = Kd
 *         self.Ks = Ks
 */
  __Pyx_INCREF(__pyx_v_Ka);
  __Pyx_GIVEREF(__pyx_v_Ka);
  __Pyx_GOTREF(__pyx_v_self->Ka);
  __Pyx_DECREF(__pyx_v_self->Ka);
  __pyx_v_self->Ka = __pyx_v_Ka;

  /* "punyverse/_model.pyx":53
 *         self.texture = texture
 *         self.Ka = Ka
 *         self.Kd = Kd             # <<<<<<<<<<<<<<
 *         self.Ks = Ks
 *         self.shininess = shininess
 */
  __Pyx_INCREF(__pyx_v_Kd);
  __Pyx_GIVEREF(__pyx_v_Kd);
  __Pyx_GOTREF(__pyx_v_self->Kd);
  __Pyx_DECREF(__pyx_v_self->Kd);
  __pyx_v_self->Kd = __pyx_v_Kd;

  /* "punyverse/_model.pyx":54
 *         self.Ka = Ka
 *         self.Kd = Kd
 *         self.Ks = Ks             # <<<<<<<<<<<<<<
 *         self.shininess = shininess
 * 
 */
  __Pyx_INCREF(__pyx_v_Ks);
  __Pyx_GIVEREF(__pyx_v_Ks);
  __Pyx_GOTREF(__pyx_v_self->Ks);
  __Pyx_DECREF(__pyx_v_self->Ks);
  __pyx_v_self->Ks = __pyx_v_Ks;

  /* "punyverse/_model.pyx":55
 *         self.Kd = Kd
 *         self.Ks = Ks
 *         self.shininess = shininess             # <<<<<<<<<<<<<<
 * 
 * cdef class Group(object):
 */
  __pyx_v_self->shininess = __pyx_v_shininess;

  /* "punyverse/_model.pyx":48
 *     cdef public double shininess
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),             # <<<<<<<<<<<<<<
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):
 *         self.name = name
 */

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":44
 * 
 * cdef class Material(object):
 *     cdef public str name, texture             # <<<<<<<<<<<<<<
 *     cdef public tuple Ka, Kd, Ks
 *     cdef public double shininess
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_4name_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_4name_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_4name___get__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_4name___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->name);
  __pyx_r = __pyx_v_self->name;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_4name_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_4name_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_4name_2__set__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_4name_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyString_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 44, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->name);
  __Pyx_DECREF(__pyx_v_self->name);
  __pyx_v_self->name = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.name.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_4name_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_4name_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_4name_4__del__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_4name_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->name);
  __Pyx_DECREF(__pyx_v_self->name);
  __pyx_v_self->name = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_7texture_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_7texture_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_7texture___get__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_7texture___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->texture);
  __pyx_r = __pyx_v_self->texture;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_7texture_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_7texture_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_7texture_2__set__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_7texture_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyString_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 44, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->texture);
  __Pyx_DECREF(__pyx_v_self->texture);
  __pyx_v_self->texture = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.texture.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_7texture_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_7texture_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_7texture_4__del__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_7texture_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->texture);
  __Pyx_DECREF(__pyx_v_self->texture);
  __pyx_v_self->texture = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":45
 * cdef class Material(object):
 *     cdef public str name, texture
 *     cdef public tuple Ka, Kd, Ks             # <<<<<<<<<<<<<<
 *     cdef public double shininess
 * 
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_2Ka_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_2Ka_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Ka___get__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_2Ka___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->Ka);
  __pyx_r = __pyx_v_self->Ka;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_2Ka_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_2Ka_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Ka_2__set__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_2Ka_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyTuple_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 45, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->Ka);
  __Pyx_DECREF(__pyx_v_self->Ka);
  __pyx_v_self->Ka = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.Ka.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_2Ka_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_2Ka_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Ka_4__del__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_2Ka_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->Ka);
  __Pyx_DECREF(__pyx_v_self->Ka);
  __pyx_v_self->Ka = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_2Kd_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_2Kd_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Kd___get__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_2Kd___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->Kd);
  __pyx_r = __pyx_v_self->Kd;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_2Kd_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_2Kd_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Kd_2__set__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_2Kd_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyTuple_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 45, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->Kd);
  __Pyx_DECREF(__pyx_v_self->Kd);
  __pyx_v_self->Kd = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.Kd.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_2Kd_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_2Kd_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Kd_4__del__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_2Kd_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->Kd);
  __Pyx_DECREF(__pyx_v_self->Kd);
  __pyx_v_self->Kd = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_2Ks_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_2Ks_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Ks___get__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_2Ks___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->Ks);
  __pyx_r = __pyx_v_self->Ks;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_2Ks_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_2Ks_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Ks_2__set__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_2Ks_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyTuple_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 45, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->Ks);
  __Pyx_DECREF(__pyx_v_self->Ks);
  __pyx_v_self->Ks = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.Ks.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_8Material_2Ks_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_2Ks_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2Ks_4__del__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_2Ks_4__del__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->Ks);
  __Pyx_DECREF(__pyx_v_self->Ks);
  __pyx_v_self->Ks = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":46
 *     cdef public str name, texture
 *     cdef public tuple Ka, Kd, Ks
 *     cdef public double shininess             # <<<<<<<<<<<<<<
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_9shininess_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_9shininess_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_9shininess___get__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_9shininess___get__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->shininess); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 46, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.shininess.__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_9punyverse_6_model_8Material_9shininess_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_8Material_9shininess_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_9shininess_2__set__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_8Material_9shininess_2__set__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  double __pyx_t_1;
  __Pyx_RefNannySetupContext("__set__", 0);
  __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_value); if (unlikely((__pyx_t_1 == (double)-1) && PyErr_Occurred())) __PYX_ERR(0, 46, __pyx_L1_error)
  __pyx_v_self->shininess = __pyx_t_1;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("punyverse._model.Material.shininess.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.Ka, self.Kd, self.Ks, self.name, self.shininess, self.texture)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_3__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_3__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_2__reduce_cython__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_2__reduce_cython__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self) {
  int __pyx_v_use_setstate;
  PyObject *__pyx_v_state = NULL;
  PyObject *__pyx_v__dict = NULL;
  PyObject *__pyx_r = 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;
  PyObject *__pyx_t_6 = NULL;
  __Pyx_RefNannySetupContext("__reduce_cython__", 0);

  /* "(tree fragment)":3
 * def __reduce_cython__(self):
 *     cdef bint use_setstate
 *     state = (self.Ka, self.Kd, self.Ks, self.name, self.shininess, self.texture)             # <<<<<<<<<<<<<<
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 */
  __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->shininess); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(6); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(__pyx_v_self->Ka);
  __Pyx_GIVEREF(__pyx_v_self->Ka);
  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->Ka);
  __Pyx_INCREF(__pyx_v_self->Kd);
  __Pyx_GIVEREF(__pyx_v_self->Kd);
  PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->Kd);
  __Pyx_INCREF(__pyx_v_self->Ks);
  __Pyx_GIVEREF(__pyx_v_self->Ks);
  PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->Ks);
  __Pyx_INCREF(__pyx_v_self->name);
  __Pyx_GIVEREF(__pyx_v_self->name);
  PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_v_self->name);
  __Pyx_GIVEREF(__pyx_t_1);
  PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_t_1);
  __Pyx_INCREF(__pyx_v_self->texture);
  __Pyx_GIVEREF(__pyx_v_self->texture);
  PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->texture);
  __pyx_t_1 = 0;
  __pyx_v_state = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "(tree fragment)":4
 *     cdef bint use_setstate
 *     state = (self.Ka, self.Kd, self.Ks, self.name, self.shininess, self.texture)
 *     _dict = getattr(self, '__dict__', None)             # <<<<<<<<<<<<<<
 *     if _dict is not None:
 *         state += (_dict,)
 */
  __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v__dict = __pyx_t_2;
  __pyx_t_2 = 0;

  /* "(tree fragment)":5
 *     state = (self.Ka, self.Kd, self.Ks, self.name, self.shininess, self.texture)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
  __pyx_t_3 = (__pyx_v__dict != Py_None);
  __pyx_t_4 = (__pyx_t_3 != 0);
  if (__pyx_t_4) {

    /* "(tree fragment)":6
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 *         state += (_dict,)             # <<<<<<<<<<<<<<
 *         use_setstate = True
 *     else:
 */
    __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_v__dict);
    __Pyx_GIVEREF(__pyx_v__dict);
    PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict);
    __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1));
    __pyx_t_1 = 0;

    /* "(tree fragment)":7
 *     if _dict is not None:
 *         state += (_dict,)
 *         use_setstate = True             # <<<<<<<<<<<<<<
 *     else:
 *         use_setstate = self.Ka is not None or self.Kd is not None or self.Ks is not None or self.name is not None or self.texture is not None
 */
    __pyx_v_use_setstate = 1;

    /* "(tree fragment)":5
 *     state = (self.Ka, self.Kd, self.Ks, self.name, self.shininess, self.texture)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
    goto __pyx_L3;
  }

  /* "(tree fragment)":9
 *         use_setstate = True
 *     else:
 *         use_setstate = self.Ka is not None or self.Kd is not None or self.Ks is not None or self.name is not None or self.texture is not None             # <<<<<<<<<<<<<<
 *     if use_setstate:
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, None), state
 */
  /*else*/ {
    __pyx_t_3 = (__pyx_v_self->Ka != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->Kd != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (__pyx_v_self->Ks != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->name != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (__pyx_v_self->texture != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    __pyx_t_4 = __pyx_t_5;
    __pyx_L4_bool_binop_done:;
    __pyx_v_use_setstate = __pyx_t_4;
  }
  __pyx_L3:;

  /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.Ka is not None or self.Kd is not None or self.Ks is not None or self.name is not None or self.texture is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, None), state
 *     else:
 */
  __pyx_t_4 = (__pyx_v_use_setstate != 0);
  if (__pyx_t_4) {

    /* "(tree fragment)":11
 *         use_setstate = self.Ka is not None or self.Kd is not None or self.Ks is not None or self.name is not None or self.texture is not None
 *     if use_setstate:
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, None), state             # <<<<<<<<<<<<<<
 *     else:
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, state)
 */
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_Material); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_242544120);
    __Pyx_GIVEREF(__pyx_int_242544120);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_242544120);
    __Pyx_INCREF(Py_None);
    __Pyx_GIVEREF(Py_None);
    PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None);
    __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state);
    __pyx_t_1 = 0;
    __pyx_t_2 = 0;
    __pyx_r = __pyx_t_6;
    __pyx_t_6 = 0;
    goto __pyx_L0;

    /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.Ka is not None or self.Kd is not None or self.Ks is not None or self.name is not None or self.texture is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, None), state
 *     else:
 */
  }

  /* "(tree fragment)":13
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, None), state
 *     else:
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, state)             # <<<<<<<<<<<<<<
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_Material__set_state(self, __pyx_state)
 */
  /*else*/ {
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_Material); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_242544120);
    __Pyx_GIVEREF(__pyx_int_242544120);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_242544120);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state);
    __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2);
    __pyx_t_6 = 0;
    __pyx_t_2 = 0;
    __pyx_r = __pyx_t_1;
    __pyx_t_1 = 0;
    goto __pyx_L0;
  }

  /* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.Ka, self.Kd, self.Ks, self.name, self.shininess, self.texture)
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.Material.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_state);
  __Pyx_XDECREF(__pyx_v__dict);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_Material__set_state(self, __pyx_state)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_8Material_5__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_8Material_5__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_8Material_4__setstate_cython__(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8Material_4__setstate_cython__(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__setstate_cython__", 0);

  /* "(tree fragment)":15
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, state)
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_Material__set_state(self, __pyx_state)             # <<<<<<<<<<<<<<
 */
  if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 15, __pyx_L1_error)
  __pyx_t_1 = __pyx_f_9punyverse_6_model___pyx_unpickle_Material__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 15, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_Material, (type(self), 0xe74edf8, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_Material__set_state(self, __pyx_state)
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Material.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":64
 *     cdef public int idx_count
 * 
 *     def __init__(self, str name=None):             # <<<<<<<<<<<<<<
 *         if name is None:
 *             self.name = str(uuid4())
 */

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_name = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_name,0};
    PyObject* values[1] = {0};
    values[0] = ((PyObject*)Py_None);
    if (unlikely(__pyx_kwds)) {
      Py_ssize_t kw_args;
      const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
      switch (pos_args) {
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name);
          if (value) { values[0] = value; kw_args--; }
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 64, __pyx_L3_error)
      }
    } else {
      switch (PyTuple_GET_SIZE(__pyx_args)) {
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
    }
    __pyx_v_name = ((PyObject*)values[0]);
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__init__", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 64, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.Group.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return -1;
  __pyx_L4_argument_unpacking_done:;
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyString_Type), 1, "name", 1))) __PYX_ERR(0, 64, __pyx_L1_error)
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group___init__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), __pyx_v_name);

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group___init__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_name) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "punyverse/_model.pyx":65
 * 
 *     def __init__(self, str name=None):
 *         if name is None:             # <<<<<<<<<<<<<<
 *             self.name = str(uuid4())
 *         else:
 */
  __pyx_t_1 = (__pyx_v_name == ((PyObject*)Py_None));
  __pyx_t_2 = (__pyx_t_1 != 0);
  if (__pyx_t_2) {

    /* "punyverse/_model.pyx":66
 *     def __init__(self, str name=None):
 *         if name is None:
 *             self.name = str(uuid4())             # <<<<<<<<<<<<<<
 *         else:
 *             self.name = name
 */
    __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_uuid4); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 66, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_5 = NULL;
    if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
      __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4);
      if (likely(__pyx_t_5)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
        __Pyx_INCREF(__pyx_t_5);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_4, function);
      }
    }
    if (__pyx_t_5) {
      __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 66, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    } else {
      __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 66, __pyx_L1_error)
    }
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_4 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyString_Type)), __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 66, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    if (!(likely(PyString_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 66, __pyx_L1_error)
    __Pyx_GIVEREF(__pyx_t_4);
    __Pyx_GOTREF(__pyx_v_self->name);
    __Pyx_DECREF(__pyx_v_self->name);
    __pyx_v_self->name = ((PyObject*)__pyx_t_4);
    __pyx_t_4 = 0;

    /* "punyverse/_model.pyx":65
 * 
 *     def __init__(self, str name=None):
 *         if name is None:             # <<<<<<<<<<<<<<
 *             self.name = str(uuid4())
 *         else:
 */
    goto __pyx_L3;
  }

  /* "punyverse/_model.pyx":68
 *             self.name = str(uuid4())
 *         else:
 *             self.name = name             # <<<<<<<<<<<<<<
 *         self.min = ()
 *         self.material = None
 */
  /*else*/ {
    __Pyx_INCREF(__pyx_v_name);
    __Pyx_GIVEREF(__pyx_v_name);
    __Pyx_GOTREF(__pyx_v_self->name);
    __Pyx_DECREF(__pyx_v_self->name);
    __pyx_v_self->name = __pyx_v_name;
  }
  __pyx_L3:;

  /* "punyverse/_model.pyx":69
 *         else:
 *             self.name = name
 *         self.min = ()             # <<<<<<<<<<<<<<
 *         self.material = None
 *         self.faces = []
 */
  __Pyx_INCREF(__pyx_empty_tuple);
  __Pyx_GIVEREF(__pyx_empty_tuple);
  __Pyx_GOTREF(__pyx_v_self->min);
  __Pyx_DECREF(__pyx_v_self->min);
  __pyx_v_self->min = __pyx_empty_tuple;

  /* "punyverse/_model.pyx":70
 *             self.name = name
 *         self.min = ()
 *         self.material = None             # <<<<<<<<<<<<<<
 *         self.faces = []
 *         self.indices = []
 */
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->material);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->material));
  __pyx_v_self->material = ((struct __pyx_obj_9punyverse_6_model_Material *)Py_None);

  /* "punyverse/_model.pyx":71
 *         self.min = ()
 *         self.material = None
 *         self.faces = []             # <<<<<<<<<<<<<<
 *         self.indices = []
 *         self.vertices = []
 */
  __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 71, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_GIVEREF(__pyx_t_4);
  __Pyx_GOTREF(__pyx_v_self->faces);
  __Pyx_DECREF(__pyx_v_self->faces);
  __pyx_v_self->faces = ((PyObject*)__pyx_t_4);
  __pyx_t_4 = 0;

  /* "punyverse/_model.pyx":72
 *         self.material = None
 *         self.faces = []
 *         self.indices = []             # <<<<<<<<<<<<<<
 *         self.vertices = []
 *         self.normals = []
 */
  __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 72, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_GIVEREF(__pyx_t_4);
  __Pyx_GOTREF(__pyx_v_self->indices);
  __Pyx_DECREF(__pyx_v_self->indices);
  __pyx_v_self->indices = ((PyObject*)__pyx_t_4);
  __pyx_t_4 = 0;

  /* "punyverse/_model.pyx":73
 *         self.faces = []
 *         self.indices = []
 *         self.vertices = []             # <<<<<<<<<<<<<<
 *         self.normals = []
 *         self.textures = []
 */
  __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 73, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_GIVEREF(__pyx_t_4);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)__pyx_t_4);
  __pyx_t_4 = 0;

  /* "punyverse/_model.pyx":74
 *         self.indices = []
 *         self.vertices = []
 *         self.normals = []             # <<<<<<<<<<<<<<
 *         self.textures = []
 *         self.idx_count = 0
 */
  __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 74, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_GIVEREF(__pyx_t_4);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)__pyx_t_4);
  __pyx_t_4 = 0;

  /* "punyverse/_model.pyx":75
 *         self.vertices = []
 *         self.normals = []
 *         self.textures = []             # <<<<<<<<<<<<<<
 *         self.idx_count = 0
 * 
 */
  __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 75, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_GIVEREF(__pyx_t_4);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)__pyx_t_4);
  __pyx_t_4 = 0;

  /* "punyverse/_model.pyx":76
 *         self.normals = []
 *         self.textures = []
 *         self.idx_count = 0             # <<<<<<<<<<<<<<
 * 
 *     def pack(self):
 */
  __pyx_v_self->idx_count = 0;

  /* "punyverse/_model.pyx":64
 *     cdef public int idx_count
 * 
 *     def __init__(self, str name=None):             # <<<<<<<<<<<<<<
 *         if name is None:
 *             self.name = str(uuid4())
 */

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_AddTraceback("punyverse._model.Group.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":78
 *         self.idx_count = 0
 * 
 *     def pack(self):             # <<<<<<<<<<<<<<
 *         min_x, min_y, min_z = 0, 0, 0
 *         for face in self.faces:
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_3pack(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_3pack(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("pack (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_2pack(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_2pack(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_v_min_x = NULL;
  PyObject *__pyx_v_min_y = NULL;
  PyObject *__pyx_v_min_z = NULL;
  PyObject *__pyx_v_face = NULL;
  PyObject *__pyx_v_x = NULL;
  PyObject *__pyx_v_y = NULL;
  PyObject *__pyx_v_z = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  Py_ssize_t __pyx_t_4;
  Py_ssize_t __pyx_t_5;
  PyObject *(*__pyx_t_6)(PyObject *);
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  PyObject *(*__pyx_t_11)(PyObject *);
  int __pyx_t_12;
  __Pyx_RefNannySetupContext("pack", 0);

  /* "punyverse/_model.pyx":79
 * 
 *     def pack(self):
 *         min_x, min_y, min_z = 0, 0, 0             # <<<<<<<<<<<<<<
 *         for face in self.faces:
 *             for x, y, z in face.vertices:
 */
  __pyx_t_1 = __pyx_int_0;
  __Pyx_INCREF(__pyx_t_1);
  __pyx_t_2 = __pyx_int_0;
  __Pyx_INCREF(__pyx_t_2);
  __pyx_t_3 = __pyx_int_0;
  __Pyx_INCREF(__pyx_t_3);
  __pyx_v_min_x = __pyx_t_1;
  __pyx_t_1 = 0;
  __pyx_v_min_y = __pyx_t_2;
  __pyx_t_2 = 0;
  __pyx_v_min_z = __pyx_t_3;
  __pyx_t_3 = 0;

  /* "punyverse/_model.pyx":80
 *     def pack(self):
 *         min_x, min_y, min_z = 0, 0, 0
 *         for face in self.faces:             # <<<<<<<<<<<<<<
 *             for x, y, z in face.vertices:
 *                 min_x = max(min_x, abs(x))
 */
  if (unlikely(__pyx_v_self->faces == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
    __PYX_ERR(0, 80, __pyx_L1_error)
  }
  __pyx_t_3 = __pyx_v_self->faces; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0;
  for (;;) {
    if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break;
    #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    __pyx_t_2 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_2); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 80, __pyx_L1_error)
    #else
    __pyx_t_2 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 80, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    #endif
    __Pyx_XDECREF_SET(__pyx_v_face, __pyx_t_2);
    __pyx_t_2 = 0;

    /* "punyverse/_model.pyx":81
 *         min_x, min_y, min_z = 0, 0, 0
 *         for face in self.faces:
 *             for x, y, z in face.vertices:             # <<<<<<<<<<<<<<
 *                 min_x = max(min_x, abs(x))
 *                 min_y = max(min_y, abs(y))
 */
    __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_face, __pyx_n_s_vertices); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 81, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    if (likely(PyList_CheckExact(__pyx_t_2)) || PyTuple_CheckExact(__pyx_t_2)) {
      __pyx_t_1 = __pyx_t_2; __Pyx_INCREF(__pyx_t_1); __pyx_t_5 = 0;
      __pyx_t_6 = NULL;
    } else {
      __pyx_t_5 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 81, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __pyx_t_6 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 81, __pyx_L1_error)
    }
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    for (;;) {
      if (likely(!__pyx_t_6)) {
        if (likely(PyList_CheckExact(__pyx_t_1))) {
          if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_1)) break;
          #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
          __pyx_t_2 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_2); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 81, __pyx_L1_error)
          #else
          __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 81, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_2);
          #endif
        } else {
          if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
          #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
          __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_5); __Pyx_INCREF(__pyx_t_2); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 81, __pyx_L1_error)
          #else
          __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 81, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_2);
          #endif
        }
      } else {
        __pyx_t_2 = __pyx_t_6(__pyx_t_1);
        if (unlikely(!__pyx_t_2)) {
          PyObject* exc_type = PyErr_Occurred();
          if (exc_type) {
            if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
            else __PYX_ERR(0, 81, __pyx_L1_error)
          }
          break;
        }
        __Pyx_GOTREF(__pyx_t_2);
      }
      if ((likely(PyTuple_CheckExact(__pyx_t_2))) || (PyList_CheckExact(__pyx_t_2))) {
        PyObject* sequence = __pyx_t_2;
        Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
        if (unlikely(size != 3)) {
          if (size > 3) __Pyx_RaiseTooManyValuesError(3);
          else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
          __PYX_ERR(0, 81, __pyx_L1_error)
        }
        #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
        if (likely(PyTuple_CheckExact(sequence))) {
          __pyx_t_7 = PyTuple_GET_ITEM(sequence, 0); 
          __pyx_t_8 = PyTuple_GET_ITEM(sequence, 1); 
          __pyx_t_9 = PyTuple_GET_ITEM(sequence, 2); 
        } else {
          __pyx_t_7 = PyList_GET_ITEM(sequence, 0); 
          __pyx_t_8 = PyList_GET_ITEM(sequence, 1); 
          __pyx_t_9 = PyList_GET_ITEM(sequence, 2); 
        }
        __Pyx_INCREF(__pyx_t_7);
        __Pyx_INCREF(__pyx_t_8);
        __Pyx_INCREF(__pyx_t_9);
        #else
        __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 81, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_7);
        __pyx_t_8 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 81, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_8);
        __pyx_t_9 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 81, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_9);
        #endif
        __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      } else {
        Py_ssize_t index = -1;
        __pyx_t_10 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 81, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_10);
        __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
        __pyx_t_11 = Py_TYPE(__pyx_t_10)->tp_iternext;
        index = 0; __pyx_t_7 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_7)) goto __pyx_L7_unpacking_failed;
        __Pyx_GOTREF(__pyx_t_7);
        index = 1; __pyx_t_8 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_8)) goto __pyx_L7_unpacking_failed;
        __Pyx_GOTREF(__pyx_t_8);
        index = 2; __pyx_t_9 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_9)) goto __pyx_L7_unpacking_failed;
        __Pyx_GOTREF(__pyx_t_9);
        if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 3) < 0) __PYX_ERR(0, 81, __pyx_L1_error)
        __pyx_t_11 = NULL;
        __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
        goto __pyx_L8_unpacking_done;
        __pyx_L7_unpacking_failed:;
        __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
        __pyx_t_11 = NULL;
        if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
        __PYX_ERR(0, 81, __pyx_L1_error)
        __pyx_L8_unpacking_done:;
      }
      __Pyx_XDECREF_SET(__pyx_v_x, __pyx_t_7);
      __pyx_t_7 = 0;
      __Pyx_XDECREF_SET(__pyx_v_y, __pyx_t_8);
      __pyx_t_8 = 0;
      __Pyx_XDECREF_SET(__pyx_v_z, __pyx_t_9);
      __pyx_t_9 = 0;

      /* "punyverse/_model.pyx":82
 *         for face in self.faces:
 *             for x, y, z in face.vertices:
 *                 min_x = max(min_x, abs(x))             # <<<<<<<<<<<<<<
 *                 min_y = max(min_y, abs(y))
 *                 min_z = max(min_x, abs(z))
 */
      __pyx_t_2 = __Pyx_PyNumber_Absolute(__pyx_v_x); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 82, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_2);
      __Pyx_INCREF(__pyx_v_min_x);
      __pyx_t_9 = __pyx_v_min_x;
      __pyx_t_7 = PyObject_RichCompare(__pyx_t_2, __pyx_t_9, Py_GT); __Pyx_XGOTREF(__pyx_t_7); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 82, __pyx_L1_error)
      __pyx_t_12 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_12 < 0)) __PYX_ERR(0, 82, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      if (__pyx_t_12) {
        __Pyx_INCREF(__pyx_t_2);
        __pyx_t_8 = __pyx_t_2;
      } else {
        __Pyx_INCREF(__pyx_t_9);
        __pyx_t_8 = __pyx_t_9;
      }
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      __pyx_t_2 = __pyx_t_8;
      __Pyx_INCREF(__pyx_t_2);
      __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
      __Pyx_DECREF_SET(__pyx_v_min_x, __pyx_t_2);
      __pyx_t_2 = 0;

      /* "punyverse/_model.pyx":83
 *             for x, y, z in face.vertices:
 *                 min_x = max(min_x, abs(x))
 *                 min_y = max(min_y, abs(y))             # <<<<<<<<<<<<<<
 *                 min_z = max(min_x, abs(z))
 *         self.min = (min_x, min_y, min_z)
 */
      __pyx_t_2 = __Pyx_PyNumber_Absolute(__pyx_v_y); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 83, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_2);
      __Pyx_INCREF(__pyx_v_min_y);
      __pyx_t_8 = __pyx_v_min_y;
      __pyx_t_7 = PyObject_RichCompare(__pyx_t_2, __pyx_t_8, Py_GT); __Pyx_XGOTREF(__pyx_t_7); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 83, __pyx_L1_error)
      __pyx_t_12 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_12 < 0)) __PYX_ERR(0, 83, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      if (__pyx_t_12) {
        __Pyx_INCREF(__pyx_t_2);
        __pyx_t_9 = __pyx_t_2;
      } else {
        __Pyx_INCREF(__pyx_t_8);
        __pyx_t_9 = __pyx_t_8;
      }
      __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      __pyx_t_2 = __pyx_t_9;
      __Pyx_INCREF(__pyx_t_2);
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_DECREF_SET(__pyx_v_min_y, __pyx_t_2);
      __pyx_t_2 = 0;

      /* "punyverse/_model.pyx":84
 *                 min_x = max(min_x, abs(x))
 *                 min_y = max(min_y, abs(y))
 *                 min_z = max(min_x, abs(z))             # <<<<<<<<<<<<<<
 *         self.min = (min_x, min_y, min_z)
 * 
 */
      __pyx_t_2 = __Pyx_PyNumber_Absolute(__pyx_v_z); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 84, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_2);
      __Pyx_INCREF(__pyx_v_min_x);
      __pyx_t_9 = __pyx_v_min_x;
      __pyx_t_7 = PyObject_RichCompare(__pyx_t_2, __pyx_t_9, Py_GT); __Pyx_XGOTREF(__pyx_t_7); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 84, __pyx_L1_error)
      __pyx_t_12 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_12 < 0)) __PYX_ERR(0, 84, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      if (__pyx_t_12) {
        __Pyx_INCREF(__pyx_t_2);
        __pyx_t_8 = __pyx_t_2;
      } else {
        __Pyx_INCREF(__pyx_t_9);
        __pyx_t_8 = __pyx_t_9;
      }
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      __pyx_t_2 = __pyx_t_8;
      __Pyx_INCREF(__pyx_t_2);
      __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
      __Pyx_DECREF_SET(__pyx_v_min_z, __pyx_t_2);
      __pyx_t_2 = 0;

      /* "punyverse/_model.pyx":81
 *         min_x, min_y, min_z = 0, 0, 0
 *         for face in self.faces:
 *             for x, y, z in face.vertices:             # <<<<<<<<<<<<<<
 *                 min_x = max(min_x, abs(x))
 *                 min_y = max(min_y, abs(y))
 */
    }
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "punyverse/_model.pyx":80
 *     def pack(self):
 *         min_x, min_y, min_z = 0, 0, 0
 *         for face in self.faces:             # <<<<<<<<<<<<<<
 *             for x, y, z in face.vertices:
 *                 min_x = max(min_x, abs(x))
 */
  }
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

  /* "punyverse/_model.pyx":85
 *                 min_y = max(min_y, abs(y))
 *                 min_z = max(min_x, abs(z))
 *         self.min = (min_x, min_y, min_z)             # <<<<<<<<<<<<<<
 * 
 * cdef class WavefrontObject(object):
 */
  __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 85, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_INCREF(__pyx_v_min_x);
  __Pyx_GIVEREF(__pyx_v_min_x);
  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_min_x);
  __Pyx_INCREF(__pyx_v_min_y);
  __Pyx_GIVEREF(__pyx_v_min_y);
  PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_min_y);
  __Pyx_INCREF(__pyx_v_min_z);
  __Pyx_GIVEREF(__pyx_v_min_z);
  PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_min_z);
  __Pyx_GIVEREF(__pyx_t_3);
  __Pyx_GOTREF(__pyx_v_self->min);
  __Pyx_DECREF(__pyx_v_self->min);
  __pyx_v_self->min = ((PyObject*)__pyx_t_3);
  __pyx_t_3 = 0;

  /* "punyverse/_model.pyx":78
 *         self.idx_count = 0
 * 
 *     def pack(self):             # <<<<<<<<<<<<<<
 *         min_x, min_y, min_z = 0, 0, 0
 *         for face in self.faces:
 */

  /* function exit code */
  __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_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_AddTraceback("punyverse._model.Group.pack", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_min_x);
  __Pyx_XDECREF(__pyx_v_min_y);
  __Pyx_XDECREF(__pyx_v_min_z);
  __Pyx_XDECREF(__pyx_v_face);
  __Pyx_XDECREF(__pyx_v_x);
  __Pyx_XDECREF(__pyx_v_y);
  __Pyx_XDECREF(__pyx_v_z);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":58
 * 
 * cdef class Group(object):
 *     cdef public str name             # <<<<<<<<<<<<<<
 *     cdef public tuple min
 *     cdef public Material material
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_4name_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_4name_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_4name___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_4name___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->name);
  __pyx_r = __pyx_v_self->name;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_4name_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_4name_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_4name_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_4name_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyString_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 58, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->name);
  __Pyx_DECREF(__pyx_v_self->name);
  __pyx_v_self->name = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.name.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_4name_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_4name_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_4name_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_4name_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->name);
  __Pyx_DECREF(__pyx_v_self->name);
  __pyx_v_self->name = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":59
 * cdef class Group(object):
 *     cdef public str name
 *     cdef public tuple min             # <<<<<<<<<<<<<<
 *     cdef public Material material
 *     cdef public list faces, indices, vertices, normals, textures
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_3min_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_3min_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_3min___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_3min___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->min);
  __pyx_r = __pyx_v_self->min;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_3min_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_3min_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_3min_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_3min_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyTuple_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 59, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->min);
  __Pyx_DECREF(__pyx_v_self->min);
  __pyx_v_self->min = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.min.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_3min_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_3min_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_3min_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_3min_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->min);
  __Pyx_DECREF(__pyx_v_self->min);
  __pyx_v_self->min = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":60
 *     cdef public str name
 *     cdef public tuple min
 *     cdef public Material material             # <<<<<<<<<<<<<<
 *     cdef public list faces, indices, vertices, normals, textures
 *     cdef public int idx_count
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_8material_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_8material_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8material___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_8material___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->material));
  __pyx_r = ((PyObject *)__pyx_v_self->material);
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_8material_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_8material_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8material_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_8material_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_9punyverse_6_model_Material))))) __PYX_ERR(0, 60, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->material);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->material));
  __pyx_v_self->material = ((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.material.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_8material_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_8material_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8material_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_8material_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->material);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->material));
  __pyx_v_self->material = ((struct __pyx_obj_9punyverse_6_model_Material *)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":61
 *     cdef public tuple min
 *     cdef public Material material
 *     cdef public list faces, indices, vertices, normals, textures             # <<<<<<<<<<<<<<
 *     cdef public int idx_count
 * 
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_5faces_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_5faces_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_5faces___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_5faces___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->faces);
  __pyx_r = __pyx_v_self->faces;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_5faces_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_5faces_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_5faces_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_5faces_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 61, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->faces);
  __Pyx_DECREF(__pyx_v_self->faces);
  __pyx_v_self->faces = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.faces.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_5faces_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_5faces_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_5faces_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_5faces_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->faces);
  __Pyx_DECREF(__pyx_v_self->faces);
  __pyx_v_self->faces = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_7indices_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_7indices_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_7indices___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_7indices___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->indices);
  __pyx_r = __pyx_v_self->indices;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_7indices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_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_9punyverse_6_model_5Group_7indices_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_7indices_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 61, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->indices);
  __Pyx_DECREF(__pyx_v_self->indices);
  __pyx_v_self->indices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.indices.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_7indices_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_7indices_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_7indices_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_7indices_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->indices);
  __Pyx_DECREF(__pyx_v_self->indices);
  __pyx_v_self->indices = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_8vertices_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_8vertices_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8vertices___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_8vertices___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->vertices);
  __pyx_r = __pyx_v_self->vertices;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_8vertices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_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_9punyverse_6_model_5Group_8vertices_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_8vertices_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 61, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.vertices.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_8vertices_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_8vertices_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8vertices_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_8vertices_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_7normals_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_7normals_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_7normals___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_7normals___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->normals);
  __pyx_r = __pyx_v_self->normals;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_7normals_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_7normals_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_7normals_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_7normals_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 61, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.normals.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_7normals_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_7normals_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_7normals_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_7normals_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_8textures_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_8textures_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8textures___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_8textures___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->textures);
  __pyx_r = __pyx_v_self->textures;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_8textures_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_8textures_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8textures_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_8textures_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 61, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.textures.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_5Group_8textures_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_8textures_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_8textures_4__del__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_8textures_4__del__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":62
 *     cdef public Material material
 *     cdef public list faces, indices, vertices, normals, textures
 *     cdef public int idx_count             # <<<<<<<<<<<<<<
 * 
 *     def __init__(self, str name=None):
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_9idx_count_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_9idx_count_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_9idx_count___get__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_9idx_count___get__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->idx_count); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 62, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_r = __pyx_t_1;
  __pyx_t_1 = 0;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.idx_count.__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_9punyverse_6_model_5Group_9idx_count_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_5Group_9idx_count_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_9idx_count_2__set__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_5Group_9idx_count_2__set__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  __Pyx_RefNannySetupContext("__set__", 0);
  __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 62, __pyx_L1_error)
  __pyx_v_self->idx_count = __pyx_t_1;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_AddTraceback("punyverse._model.Group.idx_count.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.faces, self.idx_count, self.indices, self.material, self.min, self.name, self.normals, self.textures, self.vertices)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_5__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_5__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_4__reduce_cython__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_4__reduce_cython__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self) {
  int __pyx_v_use_setstate;
  PyObject *__pyx_v_state = NULL;
  PyObject *__pyx_v__dict = NULL;
  PyObject *__pyx_r = 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;
  PyObject *__pyx_t_6 = NULL;
  __Pyx_RefNannySetupContext("__reduce_cython__", 0);

  /* "(tree fragment)":3
 * def __reduce_cython__(self):
 *     cdef bint use_setstate
 *     state = (self.faces, self.idx_count, self.indices, self.material, self.min, self.name, self.normals, self.textures, self.vertices)             # <<<<<<<<<<<<<<
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 */
  __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->idx_count); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = PyTuple_New(9); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(__pyx_v_self->faces);
  __Pyx_GIVEREF(__pyx_v_self->faces);
  PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->faces);
  __Pyx_GIVEREF(__pyx_t_1);
  PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1);
  __Pyx_INCREF(__pyx_v_self->indices);
  __Pyx_GIVEREF(__pyx_v_self->indices);
  PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->indices);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->material));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self->material));
  PyTuple_SET_ITEM(__pyx_t_2, 3, ((PyObject *)__pyx_v_self->material));
  __Pyx_INCREF(__pyx_v_self->min);
  __Pyx_GIVEREF(__pyx_v_self->min);
  PyTuple_SET_ITEM(__pyx_t_2, 4, __pyx_v_self->min);
  __Pyx_INCREF(__pyx_v_self->name);
  __Pyx_GIVEREF(__pyx_v_self->name);
  PyTuple_SET_ITEM(__pyx_t_2, 5, __pyx_v_self->name);
  __Pyx_INCREF(__pyx_v_self->normals);
  __Pyx_GIVEREF(__pyx_v_self->normals);
  PyTuple_SET_ITEM(__pyx_t_2, 6, __pyx_v_self->normals);
  __Pyx_INCREF(__pyx_v_self->textures);
  __Pyx_GIVEREF(__pyx_v_self->textures);
  PyTuple_SET_ITEM(__pyx_t_2, 7, __pyx_v_self->textures);
  __Pyx_INCREF(__pyx_v_self->vertices);
  __Pyx_GIVEREF(__pyx_v_self->vertices);
  PyTuple_SET_ITEM(__pyx_t_2, 8, __pyx_v_self->vertices);
  __pyx_t_1 = 0;
  __pyx_v_state = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "(tree fragment)":4
 *     cdef bint use_setstate
 *     state = (self.faces, self.idx_count, self.indices, self.material, self.min, self.name, self.normals, self.textures, self.vertices)
 *     _dict = getattr(self, '__dict__', None)             # <<<<<<<<<<<<<<
 *     if _dict is not None:
 *         state += (_dict,)
 */
  __pyx_t_2 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v__dict = __pyx_t_2;
  __pyx_t_2 = 0;

  /* "(tree fragment)":5
 *     state = (self.faces, self.idx_count, self.indices, self.material, self.min, self.name, self.normals, self.textures, self.vertices)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
  __pyx_t_3 = (__pyx_v__dict != Py_None);
  __pyx_t_4 = (__pyx_t_3 != 0);
  if (__pyx_t_4) {

    /* "(tree fragment)":6
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 *         state += (_dict,)             # <<<<<<<<<<<<<<
 *         use_setstate = True
 *     else:
 */
    __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_v__dict);
    __Pyx_GIVEREF(__pyx_v__dict);
    PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__dict);
    __pyx_t_1 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_1));
    __pyx_t_1 = 0;

    /* "(tree fragment)":7
 *     if _dict is not None:
 *         state += (_dict,)
 *         use_setstate = True             # <<<<<<<<<<<<<<
 *     else:
 *         use_setstate = self.faces is not None or self.indices is not None or self.material is not None or self.min is not None or self.name is not None or self.normals is not None or self.textures is not None or self.vertices is not None
 */
    __pyx_v_use_setstate = 1;

    /* "(tree fragment)":5
 *     state = (self.faces, self.idx_count, self.indices, self.material, self.min, self.name, self.normals, self.textures, self.vertices)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
    goto __pyx_L3;
  }

  /* "(tree fragment)":9
 *         use_setstate = True
 *     else:
 *         use_setstate = self.faces is not None or self.indices is not None or self.material is not None or self.min is not None or self.name is not None or self.normals is not None or self.textures is not None or self.vertices is not None             # <<<<<<<<<<<<<<
 *     if use_setstate:
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, None), state
 */
  /*else*/ {
    __pyx_t_3 = (__pyx_v_self->faces != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->indices != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (((PyObject *)__pyx_v_self->material) != Py_None);
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->min != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (__pyx_v_self->name != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->normals != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    if (!__pyx_t_3) {
    } else {
      __pyx_t_4 = __pyx_t_3;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_3 = (__pyx_v_self->textures != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_3 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_4 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->vertices != ((PyObject*)Py_None));
    __pyx_t_3 = (__pyx_t_5 != 0);
    __pyx_t_4 = __pyx_t_3;
    __pyx_L4_bool_binop_done:;
    __pyx_v_use_setstate = __pyx_t_4;
  }
  __pyx_L3:;

  /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.faces is not None or self.indices is not None or self.material is not None or self.min is not None or self.name is not None or self.normals is not None or self.textures is not None or self.vertices is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, None), state
 *     else:
 */
  __pyx_t_4 = (__pyx_v_use_setstate != 0);
  if (__pyx_t_4) {

    /* "(tree fragment)":11
 *         use_setstate = self.faces is not None or self.indices is not None or self.material is not None or self.min is not None or self.name is not None or self.normals is not None or self.textures is not None or self.vertices is not None
 *     if use_setstate:
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, None), state             # <<<<<<<<<<<<<<
 *     else:
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, state)
 */
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_Group); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_28589906);
    __Pyx_GIVEREF(__pyx_int_28589906);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_28589906);
    __Pyx_INCREF(Py_None);
    __Pyx_GIVEREF(Py_None);
    PyTuple_SET_ITEM(__pyx_t_2, 2, Py_None);
    __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state);
    __pyx_t_1 = 0;
    __pyx_t_2 = 0;
    __pyx_r = __pyx_t_6;
    __pyx_t_6 = 0;
    goto __pyx_L0;

    /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.faces is not None or self.indices is not None or self.material is not None or self.min is not None or self.name is not None or self.normals is not None or self.textures is not None or self.vertices is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, None), state
 *     else:
 */
  }

  /* "(tree fragment)":13
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, None), state
 *     else:
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, state)             # <<<<<<<<<<<<<<
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_Group__set_state(self, __pyx_state)
 */
  /*else*/ {
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_Group); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_28589906);
    __Pyx_GIVEREF(__pyx_int_28589906);
    PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_28589906);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state);
    __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_GIVEREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_2);
    PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_2);
    __pyx_t_6 = 0;
    __pyx_t_2 = 0;
    __pyx_r = __pyx_t_1;
    __pyx_t_1 = 0;
    goto __pyx_L0;
  }

  /* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.faces, self.idx_count, self.indices, self.material, self.min, self.name, self.normals, self.textures, self.vertices)
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.Group.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_state);
  __Pyx_XDECREF(__pyx_v__dict);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_Group__set_state(self, __pyx_state)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5Group_7__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5Group_7__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_5Group_6__setstate_cython__(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_5Group_6__setstate_cython__(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__setstate_cython__", 0);

  /* "(tree fragment)":15
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, state)
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_Group__set_state(self, __pyx_state)             # <<<<<<<<<<<<<<
 */
  if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 15, __pyx_L1_error)
  __pyx_t_1 = __pyx_f_9punyverse_6_model___pyx_unpickle_Group__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 15, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_Group, (type(self), 0x1b43f52, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_Group__set_state(self, __pyx_state)
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.Group.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":94
 *     cdef Material current_material
 *     cdef Group current_group
 *     def __init__(self, unicode path):             # <<<<<<<<<<<<<<
 *         self.path = path
 *         self.root = os.path.abspath(os.path.dirname(path))
 */

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v_path = 0;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_path,0};
    PyObject* values[1] = {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  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_path)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 94, __pyx_L3_error)
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
    }
    __pyx_v_path = ((PyObject*)values[0]);
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 94, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return -1;
  __pyx_L4_argument_unpacking_done:;
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_path), (&PyUnicode_Type), 1, "path", 1))) __PYX_ERR(0, 94, __pyx_L1_error)
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject___init__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), __pyx_v_path);

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject___init__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_path) {
  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;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  int __pyx_t_7;
  __Pyx_RefNannySetupContext("__init__", 0);

  /* "punyverse/_model.pyx":95
 *     cdef Group current_group
 *     def __init__(self, unicode path):
 *         self.path = path             # <<<<<<<<<<<<<<
 *         self.root = os.path.abspath(os.path.dirname(path))
 *         self.vertices = []
 */
  __Pyx_INCREF(__pyx_v_path);
  __Pyx_GIVEREF(__pyx_v_path);
  __Pyx_GOTREF(__pyx_v_self->path);
  __Pyx_DECREF(__pyx_v_self->path);
  __pyx_v_self->path = __pyx_v_path;

  /* "punyverse/_model.pyx":96
 *     def __init__(self, unicode path):
 *         self.path = path
 *         self.root = os.path.abspath(os.path.dirname(path))             # <<<<<<<<<<<<<<
 *         self.vertices = []
 *         self.normals = []
 */
  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_abspath); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_path); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_5);
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_dirname); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  __pyx_t_5 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
    __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4);
    if (likely(__pyx_t_5)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
      __Pyx_INCREF(__pyx_t_5);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_4, function);
    }
  }
  if (!__pyx_t_5) {
    __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 96, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_4)) {
      PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_v_path};
      __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
      PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_v_path};
      __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    {
      __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_6);
      __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __pyx_t_5 = NULL;
      __Pyx_INCREF(__pyx_v_path);
      __Pyx_GIVEREF(__pyx_v_path);
      PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_v_path);
      __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_3);
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_4 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_4)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_4);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (!__pyx_t_4) {
    __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_GOTREF(__pyx_t_1);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_4, __pyx_t_3};
      __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_4, __pyx_t_3};
      __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    } else
    #endif
    {
      __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_6);
      __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL;
      __Pyx_GIVEREF(__pyx_t_3);
      PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_3);
      __pyx_t_3 = 0;
      __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 96, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 96, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->root);
  __Pyx_DECREF(__pyx_v_self->root);
  __pyx_v_self->root = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":97
 *         self.path = path
 *         self.root = os.path.abspath(os.path.dirname(path))
 *         self.vertices = []             # <<<<<<<<<<<<<<
 *         self.normals = []
 *         self.textures = []
 */
  __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 97, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":98
 *         self.root = os.path.abspath(os.path.dirname(path))
 *         self.vertices = []
 *         self.normals = []             # <<<<<<<<<<<<<<
 *         self.textures = []
 *         self.groups = []
 */
  __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 98, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":99
 *         self.vertices = []
 *         self.normals = []
 *         self.textures = []             # <<<<<<<<<<<<<<
 *         self.groups = []
 *         self.materials = {}
 */
  __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 99, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":100
 *         self.normals = []
 *         self.textures = []
 *         self.groups = []             # <<<<<<<<<<<<<<
 *         self.materials = {}
 * 
 */
  __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 100, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->groups);
  __Pyx_DECREF(__pyx_v_self->groups);
  __pyx_v_self->groups = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":101
 *         self.textures = []
 *         self.groups = []
 *         self.materials = {}             # <<<<<<<<<<<<<<
 * 
 *         self.perform_io(self.path)
 */
  __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 101, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->materials);
  __Pyx_DECREF(__pyx_v_self->materials);
  __pyx_v_self->materials = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":103
 *         self.materials = {}
 * 
 *         self.perform_io(self.path)             # <<<<<<<<<<<<<<
 * 
 *     cdef void new_material(self, list words):
 */
  __pyx_t_1 = __pyx_v_self->path;
  __Pyx_INCREF(__pyx_t_1);
  __pyx_t_7 = __pyx_f_9punyverse_6_model_15WavefrontObject_perform_io(__pyx_v_self, ((PyObject*)__pyx_t_1)); if (unlikely(__pyx_t_7 == ((int)0))) __PYX_ERR(0, 103, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":94
 *     cdef Material current_material
 *     cdef Group current_group
 *     def __init__(self, unicode path):             # <<<<<<<<<<<<<<
 *         self.path = path
 *         self.root = os.path.abspath(os.path.dirname(path))
 */

  /* function exit code */
  __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_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":105
 *         self.perform_io(self.path)
 * 
 *     cdef void new_material(self, list words):             # <<<<<<<<<<<<<<
 *         material = Material(words[1])
 *         self.materials[words[1]] = material
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_new_material(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  struct __pyx_obj_9punyverse_6_model_Material *__pyx_v_material = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  __Pyx_RefNannySetupContext("new_material", 0);

  /* "punyverse/_model.pyx":106
 * 
 *     cdef void new_material(self, list words):
 *         material = Material(words[1])             # <<<<<<<<<<<<<<
 *         self.materials[words[1]] = material
 *         self.current_material = material
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 106, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 106, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_9punyverse_6_model_Material), __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 106, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_material = ((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":107
 *     cdef void new_material(self, list words):
 *         material = Material(words[1])
 *         self.materials[words[1]] = material             # <<<<<<<<<<<<<<
 *         self.current_material = material
 * 
 */
  if (unlikely(__pyx_v_self->materials == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 107, __pyx_L1_error)
  }
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 107, __pyx_L1_error)
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 107, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  if (unlikely(PyDict_SetItem(__pyx_v_self->materials, __pyx_t_2, ((PyObject *)__pyx_v_material)) < 0)) __PYX_ERR(0, 107, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":108
 *         material = Material(words[1])
 *         self.materials[words[1]] = material
 *         self.current_material = material             # <<<<<<<<<<<<<<
 * 
 *     cdef void Ka(self, list words):
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_material));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_material));
  __Pyx_GOTREF(__pyx_v_self->current_material);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->current_material));
  __pyx_v_self->current_material = __pyx_v_material;

  /* "punyverse/_model.pyx":105
 *         self.perform_io(self.path)
 * 
 *     cdef void new_material(self, list words):             # <<<<<<<<<<<<<<
 *         material = Material(words[1])
 *         self.materials[words[1]] = material
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.new_material", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_XDECREF((PyObject *)__pyx_v_material);
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":110
 *         self.current_material = material
 * 
 *     cdef void Ka(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.Ka = (float(words[1]), float(words[2]), float(words[3]))
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_Ka(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  __Pyx_RefNannySetupContext("Ka", 0);

  /* "punyverse/_model.pyx":111
 * 
 *     cdef void Ka(self, list words):
 *         self.current_material.Ka = (float(words[1]), float(words[2]), float(words[3]))             # <<<<<<<<<<<<<<
 * 
 *     cdef void Kd(self, list words):
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 111, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 111, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 111, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 3, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 111, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_2);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  __Pyx_GIVEREF(__pyx_t_4);
  PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  __pyx_t_2 = 0;
  __pyx_t_3 = 0;
  __pyx_t_4 = 0;
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->current_material->Ka);
  __Pyx_DECREF(__pyx_v_self->current_material->Ka);
  __pyx_v_self->current_material->Ka = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":110
 *         self.current_material = material
 * 
 *     cdef void Ka(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.Ka = (float(words[1]), float(words[2]), float(words[3]))
 * 
 */

  /* function exit code */
  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_WriteUnraisable("punyverse._model.WavefrontObject.Ka", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":113
 *         self.current_material.Ka = (float(words[1]), float(words[2]), float(words[3]))
 * 
 *     cdef void Kd(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.Kd = (float(words[1]), float(words[2]), float(words[3]))
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_Kd(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  __Pyx_RefNannySetupContext("Kd", 0);

  /* "punyverse/_model.pyx":114
 * 
 *     cdef void Kd(self, list words):
 *         self.current_material.Kd = (float(words[1]), float(words[2]), float(words[3]))             # <<<<<<<<<<<<<<
 * 
 *     cdef void Ks(self, list words):
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 114, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 114, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 114, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 3, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 114, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_2);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  __Pyx_GIVEREF(__pyx_t_4);
  PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  __pyx_t_2 = 0;
  __pyx_t_3 = 0;
  __pyx_t_4 = 0;
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->current_material->Kd);
  __Pyx_DECREF(__pyx_v_self->current_material->Kd);
  __pyx_v_self->current_material->Kd = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":113
 *         self.current_material.Ka = (float(words[1]), float(words[2]), float(words[3]))
 * 
 *     cdef void Kd(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.Kd = (float(words[1]), float(words[2]), float(words[3]))
 * 
 */

  /* function exit code */
  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_WriteUnraisable("punyverse._model.WavefrontObject.Kd", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":116
 *         self.current_material.Kd = (float(words[1]), float(words[2]), float(words[3]))
 * 
 *     cdef void Ks(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.Ks = (float(words[1]), float(words[2]), float(words[3]))
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_Ks(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  __Pyx_RefNannySetupContext("Ks", 0);

  /* "punyverse/_model.pyx":117
 * 
 *     cdef void Ks(self, list words):
 *         self.current_material.Ks = (float(words[1]), float(words[2]), float(words[3]))             # <<<<<<<<<<<<<<
 * 
 *     cdef void material_shininess(self, list words):
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 117, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 117, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 117, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 3, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 117, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_2);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  __Pyx_GIVEREF(__pyx_t_4);
  PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  __pyx_t_2 = 0;
  __pyx_t_3 = 0;
  __pyx_t_4 = 0;
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->current_material->Ks);
  __Pyx_DECREF(__pyx_v_self->current_material->Ks);
  __pyx_v_self->current_material->Ks = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":116
 *         self.current_material.Kd = (float(words[1]), float(words[2]), float(words[3]))
 * 
 *     cdef void Ks(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.Ks = (float(words[1]), float(words[2]), float(words[3]))
 * 
 */

  /* function exit code */
  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_WriteUnraisable("punyverse._model.WavefrontObject.Ks", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":119
 *         self.current_material.Ks = (float(words[1]), float(words[2]), float(words[3]))
 * 
 *     cdef void material_shininess(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.shininess = min(float(words[1]), 125)
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_material_shininess(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __Pyx_RefNannyDeclarations
  long __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  double __pyx_t_3;
  double __pyx_t_4;
  __Pyx_RefNannySetupContext("material_shininess", 0);

  /* "punyverse/_model.pyx":120
 * 
 *     cdef void material_shininess(self, list words):
 *         self.current_material.shininess = min(float(words[1]), 125)             # <<<<<<<<<<<<<<
 * 
 *     cdef void material_texture(self, list words):
 */
  __pyx_t_1 = 0x7D;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 120, __pyx_L1_error)
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 120, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_AsDouble(__pyx_t_2); if (unlikely(__pyx_t_3 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 120, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  if (((__pyx_t_1 < __pyx_t_3) != 0)) {
    __pyx_t_4 = __pyx_t_1;
  } else {
    __pyx_t_4 = __pyx_t_3;
  }
  __pyx_v_self->current_material->shininess = __pyx_t_4;

  /* "punyverse/_model.pyx":119
 *         self.current_material.Ks = (float(words[1]), float(words[2]), float(words[3]))
 * 
 *     cdef void material_shininess(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.shininess = min(float(words[1]), 125)
 * 
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.material_shininess", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":122
 *         self.current_material.shininess = min(float(words[1]), 125)
 * 
 *     cdef void material_texture(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.texture = words[-1]
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_material_texture(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("material_texture", 0);

  /* "punyverse/_model.pyx":123
 * 
 *     cdef void material_texture(self, list words):
 *         self.current_material.texture = words[-1]             # <<<<<<<<<<<<<<
 * 
 *     @cython.nonecheck(False)
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 123, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, -1L, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 123, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyString_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 123, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->current_material->texture);
  __Pyx_DECREF(__pyx_v_self->current_material->texture);
  __pyx_v_self->current_material->texture = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":122
 *         self.current_material.shininess = min(float(words[1]), 125)
 * 
 *     cdef void material_texture(self, list words):             # <<<<<<<<<<<<<<
 *         self.current_material.texture = words[-1]
 * 
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.material_texture", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":126
 * 
 *     @cython.nonecheck(False)
 *     cdef void vertex(self, list words):             # <<<<<<<<<<<<<<
 *         self.vertices.append((float(words[1]), float(words[2]), float(words[3])))
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_vertex(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __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;
  __Pyx_RefNannySetupContext("vertex", 0);

  /* "punyverse/_model.pyx":127
 *     @cython.nonecheck(False)
 *     cdef void vertex(self, list words):
 *         self.vertices.append((float(words[1]), float(words[2]), float(words[3])))             # <<<<<<<<<<<<<<
 * 
 *     @cython.nonecheck(False)
 */
  if (unlikely(__pyx_v_self->vertices == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append");
    __PYX_ERR(0, 127, __pyx_L1_error)
  }
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 127, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 127, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 127, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 3, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_2);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  __Pyx_GIVEREF(__pyx_t_4);
  PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  __pyx_t_2 = 0;
  __pyx_t_3 = 0;
  __pyx_t_4 = 0;
  __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_self->vertices, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 127, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":126
 * 
 *     @cython.nonecheck(False)
 *     cdef void vertex(self, list words):             # <<<<<<<<<<<<<<
 *         self.vertices.append((float(words[1]), float(words[2]), float(words[3])))
 * 
 */

  /* function exit code */
  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_WriteUnraisable("punyverse._model.WavefrontObject.vertex", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":130
 * 
 *     @cython.nonecheck(False)
 *     cdef void normal(self, list words):             # <<<<<<<<<<<<<<
 *         self.normals.append((float(words[1]), float(words[2]), float(words[3])))
 * 
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_normal(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  __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;
  __Pyx_RefNannySetupContext("normal", 0);

  /* "punyverse/_model.pyx":131
 *     @cython.nonecheck(False)
 *     cdef void normal(self, list words):
 *         self.normals.append((float(words[1]), float(words[2]), float(words[3])))             # <<<<<<<<<<<<<<
 * 
 *     cdef void texture(self, list words):
 */
  if (unlikely(__pyx_v_self->normals == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append");
    __PYX_ERR(0, 131, __pyx_L1_error)
  }
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 131, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 131, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_3 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 131, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 3, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_4 = __Pyx_PyNumber_Float(__pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_2);
  PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_3);
  PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  __Pyx_GIVEREF(__pyx_t_4);
  PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  __pyx_t_2 = 0;
  __pyx_t_3 = 0;
  __pyx_t_4 = 0;
  __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_self->normals, __pyx_t_1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 131, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":130
 * 
 *     @cython.nonecheck(False)
 *     cdef void normal(self, list words):             # <<<<<<<<<<<<<<
 *         self.normals.append((float(words[1]), float(words[2]), float(words[3])))
 * 
 */

  /* function exit code */
  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_WriteUnraisable("punyverse._model.WavefrontObject.normal", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":133
 *         self.normals.append((float(words[1]), float(words[2]), float(words[3])))
 * 
 *     cdef void texture(self, list words):             # <<<<<<<<<<<<<<
 *         cdef int l = len(words)
 *         cdef object x = 0, y = 0, z = 0
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_texture(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  int __pyx_v_l;
  PyObject *__pyx_v_x = 0;
  PyObject *__pyx_v_y = 0;
  PyObject *__pyx_v_z = 0;
  __Pyx_RefNannyDeclarations
  Py_ssize_t __pyx_t_1;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  double __pyx_t_5;
  int __pyx_t_6;
  __Pyx_RefNannySetupContext("texture", 0);

  /* "punyverse/_model.pyx":134
 * 
 *     cdef void texture(self, list words):
 *         cdef int l = len(words)             # <<<<<<<<<<<<<<
 *         cdef object x = 0, y = 0, z = 0
 *         if l >= 2:
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(0, 134, __pyx_L1_error)
  }
  __pyx_t_1 = PyList_GET_SIZE(__pyx_v_words); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(0, 134, __pyx_L1_error)
  __pyx_v_l = __pyx_t_1;

  /* "punyverse/_model.pyx":135
 *     cdef void texture(self, list words):
 *         cdef int l = len(words)
 *         cdef object x = 0, y = 0, z = 0             # <<<<<<<<<<<<<<
 *         if l >= 2:
 *             x = float(words[1])
 */
  __Pyx_INCREF(__pyx_int_0);
  __pyx_v_x = __pyx_int_0;
  __Pyx_INCREF(__pyx_int_0);
  __pyx_v_y = __pyx_int_0;
  __Pyx_INCREF(__pyx_int_0);
  __pyx_v_z = __pyx_int_0;

  /* "punyverse/_model.pyx":136
 *         cdef int l = len(words)
 *         cdef object x = 0, y = 0, z = 0
 *         if l >= 2:             # <<<<<<<<<<<<<<
 *             x = float(words[1])
 *         if l >= 3:
 */
  __pyx_t_2 = ((__pyx_v_l >= 2) != 0);
  if (__pyx_t_2) {

    /* "punyverse/_model.pyx":137
 *         cdef object x = 0, y = 0, z = 0
 *         if l >= 2:
 *             x = float(words[1])             # <<<<<<<<<<<<<<
 *         if l >= 3:
 *             # OBJ origin is at upper left, OpenGL origin is at lower left
 */
    if (unlikely(__pyx_v_words == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 137, __pyx_L1_error)
    }
    __pyx_t_3 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 137, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = __Pyx_PyNumber_Float(__pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 137, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF_SET(__pyx_v_x, __pyx_t_4);
    __pyx_t_4 = 0;

    /* "punyverse/_model.pyx":136
 *         cdef int l = len(words)
 *         cdef object x = 0, y = 0, z = 0
 *         if l >= 2:             # <<<<<<<<<<<<<<
 *             x = float(words[1])
 *         if l >= 3:
 */
  }

  /* "punyverse/_model.pyx":138
 *         if l >= 2:
 *             x = float(words[1])
 *         if l >= 3:             # <<<<<<<<<<<<<<
 *             # OBJ origin is at upper left, OpenGL origin is at lower left
 *             y = 1 - float(words[2])
 */
  __pyx_t_2 = ((__pyx_v_l >= 3) != 0);
  if (__pyx_t_2) {

    /* "punyverse/_model.pyx":140
 *         if l >= 3:
 *             # OBJ origin is at upper left, OpenGL origin is at lower left
 *             y = 1 - float(words[2])             # <<<<<<<<<<<<<<
 *         if l >= 4:
 *             z = float(words[3])
 */
    if (unlikely(__pyx_v_words == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 140, __pyx_L1_error)
    }
    __pyx_t_4 = __Pyx_GetItemInt_List(__pyx_v_words, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 140, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_5 = __Pyx_PyObject_AsDouble(__pyx_t_4); if (unlikely(__pyx_t_5 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 140, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_4 = PyFloat_FromDouble((1.0 - __pyx_t_5)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 140, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF_SET(__pyx_v_y, __pyx_t_4);
    __pyx_t_4 = 0;

    /* "punyverse/_model.pyx":138
 *         if l >= 2:
 *             x = float(words[1])
 *         if l >= 3:             # <<<<<<<<<<<<<<
 *             # OBJ origin is at upper left, OpenGL origin is at lower left
 *             y = 1 - float(words[2])
 */
  }

  /* "punyverse/_model.pyx":141
 *             # OBJ origin is at upper left, OpenGL origin is at lower left
 *             y = 1 - float(words[2])
 *         if l >= 4:             # <<<<<<<<<<<<<<
 *             z = float(words[3])
 *         self.textures.append((x, y, z))
 */
  __pyx_t_2 = ((__pyx_v_l >= 4) != 0);
  if (__pyx_t_2) {

    /* "punyverse/_model.pyx":142
 *             y = 1 - float(words[2])
 *         if l >= 4:
 *             z = float(words[3])             # <<<<<<<<<<<<<<
 *         self.textures.append((x, y, z))
 * 
 */
    if (unlikely(__pyx_v_words == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 142, __pyx_L1_error)
    }
    __pyx_t_4 = __Pyx_GetItemInt_List(__pyx_v_words, 3, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 142, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_3 = __Pyx_PyNumber_Float(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 142, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF_SET(__pyx_v_z, __pyx_t_3);
    __pyx_t_3 = 0;

    /* "punyverse/_model.pyx":141
 *             # OBJ origin is at upper left, OpenGL origin is at lower left
 *             y = 1 - float(words[2])
 *         if l >= 4:             # <<<<<<<<<<<<<<
 *             z = float(words[3])
 *         self.textures.append((x, y, z))
 */
  }

  /* "punyverse/_model.pyx":143
 *         if l >= 4:
 *             z = float(words[3])
 *         self.textures.append((x, y, z))             # <<<<<<<<<<<<<<
 * 
 *     cdef void face(self, list words):
 */
  if (unlikely(__pyx_v_self->textures == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append");
    __PYX_ERR(0, 143, __pyx_L1_error)
  }
  __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 143, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_INCREF(__pyx_v_x);
  __Pyx_GIVEREF(__pyx_v_x);
  PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_x);
  __Pyx_INCREF(__pyx_v_y);
  __Pyx_GIVEREF(__pyx_v_y);
  PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_y);
  __Pyx_INCREF(__pyx_v_z);
  __Pyx_GIVEREF(__pyx_v_z);
  PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_v_z);
  __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_self->textures, __pyx_t_3); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 143, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

  /* "punyverse/_model.pyx":133
 *         self.normals.append((float(words[1]), float(words[2]), float(words[3])))
 * 
 *     cdef void texture(self, list words):             # <<<<<<<<<<<<<<
 *         cdef int l = len(words)
 *         cdef object x = 0, y = 0, z = 0
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.texture", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_x);
  __Pyx_XDECREF(__pyx_v_y);
  __Pyx_XDECREF(__pyx_v_z);
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":145
 *         self.textures.append((x, y, z))
 * 
 *     cdef void face(self, list words):             # <<<<<<<<<<<<<<
 *         cdef int l = len(words)
 *         cdef int type = -1
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_face(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  int __pyx_v_l;
  int __pyx_v_type;
  int __pyx_v_vertex_count;
  PyObject *__pyx_v_face_vertices = 0;
  PyObject *__pyx_v_face_normals = 0;
  PyObject *__pyx_v_face_textures = 0;
  int __pyx_v_current_value;
  int __pyx_v_texture_len;
  PyObject *__pyx_v_raw_faces = 0;
  PyObject *__pyx_v_vindices = 0;
  PyObject *__pyx_v_nindices = 0;
  PyObject *__pyx_v_tindices = 0;
  long __pyx_v_i;
  struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_group = 0;
  PyObject *__pyx_v_idx_count = NULL;
  __Pyx_RefNannyDeclarations
  Py_ssize_t __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  int __pyx_t_3;
  long __pyx_t_4;
  long __pyx_t_5;
  long __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  int __pyx_t_8;
  int __pyx_t_9;
  long __pyx_t_10;
  int __pyx_t_11;
  PyObject *__pyx_t_12 = NULL;
  PyObject *__pyx_t_13 = NULL;
  __Pyx_RefNannySetupContext("face", 0);

  /* "punyverse/_model.pyx":146
 * 
 *     cdef void face(self, list words):
 *         cdef int l = len(words)             # <<<<<<<<<<<<<<
 *         cdef int type = -1
 *         cdef int vertex_count = l - 1
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(0, 146, __pyx_L1_error)
  }
  __pyx_t_1 = PyList_GET_SIZE(__pyx_v_words); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(0, 146, __pyx_L1_error)
  __pyx_v_l = __pyx_t_1;

  /* "punyverse/_model.pyx":147
 *     cdef void face(self, list words):
 *         cdef int l = len(words)
 *         cdef int type = -1             # <<<<<<<<<<<<<<
 *         cdef int vertex_count = l - 1
 *         cdef list face_vertices = [], face_normals = [], face_textures = []
 */
  __pyx_v_type = -1;

  /* "punyverse/_model.pyx":148
 *         cdef int l = len(words)
 *         cdef int type = -1
 *         cdef int vertex_count = l - 1             # <<<<<<<<<<<<<<
 *         cdef list face_vertices = [], face_normals = [], face_textures = []
 * 
 */
  __pyx_v_vertex_count = (__pyx_v_l - 1);

  /* "punyverse/_model.pyx":149
 *         cdef int type = -1
 *         cdef int vertex_count = l - 1
 *         cdef list face_vertices = [], face_normals = [], face_textures = []             # <<<<<<<<<<<<<<
 * 
 *         if vertex_count == 3:
 */
  __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 149, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v_face_vertices = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;
  __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 149, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v_face_normals = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;
  __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 149, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v_face_textures = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":151
 *         cdef list face_vertices = [], face_normals = [], face_textures = []
 * 
 *         if vertex_count == 3:             # <<<<<<<<<<<<<<
 *             type = FACE_TRIANGLES
 *         else:
 */
  __pyx_t_3 = ((__pyx_v_vertex_count == 3) != 0);
  if (__pyx_t_3) {

    /* "punyverse/_model.pyx":152
 * 
 *         if vertex_count == 3:
 *             type = FACE_TRIANGLES             # <<<<<<<<<<<<<<
 *         else:
 *             type = FACE_QUADS
 */
    __pyx_v_type = __pyx_e_9punyverse_6_model_FACE_TRIANGLES;

    /* "punyverse/_model.pyx":151
 *         cdef list face_vertices = [], face_normals = [], face_textures = []
 * 
 *         if vertex_count == 3:             # <<<<<<<<<<<<<<
 *             type = FACE_TRIANGLES
 *         else:
 */
    goto __pyx_L3;
  }

  /* "punyverse/_model.pyx":154
 *             type = FACE_TRIANGLES
 *         else:
 *             type = FACE_QUADS             # <<<<<<<<<<<<<<
 * 
 *         cdef int current_value = -1, texture_len = len(self.textures)
 */
  /*else*/ {
    __pyx_v_type = __pyx_e_9punyverse_6_model_FACE_QUADS;
  }
  __pyx_L3:;

  /* "punyverse/_model.pyx":156
 *             type = FACE_QUADS
 * 
 *         cdef int current_value = -1, texture_len = len(self.textures)             # <<<<<<<<<<<<<<
 *         cdef list raw_faces, vindices = [], nindices = [], tindices = []
 * 
 */
  __pyx_v_current_value = -1;
  __pyx_t_2 = __pyx_v_self->textures;
  __Pyx_INCREF(__pyx_t_2);
  if (unlikely(__pyx_t_2 == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(0, 156, __pyx_L1_error)
  }
  __pyx_t_1 = PyList_GET_SIZE(__pyx_t_2); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(0, 156, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v_texture_len = __pyx_t_1;

  /* "punyverse/_model.pyx":157
 * 
 *         cdef int current_value = -1, texture_len = len(self.textures)
 *         cdef list raw_faces, vindices = [], nindices = [], tindices = []             # <<<<<<<<<<<<<<
 * 
 *         for i in xrange(1, vertex_count + 1):
 */
  __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 157, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v_vindices = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;
  __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 157, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v_nindices = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;
  __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 157, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_v_tindices = ((PyObject*)__pyx_t_2);
  __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":159
 *         cdef list raw_faces, vindices = [], nindices = [], tindices = []
 * 
 *         for i in xrange(1, vertex_count + 1):             # <<<<<<<<<<<<<<
 *             raw_faces = words[i].split('/')
 *             l = len(raw_faces)
 */
  __pyx_t_4 = (__pyx_v_vertex_count + 1);
  __pyx_t_5 = __pyx_t_4;
  for (__pyx_t_6 = 1; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
    __pyx_v_i = __pyx_t_6;

    /* "punyverse/_model.pyx":160
 * 
 *         for i in xrange(1, vertex_count + 1):
 *             raw_faces = words[i].split('/')             # <<<<<<<<<<<<<<
 *             l = len(raw_faces)
 * 
 */
    if (unlikely(__pyx_v_words == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 160, __pyx_L1_error)
    }
    __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_words, __pyx_v_i, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 160, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_split); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 160, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__5, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 160, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    if (!(likely(PyList_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(0, 160, __pyx_L1_error)
    __Pyx_XDECREF_SET(__pyx_v_raw_faces, ((PyObject*)__pyx_t_2));
    __pyx_t_2 = 0;

    /* "punyverse/_model.pyx":161
 *         for i in xrange(1, vertex_count + 1):
 *             raw_faces = words[i].split('/')
 *             l = len(raw_faces)             # <<<<<<<<<<<<<<
 * 
 *             current_value = int(raw_faces[0])
 */
    if (unlikely(__pyx_v_raw_faces == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
      __PYX_ERR(0, 161, __pyx_L1_error)
    }
    __pyx_t_1 = PyList_GET_SIZE(__pyx_v_raw_faces); if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(0, 161, __pyx_L1_error)
    __pyx_v_l = __pyx_t_1;

    /* "punyverse/_model.pyx":163
 *             l = len(raw_faces)
 * 
 *             current_value = int(raw_faces[0])             # <<<<<<<<<<<<<<
 *             vindices.append(current_value - 1)
 *             face_vertices.append(self.vertices[current_value - 1])
 */
    if (unlikely(__pyx_v_raw_faces == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 163, __pyx_L1_error)
    }
    __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_raw_faces, 0, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 163, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_7 = __Pyx_PyNumber_Int(__pyx_t_2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 163, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_8 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_8 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 163, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __pyx_v_current_value = __pyx_t_8;

    /* "punyverse/_model.pyx":164
 * 
 *             current_value = int(raw_faces[0])
 *             vindices.append(current_value - 1)             # <<<<<<<<<<<<<<
 *             face_vertices.append(self.vertices[current_value - 1])
 * 
 */
    __pyx_t_7 = __Pyx_PyInt_From_long((__pyx_v_current_value - 1)); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 164, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_vindices, __pyx_t_7); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 164, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;

    /* "punyverse/_model.pyx":165
 *             current_value = int(raw_faces[0])
 *             vindices.append(current_value - 1)
 *             face_vertices.append(self.vertices[current_value - 1])             # <<<<<<<<<<<<<<
 * 
 *             if l == 1:
 */
    if (unlikely(__pyx_v_self->vertices == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 165, __pyx_L1_error)
    }
    __pyx_t_10 = (__pyx_v_current_value - 1);
    __pyx_t_7 = __Pyx_GetItemInt_List(__pyx_v_self->vertices, __pyx_t_10, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 165, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_face_vertices, __pyx_t_7); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 165, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;

    /* "punyverse/_model.pyx":167
 *             face_vertices.append(self.vertices[current_value - 1])
 * 
 *             if l == 1:             # <<<<<<<<<<<<<<
 *                 continue
 *             if l >= 2 and raw_faces[1]:
 */
    __pyx_t_3 = ((__pyx_v_l == 1) != 0);
    if (__pyx_t_3) {

      /* "punyverse/_model.pyx":168
 * 
 *             if l == 1:
 *                 continue             # <<<<<<<<<<<<<<
 *             if l >= 2 and raw_faces[1]:
 *                 current_value = int(raw_faces[1])
 */
      goto __pyx_L4_continue;

      /* "punyverse/_model.pyx":167
 *             face_vertices.append(self.vertices[current_value - 1])
 * 
 *             if l == 1:             # <<<<<<<<<<<<<<
 *                 continue
 *             if l >= 2 and raw_faces[1]:
 */
    }

    /* "punyverse/_model.pyx":169
 *             if l == 1:
 *                 continue
 *             if l >= 2 and raw_faces[1]:             # <<<<<<<<<<<<<<
 *                 current_value = int(raw_faces[1])
 *                 if current_value <= texture_len:
 */
    __pyx_t_11 = ((__pyx_v_l >= 2) != 0);
    if (__pyx_t_11) {
    } else {
      __pyx_t_3 = __pyx_t_11;
      goto __pyx_L8_bool_binop_done;
    }
    if (unlikely(__pyx_v_raw_faces == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 169, __pyx_L1_error)
    }
    __pyx_t_7 = __Pyx_GetItemInt_List(__pyx_v_raw_faces, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 169, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_11 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_11 < 0)) __PYX_ERR(0, 169, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __pyx_t_3 = __pyx_t_11;
    __pyx_L8_bool_binop_done:;
    if (__pyx_t_3) {

      /* "punyverse/_model.pyx":170
 *                 continue
 *             if l >= 2 and raw_faces[1]:
 *                 current_value = int(raw_faces[1])             # <<<<<<<<<<<<<<
 *                 if current_value <= texture_len:
 *                     tindices.append(current_value - 1)
 */
      if (unlikely(__pyx_v_raw_faces == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        __PYX_ERR(0, 170, __pyx_L1_error)
      }
      __pyx_t_7 = __Pyx_GetItemInt_List(__pyx_v_raw_faces, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 170, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_7);
      __pyx_t_2 = __Pyx_PyNumber_Int(__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 170, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_2);
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __pyx_t_8 = __Pyx_PyInt_As_int(__pyx_t_2); if (unlikely((__pyx_t_8 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 170, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      __pyx_v_current_value = __pyx_t_8;

      /* "punyverse/_model.pyx":171
 *             if l >= 2 and raw_faces[1]:
 *                 current_value = int(raw_faces[1])
 *                 if current_value <= texture_len:             # <<<<<<<<<<<<<<
 *                     tindices.append(current_value - 1)
 *                     face_textures.append(self.textures[current_value - 1])
 */
      __pyx_t_3 = ((__pyx_v_current_value <= __pyx_v_texture_len) != 0);
      if (__pyx_t_3) {

        /* "punyverse/_model.pyx":172
 *                 current_value = int(raw_faces[1])
 *                 if current_value <= texture_len:
 *                     tindices.append(current_value - 1)             # <<<<<<<<<<<<<<
 *                     face_textures.append(self.textures[current_value - 1])
 *             if l >= 3 and raw_faces[2]:
 */
        __pyx_t_2 = __Pyx_PyInt_From_long((__pyx_v_current_value - 1)); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 172, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_2);
        __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_tindices, __pyx_t_2); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 172, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

        /* "punyverse/_model.pyx":173
 *                 if current_value <= texture_len:
 *                     tindices.append(current_value - 1)
 *                     face_textures.append(self.textures[current_value - 1])             # <<<<<<<<<<<<<<
 *             if l >= 3 and raw_faces[2]:
 *                 current_value = int(raw_faces[2])
 */
        if (unlikely(__pyx_v_self->textures == Py_None)) {
          PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
          __PYX_ERR(0, 173, __pyx_L1_error)
        }
        __pyx_t_10 = (__pyx_v_current_value - 1);
        __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_self->textures, __pyx_t_10, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 173, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_2);
        __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_face_textures, __pyx_t_2); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 173, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

        /* "punyverse/_model.pyx":171
 *             if l >= 2 and raw_faces[1]:
 *                 current_value = int(raw_faces[1])
 *                 if current_value <= texture_len:             # <<<<<<<<<<<<<<
 *                     tindices.append(current_value - 1)
 *                     face_textures.append(self.textures[current_value - 1])
 */
      }

      /* "punyverse/_model.pyx":169
 *             if l == 1:
 *                 continue
 *             if l >= 2 and raw_faces[1]:             # <<<<<<<<<<<<<<
 *                 current_value = int(raw_faces[1])
 *                 if current_value <= texture_len:
 */
    }

    /* "punyverse/_model.pyx":174
 *                     tindices.append(current_value - 1)
 *                     face_textures.append(self.textures[current_value - 1])
 *             if l >= 3 and raw_faces[2]:             # <<<<<<<<<<<<<<
 *                 current_value = int(raw_faces[2])
 *                 nindices.append(current_value - 1)
 */
    __pyx_t_11 = ((__pyx_v_l >= 3) != 0);
    if (__pyx_t_11) {
    } else {
      __pyx_t_3 = __pyx_t_11;
      goto __pyx_L12_bool_binop_done;
    }
    if (unlikely(__pyx_v_raw_faces == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 174, __pyx_L1_error)
    }
    __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_raw_faces, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 174, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_11 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_11 < 0)) __PYX_ERR(0, 174, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_3 = __pyx_t_11;
    __pyx_L12_bool_binop_done:;
    if (__pyx_t_3) {

      /* "punyverse/_model.pyx":175
 *                     face_textures.append(self.textures[current_value - 1])
 *             if l >= 3 and raw_faces[2]:
 *                 current_value = int(raw_faces[2])             # <<<<<<<<<<<<<<
 *                 nindices.append(current_value - 1)
 *                 face_normals.append(self.normals[current_value - 1])
 */
      if (unlikely(__pyx_v_raw_faces == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        __PYX_ERR(0, 175, __pyx_L1_error)
      }
      __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_raw_faces, 2, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 175, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_2);
      __pyx_t_7 = __Pyx_PyNumber_Int(__pyx_t_2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 175, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_7);
      __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
      __pyx_t_8 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_8 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 175, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __pyx_v_current_value = __pyx_t_8;

      /* "punyverse/_model.pyx":176
 *             if l >= 3 and raw_faces[2]:
 *                 current_value = int(raw_faces[2])
 *                 nindices.append(current_value - 1)             # <<<<<<<<<<<<<<
 *                 face_normals.append(self.normals[current_value - 1])
 * 
 */
      __pyx_t_7 = __Pyx_PyInt_From_long((__pyx_v_current_value - 1)); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 176, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_7);
      __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_nindices, __pyx_t_7); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 176, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;

      /* "punyverse/_model.pyx":177
 *                 current_value = int(raw_faces[2])
 *                 nindices.append(current_value - 1)
 *                 face_normals.append(self.normals[current_value - 1])             # <<<<<<<<<<<<<<
 * 
 *         cdef Group group
 */
      if (unlikely(__pyx_v_self->normals == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        __PYX_ERR(0, 177, __pyx_L1_error)
      }
      __pyx_t_10 = (__pyx_v_current_value - 1);
      __pyx_t_7 = __Pyx_GetItemInt_List(__pyx_v_self->normals, __pyx_t_10, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 177, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_7);
      __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_face_normals, __pyx_t_7); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 177, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;

      /* "punyverse/_model.pyx":174
 *                     tindices.append(current_value - 1)
 *                     face_textures.append(self.textures[current_value - 1])
 *             if l >= 3 and raw_faces[2]:             # <<<<<<<<<<<<<<
 *                 current_value = int(raw_faces[2])
 *                 nindices.append(current_value - 1)
 */
    }
    __pyx_L4_continue:;
  }

  /* "punyverse/_model.pyx":180
 * 
 *         cdef Group group
 *         if self.current_group is None:             # <<<<<<<<<<<<<<
 *             self.current_group = group = Group()
 *             self.groups.append(group)
 */
  __pyx_t_3 = (((PyObject *)__pyx_v_self->current_group) == Py_None);
  __pyx_t_11 = (__pyx_t_3 != 0);
  if (__pyx_t_11) {

    /* "punyverse/_model.pyx":181
 *         cdef Group group
 *         if self.current_group is None:
 *             self.current_group = group = Group()             # <<<<<<<<<<<<<<
 *             self.groups.append(group)
 *         else:
 */
    __pyx_t_7 = __Pyx_PyObject_CallNoArg(((PyObject *)__pyx_ptype_9punyverse_6_model_Group)); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 181, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_INCREF(__pyx_t_7);
    __Pyx_GIVEREF(__pyx_t_7);
    __Pyx_GOTREF(__pyx_v_self->current_group);
    __Pyx_DECREF(((PyObject *)__pyx_v_self->current_group));
    __pyx_v_self->current_group = ((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_t_7);
    __Pyx_INCREF(__pyx_t_7);
    __pyx_v_group = ((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_t_7);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;

    /* "punyverse/_model.pyx":182
 *         if self.current_group is None:
 *             self.current_group = group = Group()
 *             self.groups.append(group)             # <<<<<<<<<<<<<<
 *         else:
 *             group = self.current_group
 */
    if (unlikely(__pyx_v_self->groups == Py_None)) {
      PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append");
      __PYX_ERR(0, 182, __pyx_L1_error)
    }
    __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_self->groups, ((PyObject *)__pyx_v_group)); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 182, __pyx_L1_error)

    /* "punyverse/_model.pyx":180
 * 
 *         cdef Group group
 *         if self.current_group is None:             # <<<<<<<<<<<<<<
 *             self.current_group = group = Group()
 *             self.groups.append(group)
 */
    goto __pyx_L14;
  }

  /* "punyverse/_model.pyx":184
 *             self.groups.append(group)
 *         else:
 *             group = self.current_group             # <<<<<<<<<<<<<<
 * 
 *         group.vertices += face_vertices
 */
  /*else*/ {
    __pyx_t_7 = ((PyObject *)__pyx_v_self->current_group);
    __Pyx_INCREF(__pyx_t_7);
    __pyx_v_group = ((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_t_7);
    __pyx_t_7 = 0;
  }
  __pyx_L14:;

  /* "punyverse/_model.pyx":186
 *             group = self.current_group
 * 
 *         group.vertices += face_vertices             # <<<<<<<<<<<<<<
 *         group.normals += face_normals
 *         group.textures += face_textures
 */
  __pyx_t_7 = PyNumber_InPlaceAdd(__pyx_v_group->vertices, __pyx_v_face_vertices); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 186, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_7);
  __Pyx_GIVEREF(__pyx_t_7);
  __Pyx_GOTREF(__pyx_v_group->vertices);
  __Pyx_DECREF(__pyx_v_group->vertices);
  __pyx_v_group->vertices = ((PyObject*)__pyx_t_7);
  __pyx_t_7 = 0;

  /* "punyverse/_model.pyx":187
 * 
 *         group.vertices += face_vertices
 *         group.normals += face_normals             # <<<<<<<<<<<<<<
 *         group.textures += face_textures
 *         idx_count = group.idx_count
 */
  __pyx_t_7 = PyNumber_InPlaceAdd(__pyx_v_group->normals, __pyx_v_face_normals); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 187, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_7);
  __Pyx_GIVEREF(__pyx_t_7);
  __Pyx_GOTREF(__pyx_v_group->normals);
  __Pyx_DECREF(__pyx_v_group->normals);
  __pyx_v_group->normals = ((PyObject*)__pyx_t_7);
  __pyx_t_7 = 0;

  /* "punyverse/_model.pyx":188
 *         group.vertices += face_vertices
 *         group.normals += face_normals
 *         group.textures += face_textures             # <<<<<<<<<<<<<<
 *         idx_count = group.idx_count
 *         group.indices += (idx_count + 1, idx_count + 2, idx_count + 3)
 */
  __pyx_t_7 = PyNumber_InPlaceAdd(__pyx_v_group->textures, __pyx_v_face_textures); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 188, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_7);
  __Pyx_GIVEREF(__pyx_t_7);
  __Pyx_GOTREF(__pyx_v_group->textures);
  __Pyx_DECREF(__pyx_v_group->textures);
  __pyx_v_group->textures = ((PyObject*)__pyx_t_7);
  __pyx_t_7 = 0;

  /* "punyverse/_model.pyx":189
 *         group.normals += face_normals
 *         group.textures += face_textures
 *         idx_count = group.idx_count             # <<<<<<<<<<<<<<
 *         group.indices += (idx_count + 1, idx_count + 2, idx_count + 3)
 *         group.idx_count += 3
 */
  __pyx_t_7 = __Pyx_PyInt_From_int(__pyx_v_group->idx_count); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 189, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_7);
  __pyx_v_idx_count = __pyx_t_7;
  __pyx_t_7 = 0;

  /* "punyverse/_model.pyx":190
 *         group.textures += face_textures
 *         idx_count = group.idx_count
 *         group.indices += (idx_count + 1, idx_count + 2, idx_count + 3)             # <<<<<<<<<<<<<<
 *         group.idx_count += 3
 * 
 */
  __pyx_t_7 = __Pyx_PyInt_AddObjC(__pyx_v_idx_count, __pyx_int_1, 1, 0); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 190, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_7);
  __pyx_t_2 = __Pyx_PyInt_AddObjC(__pyx_v_idx_count, __pyx_int_2, 2, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 190, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_12 = __Pyx_PyInt_AddObjC(__pyx_v_idx_count, __pyx_int_3, 3, 0); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 190, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_12);
  __pyx_t_13 = PyTuple_New(3); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 190, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_13);
  __Pyx_GIVEREF(__pyx_t_7);
  PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_7);
  __Pyx_GIVEREF(__pyx_t_2);
  PyTuple_SET_ITEM(__pyx_t_13, 1, __pyx_t_2);
  __Pyx_GIVEREF(__pyx_t_12);
  PyTuple_SET_ITEM(__pyx_t_13, 2, __pyx_t_12);
  __pyx_t_7 = 0;
  __pyx_t_2 = 0;
  __pyx_t_12 = 0;
  __pyx_t_12 = PyNumber_InPlaceAdd(__pyx_v_group->indices, __pyx_t_13); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 190, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_12);
  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
  if (!(likely(PyList_CheckExact(__pyx_t_12))||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_t_12)->tp_name), 0))) __PYX_ERR(0, 190, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_12);
  __Pyx_GOTREF(__pyx_v_group->indices);
  __Pyx_DECREF(__pyx_v_group->indices);
  __pyx_v_group->indices = ((PyObject*)__pyx_t_12);
  __pyx_t_12 = 0;

  /* "punyverse/_model.pyx":191
 *         idx_count = group.idx_count
 *         group.indices += (idx_count + 1, idx_count + 2, idx_count + 3)
 *         group.idx_count += 3             # <<<<<<<<<<<<<<
 * 
 *         group.faces.append(Face(type, vindices, nindices, tindices, face_vertices, face_normals, face_textures))
 */
  __pyx_v_group->idx_count = (__pyx_v_group->idx_count + 3);

  /* "punyverse/_model.pyx":193
 *         group.idx_count += 3
 * 
 *         group.faces.append(Face(type, vindices, nindices, tindices, face_vertices, face_normals, face_textures))             # <<<<<<<<<<<<<<
 * 
 *     cdef bint material(self, list words) except False:
 */
  if (unlikely(__pyx_v_group->faces == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append");
    __PYX_ERR(0, 193, __pyx_L1_error)
  }
  __pyx_t_12 = __Pyx_PyInt_From_int(__pyx_v_type); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 193, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_12);
  __pyx_t_13 = PyTuple_New(7); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 193, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_13);
  __Pyx_GIVEREF(__pyx_t_12);
  PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_12);
  __Pyx_INCREF(__pyx_v_vindices);
  __Pyx_GIVEREF(__pyx_v_vindices);
  PyTuple_SET_ITEM(__pyx_t_13, 1, __pyx_v_vindices);
  __Pyx_INCREF(__pyx_v_nindices);
  __Pyx_GIVEREF(__pyx_v_nindices);
  PyTuple_SET_ITEM(__pyx_t_13, 2, __pyx_v_nindices);
  __Pyx_INCREF(__pyx_v_tindices);
  __Pyx_GIVEREF(__pyx_v_tindices);
  PyTuple_SET_ITEM(__pyx_t_13, 3, __pyx_v_tindices);
  __Pyx_INCREF(__pyx_v_face_vertices);
  __Pyx_GIVEREF(__pyx_v_face_vertices);
  PyTuple_SET_ITEM(__pyx_t_13, 4, __pyx_v_face_vertices);
  __Pyx_INCREF(__pyx_v_face_normals);
  __Pyx_GIVEREF(__pyx_v_face_normals);
  PyTuple_SET_ITEM(__pyx_t_13, 5, __pyx_v_face_normals);
  __Pyx_INCREF(__pyx_v_face_textures);
  __Pyx_GIVEREF(__pyx_v_face_textures);
  PyTuple_SET_ITEM(__pyx_t_13, 6, __pyx_v_face_textures);
  __pyx_t_12 = 0;
  __pyx_t_12 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_9punyverse_6_model_Face), __pyx_t_13, NULL); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 193, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_12);
  __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
  __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_group->faces, __pyx_t_12); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 193, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0;

  /* "punyverse/_model.pyx":145
 *         self.textures.append((x, y, z))
 * 
 *     cdef void face(self, list words):             # <<<<<<<<<<<<<<
 *         cdef int l = len(words)
 *         cdef int type = -1
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_12);
  __Pyx_XDECREF(__pyx_t_13);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.face", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_face_vertices);
  __Pyx_XDECREF(__pyx_v_face_normals);
  __Pyx_XDECREF(__pyx_v_face_textures);
  __Pyx_XDECREF(__pyx_v_raw_faces);
  __Pyx_XDECREF(__pyx_v_vindices);
  __Pyx_XDECREF(__pyx_v_nindices);
  __Pyx_XDECREF(__pyx_v_tindices);
  __Pyx_XDECREF((PyObject *)__pyx_v_group);
  __Pyx_XDECREF(__pyx_v_idx_count);
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":195
 *         group.faces.append(Face(type, vindices, nindices, tindices, face_vertices, face_normals, face_textures))
 * 
 *     cdef bint material(self, list words) except False:             # <<<<<<<<<<<<<<
 *         return self.perform_io(os.path.join(self.root, words[1]))
 * 
 */

static int __pyx_f_9punyverse_6_model_15WavefrontObject_material(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  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;
  int __pyx_t_7;
  __Pyx_RefNannySetupContext("material", 0);

  /* "punyverse/_model.pyx":196
 * 
 *     cdef bint material(self, list words) except False:
 *         return self.perform_io(os.path.join(self.root, words[1]))             # <<<<<<<<<<<<<<
 * 
 *     cdef void use_material(self, list words):
 */
  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 196, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 196, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_join); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 196, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 196, __pyx_L1_error)
  }
  __pyx_t_3 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 196, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_4 = NULL;
  __pyx_t_5 = 0;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_4)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_4);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
      __pyx_t_5 = 1;
    }
  }
  #if CYTHON_FAST_PYCALL
  if (PyFunction_Check(__pyx_t_2)) {
    PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_self->root, __pyx_t_3};
    __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 196, __pyx_L1_error)
    __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  } else
  #endif
  #if CYTHON_FAST_PYCCALL
  if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
    PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_self->root, __pyx_t_3};
    __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 196, __pyx_L1_error)
    __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  } else
  #endif
  {
    __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 196, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    if (__pyx_t_4) {
      __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL;
    }
    __Pyx_INCREF(__pyx_v_self->root);
    __Pyx_GIVEREF(__pyx_v_self->root);
    PyTuple_SET_ITEM(__pyx_t_6, 0+__pyx_t_5, __pyx_v_self->root);
    __Pyx_GIVEREF(__pyx_t_3);
    PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_t_3);
    __pyx_t_3 = 0;
    __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 196, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 196, __pyx_L1_error)
  __pyx_t_7 = __pyx_f_9punyverse_6_model_15WavefrontObject_perform_io(__pyx_v_self, ((PyObject*)__pyx_t_1)); if (unlikely(__pyx_t_7 == ((int)0))) __PYX_ERR(0, 196, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_r = __pyx_t_7;
  goto __pyx_L0;

  /* "punyverse/_model.pyx":195
 *         group.faces.append(Face(type, vindices, nindices, tindices, face_vertices, face_normals, face_textures))
 * 
 *     cdef bint material(self, list words) except False:             # <<<<<<<<<<<<<<
 *         return self.perform_io(os.path.join(self.root, words[1]))
 * 
 */

  /* function exit code */
  __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_AddTraceback("punyverse._model.WavefrontObject.material", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":198
 *         return self.perform_io(os.path.join(self.root, words[1]))
 * 
 *     cdef void use_material(self, list words):             # <<<<<<<<<<<<<<
 *         mat = words[1]
 *         try:
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_use_material(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  PyObject *__pyx_v_mat = NULL;
  __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;
  __Pyx_RefNannySetupContext("use_material", 0);

  /* "punyverse/_model.pyx":199
 * 
 *     cdef void use_material(self, list words):
 *         mat = words[1]             # <<<<<<<<<<<<<<
 *         try:
 *             self.current_group.material = self.materials[mat]
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 199, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 199, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_v_mat = __pyx_t_1;
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":200
 *     cdef void use_material(self, list words):
 *         mat = words[1]
 *         try:             # <<<<<<<<<<<<<<
 *             self.current_group.material = self.materials[mat]
 *         except KeyError:
 */
  {
    __Pyx_PyThreadState_declare
    __Pyx_PyThreadState_assign
    __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4);
    __Pyx_XGOTREF(__pyx_t_2);
    __Pyx_XGOTREF(__pyx_t_3);
    __Pyx_XGOTREF(__pyx_t_4);
    /*try:*/ {

      /* "punyverse/_model.pyx":201
 *         mat = words[1]
 *         try:
 *             self.current_group.material = self.materials[mat]             # <<<<<<<<<<<<<<
 *         except KeyError:
 *             print "Warning: material %s undefined, only %s defined." % (mat, self.materials)
 */
      if (unlikely(__pyx_v_self->materials == Py_None)) {
        PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
        __PYX_ERR(0, 201, __pyx_L3_error)
      }
      __pyx_t_1 = __Pyx_PyDict_GetItem(__pyx_v_self->materials, __pyx_v_mat); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 201, __pyx_L3_error)
      __Pyx_GOTREF(__pyx_t_1);
      if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_9punyverse_6_model_Material))))) __PYX_ERR(0, 201, __pyx_L3_error)
      __Pyx_GIVEREF(__pyx_t_1);
      __Pyx_GOTREF(__pyx_v_self->current_group->material);
      __Pyx_DECREF(((PyObject *)__pyx_v_self->current_group->material));
      __pyx_v_self->current_group->material = ((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_t_1);
      __pyx_t_1 = 0;

      /* "punyverse/_model.pyx":200
 *     cdef void use_material(self, list words):
 *         mat = words[1]
 *         try:             # <<<<<<<<<<<<<<
 *             self.current_group.material = self.materials[mat]
 *         except KeyError:
 */
    }
    __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    goto __pyx_L8_try_end;
    __pyx_L3_error:;
    __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "punyverse/_model.pyx":202
 *         try:
 *             self.current_group.material = self.materials[mat]
 *         except KeyError:             # <<<<<<<<<<<<<<
 *             print "Warning: material %s undefined, only %s defined." % (mat, self.materials)
 *         except AttributeError:
 */
    __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_KeyError);
    if (__pyx_t_5) {
      __Pyx_AddTraceback("punyverse._model.WavefrontObject.use_material", __pyx_clineno, __pyx_lineno, __pyx_filename);
      if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(0, 202, __pyx_L5_except_error)
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_GOTREF(__pyx_t_6);
      __Pyx_GOTREF(__pyx_t_7);

      /* "punyverse/_model.pyx":203
 *             self.current_group.material = self.materials[mat]
 *         except KeyError:
 *             print "Warning: material %s undefined, only %s defined." % (mat, self.materials)             # <<<<<<<<<<<<<<
 *         except AttributeError:
 *             print "Warning: no group"
 */
      __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 203, __pyx_L5_except_error)
      __Pyx_GOTREF(__pyx_t_8);
      __Pyx_INCREF(__pyx_v_mat);
      __Pyx_GIVEREF(__pyx_v_mat);
      PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_v_mat);
      __Pyx_INCREF(__pyx_v_self->materials);
      __Pyx_GIVEREF(__pyx_v_self->materials);
      PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_v_self->materials);
      __pyx_t_9 = __Pyx_PyString_Format(__pyx_kp_s_Warning_material_s_undefined_onl, __pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 203, __pyx_L5_except_error)
      __Pyx_GOTREF(__pyx_t_9);
      __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
      if (__Pyx_PrintOne(0, __pyx_t_9) < 0) __PYX_ERR(0, 203, __pyx_L5_except_error)
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      goto __pyx_L4_exception_handled;
    }

    /* "punyverse/_model.pyx":204
 *         except KeyError:
 *             print "Warning: material %s undefined, only %s defined." % (mat, self.materials)
 *         except AttributeError:             # <<<<<<<<<<<<<<
 *             print "Warning: no group"
 * 
 */
    __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError);
    if (__pyx_t_5) {
      __Pyx_AddTraceback("punyverse._model.WavefrontObject.use_material", __pyx_clineno, __pyx_lineno, __pyx_filename);
      if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_6, &__pyx_t_1) < 0) __PYX_ERR(0, 204, __pyx_L5_except_error)
      __Pyx_GOTREF(__pyx_t_7);
      __Pyx_GOTREF(__pyx_t_6);
      __Pyx_GOTREF(__pyx_t_1);

      /* "punyverse/_model.pyx":205
 *             print "Warning: material %s undefined, only %s defined." % (mat, self.materials)
 *         except AttributeError:
 *             print "Warning: no group"             # <<<<<<<<<<<<<<
 * 
 *     cdef void group(self, list words):
 */
      if (__Pyx_PrintOne(0, __pyx_kp_s_Warning_no_group) < 0) __PYX_ERR(0, 205, __pyx_L5_except_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      goto __pyx_L4_exception_handled;
    }
    goto __pyx_L5_except_error;
    __pyx_L5_except_error:;

    /* "punyverse/_model.pyx":200
 *     cdef void use_material(self, list words):
 *         mat = words[1]
 *         try:             # <<<<<<<<<<<<<<
 *             self.current_group.material = self.materials[mat]
 *         except KeyError:
 */
    __Pyx_XGIVEREF(__pyx_t_2);
    __Pyx_XGIVEREF(__pyx_t_3);
    __Pyx_XGIVEREF(__pyx_t_4);
    __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
    goto __pyx_L1_error;
    __pyx_L4_exception_handled:;
    __Pyx_XGIVEREF(__pyx_t_2);
    __Pyx_XGIVEREF(__pyx_t_3);
    __Pyx_XGIVEREF(__pyx_t_4);
    __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
    __pyx_L8_try_end:;
  }

  /* "punyverse/_model.pyx":198
 *         return self.perform_io(os.path.join(self.root, words[1]))
 * 
 *     cdef void use_material(self, list words):             # <<<<<<<<<<<<<<
 *         mat = words[1]
 *         try:
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.use_material", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_mat);
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":207
 *             print "Warning: no group"
 * 
 *     cdef void group(self, list words):             # <<<<<<<<<<<<<<
 *         name = words[1]
 *         group = Group(name)
 */

static void __pyx_f_9punyverse_6_model_15WavefrontObject_group(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_words) {
  PyObject *__pyx_v_name = NULL;
  struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_group = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  __Pyx_RefNannySetupContext("group", 0);

  /* "punyverse/_model.pyx":208
 * 
 *     cdef void group(self, list words):
 *         name = words[1]             # <<<<<<<<<<<<<<
 *         group = Group(name)
 * 
 */
  if (unlikely(__pyx_v_words == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 208, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_List(__pyx_v_words, 1, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 208, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_v_name = __pyx_t_1;
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":209
 *     cdef void group(self, list words):
 *         name = words[1]
 *         group = Group(name)             # <<<<<<<<<<<<<<
 * 
 *         if self.groups:
 */
  __pyx_t_1 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_9punyverse_6_model_Group), __pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 209, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_v_group = ((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":211
 *         group = Group(name)
 * 
 *         if self.groups:             # <<<<<<<<<<<<<<
 *             self.current_group.pack()
 *         self.groups.append(group)
 */
  __pyx_t_2 = (__pyx_v_self->groups != Py_None)&&(PyList_GET_SIZE(__pyx_v_self->groups) != 0);
  if (__pyx_t_2) {

    /* "punyverse/_model.pyx":212
 * 
 *         if self.groups:
 *             self.current_group.pack()             # <<<<<<<<<<<<<<
 *         self.groups.append(group)
 *         self.current_group = group
 */
    __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->current_group), __pyx_n_s_pack); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 212, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = NULL;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) {
      __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
      if (likely(__pyx_t_4)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
        __Pyx_INCREF(__pyx_t_4);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_3, function);
      }
    }
    if (__pyx_t_4) {
      __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 212, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    } else {
      __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 212, __pyx_L1_error)
    }
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "punyverse/_model.pyx":211
 *         group = Group(name)
 * 
 *         if self.groups:             # <<<<<<<<<<<<<<
 *             self.current_group.pack()
 *         self.groups.append(group)
 */
  }

  /* "punyverse/_model.pyx":213
 *         if self.groups:
 *             self.current_group.pack()
 *         self.groups.append(group)             # <<<<<<<<<<<<<<
 *         self.current_group = group
 * 
 */
  if (unlikely(__pyx_v_self->groups == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append");
    __PYX_ERR(0, 213, __pyx_L1_error)
  }
  __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_self->groups, ((PyObject *)__pyx_v_group)); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 213, __pyx_L1_error)

  /* "punyverse/_model.pyx":214
 *             self.current_group.pack()
 *         self.groups.append(group)
 *         self.current_group = group             # <<<<<<<<<<<<<<
 * 
 *     cdef inline bint perform_io(self, unicode file) except False:
 */
  __Pyx_INCREF(((PyObject *)__pyx_v_group));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_group));
  __Pyx_GOTREF(__pyx_v_self->current_group);
  __Pyx_DECREF(((PyObject *)__pyx_v_self->current_group));
  __pyx_v_self->current_group = __pyx_v_group;

  /* "punyverse/_model.pyx":207
 *             print "Warning: no group"
 * 
 *     cdef void group(self, list words):             # <<<<<<<<<<<<<<
 *         name = words[1]
 *         group = Group(name)
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_WriteUnraisable("punyverse._model.WavefrontObject.group", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_name);
  __Pyx_XDECREF((PyObject *)__pyx_v_group);
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":216
 *         self.current_group = group
 * 
 *     cdef inline bint perform_io(self, unicode file) except False:             # <<<<<<<<<<<<<<
 *         cdef const char *type
 *         cdef list words
 */

static CYTHON_INLINE int __pyx_f_9punyverse_6_model_15WavefrontObject_perform_io(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_file) {
  char const *__pyx_v_type;
  PyObject *__pyx_v_words = 0;
  int __pyx_v_hash;
  int __pyx_v_length;
  PyObject *__pyx_v_ext = NULL;
  PyObject *__pyx_v_reader = NULL;
  PyObject *__pyx_v_buf = 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;
  Py_ssize_t __pyx_t_11;
  PyObject *(*__pyx_t_12)(PyObject *);
  int __pyx_t_13;
  int __pyx_t_14;
  int __pyx_t_15;
  char const *__pyx_t_16;
  PyObject *__pyx_t_17 = NULL;
  __Pyx_RefNannySetupContext("perform_io", 0);

  /* "punyverse/_model.pyx":221
 *         cdef int hash, length
 * 
 *         ext = os.path.splitext(file)[1].lstrip('.')             # <<<<<<<<<<<<<<
 *         reader = openers.get(ext, open)(file)
 *         with reader:
 */
  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_path); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_splitext); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_3 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_3)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_3);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (!__pyx_t_3) {
    __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_file); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 221, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_3, __pyx_v_file};
      __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 221, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_3, __pyx_v_file};
      __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 221, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else
    #endif
    {
      __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 221, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
      __Pyx_INCREF(__pyx_v_file);
      __Pyx_GIVEREF(__pyx_v_file);
      PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_file);
      __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 221, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_GetItemInt(__pyx_t_1, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_lstrip); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_ext = __pyx_t_2;
  __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":222
 * 
 *         ext = os.path.splitext(file)[1].lstrip('.')
 *         reader = openers.get(ext, open)(file)             # <<<<<<<<<<<<<<
 *         with reader:
 *             for buf in reader:
 */
  __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_openers); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 222, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_get); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 222, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_4 = NULL;
  __pyx_t_5 = 0;
  if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
    __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
    if (likely(__pyx_t_4)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
      __Pyx_INCREF(__pyx_t_4);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_3, function);
      __pyx_t_5 = 1;
    }
  }
  #if CYTHON_FAST_PYCALL
  if (PyFunction_Check(__pyx_t_3)) {
    PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_ext, __pyx_builtin_open};
    __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 222, __pyx_L1_error)
    __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_GOTREF(__pyx_t_1);
  } else
  #endif
  #if CYTHON_FAST_PYCCALL
  if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
    PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_v_ext, __pyx_builtin_open};
    __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 222, __pyx_L1_error)
    __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_GOTREF(__pyx_t_1);
  } else
  #endif
  {
    __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 222, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    if (__pyx_t_4) {
      __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL;
    }
    __Pyx_INCREF(__pyx_v_ext);
    __Pyx_GIVEREF(__pyx_v_ext);
    PyTuple_SET_ITEM(__pyx_t_6, 0+__pyx_t_5, __pyx_v_ext);
    __Pyx_INCREF(__pyx_builtin_open);
    __Pyx_GIVEREF(__pyx_builtin_open);
    PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_builtin_open);
    __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 222, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  }
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  __pyx_t_3 = NULL;
  if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
    __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
    if (likely(__pyx_t_3)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
      __Pyx_INCREF(__pyx_t_3);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_1, function);
    }
  }
  if (!__pyx_t_3) {
    __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_file); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 222, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_1)) {
      PyObject *__pyx_temp[2] = {__pyx_t_3, __pyx_v_file};
      __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 222, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
      __Pyx_GOTREF(__pyx_t_2);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
      PyObject *__pyx_temp[2] = {__pyx_t_3, __pyx_v_file};
      __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 222, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
      __Pyx_GOTREF(__pyx_t_2);
    } else
    #endif
    {
      __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 222, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_6);
      __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_3); __pyx_t_3 = NULL;
      __Pyx_INCREF(__pyx_v_file);
      __Pyx_GIVEREF(__pyx_v_file);
      PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_v_file);
      __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 222, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_2);
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v_reader = __pyx_t_2;
  __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":223
 *         ext = os.path.splitext(file)[1].lstrip('.')
 *         reader = openers.get(ext, open)(file)
 *         with reader:             # <<<<<<<<<<<<<<
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 */
  /*with:*/ {
    __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_v_reader, __pyx_n_s_exit); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 223, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_1 = __Pyx_PyObject_LookupSpecial(__pyx_v_reader, __pyx_n_s_enter); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 223, __pyx_L3_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_6 = NULL;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) {
      __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_1);
      if (likely(__pyx_t_6)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
        __Pyx_INCREF(__pyx_t_6);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_1, function);
      }
    }
    if (__pyx_t_6) {
      __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 223, __pyx_L3_error)
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    } else {
      __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 223, __pyx_L3_error)
    }
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    /*try:*/ {
      {
        __Pyx_PyThreadState_declare
        __Pyx_PyThreadState_assign
        __Pyx_ExceptionSave(&__pyx_t_8, &__pyx_t_9, &__pyx_t_10);
        __Pyx_XGOTREF(__pyx_t_8);
        __Pyx_XGOTREF(__pyx_t_9);
        __Pyx_XGOTREF(__pyx_t_10);
        /*try:*/ {

          /* "punyverse/_model.pyx":224
 *         reader = openers.get(ext, open)(file)
 *         with reader:
 *             for buf in reader:             # <<<<<<<<<<<<<<
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 *                     continue # Empty or comment
 */
          if (likely(PyList_CheckExact(__pyx_v_reader)) || PyTuple_CheckExact(__pyx_v_reader)) {
            __pyx_t_2 = __pyx_v_reader; __Pyx_INCREF(__pyx_t_2); __pyx_t_11 = 0;
            __pyx_t_12 = NULL;
          } else {
            __pyx_t_11 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_reader); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 224, __pyx_L7_error)
            __Pyx_GOTREF(__pyx_t_2);
            __pyx_t_12 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 224, __pyx_L7_error)
          }
          for (;;) {
            if (likely(!__pyx_t_12)) {
              if (likely(PyList_CheckExact(__pyx_t_2))) {
                if (__pyx_t_11 >= PyList_GET_SIZE(__pyx_t_2)) break;
                #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
                __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_11); __Pyx_INCREF(__pyx_t_1); __pyx_t_11++; if (unlikely(0 < 0)) __PYX_ERR(0, 224, __pyx_L7_error)
                #else
                __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_11); __pyx_t_11++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 224, __pyx_L7_error)
                __Pyx_GOTREF(__pyx_t_1);
                #endif
              } else {
                if (__pyx_t_11 >= PyTuple_GET_SIZE(__pyx_t_2)) break;
                #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
                __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_11); __Pyx_INCREF(__pyx_t_1); __pyx_t_11++; if (unlikely(0 < 0)) __PYX_ERR(0, 224, __pyx_L7_error)
                #else
                __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_11); __pyx_t_11++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 224, __pyx_L7_error)
                __Pyx_GOTREF(__pyx_t_1);
                #endif
              }
            } else {
              __pyx_t_1 = __pyx_t_12(__pyx_t_2);
              if (unlikely(!__pyx_t_1)) {
                PyObject* exc_type = PyErr_Occurred();
                if (exc_type) {
                  if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
                  else __PYX_ERR(0, 224, __pyx_L7_error)
                }
                break;
              }
              __Pyx_GOTREF(__pyx_t_1);
            }
            __Pyx_XDECREF_SET(__pyx_v_buf, __pyx_t_1);
            __pyx_t_1 = 0;

            /* "punyverse/_model.pyx":225
 *         with reader:
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):             # <<<<<<<<<<<<<<
 *                     continue # Empty or comment
 *                 words = buf.split()
 */
            __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_v_buf); if (unlikely(__pyx_t_14 < 0)) __PYX_ERR(0, 225, __pyx_L7_error)
            __pyx_t_15 = ((!__pyx_t_14) != 0);
            if (!__pyx_t_15) {
            } else {
              __pyx_t_13 = __pyx_t_15;
              goto __pyx_L16_bool_binop_done;
            }
            __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_buf, __pyx_n_s_startswith); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 225, __pyx_L7_error)
            __Pyx_GOTREF(__pyx_t_1);
            __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__12, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 225, __pyx_L7_error)
            __Pyx_GOTREF(__pyx_t_6);
            __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
            __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_15 < 0)) __PYX_ERR(0, 225, __pyx_L7_error)
            __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
            __pyx_t_13 = __pyx_t_15;
            __pyx_L16_bool_binop_done:;
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":226
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 *                     continue # Empty or comment             # <<<<<<<<<<<<<<
 *                 words = buf.split()
 *                 type = words[0]
 */
              goto __pyx_L13_continue;

              /* "punyverse/_model.pyx":225
 *         with reader:
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):             # <<<<<<<<<<<<<<
 *                     continue # Empty or comment
 *                 words = buf.split()
 */
            }

            /* "punyverse/_model.pyx":227
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 *                     continue # Empty or comment
 *                 words = buf.split()             # <<<<<<<<<<<<<<
 *                 type = words[0]
 * 
 */
            __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_buf, __pyx_n_s_split); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 227, __pyx_L7_error)
            __Pyx_GOTREF(__pyx_t_1);
            __pyx_t_3 = NULL;
            if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) {
              __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
              if (likely(__pyx_t_3)) {
                PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
                __Pyx_INCREF(__pyx_t_3);
                __Pyx_INCREF(function);
                __Pyx_DECREF_SET(__pyx_t_1, function);
              }
            }
            if (__pyx_t_3) {
              __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_3); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 227, __pyx_L7_error)
              __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
            } else {
              __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 227, __pyx_L7_error)
            }
            __Pyx_GOTREF(__pyx_t_6);
            __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
            if (!(likely(PyList_CheckExact(__pyx_t_6))||((__pyx_t_6) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_t_6)->tp_name), 0))) __PYX_ERR(0, 227, __pyx_L7_error)
            __Pyx_XDECREF_SET(__pyx_v_words, ((PyObject*)__pyx_t_6));
            __pyx_t_6 = 0;

            /* "punyverse/_model.pyx":228
 *                     continue # Empty or comment
 *                 words = buf.split()
 *                 type = words[0]             # <<<<<<<<<<<<<<
 * 
 *                 length = strlen(type)
 */
            if (unlikely(__pyx_v_words == Py_None)) {
              PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
              __PYX_ERR(0, 228, __pyx_L7_error)
            }
            __pyx_t_6 = __Pyx_GetItemInt_List(__pyx_v_words, 0, long, 1, __Pyx_PyInt_From_long, 1, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 228, __pyx_L7_error)
            __Pyx_GOTREF(__pyx_t_6);
            __pyx_t_16 = __Pyx_PyObject_AsString(__pyx_t_6); if (unlikely((!__pyx_t_16) && PyErr_Occurred())) __PYX_ERR(0, 228, __pyx_L7_error)
            __pyx_v_type = __pyx_t_16;
            __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;

            /* "punyverse/_model.pyx":230
 *                 type = words[0]
 * 
 *                 length = strlen(type)             # <<<<<<<<<<<<<<
 *                 if not length:
 *                     continue
 */
            __pyx_v_length = strlen(__pyx_v_type);

            /* "punyverse/_model.pyx":231
 * 
 *                 length = strlen(type)
 *                 if not length:             # <<<<<<<<<<<<<<
 *                     continue
 *                 elif length < 3:
 */
            __pyx_t_13 = ((!(__pyx_v_length != 0)) != 0);
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":232
 *                 length = strlen(type)
 *                 if not length:
 *                     continue             # <<<<<<<<<<<<<<
 *                 elif length < 3:
 *                     hash = type[0] << 8 | type[1]
 */
              goto __pyx_L13_continue;

              /* "punyverse/_model.pyx":231
 * 
 *                 length = strlen(type)
 *                 if not length:             # <<<<<<<<<<<<<<
 *                     continue
 *                 elif length < 3:
 */
            }

            /* "punyverse/_model.pyx":233
 *                 if not length:
 *                     continue
 *                 elif length < 3:             # <<<<<<<<<<<<<<
 *                     hash = type[0] << 8 | type[1]
 *                     if hash == 0x7600:  # v\0
 */
            __pyx_t_13 = ((__pyx_v_length < 3) != 0);
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":234
 *                     continue
 *                 elif length < 3:
 *                     hash = type[0] << 8 | type[1]             # <<<<<<<<<<<<<<
 *                     if hash == 0x7600:  # v\0
 *                         self.vertex(words)
 */
              __pyx_v_hash = (((__pyx_v_type[0]) << 8) | (__pyx_v_type[1]));

              /* "punyverse/_model.pyx":235
 *                 elif length < 3:
 *                     hash = type[0] << 8 | type[1]
 *                     if hash == 0x7600:  # v\0             # <<<<<<<<<<<<<<
 *                         self.vertex(words)
 *                     elif hash == 0x766e: # vn
 */
              switch (__pyx_v_hash) {
                case 0x7600:

                /* "punyverse/_model.pyx":236
 *                     hash = type[0] << 8 | type[1]
 *                     if hash == 0x7600:  # v\0
 *                         self.vertex(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x766e: # vn
 *                         self.normal(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->vertex(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":235
 *                 elif length < 3:
 *                     hash = type[0] << 8 | type[1]
 *                     if hash == 0x7600:  # v\0             # <<<<<<<<<<<<<<
 *                         self.vertex(words)
 *                     elif hash == 0x766e: # vn
 */
                break;

                /* "punyverse/_model.pyx":237
 *                     if hash == 0x7600:  # v\0
 *                         self.vertex(words)
 *                     elif hash == 0x766e: # vn             # <<<<<<<<<<<<<<
 *                         self.normal(words)
 *                     elif hash == 0x7674: # vt
 */
                case 0x766e:

                /* "punyverse/_model.pyx":238
 *                         self.vertex(words)
 *                     elif hash == 0x766e: # vn
 *                         self.normal(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x7674: # vt
 *                         self.texture(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->normal(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":237
 *                     if hash == 0x7600:  # v\0
 *                         self.vertex(words)
 *                     elif hash == 0x766e: # vn             # <<<<<<<<<<<<<<
 *                         self.normal(words)
 *                     elif hash == 0x7674: # vt
 */
                break;

                /* "punyverse/_model.pyx":239
 *                     elif hash == 0x766e: # vn
 *                         self.normal(words)
 *                     elif hash == 0x7674: # vt             # <<<<<<<<<<<<<<
 *                         self.texture(words)
 *                     elif hash == 0x6600: # f
 */
                case 0x7674:

                /* "punyverse/_model.pyx":240
 *                         self.normal(words)
 *                     elif hash == 0x7674: # vt
 *                         self.texture(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x6600: # f
 *                         self.face(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->texture(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":239
 *                     elif hash == 0x766e: # vn
 *                         self.normal(words)
 *                     elif hash == 0x7674: # vt             # <<<<<<<<<<<<<<
 *                         self.texture(words)
 *                     elif hash == 0x6600: # f
 */
                break;

                /* "punyverse/_model.pyx":241
 *                     elif hash == 0x7674: # vt
 *                         self.texture(words)
 *                     elif hash == 0x6600: # f             # <<<<<<<<<<<<<<
 *                         self.face(words)
 *                     elif hash == 0x6700: # g
 */
                case 0x6600:

                /* "punyverse/_model.pyx":242
 *                         self.texture(words)
 *                     elif hash == 0x6600: # f
 *                         self.face(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x6700: # g
 *                         self.group(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->face(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":241
 *                     elif hash == 0x7674: # vt
 *                         self.texture(words)
 *                     elif hash == 0x6600: # f             # <<<<<<<<<<<<<<
 *                         self.face(words)
 *                     elif hash == 0x6700: # g
 */
                break;

                /* "punyverse/_model.pyx":243
 *                     elif hash == 0x6600: # f
 *                         self.face(words)
 *                     elif hash == 0x6700: # g             # <<<<<<<<<<<<<<
 *                         self.group(words)
 *                     elif hash == 0x6f00: # o
 */
                case 0x6700:

                /* "punyverse/_model.pyx":244
 *                         self.face(words)
 *                     elif hash == 0x6700: # g
 *                         self.group(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x6f00: # o
 *                         self.group(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->group(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":243
 *                     elif hash == 0x6600: # f
 *                         self.face(words)
 *                     elif hash == 0x6700: # g             # <<<<<<<<<<<<<<
 *                         self.group(words)
 *                     elif hash == 0x6f00: # o
 */
                break;

                /* "punyverse/_model.pyx":245
 *                     elif hash == 0x6700: # g
 *                         self.group(words)
 *                     elif hash == 0x6f00: # o             # <<<<<<<<<<<<<<
 *                         self.group(words)
 *                     elif hash == 0x4b61: # Ka
 */
                case 0x6f00:

                /* "punyverse/_model.pyx":246
 *                         self.group(words)
 *                     elif hash == 0x6f00: # o
 *                         self.group(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x4b61: # Ka
 *                         self.Ka(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->group(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":245
 *                     elif hash == 0x6700: # g
 *                         self.group(words)
 *                     elif hash == 0x6f00: # o             # <<<<<<<<<<<<<<
 *                         self.group(words)
 *                     elif hash == 0x4b61: # Ka
 */
                break;

                /* "punyverse/_model.pyx":247
 *                     elif hash == 0x6f00: # o
 *                         self.group(words)
 *                     elif hash == 0x4b61: # Ka             # <<<<<<<<<<<<<<
 *                         self.Ka(words)
 *                     elif hash == 0x4b64: # Kd
 */
                case 0x4b61:

                /* "punyverse/_model.pyx":248
 *                         self.group(words)
 *                     elif hash == 0x4b61: # Ka
 *                         self.Ka(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x4b64: # Kd
 *                         self.Kd(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->Ka(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":247
 *                     elif hash == 0x6f00: # o
 *                         self.group(words)
 *                     elif hash == 0x4b61: # Ka             # <<<<<<<<<<<<<<
 *                         self.Ka(words)
 *                     elif hash == 0x4b64: # Kd
 */
                break;

                /* "punyverse/_model.pyx":249
 *                     elif hash == 0x4b61: # Ka
 *                         self.Ka(words)
 *                     elif hash == 0x4b64: # Kd             # <<<<<<<<<<<<<<
 *                         self.Kd(words)
 *                     elif hash == 0x4b73: # Ks
 */
                case 0x4b64:

                /* "punyverse/_model.pyx":250
 *                         self.Ka(words)
 *                     elif hash == 0x4b64: # Kd
 *                         self.Kd(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x4b73: # Ks
 *                         self.Ks(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->Kd(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":249
 *                     elif hash == 0x4b61: # Ka
 *                         self.Ka(words)
 *                     elif hash == 0x4b64: # Kd             # <<<<<<<<<<<<<<
 *                         self.Kd(words)
 *                     elif hash == 0x4b73: # Ks
 */
                break;

                /* "punyverse/_model.pyx":251
 *                     elif hash == 0x4b64: # Kd
 *                         self.Kd(words)
 *                     elif hash == 0x4b73: # Ks             # <<<<<<<<<<<<<<
 *                         self.Ks(words)
 *                     elif hash == 0x4e73: # Ns
 */
                case 0x4b73:

                /* "punyverse/_model.pyx":252
 *                         self.Kd(words)
 *                     elif hash == 0x4b73: # Ks
 *                         self.Ks(words)             # <<<<<<<<<<<<<<
 *                     elif hash == 0x4e73: # Ns
 *                         self.material_shininess(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->Ks(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":251
 *                     elif hash == 0x4b64: # Kd
 *                         self.Kd(words)
 *                     elif hash == 0x4b73: # Ks             # <<<<<<<<<<<<<<
 *                         self.Ks(words)
 *                     elif hash == 0x4e73: # Ns
 */
                break;

                /* "punyverse/_model.pyx":253
 *                     elif hash == 0x4b73: # Ks
 *                         self.Ks(words)
 *                     elif hash == 0x4e73: # Ns             # <<<<<<<<<<<<<<
 *                         self.material_shininess(words)
 *                 elif strcmp(type, b'mtllib') == 0:
 */
                case 0x4e73:

                /* "punyverse/_model.pyx":254
 *                         self.Ks(words)
 *                     elif hash == 0x4e73: # Ns
 *                         self.material_shininess(words)             # <<<<<<<<<<<<<<
 *                 elif strcmp(type, b'mtllib') == 0:
 *                     self.material(words)
 */
                ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->material_shininess(__pyx_v_self, __pyx_v_words);

                /* "punyverse/_model.pyx":253
 *                     elif hash == 0x4b73: # Ks
 *                         self.Ks(words)
 *                     elif hash == 0x4e73: # Ns             # <<<<<<<<<<<<<<
 *                         self.material_shininess(words)
 *                 elif strcmp(type, b'mtllib') == 0:
 */
                break;
                default: break;
              }

              /* "punyverse/_model.pyx":233
 *                 if not length:
 *                     continue
 *                 elif length < 3:             # <<<<<<<<<<<<<<
 *                     hash = type[0] << 8 | type[1]
 *                     if hash == 0x7600:  # v\0
 */
              goto __pyx_L18;
            }

            /* "punyverse/_model.pyx":255
 *                     elif hash == 0x4e73: # Ns
 *                         self.material_shininess(words)
 *                 elif strcmp(type, b'mtllib') == 0:             # <<<<<<<<<<<<<<
 *                     self.material(words)
 *                 elif strcmp(type, b'usemtl') == 0:
 */
            __pyx_t_13 = ((strcmp(__pyx_v_type, ((char const *)"mtllib")) == 0) != 0);
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":256
 *                         self.material_shininess(words)
 *                 elif strcmp(type, b'mtllib') == 0:
 *                     self.material(words)             # <<<<<<<<<<<<<<
 *                 elif strcmp(type, b'usemtl') == 0:
 *                     self.use_material(words)
 */
              __pyx_t_13 = ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->material(__pyx_v_self, __pyx_v_words); if (unlikely(__pyx_t_13 == ((int)0))) __PYX_ERR(0, 256, __pyx_L7_error)

              /* "punyverse/_model.pyx":255
 *                     elif hash == 0x4e73: # Ns
 *                         self.material_shininess(words)
 *                 elif strcmp(type, b'mtllib') == 0:             # <<<<<<<<<<<<<<
 *                     self.material(words)
 *                 elif strcmp(type, b'usemtl') == 0:
 */
              goto __pyx_L18;
            }

            /* "punyverse/_model.pyx":257
 *                 elif strcmp(type, b'mtllib') == 0:
 *                     self.material(words)
 *                 elif strcmp(type, b'usemtl') == 0:             # <<<<<<<<<<<<<<
 *                     self.use_material(words)
 *                 elif strcmp(type, b'newmtl') == 0:
 */
            __pyx_t_13 = ((strcmp(__pyx_v_type, ((char const *)"usemtl")) == 0) != 0);
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":258
 *                     self.material(words)
 *                 elif strcmp(type, b'usemtl') == 0:
 *                     self.use_material(words)             # <<<<<<<<<<<<<<
 *                 elif strcmp(type, b'newmtl') == 0:
 *                     self.new_material(words)
 */
              ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->use_material(__pyx_v_self, __pyx_v_words);

              /* "punyverse/_model.pyx":257
 *                 elif strcmp(type, b'mtllib') == 0:
 *                     self.material(words)
 *                 elif strcmp(type, b'usemtl') == 0:             # <<<<<<<<<<<<<<
 *                     self.use_material(words)
 *                 elif strcmp(type, b'newmtl') == 0:
 */
              goto __pyx_L18;
            }

            /* "punyverse/_model.pyx":259
 *                 elif strcmp(type, b'usemtl') == 0:
 *                     self.use_material(words)
 *                 elif strcmp(type, b'newmtl') == 0:             # <<<<<<<<<<<<<<
 *                     self.new_material(words)
 *                 elif strcmp(type, b'map_Kd') == 0:
 */
            __pyx_t_13 = ((strcmp(__pyx_v_type, ((char const *)"newmtl")) == 0) != 0);
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":260
 *                     self.use_material(words)
 *                 elif strcmp(type, b'newmtl') == 0:
 *                     self.new_material(words)             # <<<<<<<<<<<<<<
 *                 elif strcmp(type, b'map_Kd') == 0:
 *                     self.material_texture(words)
 */
              ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->new_material(__pyx_v_self, __pyx_v_words);

              /* "punyverse/_model.pyx":259
 *                 elif strcmp(type, b'usemtl') == 0:
 *                     self.use_material(words)
 *                 elif strcmp(type, b'newmtl') == 0:             # <<<<<<<<<<<<<<
 *                     self.new_material(words)
 *                 elif strcmp(type, b'map_Kd') == 0:
 */
              goto __pyx_L18;
            }

            /* "punyverse/_model.pyx":261
 *                 elif strcmp(type, b'newmtl') == 0:
 *                     self.new_material(words)
 *                 elif strcmp(type, b'map_Kd') == 0:             # <<<<<<<<<<<<<<
 *                     self.material_texture(words)
 *         return True
 */
            __pyx_t_13 = ((strcmp(__pyx_v_type, ((char const *)"map_Kd")) == 0) != 0);
            if (__pyx_t_13) {

              /* "punyverse/_model.pyx":262
 *                     self.new_material(words)
 *                 elif strcmp(type, b'map_Kd') == 0:
 *                     self.material_texture(words)             # <<<<<<<<<<<<<<
 *         return True
 * 
 */
              ((struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject *)__pyx_v_self->__pyx_vtab)->material_texture(__pyx_v_self, __pyx_v_words);

              /* "punyverse/_model.pyx":261
 *                 elif strcmp(type, b'newmtl') == 0:
 *                     self.new_material(words)
 *                 elif strcmp(type, b'map_Kd') == 0:             # <<<<<<<<<<<<<<
 *                     self.material_texture(words)
 *         return True
 */
            }
            __pyx_L18:;

            /* "punyverse/_model.pyx":224
 *         reader = openers.get(ext, open)(file)
 *         with reader:
 *             for buf in reader:             # <<<<<<<<<<<<<<
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 *                     continue # Empty or comment
 */
            __pyx_L13_continue:;
          }
          __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

          /* "punyverse/_model.pyx":223
 *         ext = os.path.splitext(file)[1].lstrip('.')
 *         reader = openers.get(ext, open)(file)
 *         with reader:             # <<<<<<<<<<<<<<
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 */
        }
        __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
        goto __pyx_L12_try_end;
        __pyx_L7_error:;
        __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
        __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
        __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
        __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
        __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
        /*except:*/ {
          __Pyx_AddTraceback("punyverse._model.WavefrontObject.perform_io", __pyx_clineno, __pyx_lineno, __pyx_filename);
          if (__Pyx_GetException(&__pyx_t_2, &__pyx_t_6, &__pyx_t_1) < 0) __PYX_ERR(0, 223, __pyx_L9_except_error)
          __Pyx_GOTREF(__pyx_t_2);
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_GOTREF(__pyx_t_1);
          __pyx_t_3 = PyTuple_Pack(3, __pyx_t_2, __pyx_t_6, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 223, __pyx_L9_except_error)
          __Pyx_GOTREF(__pyx_t_3);
          __pyx_t_17 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_3, NULL);
          __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
          __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
          if (unlikely(!__pyx_t_17)) __PYX_ERR(0, 223, __pyx_L9_except_error)
          __Pyx_GOTREF(__pyx_t_17);
          __pyx_t_13 = __Pyx_PyObject_IsTrue(__pyx_t_17);
          __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0;
          if (__pyx_t_13 < 0) __PYX_ERR(0, 223, __pyx_L9_except_error)
          __pyx_t_15 = ((!(__pyx_t_13 != 0)) != 0);
          if (__pyx_t_15) {
            __Pyx_GIVEREF(__pyx_t_2);
            __Pyx_GIVEREF(__pyx_t_6);
            __Pyx_XGIVEREF(__pyx_t_1);
            __Pyx_ErrRestoreWithState(__pyx_t_2, __pyx_t_6, __pyx_t_1);
            __pyx_t_2 = 0; __pyx_t_6 = 0; __pyx_t_1 = 0; 
            __PYX_ERR(0, 223, __pyx_L9_except_error)
          }
          __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
          __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
          __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
          goto __pyx_L8_exception_handled;
        }
        __pyx_L9_except_error:;
        __Pyx_XGIVEREF(__pyx_t_8);
        __Pyx_XGIVEREF(__pyx_t_9);
        __Pyx_XGIVEREF(__pyx_t_10);
        __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
        goto __pyx_L1_error;
        __pyx_L8_exception_handled:;
        __Pyx_XGIVEREF(__pyx_t_8);
        __Pyx_XGIVEREF(__pyx_t_9);
        __Pyx_XGIVEREF(__pyx_t_10);
        __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10);
        __pyx_L12_try_end:;
      }
    }
    /*finally:*/ {
      /*normal exit:*/{
        if (__pyx_t_7) {
          __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__13, NULL);
          __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
          if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 223, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_10);
          __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
        }
        goto __pyx_L6;
      }
      __pyx_L6:;
    }
    goto __pyx_L22;
    __pyx_L3_error:;
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    goto __pyx_L1_error;
    __pyx_L22:;
  }

  /* "punyverse/_model.pyx":263
 *                 elif strcmp(type, b'map_Kd') == 0:
 *                     self.material_texture(words)
 *         return True             # <<<<<<<<<<<<<<
 * 
 * model_base = None
 */
  __pyx_r = 1;
  goto __pyx_L0;

  /* "punyverse/_model.pyx":216
 *         self.current_group = group
 * 
 *     cdef inline bint perform_io(self, unicode file) except False:             # <<<<<<<<<<<<<<
 *         cdef const char *type
 *         cdef list words
 */

  /* function exit code */
  __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_AddTraceback("punyverse._model.WavefrontObject.perform_io", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_words);
  __Pyx_XDECREF(__pyx_v_ext);
  __Pyx_XDECREF(__pyx_v_reader);
  __Pyx_XDECREF(__pyx_v_buf);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":89
 * cdef class WavefrontObject(object):
 *     cdef unicode root
 *     cdef public list vertices, normals, textures, groups             # <<<<<<<<<<<<<<
 *     cdef public dict materials
 *     cdef unicode path
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices___get__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->vertices);
  __pyx_r = __pyx_v_self->vertices;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_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_9punyverse_6_model_15WavefrontObject_8vertices_2__set__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 89, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.vertices.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices_4__del__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8vertices_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->vertices);
  __Pyx_DECREF(__pyx_v_self->vertices);
  __pyx_v_self->vertices = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals___get__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_7normals___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->normals);
  __pyx_r = __pyx_v_self->normals;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals_2__set__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 89, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.normals.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals_4__del__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_7normals_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->normals);
  __Pyx_DECREF(__pyx_v_self->normals);
  __pyx_v_self->normals = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures___get__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_8textures___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->textures);
  __pyx_r = __pyx_v_self->textures;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures_2__set__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 89, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.textures.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures_4__del__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_8textures_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->textures);
  __Pyx_DECREF(__pyx_v_self->textures);
  __pyx_v_self->textures = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups___get__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_6groups___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->groups);
  __pyx_r = __pyx_v_self->groups;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups_2__set__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 89, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->groups);
  __Pyx_DECREF(__pyx_v_self->groups);
  __pyx_v_self->groups = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.groups.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups_4__del__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_6groups_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->groups);
  __Pyx_DECREF(__pyx_v_self->groups);
  __pyx_v_self->groups = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":90
 *     cdef unicode root
 *     cdef public list vertices, normals, textures, groups
 *     cdef public dict materials             # <<<<<<<<<<<<<<
 *     cdef unicode path
 *     cdef Material current_material
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_1__get__(PyObject *__pyx_v_self); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_1__get__(PyObject *__pyx_v_self) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials___get__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_9materials___get__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__get__", 0);
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v_self->materials);
  __pyx_r = __pyx_v_self->materials;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__set__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials_2__set__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), ((PyObject *)__pyx_v_value));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials_2__set__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v_value) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__set__", 0);
  if (!(likely(PyDict_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(0, 90, __pyx_L1_error)
  __pyx_t_1 = __pyx_v_value;
  __Pyx_INCREF(__pyx_t_1);
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v_self->materials);
  __Pyx_DECREF(__pyx_v_self->materials);
  __pyx_v_self->materials = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* function exit code */
  __pyx_r = 0;
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.materials.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = -1;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_5__del__(PyObject *__pyx_v_self); /*proto*/
static int __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_5__del__(PyObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials_4__del__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static int __pyx_pf_9punyverse_6_model_15WavefrontObject_9materials_4__del__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__del__", 0);
  __Pyx_INCREF(Py_None);
  __Pyx_GIVEREF(Py_None);
  __Pyx_GOTREF(__pyx_v_self->materials);
  __Pyx_DECREF(__pyx_v_self->materials);
  __pyx_v_self->materials = ((PyObject*)Py_None);

  /* function exit code */
  __pyx_r = 0;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.current_group, self.current_material, self.groups, self.materials, self.normals, self.path, self.root, self.textures, self.vertices)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_3__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_3__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_2__reduce_cython__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_2__reduce_cython__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self) {
  int __pyx_v_use_setstate;
  PyObject *__pyx_v_state = NULL;
  PyObject *__pyx_v__dict = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  int __pyx_t_3;
  PyObject *__pyx_t_4 = NULL;
  int __pyx_t_5;
  PyObject *__pyx_t_6 = NULL;
  __Pyx_RefNannySetupContext("__reduce_cython__", 0);

  /* "(tree fragment)":3
 * def __reduce_cython__(self):
 *     cdef bint use_setstate
 *     state = (self.current_group, self.current_material, self.groups, self.materials, self.normals, self.path, self.root, self.textures, self.vertices)             # <<<<<<<<<<<<<<
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 */
  __pyx_t_1 = PyTuple_New(9); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 3, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(((PyObject *)__pyx_v_self->current_group));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self->current_group));
  PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self->current_group));
  __Pyx_INCREF(((PyObject *)__pyx_v_self->current_material));
  __Pyx_GIVEREF(((PyObject *)__pyx_v_self->current_material));
  PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self->current_material));
  __Pyx_INCREF(__pyx_v_self->groups);
  __Pyx_GIVEREF(__pyx_v_self->groups);
  PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->groups);
  __Pyx_INCREF(__pyx_v_self->materials);
  __Pyx_GIVEREF(__pyx_v_self->materials);
  PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_v_self->materials);
  __Pyx_INCREF(__pyx_v_self->normals);
  __Pyx_GIVEREF(__pyx_v_self->normals);
  PyTuple_SET_ITEM(__pyx_t_1, 4, __pyx_v_self->normals);
  __Pyx_INCREF(__pyx_v_self->path);
  __Pyx_GIVEREF(__pyx_v_self->path);
  PyTuple_SET_ITEM(__pyx_t_1, 5, __pyx_v_self->path);
  __Pyx_INCREF(__pyx_v_self->root);
  __Pyx_GIVEREF(__pyx_v_self->root);
  PyTuple_SET_ITEM(__pyx_t_1, 6, __pyx_v_self->root);
  __Pyx_INCREF(__pyx_v_self->textures);
  __Pyx_GIVEREF(__pyx_v_self->textures);
  PyTuple_SET_ITEM(__pyx_t_1, 7, __pyx_v_self->textures);
  __Pyx_INCREF(__pyx_v_self->vertices);
  __Pyx_GIVEREF(__pyx_v_self->vertices);
  PyTuple_SET_ITEM(__pyx_t_1, 8, __pyx_v_self->vertices);
  __pyx_v_state = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "(tree fragment)":4
 *     cdef bint use_setstate
 *     state = (self.current_group, self.current_material, self.groups, self.materials, self.normals, self.path, self.root, self.textures, self.vertices)
 *     _dict = getattr(self, '__dict__', None)             # <<<<<<<<<<<<<<
 *     if _dict is not None:
 *         state += (_dict,)
 */
  __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 4, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_v__dict = __pyx_t_1;
  __pyx_t_1 = 0;

  /* "(tree fragment)":5
 *     state = (self.current_group, self.current_material, self.groups, self.materials, self.normals, self.path, self.root, self.textures, self.vertices)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
  __pyx_t_2 = (__pyx_v__dict != Py_None);
  __pyx_t_3 = (__pyx_t_2 != 0);
  if (__pyx_t_3) {

    /* "(tree fragment)":6
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:
 *         state += (_dict,)             # <<<<<<<<<<<<<<
 *         use_setstate = True
 *     else:
 */
    __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_INCREF(__pyx_v__dict);
    __Pyx_GIVEREF(__pyx_v__dict);
    PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict);
    __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 6, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4));
    __pyx_t_4 = 0;

    /* "(tree fragment)":7
 *     if _dict is not None:
 *         state += (_dict,)
 *         use_setstate = True             # <<<<<<<<<<<<<<
 *     else:
 *         use_setstate = self.current_group is not None or self.current_material is not None or self.groups is not None or self.materials is not None or self.normals is not None or self.path is not None or self.root is not None or self.textures is not None or self.vertices is not None
 */
    __pyx_v_use_setstate = 1;

    /* "(tree fragment)":5
 *     state = (self.current_group, self.current_material, self.groups, self.materials, self.normals, self.path, self.root, self.textures, self.vertices)
 *     _dict = getattr(self, '__dict__', None)
 *     if _dict is not None:             # <<<<<<<<<<<<<<
 *         state += (_dict,)
 *         use_setstate = True
 */
    goto __pyx_L3;
  }

  /* "(tree fragment)":9
 *         use_setstate = True
 *     else:
 *         use_setstate = self.current_group is not None or self.current_material is not None or self.groups is not None or self.materials is not None or self.normals is not None or self.path is not None or self.root is not None or self.textures is not None or self.vertices is not None             # <<<<<<<<<<<<<<
 *     if use_setstate:
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, None), state
 */
  /*else*/ {
    __pyx_t_2 = (((PyObject *)__pyx_v_self->current_group) != Py_None);
    __pyx_t_5 = (__pyx_t_2 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_3 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (((PyObject *)__pyx_v_self->current_material) != Py_None);
    __pyx_t_2 = (__pyx_t_5 != 0);
    if (!__pyx_t_2) {
    } else {
      __pyx_t_3 = __pyx_t_2;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_2 = (__pyx_v_self->groups != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_2 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_3 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->materials != ((PyObject*)Py_None));
    __pyx_t_2 = (__pyx_t_5 != 0);
    if (!__pyx_t_2) {
    } else {
      __pyx_t_3 = __pyx_t_2;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_2 = (__pyx_v_self->normals != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_2 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_3 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->path != ((PyObject*)Py_None));
    __pyx_t_2 = (__pyx_t_5 != 0);
    if (!__pyx_t_2) {
    } else {
      __pyx_t_3 = __pyx_t_2;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_2 = (__pyx_v_self->root != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_2 != 0);
    if (!__pyx_t_5) {
    } else {
      __pyx_t_3 = __pyx_t_5;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_5 = (__pyx_v_self->textures != ((PyObject*)Py_None));
    __pyx_t_2 = (__pyx_t_5 != 0);
    if (!__pyx_t_2) {
    } else {
      __pyx_t_3 = __pyx_t_2;
      goto __pyx_L4_bool_binop_done;
    }
    __pyx_t_2 = (__pyx_v_self->vertices != ((PyObject*)Py_None));
    __pyx_t_5 = (__pyx_t_2 != 0);
    __pyx_t_3 = __pyx_t_5;
    __pyx_L4_bool_binop_done:;
    __pyx_v_use_setstate = __pyx_t_3;
  }
  __pyx_L3:;

  /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.current_group is not None or self.current_material is not None or self.groups is not None or self.materials is not None or self.normals is not None or self.path is not None or self.root is not None or self.textures is not None or self.vertices is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, None), state
 *     else:
 */
  __pyx_t_3 = (__pyx_v_use_setstate != 0);
  if (__pyx_t_3) {

    /* "(tree fragment)":11
 *         use_setstate = self.current_group is not None or self.current_material is not None or self.groups is not None or self.materials is not None or self.normals is not None or self.path is not None or self.root is not None or self.textures is not None or self.vertices is not None
 *     if use_setstate:
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, None), state             # <<<<<<<<<<<<<<
 *     else:
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, state)
 */
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_WavefrontObject); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_173792776);
    __Pyx_GIVEREF(__pyx_int_173792776);
    PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_173792776);
    __Pyx_INCREF(Py_None);
    __Pyx_GIVEREF(Py_None);
    PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None);
    __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 11, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_4);
    PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_1);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_state);
    __pyx_t_4 = 0;
    __pyx_t_1 = 0;
    __pyx_r = __pyx_t_6;
    __pyx_t_6 = 0;
    goto __pyx_L0;

    /* "(tree fragment)":10
 *     else:
 *         use_setstate = self.current_group is not None or self.current_material is not None or self.groups is not None or self.materials is not None or self.normals is not None or self.path is not None or self.root is not None or self.textures is not None or self.vertices is not None
 *     if use_setstate:             # <<<<<<<<<<<<<<
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, None), state
 *     else:
 */
  }

  /* "(tree fragment)":13
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, None), state
 *     else:
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, state)             # <<<<<<<<<<<<<<
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_WavefrontObject__set_state(self, __pyx_state)
 */
  /*else*/ {
    __Pyx_XDECREF(__pyx_r);
    __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_pyx_unpickle_WavefrontObject); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
    __Pyx_INCREF(__pyx_int_173792776);
    __Pyx_GIVEREF(__pyx_int_173792776);
    PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_173792776);
    __Pyx_INCREF(__pyx_v_state);
    __Pyx_GIVEREF(__pyx_v_state);
    PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state);
    __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 13, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_GIVEREF(__pyx_t_6);
    PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6);
    __Pyx_GIVEREF(__pyx_t_1);
    PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
    __pyx_t_6 = 0;
    __pyx_t_1 = 0;
    __pyx_r = __pyx_t_4;
    __pyx_t_4 = 0;
    goto __pyx_L0;
  }

  /* "(tree fragment)":1
 * def __reduce_cython__(self):             # <<<<<<<<<<<<<<
 *     cdef bint use_setstate
 *     state = (self.current_group, self.current_material, self.groups, self.materials, self.normals, self.path, self.root, self.textures, self.vertices)
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_state);
  __Pyx_XDECREF(__pyx_v__dict);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_WavefrontObject__set_state(self, __pyx_state)
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_5__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_15WavefrontObject_5__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_15WavefrontObject_4__setstate_cython__(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_15WavefrontObject_4__setstate_cython__(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  __Pyx_RefNannySetupContext("__setstate_cython__", 0);

  /* "(tree fragment)":15
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, state)
 * def __setstate_cython__(self, __pyx_state):
 *     __pyx_unpickle_WavefrontObject__set_state(self, __pyx_state)             # <<<<<<<<<<<<<<
 */
  if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 15, __pyx_L1_error)
  __pyx_t_1 = __pyx_f_9punyverse_6_model___pyx_unpickle_WavefrontObject__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 15, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":14
 *     else:
 *         return __pyx_unpickle_WavefrontObject, (type(self), 0xa5bde08, state)
 * def __setstate_cython__(self, __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_unpickle_WavefrontObject__set_state(self, __pyx_state)
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_AddTraceback("punyverse._model.WavefrontObject.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":267
 * model_base = None
 * 
 * def load_model(path):             # <<<<<<<<<<<<<<
 *     global model_base
 *     if model_base is None:
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_3load_model(PyObject *__pyx_self, PyObject *__pyx_v_path); /*proto*/
static PyMethodDef __pyx_mdef_9punyverse_6_model_3load_model = {"load_model", (PyCFunction)__pyx_pw_9punyverse_6_model_3load_model, METH_O, 0};
static PyObject *__pyx_pw_9punyverse_6_model_3load_model(PyObject *__pyx_self, PyObject *__pyx_v_path) {
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("load_model (wrapper)", 0);
  __pyx_r = __pyx_pf_9punyverse_6_model_2load_model(__pyx_self, ((PyObject *)__pyx_v_path));

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_2load_model(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path) {
  PyObject *__pyx_v_sys = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __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;
  int __pyx_t_10;
  __Pyx_RefNannySetupContext("load_model", 0);
  __Pyx_INCREF(__pyx_v_path);

  /* "punyverse/_model.pyx":269
 * def load_model(path):
 *     global model_base
 *     if model_base is None:             # <<<<<<<<<<<<<<
 *         import sys
 *         if hasattr(sys, 'frozen'):
 */
  __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_model_base); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 269, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = (__pyx_t_1 == Py_None);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_3 = (__pyx_t_2 != 0);
  if (__pyx_t_3) {

    /* "punyverse/_model.pyx":270
 *     global model_base
 *     if model_base is None:
 *         import sys             # <<<<<<<<<<<<<<
 *         if hasattr(sys, 'frozen'):
 *             model_base = os.path.dirname(sys.executable)
 */
    __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 270, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_v_sys = __pyx_t_1;
    __pyx_t_1 = 0;

    /* "punyverse/_model.pyx":271
 *     if model_base is None:
 *         import sys
 *         if hasattr(sys, 'frozen'):             # <<<<<<<<<<<<<<
 *             model_base = os.path.dirname(sys.executable)
 *         else:
 */
    __pyx_t_3 = __Pyx_HasAttr(__pyx_v_sys, __pyx_n_s_frozen); if (unlikely(__pyx_t_3 == ((int)-1))) __PYX_ERR(0, 271, __pyx_L1_error)
    __pyx_t_2 = (__pyx_t_3 != 0);
    if (__pyx_t_2) {

      /* "punyverse/_model.pyx":272
 *         import sys
 *         if hasattr(sys, 'frozen'):
 *             model_base = os.path.dirname(sys.executable)             # <<<<<<<<<<<<<<
 *         else:
 *             model_base = os.path.join(os.path.dirname(__file__), 'assets', 'models')
 */
      __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 272, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_path); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 272, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_dirname); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 272, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_sys, __pyx_n_s_executable); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 272, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      __pyx_t_6 = NULL;
      if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
        __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4);
        if (likely(__pyx_t_6)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
          __Pyx_INCREF(__pyx_t_6);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_4, function);
        }
      }
      if (!__pyx_t_6) {
        __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 272, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_1);
      } else {
        #if CYTHON_FAST_PYCALL
        if (PyFunction_Check(__pyx_t_4)) {
          PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_t_5};
          __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 272, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
          __Pyx_GOTREF(__pyx_t_1);
          __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
        } else
        #endif
        #if CYTHON_FAST_PYCCALL
        if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
          PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_t_5};
          __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 272, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
          __Pyx_GOTREF(__pyx_t_1);
          __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
        } else
        #endif
        {
          __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 272, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_7);
          __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_6); __pyx_t_6 = NULL;
          __Pyx_GIVEREF(__pyx_t_5);
          PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_t_5);
          __pyx_t_5 = 0;
          __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 272, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_1);
          __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
        }
      }
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      if (PyDict_SetItem(__pyx_d, __pyx_n_s_model_base, __pyx_t_1) < 0) __PYX_ERR(0, 272, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

      /* "punyverse/_model.pyx":271
 *     if model_base is None:
 *         import sys
 *         if hasattr(sys, 'frozen'):             # <<<<<<<<<<<<<<
 *             model_base = os.path.dirname(sys.executable)
 *         else:
 */
      goto __pyx_L4;
    }

    /* "punyverse/_model.pyx":274
 *             model_base = os.path.dirname(sys.executable)
 *         else:
 *             model_base = os.path.join(os.path.dirname(__file__), 'assets', 'models')             # <<<<<<<<<<<<<<
 *     if not os.path.isabs(path):
 *         path = os.path.join(model_base, path)
 */
    /*else*/ {
      __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_path); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_7);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_join); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_path); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_6);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_dirname); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_file); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_6);
      __pyx_t_8 = NULL;
      if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
        __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_5);
        if (likely(__pyx_t_8)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
          __Pyx_INCREF(__pyx_t_8);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_5, function);
        }
      }
      if (!__pyx_t_8) {
        __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 274, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
        __Pyx_GOTREF(__pyx_t_7);
      } else {
        #if CYTHON_FAST_PYCALL
        if (PyFunction_Check(__pyx_t_5)) {
          PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_6};
          __pyx_t_7 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 274, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
          __Pyx_GOTREF(__pyx_t_7);
          __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
        } else
        #endif
        #if CYTHON_FAST_PYCCALL
        if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
          PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_6};
          __pyx_t_7 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 274, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
          __Pyx_GOTREF(__pyx_t_7);
          __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
        } else
        #endif
        {
          __pyx_t_9 = PyTuple_New(1+1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 274, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_9);
          __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL;
          __Pyx_GIVEREF(__pyx_t_6);
          PyTuple_SET_ITEM(__pyx_t_9, 0+1, __pyx_t_6);
          __pyx_t_6 = 0;
          __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_9, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 274, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_7);
          __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
        }
      }
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __pyx_t_5 = NULL;
      __pyx_t_10 = 0;
      if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
        __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4);
        if (likely(__pyx_t_5)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
          __Pyx_INCREF(__pyx_t_5);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_4, function);
          __pyx_t_10 = 1;
        }
      }
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_4)) {
        PyObject *__pyx_temp[4] = {__pyx_t_5, __pyx_t_7, __pyx_n_s_assets, __pyx_n_s_models};
        __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_10, 3+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 274, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
        PyObject *__pyx_temp[4] = {__pyx_t_5, __pyx_t_7, __pyx_n_s_assets, __pyx_n_s_models};
        __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_10, 3+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 274, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      {
        __pyx_t_9 = PyTuple_New(3+__pyx_t_10); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 274, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_9);
        if (__pyx_t_5) {
          __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_5); __pyx_t_5 = NULL;
        }
        __Pyx_GIVEREF(__pyx_t_7);
        PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_10, __pyx_t_7);
        __Pyx_INCREF(__pyx_n_s_assets);
        __Pyx_GIVEREF(__pyx_n_s_assets);
        PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_10, __pyx_n_s_assets);
        __Pyx_INCREF(__pyx_n_s_models);
        __Pyx_GIVEREF(__pyx_n_s_models);
        PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_10, __pyx_n_s_models);
        __pyx_t_7 = 0;
        __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 274, __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;
      if (PyDict_SetItem(__pyx_d, __pyx_n_s_model_base, __pyx_t_1) < 0) __PYX_ERR(0, 274, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    }
    __pyx_L4:;

    /* "punyverse/_model.pyx":269
 * def load_model(path):
 *     global model_base
 *     if model_base is None:             # <<<<<<<<<<<<<<
 *         import sys
 *         if hasattr(sys, 'frozen'):
 */
  }

  /* "punyverse/_model.pyx":275
 *         else:
 *             model_base = os.path.join(os.path.dirname(__file__), 'assets', 'models')
 *     if not os.path.isabs(path):             # <<<<<<<<<<<<<<
 *         path = os.path.join(model_base, path)
 *     if not isinstance(path, unicode):
 */
  __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 275, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_path); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 275, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_9);
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_isabs); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 275, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  __pyx_t_9 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
    __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_4);
    if (likely(__pyx_t_9)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
      __Pyx_INCREF(__pyx_t_9);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_4, function);
    }
  }
  if (!__pyx_t_9) {
    __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_path); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 275, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_4)) {
      PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_v_path};
      __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 275, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
      PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_v_path};
      __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 275, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else
    #endif
    {
      __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 275, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_7);
      __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_9); __pyx_t_9 = NULL;
      __Pyx_INCREF(__pyx_v_path);
      __Pyx_GIVEREF(__pyx_v_path);
      PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_path);
      __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 275, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 275, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_3 = ((!__pyx_t_2) != 0);
  if (__pyx_t_3) {

    /* "punyverse/_model.pyx":276
 *             model_base = os.path.join(os.path.dirname(__file__), 'assets', 'models')
 *     if not os.path.isabs(path):
 *         path = os.path.join(model_base, path)             # <<<<<<<<<<<<<<
 *     if not isinstance(path, unicode):
 *         path = path.decode('mbcs')
 */
    __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 276, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_path); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 276, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_join); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 276, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_model_base); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 276, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_9 = NULL;
    __pyx_t_10 = 0;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
      __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_4);
      if (likely(__pyx_t_9)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
        __Pyx_INCREF(__pyx_t_9);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_4, function);
        __pyx_t_10 = 1;
      }
    }
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_4)) {
      PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_7, __pyx_v_path};
      __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
      PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_t_7, __pyx_v_path};
      __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    } else
    #endif
    {
      __pyx_t_5 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 276, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      if (__pyx_t_9) {
        __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_9); __pyx_t_9 = NULL;
      }
      __Pyx_GIVEREF(__pyx_t_7);
      PyTuple_SET_ITEM(__pyx_t_5, 0+__pyx_t_10, __pyx_t_7);
      __Pyx_INCREF(__pyx_v_path);
      __Pyx_GIVEREF(__pyx_v_path);
      PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_10, __pyx_v_path);
      __pyx_t_7 = 0;
      __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 276, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
    }
    __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    __Pyx_DECREF_SET(__pyx_v_path, __pyx_t_1);
    __pyx_t_1 = 0;

    /* "punyverse/_model.pyx":275
 *         else:
 *             model_base = os.path.join(os.path.dirname(__file__), 'assets', 'models')
 *     if not os.path.isabs(path):             # <<<<<<<<<<<<<<
 *         path = os.path.join(model_base, path)
 *     if not isinstance(path, unicode):
 */
  }

  /* "punyverse/_model.pyx":277
 *     if not os.path.isabs(path):
 *         path = os.path.join(model_base, path)
 *     if not isinstance(path, unicode):             # <<<<<<<<<<<<<<
 *         path = path.decode('mbcs')
 *     return WavefrontObject(path)
 */
  __pyx_t_3 = PyUnicode_Check(__pyx_v_path); 
  __pyx_t_2 = ((!(__pyx_t_3 != 0)) != 0);
  if (__pyx_t_2) {

    /* "punyverse/_model.pyx":278
 *         path = os.path.join(model_base, path)
 *     if not isinstance(path, unicode):
 *         path = path.decode('mbcs')             # <<<<<<<<<<<<<<
 *     return WavefrontObject(path)
 * 
 */
    __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_path, __pyx_n_s_decode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 278, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 278, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
    __Pyx_DECREF_SET(__pyx_v_path, __pyx_t_4);
    __pyx_t_4 = 0;

    /* "punyverse/_model.pyx":277
 *     if not os.path.isabs(path):
 *         path = os.path.join(model_base, path)
 *     if not isinstance(path, unicode):             # <<<<<<<<<<<<<<
 *         path = path.decode('mbcs')
 *     return WavefrontObject(path)
 */
  }

  /* "punyverse/_model.pyx":279
 *     if not isinstance(path, unicode):
 *         path = path.decode('mbcs')
 *     return WavefrontObject(path)             # <<<<<<<<<<<<<<
 * 
 * @cython.nonecheck(False)
 */
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_4 = __Pyx_PyObject_CallOneArg(((PyObject *)__pyx_ptype_9punyverse_6_model_WavefrontObject), __pyx_v_path); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 279, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_4);
  __pyx_r = __pyx_t_4;
  __pyx_t_4 = 0;
  goto __pyx_L0;

  /* "punyverse/_model.pyx":267
 * model_base = None
 * 
 * def load_model(path):             # <<<<<<<<<<<<<<
 *     global model_base
 *     if model_base is None:
 */

  /* function exit code */
  __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_AddTraceback("punyverse._model.load_model", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_sys);
  __Pyx_XDECREF(__pyx_v_path);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "punyverse/_model.pyx":282
 * 
 * @cython.nonecheck(False)
 * cdef inline void point(Face f, WavefrontObject m, int tex_id, float sx, float sy, float sz, int n):             # <<<<<<<<<<<<<<
 *     cdef float x, y, z
 *     cdef tuple normal, texture
 */

static CYTHON_INLINE void __pyx_f_9punyverse_6_model_point(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_f, struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_m, int __pyx_v_tex_id, float __pyx_v_sx, float __pyx_v_sy, float __pyx_v_sz, int __pyx_v_n) {
  float __pyx_v_x;
  float __pyx_v_y;
  float __pyx_v_z;
  PyObject *__pyx_v_normal = 0;
  PyObject *__pyx_v_texture = 0;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  GLfloat __pyx_t_4;
  GLfloat __pyx_t_5;
  GLfloat __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *(*__pyx_t_10)(PyObject *);
  float __pyx_t_11;
  float __pyx_t_12;
  float __pyx_t_13;
  __Pyx_RefNannySetupContext("point", 0);

  /* "punyverse/_model.pyx":285
 *     cdef float x, y, z
 *     cdef tuple normal, texture
 *     if f.norms:             # <<<<<<<<<<<<<<
 *         normal = m.normals[f.norms[n]]
 *         glNormal3f(normal[0], normal[1], normal[2])
 */
  __pyx_t_1 = (__pyx_v_f->norms != Py_None)&&(PyList_GET_SIZE(__pyx_v_f->norms) != 0);
  if (__pyx_t_1) {

    /* "punyverse/_model.pyx":286
 *     cdef tuple normal, texture
 *     if f.norms:
 *         normal = m.normals[f.norms[n]]             # <<<<<<<<<<<<<<
 *         glNormal3f(normal[0], normal[1], normal[2])
 *     if tex_id:
 */
    if (unlikely(__pyx_v_m->normals == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 286, __pyx_L1_error)
    }
    if (unlikely(__pyx_v_f->norms == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 286, __pyx_L1_error)
    }
    __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_f->norms, __pyx_v_n, int, 1, __Pyx_PyInt_From_int, 1, 1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 286, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_v_m->normals, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 286, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    if (!(likely(PyTuple_CheckExact(__pyx_t_3))||((__pyx_t_3) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_3)->tp_name), 0))) __PYX_ERR(0, 286, __pyx_L1_error)
    __pyx_v_normal = ((PyObject*)__pyx_t_3);
    __pyx_t_3 = 0;

    /* "punyverse/_model.pyx":287
 *     if f.norms:
 *         normal = m.normals[f.norms[n]]
 *         glNormal3f(normal[0], normal[1], normal[2])             # <<<<<<<<<<<<<<
 *     if tex_id:
 *         texture = m.textures[f.texs[n]]
 */
    if (unlikely(__pyx_v_normal == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 287, __pyx_L1_error)
    }
    __pyx_t_3 = __Pyx_GetItemInt_Tuple(__pyx_v_normal, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 287, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_4 = __pyx_PyFloat_AsFloat(__pyx_t_3); if (unlikely((__pyx_t_4 == ((GLfloat)-1)) && PyErr_Occurred())) __PYX_ERR(0, 287, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    if (unlikely(__pyx_v_normal == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 287, __pyx_L1_error)
    }
    __pyx_t_3 = __Pyx_GetItemInt_Tuple(__pyx_v_normal, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 287, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_3); if (unlikely((__pyx_t_5 == ((GLfloat)-1)) && PyErr_Occurred())) __PYX_ERR(0, 287, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    if (unlikely(__pyx_v_normal == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 287, __pyx_L1_error)
    }
    __pyx_t_3 = __Pyx_GetItemInt_Tuple(__pyx_v_normal, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 287, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_6 = __pyx_PyFloat_AsFloat(__pyx_t_3); if (unlikely((__pyx_t_6 == ((GLfloat)-1)) && PyErr_Occurred())) __PYX_ERR(0, 287, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    glNormal3f(__pyx_t_4, __pyx_t_5, __pyx_t_6);

    /* "punyverse/_model.pyx":285
 *     cdef float x, y, z
 *     cdef tuple normal, texture
 *     if f.norms:             # <<<<<<<<<<<<<<
 *         normal = m.normals[f.norms[n]]
 *         glNormal3f(normal[0], normal[1], normal[2])
 */
  }

  /* "punyverse/_model.pyx":288
 *         normal = m.normals[f.norms[n]]
 *         glNormal3f(normal[0], normal[1], normal[2])
 *     if tex_id:             # <<<<<<<<<<<<<<
 *         texture = m.textures[f.texs[n]]
 *         glTexCoord2f(texture[0], texture[1])
 */
  __pyx_t_1 = (__pyx_v_tex_id != 0);
  if (__pyx_t_1) {

    /* "punyverse/_model.pyx":289
 *         glNormal3f(normal[0], normal[1], normal[2])
 *     if tex_id:
 *         texture = m.textures[f.texs[n]]             # <<<<<<<<<<<<<<
 *         glTexCoord2f(texture[0], texture[1])
 * 
 */
    if (unlikely(__pyx_v_m->textures == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 289, __pyx_L1_error)
    }
    if (unlikely(__pyx_v_f->texs == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 289, __pyx_L1_error)
    }
    __pyx_t_3 = __Pyx_GetItemInt_List(__pyx_v_f->texs, __pyx_v_n, int, 1, __Pyx_PyInt_From_int, 1, 1, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 289, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __pyx_t_2 = __Pyx_PyObject_GetItem(__pyx_v_m->textures, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 289, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    if (!(likely(PyTuple_CheckExact(__pyx_t_2))||((__pyx_t_2) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_2)->tp_name), 0))) __PYX_ERR(0, 289, __pyx_L1_error)
    __pyx_v_texture = ((PyObject*)__pyx_t_2);
    __pyx_t_2 = 0;

    /* "punyverse/_model.pyx":290
 *     if tex_id:
 *         texture = m.textures[f.texs[n]]
 *         glTexCoord2f(texture[0], texture[1])             # <<<<<<<<<<<<<<
 * 
 *     x, y, z = m.vertices[f.verts[n]]
 */
    if (unlikely(__pyx_v_texture == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 290, __pyx_L1_error)
    }
    __pyx_t_2 = __Pyx_GetItemInt_Tuple(__pyx_v_texture, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 290, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_6 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_6 == ((GLfloat)-1)) && PyErr_Occurred())) __PYX_ERR(0, 290, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    if (unlikely(__pyx_v_texture == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(0, 290, __pyx_L1_error)
    }
    __pyx_t_2 = __Pyx_GetItemInt_Tuple(__pyx_v_texture, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 290, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_5 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_5 == ((GLfloat)-1)) && PyErr_Occurred())) __PYX_ERR(0, 290, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    glTexCoord2f(__pyx_t_6, __pyx_t_5);

    /* "punyverse/_model.pyx":288
 *         normal = m.normals[f.norms[n]]
 *         glNormal3f(normal[0], normal[1], normal[2])
 *     if tex_id:             # <<<<<<<<<<<<<<
 *         texture = m.textures[f.texs[n]]
 *         glTexCoord2f(texture[0], texture[1])
 */
  }

  /* "punyverse/_model.pyx":292
 *         glTexCoord2f(texture[0], texture[1])
 * 
 *     x, y, z = m.vertices[f.verts[n]]             # <<<<<<<<<<<<<<
 *     glVertex3f(x * sx, y * sy, z * sz)
 * 
 */
  if (unlikely(__pyx_v_m->vertices == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 292, __pyx_L1_error)
  }
  if (unlikely(__pyx_v_f->verts == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(0, 292, __pyx_L1_error)
  }
  __pyx_t_2 = __Pyx_GetItemInt_List(__pyx_v_f->verts, __pyx_v_n, int, 1, __Pyx_PyInt_From_int, 1, 1, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 292, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_v_m->vertices, __pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 292, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  if ((likely(PyTuple_CheckExact(__pyx_t_3))) || (PyList_CheckExact(__pyx_t_3))) {
    PyObject* sequence = __pyx_t_3;
    Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
    if (unlikely(size != 3)) {
      if (size > 3) __Pyx_RaiseTooManyValuesError(3);
      else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
      __PYX_ERR(0, 292, __pyx_L1_error)
    }
    #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    if (likely(PyTuple_CheckExact(sequence))) {
      __pyx_t_2 = PyTuple_GET_ITEM(sequence, 0); 
      __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); 
      __pyx_t_8 = PyTuple_GET_ITEM(sequence, 2); 
    } else {
      __pyx_t_2 = PyList_GET_ITEM(sequence, 0); 
      __pyx_t_7 = PyList_GET_ITEM(sequence, 1); 
      __pyx_t_8 = PyList_GET_ITEM(sequence, 2); 
    }
    __Pyx_INCREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_t_7);
    __Pyx_INCREF(__pyx_t_8);
    #else
    __pyx_t_2 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 292, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 292, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_8 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 292, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_8);
    #endif
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  } else {
    Py_ssize_t index = -1;
    __pyx_t_9 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 292, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_9);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __pyx_t_10 = Py_TYPE(__pyx_t_9)->tp_iternext;
    index = 0; __pyx_t_2 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_2)) goto __pyx_L5_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_2);
    index = 1; __pyx_t_7 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_7)) goto __pyx_L5_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_7);
    index = 2; __pyx_t_8 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_8)) goto __pyx_L5_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_8);
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 3) < 0) __PYX_ERR(0, 292, __pyx_L1_error)
    __pyx_t_10 = NULL;
    __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
    goto __pyx_L6_unpacking_done;
    __pyx_L5_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
    __pyx_t_10 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    __PYX_ERR(0, 292, __pyx_L1_error)
    __pyx_L6_unpacking_done:;
  }
  __pyx_t_11 = __pyx_PyFloat_AsFloat(__pyx_t_2); if (unlikely((__pyx_t_11 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 292, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_12 = __pyx_PyFloat_AsFloat(__pyx_t_7); if (unlikely((__pyx_t_12 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 292, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  __pyx_t_13 = __pyx_PyFloat_AsFloat(__pyx_t_8); if (unlikely((__pyx_t_13 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 292, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  __pyx_v_x = __pyx_t_11;
  __pyx_v_y = __pyx_t_12;
  __pyx_v_z = __pyx_t_13;

  /* "punyverse/_model.pyx":293
 * 
 *     x, y, z = m.vertices[f.verts[n]]
 *     glVertex3f(x * sx, y * sy, z * sz)             # <<<<<<<<<<<<<<
 * 
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):
 */
  glVertex3f((__pyx_v_x * __pyx_v_sx), (__pyx_v_y * __pyx_v_sy), (__pyx_v_z * __pyx_v_sz));

  /* "punyverse/_model.pyx":282
 * 
 * @cython.nonecheck(False)
 * cdef inline void point(Face f, WavefrontObject m, int tex_id, float sx, float sy, float sz, int n):             # <<<<<<<<<<<<<<
 *     cdef float x, y, z
 *     cdef tuple normal, texture
 */

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_WriteUnraisable("punyverse._model.point", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_normal);
  __Pyx_XDECREF(__pyx_v_texture);
  __Pyx_RefNannyFinishContext();
}

/* "punyverse/_model.pyx":295
 *     glVertex3f(x * sx, y * sy, z * sz)
 * 
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):             # <<<<<<<<<<<<<<
 *     for m, text in model.materials.iteritems():
 *         if text.texture:
 */

static PyObject *__pyx_pw_9punyverse_6_model_5model_list(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static int __pyx_f_9punyverse_6_model_model_list(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_model, CYTHON_UNUSED int __pyx_skip_dispatch, struct __pyx_opt_args_9punyverse_6_model_model_list *__pyx_optional_args) {
  float __pyx_v_sx = ((float)1.0);
  float __pyx_v_sy = ((float)1.0);
  float __pyx_v_sz = ((float)1.0);
  PyObject *__pyx_v_rotation = ((PyObject *)__pyx_tuple__15);
  CYTHON_UNUSED PyObject *__pyx_v_m = NULL;
  PyObject *__pyx_v_text = NULL;
  int __pyx_v_display;
  float __pyx_v_pitch;
  float __pyx_v_yaw;
  float __pyx_v_roll;
  float __pyx_v_kx;
  float __pyx_v_ky;
  float __pyx_v_kz;
  struct __pyx_obj_9punyverse_6_model_Face *__pyx_v_f = 0;
  struct __pyx_obj_9punyverse_6_model_Group *__pyx_v_g = 0;
  int __pyx_v_tex_id;
  int __pyx_r;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  Py_ssize_t __pyx_t_2;
  Py_ssize_t __pyx_t_3;
  int __pyx_t_4;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  int __pyx_t_7;
  int __pyx_t_8;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  PyObject *__pyx_t_11 = NULL;
  PyObject *__pyx_t_12 = NULL;
  PyObject *__pyx_t_13 = NULL;
  PyObject *(*__pyx_t_14)(PyObject *);
  float __pyx_t_15;
  float __pyx_t_16;
  float __pyx_t_17;
  int __pyx_t_18;
  GLfloat __pyx_t_19[4];
  GLfloat __pyx_t_20[4];
  GLfloat __pyx_t_21[4];
  __Pyx_RefNannySetupContext("model_list", 0);
  if (__pyx_optional_args) {
    if (__pyx_optional_args->__pyx_n > 0) {
      __pyx_v_sx = __pyx_optional_args->sx;
      if (__pyx_optional_args->__pyx_n > 1) {
        __pyx_v_sy = __pyx_optional_args->sy;
        if (__pyx_optional_args->__pyx_n > 2) {
          __pyx_v_sz = __pyx_optional_args->sz;
          if (__pyx_optional_args->__pyx_n > 3) {
            __pyx_v_rotation = __pyx_optional_args->rotation;
          }
        }
      }
    }
  }

  /* "punyverse/_model.pyx":296
 * 
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):
 *     for m, text in model.materials.iteritems():             # <<<<<<<<<<<<<<
 *         if text.texture:
 *             load_texture(os.path.join(model.root, text.texture))
 */
  __pyx_t_2 = 0;
  if (unlikely(__pyx_v_model->materials == Py_None)) {
    PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "iteritems");
    __PYX_ERR(0, 296, __pyx_L1_error)
  }
  __pyx_t_5 = __Pyx_dict_iterator(__pyx_v_model->materials, 1, __pyx_n_s_iteritems, (&__pyx_t_3), (&__pyx_t_4)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 296, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_1);
  __pyx_t_1 = __pyx_t_5;
  __pyx_t_5 = 0;
  while (1) {
    __pyx_t_7 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_3, &__pyx_t_2, &__pyx_t_5, &__pyx_t_6, NULL, __pyx_t_4);
    if (unlikely(__pyx_t_7 == 0)) break;
    if (unlikely(__pyx_t_7 == -1)) __PYX_ERR(0, 296, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_5);
    __Pyx_GOTREF(__pyx_t_6);
    __Pyx_XDECREF_SET(__pyx_v_m, __pyx_t_5);
    __pyx_t_5 = 0;
    __Pyx_XDECREF_SET(__pyx_v_text, __pyx_t_6);
    __pyx_t_6 = 0;

    /* "punyverse/_model.pyx":297
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):
 *     for m, text in model.materials.iteritems():
 *         if text.texture:             # <<<<<<<<<<<<<<
 *             load_texture(os.path.join(model.root, text.texture))
 * 
 */
    __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_text, __pyx_n_s_texture); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 297, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_8 < 0)) __PYX_ERR(0, 297, __pyx_L1_error)
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    if (__pyx_t_8) {

      /* "punyverse/_model.pyx":298
 *     for m, text in model.materials.iteritems():
 *         if text.texture:
 *             load_texture(os.path.join(model.root, text.texture))             # <<<<<<<<<<<<<<
 * 
 *     cdef int display = glGenLists(1)
 */
      __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_load_texture); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 298, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_5);
      __pyx_t_10 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 298, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_10);
      __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_t_10, __pyx_n_s_path); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 298, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_11);
      __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
      __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_11, __pyx_n_s_join); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 298, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_10);
      __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
      __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_v_text, __pyx_n_s_texture); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 298, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_11);
      __pyx_t_12 = NULL;
      __pyx_t_7 = 0;
      if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_10))) {
        __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_10);
        if (likely(__pyx_t_12)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_10);
          __Pyx_INCREF(__pyx_t_12);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_10, function);
          __pyx_t_7 = 1;
        }
      }
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_10)) {
        PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_v_model->root, __pyx_t_11};
        __pyx_t_9 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 298, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0;
        __Pyx_GOTREF(__pyx_t_9);
        __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_10)) {
        PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_v_model->root, __pyx_t_11};
        __pyx_t_9 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 298, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0;
        __Pyx_GOTREF(__pyx_t_9);
        __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
      } else
      #endif
      {
        __pyx_t_13 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 298, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_13);
        if (__pyx_t_12) {
          __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_12); __pyx_t_12 = NULL;
        }
        __Pyx_INCREF(__pyx_v_model->root);
        __Pyx_GIVEREF(__pyx_v_model->root);
        PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_7, __pyx_v_model->root);
        __Pyx_GIVEREF(__pyx_t_11);
        PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_7, __pyx_t_11);
        __pyx_t_11 = 0;
        __pyx_t_9 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_13, NULL); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 298, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_9);
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
      }
      __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
      __pyx_t_10 = NULL;
      if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) {
        __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_5);
        if (likely(__pyx_t_10)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
          __Pyx_INCREF(__pyx_t_10);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_5, function);
        }
      }
      if (!__pyx_t_10) {
        __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_9); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 298, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_6);
      } else {
        #if CYTHON_FAST_PYCALL
        if (PyFunction_Check(__pyx_t_5)) {
          PyObject *__pyx_temp[2] = {__pyx_t_10, __pyx_t_9};
          __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 298, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
        } else
        #endif
        #if CYTHON_FAST_PYCCALL
        if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
          PyObject *__pyx_temp[2] = {__pyx_t_10, __pyx_t_9};
          __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 298, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
        } else
        #endif
        {
          __pyx_t_13 = PyTuple_New(1+1); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 298, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_13);
          __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_10); __pyx_t_10 = NULL;
          __Pyx_GIVEREF(__pyx_t_9);
          PyTuple_SET_ITEM(__pyx_t_13, 0+1, __pyx_t_9);
          __pyx_t_9 = 0;
          __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_13, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 298, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        }
      }
      __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;

      /* "punyverse/_model.pyx":297
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):
 *     for m, text in model.materials.iteritems():
 *         if text.texture:             # <<<<<<<<<<<<<<
 *             load_texture(os.path.join(model.root, text.texture))
 * 
 */
    }
  }
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":300
 *             load_texture(os.path.join(model.root, text.texture))
 * 
 *     cdef int display = glGenLists(1)             # <<<<<<<<<<<<<<
 * 
 *     glNewList(display, GL_COMPILE)
 */
  __pyx_v_display = glGenLists(1);

  /* "punyverse/_model.pyx":302
 *     cdef int display = glGenLists(1)
 * 
 *     glNewList(display, GL_COMPILE)             # <<<<<<<<<<<<<<
 *     glPushMatrix()
 *     glPushAttrib(GL_CURRENT_BIT)
 */
  glNewList(__pyx_v_display, __pyx_e_9punyverse_6_model_GL_COMPILE);

  /* "punyverse/_model.pyx":303
 * 
 *     glNewList(display, GL_COMPILE)
 *     glPushMatrix()             # <<<<<<<<<<<<<<
 *     glPushAttrib(GL_CURRENT_BIT)
 * 
 */
  glPushMatrix();

  /* "punyverse/_model.pyx":304
 *     glNewList(display, GL_COMPILE)
 *     glPushMatrix()
 *     glPushAttrib(GL_CURRENT_BIT)             # <<<<<<<<<<<<<<
 * 
 *     cdef float pitch, yaw, roll
 */
  glPushAttrib(__pyx_e_9punyverse_6_model_GL_CURRENT_BIT);

  /* "punyverse/_model.pyx":309
 *     cdef float kx, ky, kz
 * 
 *     pitch, yaw, roll = rotation             # <<<<<<<<<<<<<<
 *     glPushAttrib(GL_TRANSFORM_BIT)
 *     glRotatef(pitch, 1, 0, 0)
 */
  if ((likely(PyTuple_CheckExact(__pyx_v_rotation))) || (PyList_CheckExact(__pyx_v_rotation))) {
    PyObject* sequence = __pyx_v_rotation;
    Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
    if (unlikely(size != 3)) {
      if (size > 3) __Pyx_RaiseTooManyValuesError(3);
      else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
      __PYX_ERR(0, 309, __pyx_L1_error)
    }
    #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    if (likely(PyTuple_CheckExact(sequence))) {
      __pyx_t_1 = PyTuple_GET_ITEM(sequence, 0); 
      __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1); 
      __pyx_t_5 = PyTuple_GET_ITEM(sequence, 2); 
    } else {
      __pyx_t_1 = PyList_GET_ITEM(sequence, 0); 
      __pyx_t_6 = PyList_GET_ITEM(sequence, 1); 
      __pyx_t_5 = PyList_GET_ITEM(sequence, 2); 
    }
    __Pyx_INCREF(__pyx_t_1);
    __Pyx_INCREF(__pyx_t_6);
    __Pyx_INCREF(__pyx_t_5);
    #else
    __pyx_t_1 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 309, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_1);
    __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 309, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_5 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 309, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_5);
    #endif
  } else {
    Py_ssize_t index = -1;
    __pyx_t_13 = PyObject_GetIter(__pyx_v_rotation); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 309, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_13);
    __pyx_t_14 = Py_TYPE(__pyx_t_13)->tp_iternext;
    index = 0; __pyx_t_1 = __pyx_t_14(__pyx_t_13); if (unlikely(!__pyx_t_1)) goto __pyx_L6_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_1);
    index = 1; __pyx_t_6 = __pyx_t_14(__pyx_t_13); if (unlikely(!__pyx_t_6)) goto __pyx_L6_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_6);
    index = 2; __pyx_t_5 = __pyx_t_14(__pyx_t_13); if (unlikely(!__pyx_t_5)) goto __pyx_L6_unpacking_failed;
    __Pyx_GOTREF(__pyx_t_5);
    if (__Pyx_IternextUnpackEndCheck(__pyx_t_14(__pyx_t_13), 3) < 0) __PYX_ERR(0, 309, __pyx_L1_error)
    __pyx_t_14 = NULL;
    __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
    goto __pyx_L7_unpacking_done;
    __pyx_L6_unpacking_failed:;
    __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
    __pyx_t_14 = NULL;
    if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
    __PYX_ERR(0, 309, __pyx_L1_error)
    __pyx_L7_unpacking_done:;
  }
  __pyx_t_15 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_15 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 309, __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_ERR(0, 309, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_5); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 309, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  __pyx_v_pitch = __pyx_t_15;
  __pyx_v_yaw = __pyx_t_16;
  __pyx_v_roll = __pyx_t_17;

  /* "punyverse/_model.pyx":310
 * 
 *     pitch, yaw, roll = rotation
 *     glPushAttrib(GL_TRANSFORM_BIT)             # <<<<<<<<<<<<<<
 *     glRotatef(pitch, 1, 0, 0)
 *     glRotatef(yaw, 0, 1, 0)
 */
  glPushAttrib(__pyx_e_9punyverse_6_model_GL_TRANSFORM_BIT);

  /* "punyverse/_model.pyx":311
 *     pitch, yaw, roll = rotation
 *     glPushAttrib(GL_TRANSFORM_BIT)
 *     glRotatef(pitch, 1, 0, 0)             # <<<<<<<<<<<<<<
 *     glRotatef(yaw, 0, 1, 0)
 *     glRotatef(roll, 0, 0, 1)
 */
  glRotatef(__pyx_v_pitch, 1.0, 0.0, 0.0);

  /* "punyverse/_model.pyx":312
 *     glPushAttrib(GL_TRANSFORM_BIT)
 *     glRotatef(pitch, 1, 0, 0)
 *     glRotatef(yaw, 0, 1, 0)             # <<<<<<<<<<<<<<
 *     glRotatef(roll, 0, 0, 1)
 *     glPopAttrib()
 */
  glRotatef(__pyx_v_yaw, 0.0, 1.0, 0.0);

  /* "punyverse/_model.pyx":313
 *     glRotatef(pitch, 1, 0, 0)
 *     glRotatef(yaw, 0, 1, 0)
 *     glRotatef(roll, 0, 0, 1)             # <<<<<<<<<<<<<<
 *     glPopAttrib()
 * 
 */
  glRotatef(__pyx_v_roll, 0.0, 0.0, 1.0);

  /* "punyverse/_model.pyx":314
 *     glRotatef(yaw, 0, 1, 0)
 *     glRotatef(roll, 0, 0, 1)
 *     glPopAttrib()             # <<<<<<<<<<<<<<
 * 
 *     cdef Face f
 */
  glPopAttrib();

  /* "punyverse/_model.pyx":320
 *     cdef int tex_id
 * 
 *     for g in model.groups:             # <<<<<<<<<<<<<<
 *         tex_id = load_texture(os.path.join(model.root, g.material.texture)) if (g.material and g.material.texture) else 0
 * 
 */
  if (unlikely(__pyx_v_model->groups == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
    __PYX_ERR(0, 320, __pyx_L1_error)
  }
  __pyx_t_5 = __pyx_v_model->groups; __Pyx_INCREF(__pyx_t_5); __pyx_t_3 = 0;
  for (;;) {
    if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_5)) break;
    #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    __pyx_t_6 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_3); __Pyx_INCREF(__pyx_t_6); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 320, __pyx_L1_error)
    #else
    __pyx_t_6 = PySequence_ITEM(__pyx_t_5, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 320, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    #endif
    if (!(likely(((__pyx_t_6) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_6, __pyx_ptype_9punyverse_6_model_Group))))) __PYX_ERR(0, 320, __pyx_L1_error)
    __Pyx_XDECREF_SET(__pyx_v_g, ((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_t_6));
    __pyx_t_6 = 0;

    /* "punyverse/_model.pyx":321
 * 
 *     for g in model.groups:
 *         tex_id = load_texture(os.path.join(model.root, g.material.texture)) if (g.material and g.material.texture) else 0             # <<<<<<<<<<<<<<
 * 
 *         if tex_id:
 */
    __pyx_t_18 = __Pyx_PyObject_IsTrue(((PyObject *)__pyx_v_g->material)); if (unlikely(__pyx_t_18 < 0)) __PYX_ERR(0, 321, __pyx_L1_error)
    if (__pyx_t_18) {
    } else {
      __pyx_t_8 = __pyx_t_18;
      goto __pyx_L10_bool_binop_done;
    }
    __pyx_t_18 = __Pyx_PyObject_IsTrue(__pyx_v_g->material->texture); if (unlikely(__pyx_t_18 < 0)) __PYX_ERR(0, 321, __pyx_L1_error)
    __pyx_t_8 = __pyx_t_18;
    __pyx_L10_bool_binop_done:;
    if (__pyx_t_8) {
      __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_load_texture); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 321, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_1);
      __pyx_t_9 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 321, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_9);
      __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_path); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 321, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_10);
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_10, __pyx_n_s_join); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 321, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_9);
      __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
      __pyx_t_10 = NULL;
      __pyx_t_7 = 0;
      if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_9))) {
        __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9);
        if (likely(__pyx_t_10)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9);
          __Pyx_INCREF(__pyx_t_10);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_9, function);
          __pyx_t_7 = 1;
        }
      }
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_9)) {
        PyObject *__pyx_temp[3] = {__pyx_t_10, __pyx_v_model->root, __pyx_v_g->material->texture};
        __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 321, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
        __Pyx_GOTREF(__pyx_t_13);
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) {
        PyObject *__pyx_temp[3] = {__pyx_t_10, __pyx_v_model->root, __pyx_v_g->material->texture};
        __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 321, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
        __Pyx_GOTREF(__pyx_t_13);
      } else
      #endif
      {
        __pyx_t_11 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 321, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_11);
        if (__pyx_t_10) {
          __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_10); __pyx_t_10 = NULL;
        }
        __Pyx_INCREF(__pyx_v_model->root);
        __Pyx_GIVEREF(__pyx_v_model->root);
        PyTuple_SET_ITEM(__pyx_t_11, 0+__pyx_t_7, __pyx_v_model->root);
        __Pyx_INCREF(__pyx_v_g->material->texture);
        __Pyx_GIVEREF(__pyx_v_g->material->texture);
        PyTuple_SET_ITEM(__pyx_t_11, 1+__pyx_t_7, __pyx_v_g->material->texture);
        __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_11, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 321, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_13);
        __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
      }
      __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      __pyx_t_9 = NULL;
      if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
        __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_1);
        if (likely(__pyx_t_9)) {
          PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
          __Pyx_INCREF(__pyx_t_9);
          __Pyx_INCREF(function);
          __Pyx_DECREF_SET(__pyx_t_1, function);
        }
      }
      if (!__pyx_t_9) {
        __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_13); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 321, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        __Pyx_GOTREF(__pyx_t_6);
      } else {
        #if CYTHON_FAST_PYCALL
        if (PyFunction_Check(__pyx_t_1)) {
          PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_13};
          __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 321, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        } else
        #endif
        #if CYTHON_FAST_PYCCALL
        if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
          PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_13};
          __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 321, __pyx_L1_error)
          __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        } else
        #endif
        {
          __pyx_t_11 = PyTuple_New(1+1); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 321, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_11);
          __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_9); __pyx_t_9 = NULL;
          __Pyx_GIVEREF(__pyx_t_13);
          PyTuple_SET_ITEM(__pyx_t_11, 0+1, __pyx_t_13);
          __pyx_t_13 = 0;
          __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_11, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 321, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_6);
          __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
        }
      }
      __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
      __pyx_t_7 = __Pyx_PyInt_As_int(__pyx_t_6); if (unlikely((__pyx_t_7 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 321, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      __pyx_t_4 = __pyx_t_7;
    } else {
      __pyx_t_4 = 0;
    }
    __pyx_v_tex_id = __pyx_t_4;

    /* "punyverse/_model.pyx":323
 *         tex_id = load_texture(os.path.join(model.root, g.material.texture)) if (g.material and g.material.texture) else 0
 * 
 *         if tex_id:             # <<<<<<<<<<<<<<
 *             glEnable(GL_TEXTURE_2D)
 *             glBindTexture(GL_TEXTURE_2D, tex_id)
 */
    __pyx_t_8 = (__pyx_v_tex_id != 0);
    if (__pyx_t_8) {

      /* "punyverse/_model.pyx":324
 * 
 *         if tex_id:
 *             glEnable(GL_TEXTURE_2D)             # <<<<<<<<<<<<<<
 *             glBindTexture(GL_TEXTURE_2D, tex_id)
 *         else:
 */
      glEnable(__pyx_e_9punyverse_6_model_GL_TEXTURE_2D);

      /* "punyverse/_model.pyx":325
 *         if tex_id:
 *             glEnable(GL_TEXTURE_2D)
 *             glBindTexture(GL_TEXTURE_2D, tex_id)             # <<<<<<<<<<<<<<
 *         else:
 *             glBindTexture(GL_TEXTURE_2D, 0)
 */
      glBindTexture(__pyx_e_9punyverse_6_model_GL_TEXTURE_2D, __pyx_v_tex_id);

      /* "punyverse/_model.pyx":323
 *         tex_id = load_texture(os.path.join(model.root, g.material.texture)) if (g.material and g.material.texture) else 0
 * 
 *         if tex_id:             # <<<<<<<<<<<<<<
 *             glEnable(GL_TEXTURE_2D)
 *             glBindTexture(GL_TEXTURE_2D, tex_id)
 */
      goto __pyx_L12;
    }

    /* "punyverse/_model.pyx":327
 *             glBindTexture(GL_TEXTURE_2D, tex_id)
 *         else:
 *             glBindTexture(GL_TEXTURE_2D, 0)             # <<<<<<<<<<<<<<
 *             glDisable(GL_TEXTURE_2D)
 * 
 */
    /*else*/ {
      glBindTexture(__pyx_e_9punyverse_6_model_GL_TEXTURE_2D, 0);

      /* "punyverse/_model.pyx":328
 *         else:
 *             glBindTexture(GL_TEXTURE_2D, 0)
 *             glDisable(GL_TEXTURE_2D)             # <<<<<<<<<<<<<<
 * 
 *         if g.material is not None:
 */
      glDisable(__pyx_e_9punyverse_6_model_GL_TEXTURE_2D);
    }
    __pyx_L12:;

    /* "punyverse/_model.pyx":330
 *             glDisable(GL_TEXTURE_2D)
 * 
 *         if g.material is not None:             # <<<<<<<<<<<<<<
 *             if g.material.Ka:
 *                 kx, ky, kz = g.material.Ka
 */
    __pyx_t_8 = (((PyObject *)__pyx_v_g->material) != Py_None);
    __pyx_t_18 = (__pyx_t_8 != 0);
    if (__pyx_t_18) {

      /* "punyverse/_model.pyx":331
 * 
 *         if g.material is not None:
 *             if g.material.Ka:             # <<<<<<<<<<<<<<
 *                 kx, ky, kz = g.material.Ka
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])
 */
      __pyx_t_18 = (__pyx_v_g->material->Ka != Py_None)&&(PyTuple_GET_SIZE(__pyx_v_g->material->Ka) != 0);
      if (__pyx_t_18) {

        /* "punyverse/_model.pyx":332
 *         if g.material is not None:
 *             if g.material.Ka:
 *                 kx, ky, kz = g.material.Ka             # <<<<<<<<<<<<<<
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])
 *             if g.material.Kd:
 */
        __pyx_t_6 = __pyx_v_g->material->Ka;
        __Pyx_INCREF(__pyx_t_6);
        if (likely(__pyx_t_6 != Py_None)) {
          PyObject* sequence = __pyx_t_6;
          Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
          if (unlikely(size != 3)) {
            if (size > 3) __Pyx_RaiseTooManyValuesError(3);
            else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
            __PYX_ERR(0, 332, __pyx_L1_error)
          }
          #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
          __pyx_t_1 = PyTuple_GET_ITEM(sequence, 0); 
          __pyx_t_11 = PyTuple_GET_ITEM(sequence, 1); 
          __pyx_t_13 = PyTuple_GET_ITEM(sequence, 2); 
          __Pyx_INCREF(__pyx_t_1);
          __Pyx_INCREF(__pyx_t_11);
          __Pyx_INCREF(__pyx_t_13);
          #else
          __pyx_t_1 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 332, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_1);
          __pyx_t_11 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 332, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_11);
          __pyx_t_13 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 332, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_13);
          #endif
          __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
        } else {
          __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 332, __pyx_L1_error)
        }
        __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 332, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __pyx_t_16 = __pyx_PyFloat_AsFloat(__pyx_t_11); if (unlikely((__pyx_t_16 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 332, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
        __pyx_t_15 = __pyx_PyFloat_AsFloat(__pyx_t_13); if (unlikely((__pyx_t_15 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 332, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        __pyx_v_kx = __pyx_t_17;
        __pyx_v_ky = __pyx_t_16;
        __pyx_v_kz = __pyx_t_15;

        /* "punyverse/_model.pyx":333
 *             if g.material.Ka:
 *                 kx, ky, kz = g.material.Ka
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])             # <<<<<<<<<<<<<<
 *             if g.material.Kd:
 *                 kx, ky, kz = g.material.Kd
 */
        __pyx_t_19[0] = __pyx_v_kx;
        __pyx_t_19[1] = __pyx_v_ky;
        __pyx_t_19[2] = __pyx_v_kz;
        __pyx_t_19[3] = 1.0;
        glMaterialfv(__pyx_e_9punyverse_6_model_GL_FRONT_AND_BACK, __pyx_e_9punyverse_6_model_GL_AMBIENT, __pyx_t_19);

        /* "punyverse/_model.pyx":331
 * 
 *         if g.material is not None:
 *             if g.material.Ka:             # <<<<<<<<<<<<<<
 *                 kx, ky, kz = g.material.Ka
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])
 */
      }

      /* "punyverse/_model.pyx":334
 *                 kx, ky, kz = g.material.Ka
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])
 *             if g.material.Kd:             # <<<<<<<<<<<<<<
 *                 kx, ky, kz = g.material.Kd
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])
 */
      __pyx_t_18 = (__pyx_v_g->material->Kd != Py_None)&&(PyTuple_GET_SIZE(__pyx_v_g->material->Kd) != 0);
      if (__pyx_t_18) {

        /* "punyverse/_model.pyx":335
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])
 *             if g.material.Kd:
 *                 kx, ky, kz = g.material.Kd             # <<<<<<<<<<<<<<
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])
 *             if g.material.Ks:
 */
        __pyx_t_6 = __pyx_v_g->material->Kd;
        __Pyx_INCREF(__pyx_t_6);
        if (likely(__pyx_t_6 != Py_None)) {
          PyObject* sequence = __pyx_t_6;
          Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
          if (unlikely(size != 3)) {
            if (size > 3) __Pyx_RaiseTooManyValuesError(3);
            else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
            __PYX_ERR(0, 335, __pyx_L1_error)
          }
          #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
          __pyx_t_13 = PyTuple_GET_ITEM(sequence, 0); 
          __pyx_t_11 = PyTuple_GET_ITEM(sequence, 1); 
          __pyx_t_1 = PyTuple_GET_ITEM(sequence, 2); 
          __Pyx_INCREF(__pyx_t_13);
          __Pyx_INCREF(__pyx_t_11);
          __Pyx_INCREF(__pyx_t_1);
          #else
          __pyx_t_13 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 335, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_13);
          __pyx_t_11 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 335, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_11);
          __pyx_t_1 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 335, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_1);
          #endif
          __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
        } else {
          __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 335, __pyx_L1_error)
        }
        __pyx_t_15 = __pyx_PyFloat_AsFloat(__pyx_t_13); if (unlikely((__pyx_t_15 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 335, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        __pyx_t_16 = __pyx_PyFloat_AsFloat(__pyx_t_11); if (unlikely((__pyx_t_16 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 335, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
        __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 335, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __pyx_v_kx = __pyx_t_15;
        __pyx_v_ky = __pyx_t_16;
        __pyx_v_kz = __pyx_t_17;

        /* "punyverse/_model.pyx":336
 *             if g.material.Kd:
 *                 kx, ky, kz = g.material.Kd
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])             # <<<<<<<<<<<<<<
 *             if g.material.Ks:
 *                 kx, ky, kz = g.material.Ks
 */
        __pyx_t_20[0] = __pyx_v_kx;
        __pyx_t_20[1] = __pyx_v_ky;
        __pyx_t_20[2] = __pyx_v_kz;
        __pyx_t_20[3] = 1.0;
        glMaterialfv(__pyx_e_9punyverse_6_model_GL_FRONT_AND_BACK, __pyx_e_9punyverse_6_model_GL_DIFFUSE, __pyx_t_20);

        /* "punyverse/_model.pyx":334
 *                 kx, ky, kz = g.material.Ka
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT, [kx, ky, kz, 1])
 *             if g.material.Kd:             # <<<<<<<<<<<<<<
 *                 kx, ky, kz = g.material.Kd
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])
 */
      }

      /* "punyverse/_model.pyx":337
 *                 kx, ky, kz = g.material.Kd
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])
 *             if g.material.Ks:             # <<<<<<<<<<<<<<
 *                 kx, ky, kz = g.material.Ks
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, [kx, ky, kz, 1])
 */
      __pyx_t_18 = (__pyx_v_g->material->Ks != Py_None)&&(PyTuple_GET_SIZE(__pyx_v_g->material->Ks) != 0);
      if (__pyx_t_18) {

        /* "punyverse/_model.pyx":338
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])
 *             if g.material.Ks:
 *                 kx, ky, kz = g.material.Ks             # <<<<<<<<<<<<<<
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, [kx, ky, kz, 1])
 *             glMaterialf(GL_FRONT_AND_BACK, GL_SHININESS, g.material.shininess)
 */
        __pyx_t_6 = __pyx_v_g->material->Ks;
        __Pyx_INCREF(__pyx_t_6);
        if (likely(__pyx_t_6 != Py_None)) {
          PyObject* sequence = __pyx_t_6;
          Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
          if (unlikely(size != 3)) {
            if (size > 3) __Pyx_RaiseTooManyValuesError(3);
            else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
            __PYX_ERR(0, 338, __pyx_L1_error)
          }
          #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
          __pyx_t_1 = PyTuple_GET_ITEM(sequence, 0); 
          __pyx_t_11 = PyTuple_GET_ITEM(sequence, 1); 
          __pyx_t_13 = PyTuple_GET_ITEM(sequence, 2); 
          __Pyx_INCREF(__pyx_t_1);
          __Pyx_INCREF(__pyx_t_11);
          __Pyx_INCREF(__pyx_t_13);
          #else
          __pyx_t_1 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 338, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_1);
          __pyx_t_11 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 338, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_11);
          __pyx_t_13 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 338, __pyx_L1_error)
          __Pyx_GOTREF(__pyx_t_13);
          #endif
          __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
        } else {
          __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 338, __pyx_L1_error)
        }
        __pyx_t_17 = __pyx_PyFloat_AsFloat(__pyx_t_1); if (unlikely((__pyx_t_17 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 338, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
        __pyx_t_16 = __pyx_PyFloat_AsFloat(__pyx_t_11); if (unlikely((__pyx_t_16 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 338, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
        __pyx_t_15 = __pyx_PyFloat_AsFloat(__pyx_t_13); if (unlikely((__pyx_t_15 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 338, __pyx_L1_error)
        __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
        __pyx_v_kx = __pyx_t_17;
        __pyx_v_ky = __pyx_t_16;
        __pyx_v_kz = __pyx_t_15;

        /* "punyverse/_model.pyx":339
 *             if g.material.Ks:
 *                 kx, ky, kz = g.material.Ks
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, [kx, ky, kz, 1])             # <<<<<<<<<<<<<<
 *             glMaterialf(GL_FRONT_AND_BACK, GL_SHININESS, g.material.shininess)
 * 
 */
        __pyx_t_21[0] = __pyx_v_kx;
        __pyx_t_21[1] = __pyx_v_ky;
        __pyx_t_21[2] = __pyx_v_kz;
        __pyx_t_21[3] = 1.0;
        glMaterialfv(__pyx_e_9punyverse_6_model_GL_FRONT_AND_BACK, __pyx_e_9punyverse_6_model_GL_SPECULAR, __pyx_t_21);

        /* "punyverse/_model.pyx":337
 *                 kx, ky, kz = g.material.Kd
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, [kx, ky, kz, 1])
 *             if g.material.Ks:             # <<<<<<<<<<<<<<
 *                 kx, ky, kz = g.material.Ks
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, [kx, ky, kz, 1])
 */
      }

      /* "punyverse/_model.pyx":340
 *                 kx, ky, kz = g.material.Ks
 *                 glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, [kx, ky, kz, 1])
 *             glMaterialf(GL_FRONT_AND_BACK, GL_SHININESS, g.material.shininess)             # <<<<<<<<<<<<<<
 * 
 *         glBegin(GL_TRIANGLES)
 */
      glMaterialf(__pyx_e_9punyverse_6_model_GL_FRONT_AND_BACK, __pyx_e_9punyverse_6_model_GL_SHININESS, __pyx_v_g->material->shininess);

      /* "punyverse/_model.pyx":330
 *             glDisable(GL_TEXTURE_2D)
 * 
 *         if g.material is not None:             # <<<<<<<<<<<<<<
 *             if g.material.Ka:
 *                 kx, ky, kz = g.material.Ka
 */
    }

    /* "punyverse/_model.pyx":342
 *             glMaterialf(GL_FRONT_AND_BACK, GL_SHININESS, g.material.shininess)
 * 
 *         glBegin(GL_TRIANGLES)             # <<<<<<<<<<<<<<
 *         for f in g.faces:
 *             point(f, model, tex_id, sx, sy, sz, 0)
 */
    glBegin(__pyx_e_9punyverse_6_model_GL_TRIANGLES);

    /* "punyverse/_model.pyx":343
 * 
 *         glBegin(GL_TRIANGLES)
 *         for f in g.faces:             # <<<<<<<<<<<<<<
 *             point(f, model, tex_id, sx, sy, sz, 0)
 *             point(f, model, tex_id, sx, sy, sz, 1)
 */
    if (unlikely(__pyx_v_g->faces == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
      __PYX_ERR(0, 343, __pyx_L1_error)
    }
    __pyx_t_6 = __pyx_v_g->faces; __Pyx_INCREF(__pyx_t_6); __pyx_t_2 = 0;
    for (;;) {
      if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_6)) break;
      #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
      __pyx_t_13 = PyList_GET_ITEM(__pyx_t_6, __pyx_t_2); __Pyx_INCREF(__pyx_t_13); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 343, __pyx_L1_error)
      #else
      __pyx_t_13 = PySequence_ITEM(__pyx_t_6, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 343, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_13);
      #endif
      if (!(likely(((__pyx_t_13) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_13, __pyx_ptype_9punyverse_6_model_Face))))) __PYX_ERR(0, 343, __pyx_L1_error)
      __Pyx_XDECREF_SET(__pyx_v_f, ((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_t_13));
      __pyx_t_13 = 0;

      /* "punyverse/_model.pyx":344
 *         glBegin(GL_TRIANGLES)
 *         for f in g.faces:
 *             point(f, model, tex_id, sx, sy, sz, 0)             # <<<<<<<<<<<<<<
 *             point(f, model, tex_id, sx, sy, sz, 1)
 *             point(f, model, tex_id, sx, sy, sz, 2)
 */
      __pyx_f_9punyverse_6_model_point(__pyx_v_f, __pyx_v_model, __pyx_v_tex_id, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, 0);

      /* "punyverse/_model.pyx":345
 *         for f in g.faces:
 *             point(f, model, tex_id, sx, sy, sz, 0)
 *             point(f, model, tex_id, sx, sy, sz, 1)             # <<<<<<<<<<<<<<
 *             point(f, model, tex_id, sx, sy, sz, 2)
 * 
 */
      __pyx_f_9punyverse_6_model_point(__pyx_v_f, __pyx_v_model, __pyx_v_tex_id, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, 1);

      /* "punyverse/_model.pyx":346
 *             point(f, model, tex_id, sx, sy, sz, 0)
 *             point(f, model, tex_id, sx, sy, sz, 1)
 *             point(f, model, tex_id, sx, sy, sz, 2)             # <<<<<<<<<<<<<<
 * 
 *             if f.type == FACE_QUADS:
 */
      __pyx_f_9punyverse_6_model_point(__pyx_v_f, __pyx_v_model, __pyx_v_tex_id, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, 2);

      /* "punyverse/_model.pyx":348
 *             point(f, model, tex_id, sx, sy, sz, 2)
 * 
 *             if f.type == FACE_QUADS:             # <<<<<<<<<<<<<<
 *                 point(f, model, tex_id, sx, sy, sz, 2)
 *                 point(f, model, tex_id, sx, sy, sz, 3)
 */
      __pyx_t_18 = ((__pyx_v_f->type == __pyx_e_9punyverse_6_model_FACE_QUADS) != 0);
      if (__pyx_t_18) {

        /* "punyverse/_model.pyx":349
 * 
 *             if f.type == FACE_QUADS:
 *                 point(f, model, tex_id, sx, sy, sz, 2)             # <<<<<<<<<<<<<<
 *                 point(f, model, tex_id, sx, sy, sz, 3)
 *                 point(f, model, tex_id, sx, sy, sz, 0)
 */
        __pyx_f_9punyverse_6_model_point(__pyx_v_f, __pyx_v_model, __pyx_v_tex_id, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, 2);

        /* "punyverse/_model.pyx":350
 *             if f.type == FACE_QUADS:
 *                 point(f, model, tex_id, sx, sy, sz, 2)
 *                 point(f, model, tex_id, sx, sy, sz, 3)             # <<<<<<<<<<<<<<
 *                 point(f, model, tex_id, sx, sy, sz, 0)
 *         glEnd()
 */
        __pyx_f_9punyverse_6_model_point(__pyx_v_f, __pyx_v_model, __pyx_v_tex_id, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, 3);

        /* "punyverse/_model.pyx":351
 *                 point(f, model, tex_id, sx, sy, sz, 2)
 *                 point(f, model, tex_id, sx, sy, sz, 3)
 *                 point(f, model, tex_id, sx, sy, sz, 0)             # <<<<<<<<<<<<<<
 *         glEnd()
 * 
 */
        __pyx_f_9punyverse_6_model_point(__pyx_v_f, __pyx_v_model, __pyx_v_tex_id, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, 0);

        /* "punyverse/_model.pyx":348
 *             point(f, model, tex_id, sx, sy, sz, 2)
 * 
 *             if f.type == FACE_QUADS:             # <<<<<<<<<<<<<<
 *                 point(f, model, tex_id, sx, sy, sz, 2)
 *                 point(f, model, tex_id, sx, sy, sz, 3)
 */
      }

      /* "punyverse/_model.pyx":343
 * 
 *         glBegin(GL_TRIANGLES)
 *         for f in g.faces:             # <<<<<<<<<<<<<<
 *             point(f, model, tex_id, sx, sy, sz, 0)
 *             point(f, model, tex_id, sx, sy, sz, 1)
 */
    }
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;

    /* "punyverse/_model.pyx":352
 *                 point(f, model, tex_id, sx, sy, sz, 3)
 *                 point(f, model, tex_id, sx, sy, sz, 0)
 *         glEnd()             # <<<<<<<<<<<<<<
 * 
 *         if tex_id:
 */
    glEnd();

    /* "punyverse/_model.pyx":354
 *         glEnd()
 * 
 *         if tex_id:             # <<<<<<<<<<<<<<
 *             glBindTexture(GL_TEXTURE_2D, 0)
 *             glDisable(GL_TEXTURE_2D)
 */
    __pyx_t_18 = (__pyx_v_tex_id != 0);
    if (__pyx_t_18) {

      /* "punyverse/_model.pyx":355
 * 
 *         if tex_id:
 *             glBindTexture(GL_TEXTURE_2D, 0)             # <<<<<<<<<<<<<<
 *             glDisable(GL_TEXTURE_2D)
 * 
 */
      glBindTexture(__pyx_e_9punyverse_6_model_GL_TEXTURE_2D, 0);

      /* "punyverse/_model.pyx":356
 *         if tex_id:
 *             glBindTexture(GL_TEXTURE_2D, 0)
 *             glDisable(GL_TEXTURE_2D)             # <<<<<<<<<<<<<<
 * 
 *     glPopAttrib()
 */
      glDisable(__pyx_e_9punyverse_6_model_GL_TEXTURE_2D);

      /* "punyverse/_model.pyx":354
 *         glEnd()
 * 
 *         if tex_id:             # <<<<<<<<<<<<<<
 *             glBindTexture(GL_TEXTURE_2D, 0)
 *             glDisable(GL_TEXTURE_2D)
 */
    }

    /* "punyverse/_model.pyx":320
 *     cdef int tex_id
 * 
 *     for g in model.groups:             # <<<<<<<<<<<<<<
 *         tex_id = load_texture(os.path.join(model.root, g.material.texture)) if (g.material and g.material.texture) else 0
 * 
 */
  }
  __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;

  /* "punyverse/_model.pyx":358
 *             glDisable(GL_TEXTURE_2D)
 * 
 *     glPopAttrib()             # <<<<<<<<<<<<<<
 *     glPopMatrix()
 * 
 */
  glPopAttrib();

  /* "punyverse/_model.pyx":359
 * 
 *     glPopAttrib()
 *     glPopMatrix()             # <<<<<<<<<<<<<<
 * 
 *     glEndList()
 */
  glPopMatrix();

  /* "punyverse/_model.pyx":361
 *     glPopMatrix()
 * 
 *     glEndList()             # <<<<<<<<<<<<<<
 *     return display
 */
  glEndList();

  /* "punyverse/_model.pyx":362
 * 
 *     glEndList()
 *     return display             # <<<<<<<<<<<<<<
 */
  __pyx_r = __pyx_v_display;
  goto __pyx_L0;

  /* "punyverse/_model.pyx":295
 *     glVertex3f(x * sx, y * sy, z * sz)
 * 
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):             # <<<<<<<<<<<<<<
 *     for m, text in model.materials.iteritems():
 *         if text.texture:
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_XDECREF(__pyx_t_11);
  __Pyx_XDECREF(__pyx_t_12);
  __Pyx_XDECREF(__pyx_t_13);
  __Pyx_WriteUnraisable("punyverse._model.model_list", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v_m);
  __Pyx_XDECREF(__pyx_v_text);
  __Pyx_XDECREF((PyObject *)__pyx_v_f);
  __Pyx_XDECREF((PyObject *)__pyx_v_g);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_5model_list(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static PyObject *__pyx_pw_9punyverse_6_model_5model_list(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_model = 0;
  float __pyx_v_sx;
  float __pyx_v_sy;
  float __pyx_v_sz;
  PyObject *__pyx_v_rotation = 0;
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("model_list (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_model,&__pyx_n_s_sx,&__pyx_n_s_sy,&__pyx_n_s_sz,&__pyx_n_s_rotation,0};
    PyObject* values[5] = {0,0,0,0,0};
    values[4] = ((PyObject *)__pyx_tuple__16);
    if (unlikely(__pyx_kwds)) {
      Py_ssize_t kw_args;
      const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
      switch (pos_args) {
        case  5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
        CYTHON_FALLTHROUGH;
        case  4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
        CYTHON_FALLTHROUGH;
        case  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_model)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_sx);
          if (value) { values[1] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_sy);
          if (value) { values[2] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  3:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_sz);
          if (value) { values[3] = value; kw_args--; }
        }
        CYTHON_FALLTHROUGH;
        case  4:
        if (kw_args > 0) {
          PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_rotation);
          if (value) { values[4] = value; kw_args--; }
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "model_list") < 0)) __PYX_ERR(0, 295, __pyx_L3_error)
      }
    } else {
      switch (PyTuple_GET_SIZE(__pyx_args)) {
        case  5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
        CYTHON_FALLTHROUGH;
        case  4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
        CYTHON_FALLTHROUGH;
        case  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        break;
        default: goto __pyx_L5_argtuple_error;
      }
    }
    __pyx_v_model = ((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)values[0]);
    if (values[1]) {
      __pyx_v_sx = __pyx_PyFloat_AsFloat(values[1]); if (unlikely((__pyx_v_sx == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 295, __pyx_L3_error)
    } else {
      __pyx_v_sx = ((float)1.0);
    }
    if (values[2]) {
      __pyx_v_sy = __pyx_PyFloat_AsFloat(values[2]); if (unlikely((__pyx_v_sy == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 295, __pyx_L3_error)
    } else {
      __pyx_v_sy = ((float)1.0);
    }
    if (values[3]) {
      __pyx_v_sz = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_sz == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 295, __pyx_L3_error)
    } else {
      __pyx_v_sz = ((float)1.0);
    }
    __pyx_v_rotation = values[4];
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("model_list", 0, 1, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 295, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.model_list", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return NULL;
  __pyx_L4_argument_unpacking_done:;
  if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_model), __pyx_ptype_9punyverse_6_model_WavefrontObject, 1, "model", 0))) __PYX_ERR(0, 295, __pyx_L1_error)
  __pyx_r = __pyx_pf_9punyverse_6_model_4model_list(__pyx_self, __pyx_v_model, __pyx_v_sx, __pyx_v_sy, __pyx_v_sz, __pyx_v_rotation);

  /* function exit code */
  goto __pyx_L0;
  __pyx_L1_error:;
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_4model_list(CYTHON_UNUSED PyObject *__pyx_self, struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v_model, float __pyx_v_sx, float __pyx_v_sy, float __pyx_v_sz, PyObject *__pyx_v_rotation) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  struct __pyx_opt_args_9punyverse_6_model_model_list __pyx_t_2;
  PyObject *__pyx_t_3 = NULL;
  __Pyx_RefNannySetupContext("model_list", 0);
  __Pyx_XDECREF(__pyx_r);
  __pyx_t_2.__pyx_n = 4;
  __pyx_t_2.sx = __pyx_v_sx;
  __pyx_t_2.sy = __pyx_v_sy;
  __pyx_t_2.sz = __pyx_v_sz;
  __pyx_t_2.rotation = __pyx_v_rotation;
  __pyx_t_1 = __pyx_f_9punyverse_6_model_model_list(__pyx_v_model, 0, &__pyx_t_2); 
  __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 295, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_r = __pyx_t_3;
  __pyx_t_3 = 0;
  goto __pyx_L0;

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_AddTraceback("punyverse._model.model_list", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x87a431c:
 *         from pickle import PickleError as __pyx_PickleError
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_7__pyx_unpickle_Face(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static PyMethodDef __pyx_mdef_9punyverse_6_model_7__pyx_unpickle_Face = {"__pyx_unpickle_Face", (PyCFunction)__pyx_pw_9punyverse_6_model_7__pyx_unpickle_Face, METH_VARARGS|METH_KEYWORDS, 0};
static PyObject *__pyx_pw_9punyverse_6_model_7__pyx_unpickle_Face(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v___pyx_type = 0;
  long __pyx_v___pyx_checksum;
  PyObject *__pyx_v___pyx_state = 0;
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__pyx_unpickle_Face (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
    PyObject* values[3] = {0,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  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_type)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_checksum)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Face", 1, 3, 3, 1); __PYX_ERR(1, 1, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_state)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Face", 1, 3, 3, 2); __PYX_ERR(1, 1, __pyx_L3_error)
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__pyx_unpickle_Face") < 0)) __PYX_ERR(1, 1, __pyx_L3_error)
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
      values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
      values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
    }
    __pyx_v___pyx_type = values[0];
    __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]); if (unlikely((__pyx_v___pyx_checksum == (long)-1) && PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
    __pyx_v___pyx_state = values[2];
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Face", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Face", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return NULL;
  __pyx_L4_argument_unpacking_done:;
  __pyx_r = __pyx_pf_9punyverse_6_model_6__pyx_unpickle_Face(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_6__pyx_unpickle_Face(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_v___pyx_PickleError = NULL;
  PyObject *__pyx_v___pyx_result = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  int __pyx_t_7;
  __Pyx_RefNannySetupContext("__pyx_unpickle_Face", 0);

  /* "(tree fragment)":2
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0x87a431c:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)
 */
  __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x87a431c) != 0);
  if (__pyx_t_1) {

    /* "(tree fragment)":3
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0x87a431c:
 *         from pickle import PickleError as __pyx_PickleError             # <<<<<<<<<<<<<<
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)
 *     __pyx_result = Face.__new__(__pyx_type)
 */
    __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_n_s_PickleError);
    __Pyx_GIVEREF(__pyx_n_s_PickleError);
    PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_PickleError);
    __pyx_t_3 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_2, -1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_3, __pyx_n_s_PickleError); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_t_2);
    __pyx_v___pyx_PickleError = __pyx_t_2;
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":4
 *     if __pyx_checksum != 0x87a431c:
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)             # <<<<<<<<<<<<<<
 *     __pyx_result = Face.__new__(__pyx_type)
 *     if __pyx_state is not None:
 */
    __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x87, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(__pyx_v___pyx_PickleError);
    __pyx_t_2 = __pyx_v___pyx_PickleError; __pyx_t_5 = NULL;
    if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
      __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
      if (likely(__pyx_t_5)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
        __Pyx_INCREF(__pyx_t_5);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_2, function);
      }
    }
    if (!__pyx_t_5) {
      __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      {
        __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_6);
        __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __pyx_t_5 = NULL;
        __Pyx_GIVEREF(__pyx_t_4);
        PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_4);
        __pyx_t_4 = 0;
        __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __PYX_ERR(1, 4, __pyx_L1_error)

    /* "(tree fragment)":2
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0x87a431c:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)
 */
  }

  /* "(tree fragment)":5
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)
 *     __pyx_result = Face.__new__(__pyx_type)             # <<<<<<<<<<<<<<
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 */
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_9punyverse_6_model_Face), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_6 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_6)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_6);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (!__pyx_t_6) {
    __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v___pyx_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    {
      __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); __pyx_t_6 = NULL;
      __Pyx_INCREF(__pyx_v___pyx_type);
      __Pyx_GIVEREF(__pyx_v___pyx_type);
      PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v___pyx_type);
      __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_3);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v___pyx_result = __pyx_t_3;
  __pyx_t_3 = 0;

  /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)
 *     __pyx_result = Face.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  __pyx_t_1 = (__pyx_v___pyx_state != Py_None);
  __pyx_t_7 = (__pyx_t_1 != 0);
  if (__pyx_t_7) {

    /* "(tree fragment)":7
 *     __pyx_result = Face.__new__(__pyx_type)
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)             # <<<<<<<<<<<<<<
 *     return __pyx_result
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):
 */
    if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 7, __pyx_L1_error)
    __pyx_t_3 = __pyx_f_9punyverse_6_model___pyx_unpickle_Face__set_state(((struct __pyx_obj_9punyverse_6_model_Face *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 7, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x87a431c = (normals, norms, texs, textures, type, vertices, verts))" % __pyx_checksum)
 *     __pyx_result = Face.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  }

  /* "(tree fragment)":8
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 *     return __pyx_result             # <<<<<<<<<<<<<<
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v___pyx_result);
  __pyx_r = __pyx_v___pyx_result;
  goto __pyx_L0;

  /* "(tree fragment)":1
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x87a431c:
 *         from pickle import PickleError as __pyx_PickleError
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Face", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v___pyx_PickleError);
  __Pyx_XDECREF(__pyx_v___pyx_result);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":9
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):
 */

static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_Face__set_state(struct __pyx_obj_9punyverse_6_model_Face *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  int __pyx_t_3;
  Py_ssize_t __pyx_t_4;
  int __pyx_t_5;
  int __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  __Pyx_RefNannySetupContext("__pyx_unpickle_Face__set_state", 0);

  /* "(tree fragment)":10
 *     return __pyx_result
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]             # <<<<<<<<<<<<<<
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[7])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->normals);
  __Pyx_DECREF(__pyx_v___pyx_result->normals);
  __pyx_v___pyx_result->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->norms);
  __Pyx_DECREF(__pyx_v___pyx_result->norms);
  __pyx_v___pyx_result->norms = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->texs);
  __Pyx_DECREF(__pyx_v___pyx_result->texs);
  __pyx_v___pyx_result->texs = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->textures);
  __Pyx_DECREF(__pyx_v___pyx_result->textures);
  __pyx_v___pyx_result->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v___pyx_result->type = __pyx_t_2;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->vertices);
  __Pyx_DECREF(__pyx_v___pyx_result->vertices);
  __pyx_v___pyx_result->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->verts);
  __Pyx_DECREF(__pyx_v___pyx_result->verts);
  __pyx_v___pyx_result->verts = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "(tree fragment)":11
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[7])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(1, 11, __pyx_L1_error)
  }
  __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_5 = ((__pyx_t_4 > 7) != 0);
  if (__pyx_t_5) {
  } else {
    __pyx_t_3 = __pyx_t_5;
    goto __pyx_L4_bool_binop_done;
  }
  __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_6 = (__pyx_t_5 != 0);
  __pyx_t_3 = __pyx_t_6;
  __pyx_L4_bool_binop_done:;
  if (__pyx_t_3) {

    /* "(tree fragment)":12
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[7])             # <<<<<<<<<<<<<<
 */
    __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_8);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    if (unlikely(__pyx_v___pyx_state == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(1, 12, __pyx_L1_error)
    }
    __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_9 = NULL;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) {
      __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8);
      if (likely(__pyx_t_9)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8);
        __Pyx_INCREF(__pyx_t_9);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_8, function);
      }
    }
    if (!__pyx_t_9) {
      __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_8)) {
        PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_7};
        __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) {
        PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_7};
        __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      {
        __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_10);
        __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_9); __pyx_t_9 = NULL;
        __Pyx_GIVEREF(__pyx_t_7);
        PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_t_7);
        __pyx_t_7 = 0;
        __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_10, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "(tree fragment)":11
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[7])
 */
  }

  /* "(tree fragment)":9
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Face__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __pyx_unpickle_Material(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0xe74edf8:
 *         from pickle import PickleError as __pyx_PickleError
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_9__pyx_unpickle_Material(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static PyMethodDef __pyx_mdef_9punyverse_6_model_9__pyx_unpickle_Material = {"__pyx_unpickle_Material", (PyCFunction)__pyx_pw_9punyverse_6_model_9__pyx_unpickle_Material, METH_VARARGS|METH_KEYWORDS, 0};
static PyObject *__pyx_pw_9punyverse_6_model_9__pyx_unpickle_Material(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v___pyx_type = 0;
  long __pyx_v___pyx_checksum;
  PyObject *__pyx_v___pyx_state = 0;
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__pyx_unpickle_Material (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
    PyObject* values[3] = {0,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  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_type)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_checksum)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Material", 1, 3, 3, 1); __PYX_ERR(1, 1, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_state)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Material", 1, 3, 3, 2); __PYX_ERR(1, 1, __pyx_L3_error)
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__pyx_unpickle_Material") < 0)) __PYX_ERR(1, 1, __pyx_L3_error)
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
      values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
      values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
    }
    __pyx_v___pyx_type = values[0];
    __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]); if (unlikely((__pyx_v___pyx_checksum == (long)-1) && PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
    __pyx_v___pyx_state = values[2];
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Material", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Material", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return NULL;
  __pyx_L4_argument_unpacking_done:;
  __pyx_r = __pyx_pf_9punyverse_6_model_8__pyx_unpickle_Material(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_8__pyx_unpickle_Material(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_v___pyx_PickleError = NULL;
  PyObject *__pyx_v___pyx_result = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  int __pyx_t_7;
  __Pyx_RefNannySetupContext("__pyx_unpickle_Material", 0);

  /* "(tree fragment)":2
 * def __pyx_unpickle_Material(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0xe74edf8:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)
 */
  __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xe74edf8) != 0);
  if (__pyx_t_1) {

    /* "(tree fragment)":3
 * def __pyx_unpickle_Material(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0xe74edf8:
 *         from pickle import PickleError as __pyx_PickleError             # <<<<<<<<<<<<<<
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)
 *     __pyx_result = Material.__new__(__pyx_type)
 */
    __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_n_s_PickleError);
    __Pyx_GIVEREF(__pyx_n_s_PickleError);
    PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_PickleError);
    __pyx_t_3 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_2, -1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_3, __pyx_n_s_PickleError); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_t_2);
    __pyx_v___pyx_PickleError = __pyx_t_2;
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":4
 *     if __pyx_checksum != 0xe74edf8:
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)             # <<<<<<<<<<<<<<
 *     __pyx_result = Material.__new__(__pyx_type)
 *     if __pyx_state is not None:
 */
    __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xe7, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(__pyx_v___pyx_PickleError);
    __pyx_t_2 = __pyx_v___pyx_PickleError; __pyx_t_5 = NULL;
    if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
      __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
      if (likely(__pyx_t_5)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
        __Pyx_INCREF(__pyx_t_5);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_2, function);
      }
    }
    if (!__pyx_t_5) {
      __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      {
        __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_6);
        __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __pyx_t_5 = NULL;
        __Pyx_GIVEREF(__pyx_t_4);
        PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_4);
        __pyx_t_4 = 0;
        __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __PYX_ERR(1, 4, __pyx_L1_error)

    /* "(tree fragment)":2
 * def __pyx_unpickle_Material(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0xe74edf8:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)
 */
  }

  /* "(tree fragment)":5
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)
 *     __pyx_result = Material.__new__(__pyx_type)             # <<<<<<<<<<<<<<
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)
 */
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_9punyverse_6_model_Material), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_6 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_6)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_6);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (!__pyx_t_6) {
    __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v___pyx_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    {
      __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); __pyx_t_6 = NULL;
      __Pyx_INCREF(__pyx_v___pyx_type);
      __Pyx_GIVEREF(__pyx_v___pyx_type);
      PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v___pyx_type);
      __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_3);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v___pyx_result = __pyx_t_3;
  __pyx_t_3 = 0;

  /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)
 *     __pyx_result = Material.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  __pyx_t_1 = (__pyx_v___pyx_state != Py_None);
  __pyx_t_7 = (__pyx_t_1 != 0);
  if (__pyx_t_7) {

    /* "(tree fragment)":7
 *     __pyx_result = Material.__new__(__pyx_type)
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)             # <<<<<<<<<<<<<<
 *     return __pyx_result
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):
 */
    if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 7, __pyx_L1_error)
    __pyx_t_3 = __pyx_f_9punyverse_6_model___pyx_unpickle_Material__set_state(((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 7, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xe74edf8 = (Ka, Kd, Ks, name, shininess, texture))" % __pyx_checksum)
 *     __pyx_result = Material.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  }

  /* "(tree fragment)":8
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)
 *     return __pyx_result             # <<<<<<<<<<<<<<
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v___pyx_result);
  __pyx_r = __pyx_v___pyx_result;
  goto __pyx_L0;

  /* "(tree fragment)":1
 * def __pyx_unpickle_Material(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0xe74edf8:
 *         from pickle import PickleError as __pyx_PickleError
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Material", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v___pyx_PickleError);
  __Pyx_XDECREF(__pyx_v___pyx_result);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":9
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]
 *     if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
 */

static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_Material__set_state(struct __pyx_obj_9punyverse_6_model_Material *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  double __pyx_t_2;
  int __pyx_t_3;
  Py_ssize_t __pyx_t_4;
  int __pyx_t_5;
  int __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  __Pyx_RefNannySetupContext("__pyx_unpickle_Material__set_state", 0);

  /* "(tree fragment)":10
 *     return __pyx_result
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]             # <<<<<<<<<<<<<<
 *     if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[6])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->Ka);
  __Pyx_DECREF(__pyx_v___pyx_result->Ka);
  __pyx_v___pyx_result->Ka = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->Kd);
  __Pyx_DECREF(__pyx_v___pyx_result->Kd);
  __pyx_v___pyx_result->Kd = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->Ks);
  __Pyx_DECREF(__pyx_v___pyx_result->Ks);
  __pyx_v___pyx_result->Ks = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyString_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->name);
  __Pyx_DECREF(__pyx_v___pyx_result->name);
  __pyx_v___pyx_result->name = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __pyx_PyFloat_AsDouble(__pyx_t_1); if (unlikely((__pyx_t_2 == (double)-1) && PyErr_Occurred())) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v___pyx_result->shininess = __pyx_t_2;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyString_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->texture);
  __Pyx_DECREF(__pyx_v___pyx_result->texture);
  __pyx_v___pyx_result->texture = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "(tree fragment)":11
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]
 *     if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[6])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(1, 11, __pyx_L1_error)
  }
  __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_5 = ((__pyx_t_4 > 6) != 0);
  if (__pyx_t_5) {
  } else {
    __pyx_t_3 = __pyx_t_5;
    goto __pyx_L4_bool_binop_done;
  }
  __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_6 = (__pyx_t_5 != 0);
  __pyx_t_3 = __pyx_t_6;
  __pyx_L4_bool_binop_done:;
  if (__pyx_t_3) {

    /* "(tree fragment)":12
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]
 *     if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[6])             # <<<<<<<<<<<<<<
 */
    __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_8);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    if (unlikely(__pyx_v___pyx_state == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(1, 12, __pyx_L1_error)
    }
    __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_9 = NULL;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) {
      __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8);
      if (likely(__pyx_t_9)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8);
        __Pyx_INCREF(__pyx_t_9);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_8, function);
      }
    }
    if (!__pyx_t_9) {
      __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_8)) {
        PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_7};
        __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) {
        PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_7};
        __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      {
        __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_10);
        __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_9); __pyx_t_9 = NULL;
        __Pyx_GIVEREF(__pyx_t_7);
        PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_t_7);
        __pyx_t_7 = 0;
        __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_10, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "(tree fragment)":11
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]
 *     if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[6])
 */
  }

  /* "(tree fragment)":9
 *         __pyx_unpickle_Material__set_state(<Material> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Material__set_state(Material __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.Ka = __pyx_state[0]; __pyx_result.Kd = __pyx_state[1]; __pyx_result.Ks = __pyx_state[2]; __pyx_result.name = __pyx_state[3]; __pyx_result.shininess = __pyx_state[4]; __pyx_result.texture = __pyx_state[5]
 *     if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Material__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __pyx_unpickle_Group(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x1b43f52:
 *         from pickle import PickleError as __pyx_PickleError
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_11__pyx_unpickle_Group(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static PyMethodDef __pyx_mdef_9punyverse_6_model_11__pyx_unpickle_Group = {"__pyx_unpickle_Group", (PyCFunction)__pyx_pw_9punyverse_6_model_11__pyx_unpickle_Group, METH_VARARGS|METH_KEYWORDS, 0};
static PyObject *__pyx_pw_9punyverse_6_model_11__pyx_unpickle_Group(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v___pyx_type = 0;
  long __pyx_v___pyx_checksum;
  PyObject *__pyx_v___pyx_state = 0;
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__pyx_unpickle_Group (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
    PyObject* values[3] = {0,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  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_type)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_checksum)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Group", 1, 3, 3, 1); __PYX_ERR(1, 1, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_state)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Group", 1, 3, 3, 2); __PYX_ERR(1, 1, __pyx_L3_error)
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__pyx_unpickle_Group") < 0)) __PYX_ERR(1, 1, __pyx_L3_error)
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
      values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
      values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
    }
    __pyx_v___pyx_type = values[0];
    __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]); if (unlikely((__pyx_v___pyx_checksum == (long)-1) && PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
    __pyx_v___pyx_state = values[2];
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Group", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Group", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return NULL;
  __pyx_L4_argument_unpacking_done:;
  __pyx_r = __pyx_pf_9punyverse_6_model_10__pyx_unpickle_Group(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_10__pyx_unpickle_Group(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_v___pyx_PickleError = NULL;
  PyObject *__pyx_v___pyx_result = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  int __pyx_t_7;
  __Pyx_RefNannySetupContext("__pyx_unpickle_Group", 0);

  /* "(tree fragment)":2
 * def __pyx_unpickle_Group(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0x1b43f52:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)
 */
  __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x1b43f52) != 0);
  if (__pyx_t_1) {

    /* "(tree fragment)":3
 * def __pyx_unpickle_Group(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0x1b43f52:
 *         from pickle import PickleError as __pyx_PickleError             # <<<<<<<<<<<<<<
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = Group.__new__(__pyx_type)
 */
    __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_n_s_PickleError);
    __Pyx_GIVEREF(__pyx_n_s_PickleError);
    PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_PickleError);
    __pyx_t_3 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_2, -1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_3, __pyx_n_s_PickleError); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_t_2);
    __pyx_v___pyx_PickleError = __pyx_t_2;
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":4
 *     if __pyx_checksum != 0x1b43f52:
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)             # <<<<<<<<<<<<<<
 *     __pyx_result = Group.__new__(__pyx_type)
 *     if __pyx_state is not None:
 */
    __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x1b, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(__pyx_v___pyx_PickleError);
    __pyx_t_2 = __pyx_v___pyx_PickleError; __pyx_t_5 = NULL;
    if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
      __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
      if (likely(__pyx_t_5)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
        __Pyx_INCREF(__pyx_t_5);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_2, function);
      }
    }
    if (!__pyx_t_5) {
      __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      {
        __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_6);
        __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __pyx_t_5 = NULL;
        __Pyx_GIVEREF(__pyx_t_4);
        PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_4);
        __pyx_t_4 = 0;
        __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __PYX_ERR(1, 4, __pyx_L1_error)

    /* "(tree fragment)":2
 * def __pyx_unpickle_Group(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0x1b43f52:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)
 */
  }

  /* "(tree fragment)":5
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = Group.__new__(__pyx_type)             # <<<<<<<<<<<<<<
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 */
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_9punyverse_6_model_Group), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_6 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_6)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_6);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (!__pyx_t_6) {
    __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v___pyx_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    {
      __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); __pyx_t_6 = NULL;
      __Pyx_INCREF(__pyx_v___pyx_type);
      __Pyx_GIVEREF(__pyx_v___pyx_type);
      PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v___pyx_type);
      __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_3);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v___pyx_result = __pyx_t_3;
  __pyx_t_3 = 0;

  /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = Group.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  __pyx_t_1 = (__pyx_v___pyx_state != Py_None);
  __pyx_t_7 = (__pyx_t_1 != 0);
  if (__pyx_t_7) {

    /* "(tree fragment)":7
 *     __pyx_result = Group.__new__(__pyx_type)
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)             # <<<<<<<<<<<<<<
 *     return __pyx_result
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):
 */
    if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 7, __pyx_L1_error)
    __pyx_t_3 = __pyx_f_9punyverse_6_model___pyx_unpickle_Group__set_state(((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 7, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0x1b43f52 = (faces, idx_count, indices, material, min, name, normals, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = Group.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  }

  /* "(tree fragment)":8
 *     if __pyx_state is not None:
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 *     return __pyx_result             # <<<<<<<<<<<<<<
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v___pyx_result);
  __pyx_r = __pyx_v___pyx_result;
  goto __pyx_L0;

  /* "(tree fragment)":1
 * def __pyx_unpickle_Group(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x1b43f52:
 *         from pickle import PickleError as __pyx_PickleError
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Group", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v___pyx_PickleError);
  __Pyx_XDECREF(__pyx_v___pyx_result);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":9
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 */

static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_Group__set_state(struct __pyx_obj_9punyverse_6_model_Group *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  int __pyx_t_3;
  Py_ssize_t __pyx_t_4;
  int __pyx_t_5;
  int __pyx_t_6;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  PyObject *__pyx_t_10 = NULL;
  __Pyx_RefNannySetupContext("__pyx_unpickle_Group__set_state", 0);

  /* "(tree fragment)":10
 *     return __pyx_result
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]             # <<<<<<<<<<<<<<
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[9])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->faces);
  __Pyx_DECREF(__pyx_v___pyx_result->faces);
  __pyx_v___pyx_result->faces = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_v___pyx_result->idx_count = __pyx_t_2;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->indices);
  __Pyx_DECREF(__pyx_v___pyx_result->indices);
  __pyx_v___pyx_result->indices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_9punyverse_6_model_Material))))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->material);
  __Pyx_DECREF(((PyObject *)__pyx_v___pyx_result->material));
  __pyx_v___pyx_result->material = ((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyTuple_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->min);
  __Pyx_DECREF(__pyx_v___pyx_result->min);
  __pyx_v___pyx_result->min = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyString_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "str", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->name);
  __Pyx_DECREF(__pyx_v___pyx_result->name);
  __pyx_v___pyx_result->name = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->normals);
  __Pyx_DECREF(__pyx_v___pyx_result->normals);
  __pyx_v___pyx_result->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->textures);
  __Pyx_DECREF(__pyx_v___pyx_result->textures);
  __pyx_v___pyx_result->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->vertices);
  __Pyx_DECREF(__pyx_v___pyx_result->vertices);
  __pyx_v___pyx_result->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "(tree fragment)":11
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[9])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(1, 11, __pyx_L1_error)
  }
  __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_5 = ((__pyx_t_4 > 9) != 0);
  if (__pyx_t_5) {
  } else {
    __pyx_t_3 = __pyx_t_5;
    goto __pyx_L4_bool_binop_done;
  }
  __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_6 = (__pyx_t_5 != 0);
  __pyx_t_3 = __pyx_t_6;
  __pyx_L4_bool_binop_done:;
  if (__pyx_t_3) {

    /* "(tree fragment)":12
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[9])             # <<<<<<<<<<<<<<
 */
    __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_8);
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    if (unlikely(__pyx_v___pyx_state == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(1, 12, __pyx_L1_error)
    }
    __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 9, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __pyx_t_9 = NULL;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) {
      __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8);
      if (likely(__pyx_t_9)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8);
        __Pyx_INCREF(__pyx_t_9);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_8, function);
      }
    }
    if (!__pyx_t_9) {
      __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_8)) {
        PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_7};
        __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) {
        PyObject *__pyx_temp[2] = {__pyx_t_9, __pyx_t_7};
        __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
      } else
      #endif
      {
        __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_10);
        __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_9); __pyx_t_9 = NULL;
        __Pyx_GIVEREF(__pyx_t_7);
        PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_t_7);
        __pyx_t_7 = 0;
        __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_10, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "(tree fragment)":11
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[9])
 */
  }

  /* "(tree fragment)":9
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_XDECREF(__pyx_t_10);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_Group__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":1
 * def __pyx_unpickle_WavefrontObject(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0xa5bde08:
 *         from pickle import PickleError as __pyx_PickleError
 */

/* Python wrapper */
static PyObject *__pyx_pw_9punyverse_6_model_13__pyx_unpickle_WavefrontObject(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
static PyMethodDef __pyx_mdef_9punyverse_6_model_13__pyx_unpickle_WavefrontObject = {"__pyx_unpickle_WavefrontObject", (PyCFunction)__pyx_pw_9punyverse_6_model_13__pyx_unpickle_WavefrontObject, METH_VARARGS|METH_KEYWORDS, 0};
static PyObject *__pyx_pw_9punyverse_6_model_13__pyx_unpickle_WavefrontObject(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  PyObject *__pyx_v___pyx_type = 0;
  long __pyx_v___pyx_checksum;
  PyObject *__pyx_v___pyx_state = 0;
  PyObject *__pyx_r = 0;
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__pyx_unpickle_WavefrontObject (wrapper)", 0);
  {
    static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
    PyObject* values[3] = {0,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  3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
        CYTHON_FALLTHROUGH;
        case  2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
        CYTHON_FALLTHROUGH;
        case  1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
        CYTHON_FALLTHROUGH;
        case  0: break;
        default: goto __pyx_L5_argtuple_error;
      }
      kw_args = PyDict_Size(__pyx_kwds);
      switch (pos_args) {
        case  0:
        if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_type)) != 0)) kw_args--;
        else goto __pyx_L5_argtuple_error;
        CYTHON_FALLTHROUGH;
        case  1:
        if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_checksum)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_WavefrontObject", 1, 3, 3, 1); __PYX_ERR(1, 1, __pyx_L3_error)
        }
        CYTHON_FALLTHROUGH;
        case  2:
        if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_state)) != 0)) kw_args--;
        else {
          __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_WavefrontObject", 1, 3, 3, 2); __PYX_ERR(1, 1, __pyx_L3_error)
        }
      }
      if (unlikely(kw_args > 0)) {
        if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__pyx_unpickle_WavefrontObject") < 0)) __PYX_ERR(1, 1, __pyx_L3_error)
      }
    } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
      goto __pyx_L5_argtuple_error;
    } else {
      values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
      values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
      values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
    }
    __pyx_v___pyx_type = values[0];
    __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]); if (unlikely((__pyx_v___pyx_checksum == (long)-1) && PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
    __pyx_v___pyx_state = values[2];
  }
  goto __pyx_L4_argument_unpacking_done;
  __pyx_L5_argtuple_error:;
  __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_WavefrontObject", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1, __pyx_L3_error)
  __pyx_L3_error:;
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_WavefrontObject", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __Pyx_RefNannyFinishContext();
  return NULL;
  __pyx_L4_argument_unpacking_done:;
  __pyx_r = __pyx_pf_9punyverse_6_model_12__pyx_unpickle_WavefrontObject(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);

  /* function exit code */
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_pf_9punyverse_6_model_12__pyx_unpickle_WavefrontObject(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_v___pyx_PickleError = NULL;
  PyObject *__pyx_v___pyx_result = NULL;
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  int __pyx_t_1;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  PyObject *__pyx_t_4 = NULL;
  PyObject *__pyx_t_5 = NULL;
  PyObject *__pyx_t_6 = NULL;
  int __pyx_t_7;
  __Pyx_RefNannySetupContext("__pyx_unpickle_WavefrontObject", 0);

  /* "(tree fragment)":2
 * def __pyx_unpickle_WavefrontObject(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0xa5bde08:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)
 */
  __pyx_t_1 = ((__pyx_v___pyx_checksum != 0xa5bde08) != 0);
  if (__pyx_t_1) {

    /* "(tree fragment)":3
 * def __pyx_unpickle_WavefrontObject(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0xa5bde08:
 *         from pickle import PickleError as __pyx_PickleError             # <<<<<<<<<<<<<<
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = WavefrontObject.__new__(__pyx_type)
 */
    __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_n_s_PickleError);
    __Pyx_GIVEREF(__pyx_n_s_PickleError);
    PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_PickleError);
    __pyx_t_3 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_2, -1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_3, __pyx_n_s_PickleError); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 3, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __Pyx_INCREF(__pyx_t_2);
    __pyx_v___pyx_PickleError = __pyx_t_2;
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":4
 *     if __pyx_checksum != 0xa5bde08:
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)             # <<<<<<<<<<<<<<
 *     __pyx_result = WavefrontObject.__new__(__pyx_type)
 *     if __pyx_state is not None:
 */
    __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_2);
    __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0xa5, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 4, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_4);
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_INCREF(__pyx_v___pyx_PickleError);
    __pyx_t_2 = __pyx_v___pyx_PickleError; __pyx_t_5 = NULL;
    if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
      __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
      if (likely(__pyx_t_5)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
        __Pyx_INCREF(__pyx_t_5);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_2, function);
      }
    }
    if (!__pyx_t_5) {
      __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
        PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_4};
        __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
      } else
      #endif
      {
        __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_6);
        __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __pyx_t_5 = NULL;
        __Pyx_GIVEREF(__pyx_t_4);
        PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_4);
        __pyx_t_4 = 0;
        __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 4, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_3);
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
    __Pyx_Raise(__pyx_t_3, 0, 0, 0);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
    __PYX_ERR(1, 4, __pyx_L1_error)

    /* "(tree fragment)":2
 * def __pyx_unpickle_WavefrontObject(__pyx_type, long __pyx_checksum, __pyx_state):
 *     if __pyx_checksum != 0xa5bde08:             # <<<<<<<<<<<<<<
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)
 */
  }

  /* "(tree fragment)":5
 *         from pickle import PickleError as __pyx_PickleError
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = WavefrontObject.__new__(__pyx_type)             # <<<<<<<<<<<<<<
 *     if __pyx_state is not None:
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)
 */
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_9punyverse_6_model_WavefrontObject), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_6 = NULL;
  if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
    __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_2);
    if (likely(__pyx_t_6)) {
      PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
      __Pyx_INCREF(__pyx_t_6);
      __Pyx_INCREF(function);
      __Pyx_DECREF_SET(__pyx_t_2, function);
    }
  }
  if (!__pyx_t_6) {
    __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v___pyx_type); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
  } else {
    #if CYTHON_FAST_PYCALL
    if (PyFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    #if CYTHON_FAST_PYCCALL
    if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
      PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_v___pyx_type};
      __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_3);
    } else
    #endif
    {
      __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_4);
      __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_6); __pyx_t_6 = NULL;
      __Pyx_INCREF(__pyx_v___pyx_type);
      __Pyx_GIVEREF(__pyx_v___pyx_type);
      PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v___pyx_type);
      __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
      __Pyx_GOTREF(__pyx_t_3);
      __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
    }
  }
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_v___pyx_result = __pyx_t_3;
  __pyx_t_3 = 0;

  /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = WavefrontObject.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  __pyx_t_1 = (__pyx_v___pyx_state != Py_None);
  __pyx_t_7 = (__pyx_t_1 != 0);
  if (__pyx_t_7) {

    /* "(tree fragment)":7
 *     __pyx_result = WavefrontObject.__new__(__pyx_type)
 *     if __pyx_state is not None:
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)             # <<<<<<<<<<<<<<
 *     return __pyx_result
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):
 */
    if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 7, __pyx_L1_error)
    __pyx_t_3 = __pyx_f_9punyverse_6_model___pyx_unpickle_WavefrontObject__set_state(((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 7, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_3);
    __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

    /* "(tree fragment)":6
 *         raise __pyx_PickleError("Incompatible checksums (%s vs 0xa5bde08 = (current_group, current_material, groups, materials, normals, path, root, textures, vertices))" % __pyx_checksum)
 *     __pyx_result = WavefrontObject.__new__(__pyx_type)
 *     if __pyx_state is not None:             # <<<<<<<<<<<<<<
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)
 *     return __pyx_result
 */
  }

  /* "(tree fragment)":8
 *     if __pyx_state is not None:
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)
 *     return __pyx_result             # <<<<<<<<<<<<<<
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 */
  __Pyx_XDECREF(__pyx_r);
  __Pyx_INCREF(__pyx_v___pyx_result);
  __pyx_r = __pyx_v___pyx_result;
  goto __pyx_L0;

  /* "(tree fragment)":1
 * def __pyx_unpickle_WavefrontObject(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0xa5bde08:
 *         from pickle import PickleError as __pyx_PickleError
 */

  /* function exit code */
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  __Pyx_XDECREF(__pyx_t_4);
  __Pyx_XDECREF(__pyx_t_5);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_WavefrontObject", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = NULL;
  __pyx_L0:;
  __Pyx_XDECREF(__pyx_v___pyx_PickleError);
  __Pyx_XDECREF(__pyx_v___pyx_result);
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

/* "(tree fragment)":9
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 */

static PyObject *__pyx_f_9punyverse_6_model___pyx_unpickle_WavefrontObject__set_state(struct __pyx_obj_9punyverse_6_model_WavefrontObject *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
  PyObject *__pyx_r = NULL;
  __Pyx_RefNannyDeclarations
  PyObject *__pyx_t_1 = NULL;
  int __pyx_t_2;
  Py_ssize_t __pyx_t_3;
  int __pyx_t_4;
  int __pyx_t_5;
  PyObject *__pyx_t_6 = NULL;
  PyObject *__pyx_t_7 = NULL;
  PyObject *__pyx_t_8 = NULL;
  PyObject *__pyx_t_9 = NULL;
  __Pyx_RefNannySetupContext("__pyx_unpickle_WavefrontObject__set_state", 0);

  /* "(tree fragment)":10
 *     return __pyx_result
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]             # <<<<<<<<<<<<<<
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[9])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_9punyverse_6_model_Group))))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->current_group);
  __Pyx_DECREF(((PyObject *)__pyx_v___pyx_result->current_group));
  __pyx_v___pyx_result->current_group = ((struct __pyx_obj_9punyverse_6_model_Group *)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_9punyverse_6_model_Material))))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->current_material);
  __Pyx_DECREF(((PyObject *)__pyx_v___pyx_result->current_material));
  __pyx_v___pyx_result->current_material = ((struct __pyx_obj_9punyverse_6_model_Material *)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->groups);
  __Pyx_DECREF(__pyx_v___pyx_result->groups);
  __pyx_v___pyx_result->groups = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyDict_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->materials);
  __Pyx_DECREF(__pyx_v___pyx_result->materials);
  __pyx_v___pyx_result->materials = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->normals);
  __Pyx_DECREF(__pyx_v___pyx_result->normals);
  __pyx_v___pyx_result->normals = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->path);
  __Pyx_DECREF(__pyx_v___pyx_result->path);
  __pyx_v___pyx_result->path = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->root);
  __Pyx_DECREF(__pyx_v___pyx_result->root);
  __pyx_v___pyx_result->root = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 7, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->textures);
  __Pyx_DECREF(__pyx_v___pyx_result->textures);
  __pyx_v___pyx_result->textures = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
    __PYX_ERR(1, 10, __pyx_L1_error)
  }
  __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 8, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 10, __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 %.16s, got %.200s", "list", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(1, 10, __pyx_L1_error)
  __Pyx_GIVEREF(__pyx_t_1);
  __Pyx_GOTREF(__pyx_v___pyx_result->vertices);
  __Pyx_DECREF(__pyx_v___pyx_result->vertices);
  __pyx_v___pyx_result->vertices = ((PyObject*)__pyx_t_1);
  __pyx_t_1 = 0;

  /* "(tree fragment)":11
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[9])
 */
  if (unlikely(__pyx_v___pyx_state == Py_None)) {
    PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
    __PYX_ERR(1, 11, __pyx_L1_error)
  }
  __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_4 = ((__pyx_t_3 > 9) != 0);
  if (__pyx_t_4) {
  } else {
    __pyx_t_2 = __pyx_t_4;
    goto __pyx_L4_bool_binop_done;
  }
  __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(1, 11, __pyx_L1_error)
  __pyx_t_5 = (__pyx_t_4 != 0);
  __pyx_t_2 = __pyx_t_5;
  __pyx_L4_bool_binop_done:;
  if (__pyx_t_2) {

    /* "(tree fragment)":12
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 *         __pyx_result.__dict__.update(__pyx_state[9])             # <<<<<<<<<<<<<<
 */
    __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_7);
    __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
    if (unlikely(__pyx_v___pyx_state == Py_None)) {
      PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
      __PYX_ERR(1, 12, __pyx_L1_error)
    }
    __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 9, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 12, __pyx_L1_error)
    __Pyx_GOTREF(__pyx_t_6);
    __pyx_t_8 = NULL;
    if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) {
      __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7);
      if (likely(__pyx_t_8)) {
        PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7);
        __Pyx_INCREF(__pyx_t_8);
        __Pyx_INCREF(function);
        __Pyx_DECREF_SET(__pyx_t_7, function);
      }
    }
    if (!__pyx_t_8) {
      __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
      __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      __Pyx_GOTREF(__pyx_t_1);
    } else {
      #if CYTHON_FAST_PYCALL
      if (PyFunction_Check(__pyx_t_7)) {
        PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_6};
        __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      } else
      #endif
      #if CYTHON_FAST_PYCCALL
      if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) {
        PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_6};
        __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
      } else
      #endif
      {
        __pyx_t_9 = PyTuple_New(1+1); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_9);
        __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL;
        __Pyx_GIVEREF(__pyx_t_6);
        PyTuple_SET_ITEM(__pyx_t_9, 0+1, __pyx_t_6);
        __pyx_t_6 = 0;
        __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
        __Pyx_GOTREF(__pyx_t_1);
        __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
      }
    }
    __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
    __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

    /* "(tree fragment)":11
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):             # <<<<<<<<<<<<<<
 *         __pyx_result.__dict__.update(__pyx_state[9])
 */
  }

  /* "(tree fragment)":9
 *         __pyx_unpickle_WavefrontObject__set_state(<WavefrontObject> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_WavefrontObject__set_state(WavefrontObject __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.current_group = __pyx_state[0]; __pyx_result.current_material = __pyx_state[1]; __pyx_result.groups = __pyx_state[2]; __pyx_result.materials = __pyx_state[3]; __pyx_result.normals = __pyx_state[4]; __pyx_result.path = __pyx_state[5]; __pyx_result.root = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 */

  /* function exit code */
  __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_6);
  __Pyx_XDECREF(__pyx_t_7);
  __Pyx_XDECREF(__pyx_t_8);
  __Pyx_XDECREF(__pyx_t_9);
  __Pyx_AddTraceback("punyverse._model.__pyx_unpickle_WavefrontObject__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
  __pyx_r = 0;
  __pyx_L0:;
  __Pyx_XGIVEREF(__pyx_r);
  __Pyx_RefNannyFinishContext();
  return __pyx_r;
}

static PyObject *__pyx_tp_new_9punyverse_6_model_Face(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  struct __pyx_obj_9punyverse_6_model_Face *p;
  PyObject *o;
  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
    o = (*t->tp_alloc)(t, 0);
  } else {
    o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  }
  if (unlikely(!o)) return 0;
  p = ((struct __pyx_obj_9punyverse_6_model_Face *)o);
  p->verts = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->norms = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->texs = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->normals = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->textures = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_9punyverse_6_model_Face(PyObject *o) {
  struct __pyx_obj_9punyverse_6_model_Face *p = (struct __pyx_obj_9punyverse_6_model_Face *)o;
  #if CYTHON_USE_TP_FINALIZE
  if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
    if (PyObject_CallFinalizerFromDealloc(o)) return;
  }
  #endif
  PyObject_GC_UnTrack(o);
  Py_CLEAR(p->verts);
  Py_CLEAR(p->norms);
  Py_CLEAR(p->texs);
  Py_CLEAR(p->vertices);
  Py_CLEAR(p->normals);
  Py_CLEAR(p->textures);
  (*Py_TYPE(o)->tp_free)(o);
}

static int __pyx_tp_traverse_9punyverse_6_model_Face(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_9punyverse_6_model_Face *p = (struct __pyx_obj_9punyverse_6_model_Face *)o;
  if (p->verts) {
    e = (*v)(p->verts, a); if (e) return e;
  }
  if (p->norms) {
    e = (*v)(p->norms, a); if (e) return e;
  }
  if (p->texs) {
    e = (*v)(p->texs, a); if (e) return e;
  }
  if (p->vertices) {
    e = (*v)(p->vertices, a); if (e) return e;
  }
  if (p->normals) {
    e = (*v)(p->normals, a); if (e) return e;
  }
  if (p->textures) {
    e = (*v)(p->textures, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_9punyverse_6_model_Face(PyObject *o) {
  PyObject* tmp;
  struct __pyx_obj_9punyverse_6_model_Face *p = (struct __pyx_obj_9punyverse_6_model_Face *)o;
  tmp = ((PyObject*)p->verts);
  p->verts = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->norms);
  p->norms = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->texs);
  p->texs = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->vertices);
  p->vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->normals);
  p->normals = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->textures);
  p->textures = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_type(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_4type_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_type(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_4type_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_verts(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_5verts_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_verts(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_5verts_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_4Face_5verts_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_norms(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_5norms_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_norms(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_5norms_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_4Face_5norms_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_texs(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_4texs_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_texs(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_4texs_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_4Face_4texs_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_vertices(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_8vertices_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_vertices(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_8vertices_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_4Face_8vertices_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_normals(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_7normals_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_normals(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_7normals_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_4Face_7normals_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_4Face_textures(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_4Face_8textures_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_4Face_textures(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_4Face_8textures_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_4Face_8textures_5__del__(o);
  }
}

static PyMethodDef __pyx_methods_9punyverse_6_model_Face[] = {
  {"__reduce_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_4Face_3__reduce_cython__, METH_NOARGS, 0},
  {"__setstate_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_4Face_5__setstate_cython__, METH_O, 0},
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_9punyverse_6_model_Face[] = {
  {(char *)"type", __pyx_getprop_9punyverse_6_model_4Face_type, __pyx_setprop_9punyverse_6_model_4Face_type, (char *)0, 0},
  {(char *)"verts", __pyx_getprop_9punyverse_6_model_4Face_verts, __pyx_setprop_9punyverse_6_model_4Face_verts, (char *)0, 0},
  {(char *)"norms", __pyx_getprop_9punyverse_6_model_4Face_norms, __pyx_setprop_9punyverse_6_model_4Face_norms, (char *)0, 0},
  {(char *)"texs", __pyx_getprop_9punyverse_6_model_4Face_texs, __pyx_setprop_9punyverse_6_model_4Face_texs, (char *)0, 0},
  {(char *)"vertices", __pyx_getprop_9punyverse_6_model_4Face_vertices, __pyx_setprop_9punyverse_6_model_4Face_vertices, (char *)0, 0},
  {(char *)"normals", __pyx_getprop_9punyverse_6_model_4Face_normals, __pyx_setprop_9punyverse_6_model_4Face_normals, (char *)0, 0},
  {(char *)"textures", __pyx_getprop_9punyverse_6_model_4Face_textures, __pyx_setprop_9punyverse_6_model_4Face_textures, (char *)0, 0},
  {0, 0, 0, 0, 0}
};

static PyTypeObject __pyx_type_9punyverse_6_model_Face = {
  PyVarObject_HEAD_INIT(0, 0)
  "punyverse._model.Face", /*tp_name*/
  sizeof(struct __pyx_obj_9punyverse_6_model_Face), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_9punyverse_6_model_Face, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #endif
  #if PY_MAJOR_VERSION >= 3
  0, /*tp_as_async*/
  #endif
  0, /*tp_repr*/
  0, /*tp_as_number*/
  0, /*tp_as_sequence*/
  0, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  0, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  0, /*tp_doc*/
  __pyx_tp_traverse_9punyverse_6_model_Face, /*tp_traverse*/
  __pyx_tp_clear_9punyverse_6_model_Face, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_9punyverse_6_model_Face, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_9punyverse_6_model_Face, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_9punyverse_6_model_4Face_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_9punyverse_6_model_Face, /*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*/
  0, /*tp_version_tag*/
  #if PY_VERSION_HEX >= 0x030400a1
  0, /*tp_finalize*/
  #endif
};

static PyObject *__pyx_tp_new_9punyverse_6_model_Material(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  struct __pyx_obj_9punyverse_6_model_Material *p;
  PyObject *o;
  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
    o = (*t->tp_alloc)(t, 0);
  } else {
    o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  }
  if (unlikely(!o)) return 0;
  p = ((struct __pyx_obj_9punyverse_6_model_Material *)o);
  p->name = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->texture = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->Ka = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->Kd = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->Ks = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_9punyverse_6_model_Material(PyObject *o) {
  struct __pyx_obj_9punyverse_6_model_Material *p = (struct __pyx_obj_9punyverse_6_model_Material *)o;
  #if CYTHON_USE_TP_FINALIZE
  if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
    if (PyObject_CallFinalizerFromDealloc(o)) return;
  }
  #endif
  PyObject_GC_UnTrack(o);
  Py_CLEAR(p->name);
  Py_CLEAR(p->texture);
  Py_CLEAR(p->Ka);
  Py_CLEAR(p->Kd);
  Py_CLEAR(p->Ks);
  (*Py_TYPE(o)->tp_free)(o);
}

static int __pyx_tp_traverse_9punyverse_6_model_Material(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_9punyverse_6_model_Material *p = (struct __pyx_obj_9punyverse_6_model_Material *)o;
  if (p->Ka) {
    e = (*v)(p->Ka, a); if (e) return e;
  }
  if (p->Kd) {
    e = (*v)(p->Kd, a); if (e) return e;
  }
  if (p->Ks) {
    e = (*v)(p->Ks, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_9punyverse_6_model_Material(PyObject *o) {
  PyObject* tmp;
  struct __pyx_obj_9punyverse_6_model_Material *p = (struct __pyx_obj_9punyverse_6_model_Material *)o;
  tmp = ((PyObject*)p->Ka);
  p->Ka = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->Kd);
  p->Kd = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->Ks);
  p->Ks = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_9punyverse_6_model_8Material_name(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_8Material_4name_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_8Material_name(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_8Material_4name_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_8Material_4name_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_8Material_texture(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_8Material_7texture_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_8Material_texture(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_8Material_7texture_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_8Material_7texture_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_8Material_Ka(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_8Material_2Ka_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_8Material_Ka(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_8Material_2Ka_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_8Material_2Ka_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_8Material_Kd(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_8Material_2Kd_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_8Material_Kd(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_8Material_2Kd_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_8Material_2Kd_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_8Material_Ks(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_8Material_2Ks_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_8Material_Ks(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_8Material_2Ks_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_8Material_2Ks_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_8Material_shininess(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_8Material_9shininess_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_8Material_shininess(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_8Material_9shininess_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_9punyverse_6_model_Material[] = {
  {"__reduce_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_8Material_3__reduce_cython__, METH_NOARGS, 0},
  {"__setstate_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_8Material_5__setstate_cython__, METH_O, 0},
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_9punyverse_6_model_Material[] = {
  {(char *)"name", __pyx_getprop_9punyverse_6_model_8Material_name, __pyx_setprop_9punyverse_6_model_8Material_name, (char *)0, 0},
  {(char *)"texture", __pyx_getprop_9punyverse_6_model_8Material_texture, __pyx_setprop_9punyverse_6_model_8Material_texture, (char *)0, 0},
  {(char *)"Ka", __pyx_getprop_9punyverse_6_model_8Material_Ka, __pyx_setprop_9punyverse_6_model_8Material_Ka, (char *)0, 0},
  {(char *)"Kd", __pyx_getprop_9punyverse_6_model_8Material_Kd, __pyx_setprop_9punyverse_6_model_8Material_Kd, (char *)0, 0},
  {(char *)"Ks", __pyx_getprop_9punyverse_6_model_8Material_Ks, __pyx_setprop_9punyverse_6_model_8Material_Ks, (char *)0, 0},
  {(char *)"shininess", __pyx_getprop_9punyverse_6_model_8Material_shininess, __pyx_setprop_9punyverse_6_model_8Material_shininess, (char *)0, 0},
  {0, 0, 0, 0, 0}
};

static PyTypeObject __pyx_type_9punyverse_6_model_Material = {
  PyVarObject_HEAD_INIT(0, 0)
  "punyverse._model.Material", /*tp_name*/
  sizeof(struct __pyx_obj_9punyverse_6_model_Material), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_9punyverse_6_model_Material, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #endif
  #if PY_MAJOR_VERSION >= 3
  0, /*tp_as_async*/
  #endif
  0, /*tp_repr*/
  0, /*tp_as_number*/
  0, /*tp_as_sequence*/
  0, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  0, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  0, /*tp_doc*/
  __pyx_tp_traverse_9punyverse_6_model_Material, /*tp_traverse*/
  __pyx_tp_clear_9punyverse_6_model_Material, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_9punyverse_6_model_Material, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_9punyverse_6_model_Material, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_9punyverse_6_model_8Material_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_9punyverse_6_model_Material, /*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*/
  0, /*tp_version_tag*/
  #if PY_VERSION_HEX >= 0x030400a1
  0, /*tp_finalize*/
  #endif
};

static PyObject *__pyx_tp_new_9punyverse_6_model_Group(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  struct __pyx_obj_9punyverse_6_model_Group *p;
  PyObject *o;
  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
    o = (*t->tp_alloc)(t, 0);
  } else {
    o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  }
  if (unlikely(!o)) return 0;
  p = ((struct __pyx_obj_9punyverse_6_model_Group *)o);
  p->name = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->min = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->material = ((struct __pyx_obj_9punyverse_6_model_Material *)Py_None); Py_INCREF(Py_None);
  p->faces = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->indices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->normals = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->textures = ((PyObject*)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_9punyverse_6_model_Group(PyObject *o) {
  struct __pyx_obj_9punyverse_6_model_Group *p = (struct __pyx_obj_9punyverse_6_model_Group *)o;
  #if CYTHON_USE_TP_FINALIZE
  if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
    if (PyObject_CallFinalizerFromDealloc(o)) return;
  }
  #endif
  PyObject_GC_UnTrack(o);
  Py_CLEAR(p->name);
  Py_CLEAR(p->min);
  Py_CLEAR(p->material);
  Py_CLEAR(p->faces);
  Py_CLEAR(p->indices);
  Py_CLEAR(p->vertices);
  Py_CLEAR(p->normals);
  Py_CLEAR(p->textures);
  (*Py_TYPE(o)->tp_free)(o);
}

static int __pyx_tp_traverse_9punyverse_6_model_Group(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_9punyverse_6_model_Group *p = (struct __pyx_obj_9punyverse_6_model_Group *)o;
  if (p->min) {
    e = (*v)(p->min, a); if (e) return e;
  }
  if (p->material) {
    e = (*v)(((PyObject *)p->material), a); if (e) return e;
  }
  if (p->faces) {
    e = (*v)(p->faces, a); if (e) return e;
  }
  if (p->indices) {
    e = (*v)(p->indices, a); if (e) return e;
  }
  if (p->vertices) {
    e = (*v)(p->vertices, a); if (e) return e;
  }
  if (p->normals) {
    e = (*v)(p->normals, a); if (e) return e;
  }
  if (p->textures) {
    e = (*v)(p->textures, a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_9punyverse_6_model_Group(PyObject *o) {
  PyObject* tmp;
  struct __pyx_obj_9punyverse_6_model_Group *p = (struct __pyx_obj_9punyverse_6_model_Group *)o;
  tmp = ((PyObject*)p->min);
  p->min = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->material);
  p->material = ((struct __pyx_obj_9punyverse_6_model_Material *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->faces);
  p->faces = ((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);
  tmp = ((PyObject*)p->vertices);
  p->vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->normals);
  p->normals = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->textures);
  p->textures = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_name(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_4name_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_name(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_4name_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_4name_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_min(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_3min_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_min(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_3min_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_3min_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_material(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_8material_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_material(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_8material_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_8material_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_faces(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_5faces_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_faces(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_5faces_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_5faces_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_indices(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_7indices_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_indices(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_7indices_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_7indices_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_vertices(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_8vertices_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_vertices(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_8vertices_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_8vertices_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_normals(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_7normals_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_normals(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_7normals_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_7normals_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_textures(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_8textures_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_textures(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_8textures_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_5Group_8textures_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_5Group_idx_count(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_5Group_9idx_count_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_5Group_idx_count(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_5Group_9idx_count_3__set__(o, v);
  }
  else {
    PyErr_SetString(PyExc_NotImplementedError, "__del__");
    return -1;
  }
}

static PyMethodDef __pyx_methods_9punyverse_6_model_Group[] = {
  {"pack", (PyCFunction)__pyx_pw_9punyverse_6_model_5Group_3pack, METH_NOARGS, 0},
  {"__reduce_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_5Group_5__reduce_cython__, METH_NOARGS, 0},
  {"__setstate_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_5Group_7__setstate_cython__, METH_O, 0},
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_9punyverse_6_model_Group[] = {
  {(char *)"name", __pyx_getprop_9punyverse_6_model_5Group_name, __pyx_setprop_9punyverse_6_model_5Group_name, (char *)0, 0},
  {(char *)"min", __pyx_getprop_9punyverse_6_model_5Group_min, __pyx_setprop_9punyverse_6_model_5Group_min, (char *)0, 0},
  {(char *)"material", __pyx_getprop_9punyverse_6_model_5Group_material, __pyx_setprop_9punyverse_6_model_5Group_material, (char *)0, 0},
  {(char *)"faces", __pyx_getprop_9punyverse_6_model_5Group_faces, __pyx_setprop_9punyverse_6_model_5Group_faces, (char *)0, 0},
  {(char *)"indices", __pyx_getprop_9punyverse_6_model_5Group_indices, __pyx_setprop_9punyverse_6_model_5Group_indices, (char *)0, 0},
  {(char *)"vertices", __pyx_getprop_9punyverse_6_model_5Group_vertices, __pyx_setprop_9punyverse_6_model_5Group_vertices, (char *)0, 0},
  {(char *)"normals", __pyx_getprop_9punyverse_6_model_5Group_normals, __pyx_setprop_9punyverse_6_model_5Group_normals, (char *)0, 0},
  {(char *)"textures", __pyx_getprop_9punyverse_6_model_5Group_textures, __pyx_setprop_9punyverse_6_model_5Group_textures, (char *)0, 0},
  {(char *)"idx_count", __pyx_getprop_9punyverse_6_model_5Group_idx_count, __pyx_setprop_9punyverse_6_model_5Group_idx_count, (char *)0, 0},
  {0, 0, 0, 0, 0}
};

static PyTypeObject __pyx_type_9punyverse_6_model_Group = {
  PyVarObject_HEAD_INIT(0, 0)
  "punyverse._model.Group", /*tp_name*/
  sizeof(struct __pyx_obj_9punyverse_6_model_Group), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_9punyverse_6_model_Group, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #endif
  #if PY_MAJOR_VERSION >= 3
  0, /*tp_as_async*/
  #endif
  0, /*tp_repr*/
  0, /*tp_as_number*/
  0, /*tp_as_sequence*/
  0, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  0, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  0, /*tp_doc*/
  __pyx_tp_traverse_9punyverse_6_model_Group, /*tp_traverse*/
  __pyx_tp_clear_9punyverse_6_model_Group, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_9punyverse_6_model_Group, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_9punyverse_6_model_Group, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_9punyverse_6_model_5Group_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_9punyverse_6_model_Group, /*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*/
  0, /*tp_version_tag*/
  #if PY_VERSION_HEX >= 0x030400a1
  0, /*tp_finalize*/
  #endif
};
static struct __pyx_vtabstruct_9punyverse_6_model_WavefrontObject __pyx_vtable_9punyverse_6_model_WavefrontObject;

static PyObject *__pyx_tp_new_9punyverse_6_model_WavefrontObject(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  struct __pyx_obj_9punyverse_6_model_WavefrontObject *p;
  PyObject *o;
  if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
    o = (*t->tp_alloc)(t, 0);
  } else {
    o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  }
  if (unlikely(!o)) return 0;
  p = ((struct __pyx_obj_9punyverse_6_model_WavefrontObject *)o);
  p->__pyx_vtab = __pyx_vtabptr_9punyverse_6_model_WavefrontObject;
  p->root = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->normals = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->textures = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->groups = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->materials = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->path = ((PyObject*)Py_None); Py_INCREF(Py_None);
  p->current_material = ((struct __pyx_obj_9punyverse_6_model_Material *)Py_None); Py_INCREF(Py_None);
  p->current_group = ((struct __pyx_obj_9punyverse_6_model_Group *)Py_None); Py_INCREF(Py_None);
  return o;
}

static void __pyx_tp_dealloc_9punyverse_6_model_WavefrontObject(PyObject *o) {
  struct __pyx_obj_9punyverse_6_model_WavefrontObject *p = (struct __pyx_obj_9punyverse_6_model_WavefrontObject *)o;
  #if CYTHON_USE_TP_FINALIZE
  if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
    if (PyObject_CallFinalizerFromDealloc(o)) return;
  }
  #endif
  PyObject_GC_UnTrack(o);
  Py_CLEAR(p->root);
  Py_CLEAR(p->vertices);
  Py_CLEAR(p->normals);
  Py_CLEAR(p->textures);
  Py_CLEAR(p->groups);
  Py_CLEAR(p->materials);
  Py_CLEAR(p->path);
  Py_CLEAR(p->current_material);
  Py_CLEAR(p->current_group);
  (*Py_TYPE(o)->tp_free)(o);
}

static int __pyx_tp_traverse_9punyverse_6_model_WavefrontObject(PyObject *o, visitproc v, void *a) {
  int e;
  struct __pyx_obj_9punyverse_6_model_WavefrontObject *p = (struct __pyx_obj_9punyverse_6_model_WavefrontObject *)o;
  if (p->vertices) {
    e = (*v)(p->vertices, a); if (e) return e;
  }
  if (p->normals) {
    e = (*v)(p->normals, a); if (e) return e;
  }
  if (p->textures) {
    e = (*v)(p->textures, a); if (e) return e;
  }
  if (p->groups) {
    e = (*v)(p->groups, a); if (e) return e;
  }
  if (p->materials) {
    e = (*v)(p->materials, a); if (e) return e;
  }
  if (p->current_material) {
    e = (*v)(((PyObject *)p->current_material), a); if (e) return e;
  }
  if (p->current_group) {
    e = (*v)(((PyObject *)p->current_group), a); if (e) return e;
  }
  return 0;
}

static int __pyx_tp_clear_9punyverse_6_model_WavefrontObject(PyObject *o) {
  PyObject* tmp;
  struct __pyx_obj_9punyverse_6_model_WavefrontObject *p = (struct __pyx_obj_9punyverse_6_model_WavefrontObject *)o;
  tmp = ((PyObject*)p->vertices);
  p->vertices = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->normals);
  p->normals = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->textures);
  p->textures = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->groups);
  p->groups = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->materials);
  p->materials = ((PyObject*)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->current_material);
  p->current_material = ((struct __pyx_obj_9punyverse_6_model_Material *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  tmp = ((PyObject*)p->current_group);
  p->current_group = ((struct __pyx_obj_9punyverse_6_model_Group *)Py_None); Py_INCREF(Py_None);
  Py_XDECREF(tmp);
  return 0;
}

static PyObject *__pyx_getprop_9punyverse_6_model_15WavefrontObject_vertices(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_15WavefrontObject_vertices(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_8vertices_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_15WavefrontObject_normals(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_15WavefrontObject_normals(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_7normals_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_15WavefrontObject_textures(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_15WavefrontObject_textures(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_8textures_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_15WavefrontObject_groups(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_15WavefrontObject_groups(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_6groups_5__del__(o);
  }
}

static PyObject *__pyx_getprop_9punyverse_6_model_15WavefrontObject_materials(PyObject *o, CYTHON_UNUSED void *x) {
  return __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_1__get__(o);
}

static int __pyx_setprop_9punyverse_6_model_15WavefrontObject_materials(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) {
  if (v) {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_3__set__(o, v);
  }
  else {
    return __pyx_pw_9punyverse_6_model_15WavefrontObject_9materials_5__del__(o);
  }
}

static PyMethodDef __pyx_methods_9punyverse_6_model_WavefrontObject[] = {
  {"__reduce_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_15WavefrontObject_3__reduce_cython__, METH_NOARGS, 0},
  {"__setstate_cython__", (PyCFunction)__pyx_pw_9punyverse_6_model_15WavefrontObject_5__setstate_cython__, METH_O, 0},
  {0, 0, 0, 0}
};

static struct PyGetSetDef __pyx_getsets_9punyverse_6_model_WavefrontObject[] = {
  {(char *)"vertices", __pyx_getprop_9punyverse_6_model_15WavefrontObject_vertices, __pyx_setprop_9punyverse_6_model_15WavefrontObject_vertices, (char *)0, 0},
  {(char *)"normals", __pyx_getprop_9punyverse_6_model_15WavefrontObject_normals, __pyx_setprop_9punyverse_6_model_15WavefrontObject_normals, (char *)0, 0},
  {(char *)"textures", __pyx_getprop_9punyverse_6_model_15WavefrontObject_textures, __pyx_setprop_9punyverse_6_model_15WavefrontObject_textures, (char *)0, 0},
  {(char *)"groups", __pyx_getprop_9punyverse_6_model_15WavefrontObject_groups, __pyx_setprop_9punyverse_6_model_15WavefrontObject_groups, (char *)0, 0},
  {(char *)"materials", __pyx_getprop_9punyverse_6_model_15WavefrontObject_materials, __pyx_setprop_9punyverse_6_model_15WavefrontObject_materials, (char *)0, 0},
  {0, 0, 0, 0, 0}
};

static PyTypeObject __pyx_type_9punyverse_6_model_WavefrontObject = {
  PyVarObject_HEAD_INIT(0, 0)
  "punyverse._model.WavefrontObject", /*tp_name*/
  sizeof(struct __pyx_obj_9punyverse_6_model_WavefrontObject), /*tp_basicsize*/
  0, /*tp_itemsize*/
  __pyx_tp_dealloc_9punyverse_6_model_WavefrontObject, /*tp_dealloc*/
  0, /*tp_print*/
  0, /*tp_getattr*/
  0, /*tp_setattr*/
  #if PY_MAJOR_VERSION < 3
  0, /*tp_compare*/
  #endif
  #if PY_MAJOR_VERSION >= 3
  0, /*tp_as_async*/
  #endif
  0, /*tp_repr*/
  0, /*tp_as_number*/
  0, /*tp_as_sequence*/
  0, /*tp_as_mapping*/
  0, /*tp_hash*/
  0, /*tp_call*/
  0, /*tp_str*/
  0, /*tp_getattro*/
  0, /*tp_setattro*/
  0, /*tp_as_buffer*/
  Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  0, /*tp_doc*/
  __pyx_tp_traverse_9punyverse_6_model_WavefrontObject, /*tp_traverse*/
  __pyx_tp_clear_9punyverse_6_model_WavefrontObject, /*tp_clear*/
  0, /*tp_richcompare*/
  0, /*tp_weaklistoffset*/
  0, /*tp_iter*/
  0, /*tp_iternext*/
  __pyx_methods_9punyverse_6_model_WavefrontObject, /*tp_methods*/
  0, /*tp_members*/
  __pyx_getsets_9punyverse_6_model_WavefrontObject, /*tp_getset*/
  0, /*tp_base*/
  0, /*tp_dict*/
  0, /*tp_descr_get*/
  0, /*tp_descr_set*/
  0, /*tp_dictoffset*/
  __pyx_pw_9punyverse_6_model_15WavefrontObject_1__init__, /*tp_init*/
  0, /*tp_alloc*/
  __pyx_tp_new_9punyverse_6_model_WavefrontObject, /*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*/
  0, /*tp_version_tag*/
  #if PY_VERSION_HEX >= 0x030400a1
  0, /*tp_finalize*/
  #endif
};

static PyMethodDef __pyx_methods[] = {
  {"model_list", (PyCFunction)__pyx_pw_9punyverse_6_model_5model_list, METH_VARARGS|METH_KEYWORDS, 0},
  {0, 0, 0, 0}
};

#if PY_MAJOR_VERSION >= 3
#if CYTHON_PEP489_MULTI_PHASE_INIT
static PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def); /*proto*/
static int __pyx_pymod_exec__model(PyObject* module); /*proto*/
static PyModuleDef_Slot __pyx_moduledef_slots[] = {
  {Py_mod_create, (void*)__pyx_pymod_create},
  {Py_mod_exec, (void*)__pyx_pymod_exec__model},
  {0, NULL}
};
#endif

static struct PyModuleDef __pyx_moduledef = {
    PyModuleDef_HEAD_INIT,
    "_model",
    0, /* m_doc */
  #if CYTHON_PEP489_MULTI_PHASE_INIT
    0, /* m_size */
  #else
    -1, /* m_size */
  #endif
    __pyx_methods /* m_methods */,
  #if CYTHON_PEP489_MULTI_PHASE_INIT
    __pyx_moduledef_slots, /* m_slots */
  #else
    NULL, /* m_reload */
  #endif
    NULL, /* m_traverse */
    NULL, /* m_clear */
    NULL /* m_free */
};
#endif

static __Pyx_StringTabEntry __pyx_string_tab[] = {
  {&__pyx_n_s_AttributeError, __pyx_k_AttributeError, sizeof(__pyx_k_AttributeError), 0, 0, 1, 1},
  {&__pyx_n_s_BZ2File, __pyx_k_BZ2File, sizeof(__pyx_k_BZ2File), 0, 0, 1, 1},
  {&__pyx_kp_s_Incompatible_checksums_s_vs_0x1b, __pyx_k_Incompatible_checksums_s_vs_0x1b, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x1b), 0, 0, 1, 0},
  {&__pyx_kp_s_Incompatible_checksums_s_vs_0x87, __pyx_k_Incompatible_checksums_s_vs_0x87, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x87), 0, 0, 1, 0},
  {&__pyx_kp_s_Incompatible_checksums_s_vs_0xa5, __pyx_k_Incompatible_checksums_s_vs_0xa5, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xa5), 0, 0, 1, 0},
  {&__pyx_kp_s_Incompatible_checksums_s_vs_0xe7, __pyx_k_Incompatible_checksums_s_vs_0xe7, sizeof(__pyx_k_Incompatible_checksums_s_vs_0xe7), 0, 0, 1, 0},
  {&__pyx_n_s_Ka, __pyx_k_Ka, sizeof(__pyx_k_Ka), 0, 0, 1, 1},
  {&__pyx_n_s_Kd, __pyx_k_Kd, sizeof(__pyx_k_Kd), 0, 0, 1, 1},
  {&__pyx_n_s_KeyError, __pyx_k_KeyError, sizeof(__pyx_k_KeyError), 0, 0, 1, 1},
  {&__pyx_n_s_Ks, __pyx_k_Ks, sizeof(__pyx_k_Ks), 0, 0, 1, 1},
  {&__pyx_n_s_PickleError, __pyx_k_PickleError, sizeof(__pyx_k_PickleError), 0, 0, 1, 1},
  {&__pyx_kp_s_Warning_material_s_undefined_onl, __pyx_k_Warning_material_s_undefined_onl, sizeof(__pyx_k_Warning_material_s_undefined_onl), 0, 0, 1, 0},
  {&__pyx_kp_s_Warning_no_group, __pyx_k_Warning_no_group, sizeof(__pyx_k_Warning_no_group), 0, 0, 1, 0},
  {&__pyx_n_s_ZipFile, __pyx_k_ZipFile, sizeof(__pyx_k_ZipFile), 0, 0, 1, 1},
  {&__pyx_kp_s__10, __pyx_k__10, sizeof(__pyx_k__10), 0, 0, 1, 0},
  {&__pyx_kp_s__4, __pyx_k__4, sizeof(__pyx_k__4), 0, 0, 1, 0},
  {&__pyx_kp_s__6, __pyx_k__6, sizeof(__pyx_k__6), 0, 0, 1, 0},
  {&__pyx_kp_s__8, __pyx_k__8, sizeof(__pyx_k__8), 0, 0, 1, 0},
  {&__pyx_kp_s__9, __pyx_k__9, sizeof(__pyx_k__9), 0, 0, 1, 0},
  {&__pyx_n_s_abspath, __pyx_k_abspath, sizeof(__pyx_k_abspath), 0, 0, 1, 1},
  {&__pyx_n_s_assets, __pyx_k_assets, sizeof(__pyx_k_assets), 0, 0, 1, 1},
  {&__pyx_n_s_bz2, __pyx_k_bz2, sizeof(__pyx_k_bz2), 0, 0, 1, 1},
  {&__pyx_n_s_cline_in_traceback, __pyx_k_cline_in_traceback, sizeof(__pyx_k_cline_in_traceback), 0, 0, 1, 1},
  {&__pyx_n_s_decode, __pyx_k_decode, sizeof(__pyx_k_decode), 0, 0, 1, 1},
  {&__pyx_n_s_dict, __pyx_k_dict, sizeof(__pyx_k_dict), 0, 0, 1, 1},
  {&__pyx_n_s_dirname, __pyx_k_dirname, sizeof(__pyx_k_dirname), 0, 0, 1, 1},
  {&__pyx_n_s_end, __pyx_k_end, sizeof(__pyx_k_end), 0, 0, 1, 1},
  {&__pyx_n_s_enter, __pyx_k_enter, sizeof(__pyx_k_enter), 0, 0, 1, 1},
  {&__pyx_n_s_executable, __pyx_k_executable, sizeof(__pyx_k_executable), 0, 0, 1, 1},
  {&__pyx_n_s_exit, __pyx_k_exit, sizeof(__pyx_k_exit), 0, 0, 1, 1},
  {&__pyx_n_s_file, __pyx_k_file, sizeof(__pyx_k_file), 0, 0, 1, 1},
  {&__pyx_n_s_file_2, __pyx_k_file_2, sizeof(__pyx_k_file_2), 0, 0, 1, 1},
  {&__pyx_n_s_frozen, __pyx_k_frozen, sizeof(__pyx_k_frozen), 0, 0, 1, 1},
  {&__pyx_n_s_get, __pyx_k_get, sizeof(__pyx_k_get), 0, 0, 1, 1},
  {&__pyx_n_s_getstate, __pyx_k_getstate, sizeof(__pyx_k_getstate), 0, 0, 1, 1},
  {&__pyx_n_s_gz, __pyx_k_gz, sizeof(__pyx_k_gz), 0, 0, 1, 1},
  {&__pyx_n_s_gzip, __pyx_k_gzip, sizeof(__pyx_k_gzip), 0, 0, 1, 1},
  {&__pyx_n_s_import, __pyx_k_import, sizeof(__pyx_k_import), 0, 0, 1, 1},
  {&__pyx_n_s_isabs, __pyx_k_isabs, sizeof(__pyx_k_isabs), 0, 0, 1, 1},
  {&__pyx_n_s_iteritems, __pyx_k_iteritems, sizeof(__pyx_k_iteritems), 0, 0, 1, 1},
  {&__pyx_n_s_join, __pyx_k_join, sizeof(__pyx_k_join), 0, 0, 1, 1},
  {&__pyx_n_s_load_model, __pyx_k_load_model, sizeof(__pyx_k_load_model), 0, 0, 1, 1},
  {&__pyx_n_s_load_texture, __pyx_k_load_texture, sizeof(__pyx_k_load_texture), 0, 0, 1, 1},
  {&__pyx_n_s_lstrip, __pyx_k_lstrip, sizeof(__pyx_k_lstrip), 0, 0, 1, 1},
  {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1},
  {&__pyx_n_s_mbcs, __pyx_k_mbcs, sizeof(__pyx_k_mbcs), 0, 0, 1, 1},
  {&__pyx_n_s_model, __pyx_k_model, sizeof(__pyx_k_model), 0, 0, 1, 1},
  {&__pyx_n_s_model_base, __pyx_k_model_base, sizeof(__pyx_k_model_base), 0, 0, 1, 1},
  {&__pyx_n_s_models, __pyx_k_models, sizeof(__pyx_k_models), 0, 0, 1, 1},
  {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1},
  {&__pyx_n_s_name_2, __pyx_k_name_2, sizeof(__pyx_k_name_2), 0, 0, 1, 1},
  {&__pyx_n_s_namelist, __pyx_k_namelist, sizeof(__pyx_k_namelist), 0, 0, 1, 1},
  {&__pyx_n_s_new, __pyx_k_new, sizeof(__pyx_k_new), 0, 0, 1, 1},
  {&__pyx_n_s_normals, __pyx_k_normals, sizeof(__pyx_k_normals), 0, 0, 1, 1},
  {&__pyx_n_s_norms, __pyx_k_norms, sizeof(__pyx_k_norms), 0, 0, 1, 1},
  {&__pyx_n_s_open, __pyx_k_open, sizeof(__pyx_k_open), 0, 0, 1, 1},
  {&__pyx_n_s_openers, __pyx_k_openers, sizeof(__pyx_k_openers), 0, 0, 1, 1},
  {&__pyx_n_s_os, __pyx_k_os, sizeof(__pyx_k_os), 0, 0, 1, 1},
  {&__pyx_n_s_pack, __pyx_k_pack, sizeof(__pyx_k_pack), 0, 0, 1, 1},
  {&__pyx_n_s_path, __pyx_k_path, sizeof(__pyx_k_path), 0, 0, 1, 1},
  {&__pyx_n_s_pickle, __pyx_k_pickle, sizeof(__pyx_k_pickle), 0, 0, 1, 1},
  {&__pyx_n_s_print, __pyx_k_print, sizeof(__pyx_k_print), 0, 0, 1, 1},
  {&__pyx_n_s_punyverse__model, __pyx_k_punyverse__model, sizeof(__pyx_k_punyverse__model), 0, 0, 1, 1},
  {&__pyx_kp_s_punyverse__model_pyx, __pyx_k_punyverse__model_pyx, sizeof(__pyx_k_punyverse__model_pyx), 0, 0, 1, 0},
  {&__pyx_n_s_punyverse_texture, __pyx_k_punyverse_texture, sizeof(__pyx_k_punyverse_texture), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_PickleError, __pyx_k_pyx_PickleError, sizeof(__pyx_k_pyx_PickleError), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_checksum, __pyx_k_pyx_checksum, sizeof(__pyx_k_pyx_checksum), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_result, __pyx_k_pyx_result, sizeof(__pyx_k_pyx_result), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_state, __pyx_k_pyx_state, sizeof(__pyx_k_pyx_state), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_type, __pyx_k_pyx_type, sizeof(__pyx_k_pyx_type), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_unpickle_Face, __pyx_k_pyx_unpickle_Face, sizeof(__pyx_k_pyx_unpickle_Face), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_unpickle_Group, __pyx_k_pyx_unpickle_Group, sizeof(__pyx_k_pyx_unpickle_Group), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_unpickle_Material, __pyx_k_pyx_unpickle_Material, sizeof(__pyx_k_pyx_unpickle_Material), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_unpickle_WavefrontObject, __pyx_k_pyx_unpickle_WavefrontObject, sizeof(__pyx_k_pyx_unpickle_WavefrontObject), 0, 0, 1, 1},
  {&__pyx_n_s_pyx_vtable, __pyx_k_pyx_vtable, sizeof(__pyx_k_pyx_vtable), 0, 0, 1, 1},
  {&__pyx_n_s_range, __pyx_k_range, sizeof(__pyx_k_range), 0, 0, 1, 1},
  {&__pyx_n_s_reduce, __pyx_k_reduce, sizeof(__pyx_k_reduce), 0, 0, 1, 1},
  {&__pyx_n_s_reduce_cython, __pyx_k_reduce_cython, sizeof(__pyx_k_reduce_cython), 0, 0, 1, 1},
  {&__pyx_n_s_reduce_ex, __pyx_k_reduce_ex, sizeof(__pyx_k_reduce_ex), 0, 0, 1, 1},
  {&__pyx_n_s_rotation, __pyx_k_rotation, sizeof(__pyx_k_rotation), 0, 0, 1, 1},
  {&__pyx_n_s_setstate, __pyx_k_setstate, sizeof(__pyx_k_setstate), 0, 0, 1, 1},
  {&__pyx_n_s_setstate_cython, __pyx_k_setstate_cython, sizeof(__pyx_k_setstate_cython), 0, 0, 1, 1},
  {&__pyx_n_s_shininess, __pyx_k_shininess, sizeof(__pyx_k_shininess), 0, 0, 1, 1},
  {&__pyx_n_s_split, __pyx_k_split, sizeof(__pyx_k_split), 0, 0, 1, 1},
  {&__pyx_n_s_splitext, __pyx_k_splitext, sizeof(__pyx_k_splitext), 0, 0, 1, 1},
  {&__pyx_n_s_startswith, __pyx_k_startswith, sizeof(__pyx_k_startswith), 0, 0, 1, 1},
  {&__pyx_kp_s_stringsource, __pyx_k_stringsource, sizeof(__pyx_k_stringsource), 0, 0, 1, 0},
  {&__pyx_n_s_sx, __pyx_k_sx, sizeof(__pyx_k_sx), 0, 0, 1, 1},
  {&__pyx_n_s_sy, __pyx_k_sy, sizeof(__pyx_k_sy), 0, 0, 1, 1},
  {&__pyx_n_s_sys, __pyx_k_sys, sizeof(__pyx_k_sys), 0, 0, 1, 1},
  {&__pyx_n_s_sz, __pyx_k_sz, sizeof(__pyx_k_sz), 0, 0, 1, 1},
  {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1},
  {&__pyx_n_s_texs, __pyx_k_texs, sizeof(__pyx_k_texs), 0, 0, 1, 1},
  {&__pyx_n_s_texture, __pyx_k_texture, sizeof(__pyx_k_texture), 0, 0, 1, 1},
  {&__pyx_n_s_textures, __pyx_k_textures, sizeof(__pyx_k_textures), 0, 0, 1, 1},
  {&__pyx_n_s_type, __pyx_k_type, sizeof(__pyx_k_type), 0, 0, 1, 1},
  {&__pyx_n_s_update, __pyx_k_update, sizeof(__pyx_k_update), 0, 0, 1, 1},
  {&__pyx_n_s_uuid, __pyx_k_uuid, sizeof(__pyx_k_uuid), 0, 0, 1, 1},
  {&__pyx_n_s_uuid4, __pyx_k_uuid4, sizeof(__pyx_k_uuid4), 0, 0, 1, 1},
  {&__pyx_n_s_vertices, __pyx_k_vertices, sizeof(__pyx_k_vertices), 0, 0, 1, 1},
  {&__pyx_n_s_verts, __pyx_k_verts, sizeof(__pyx_k_verts), 0, 0, 1, 1},
  {&__pyx_n_s_xrange, __pyx_k_xrange, sizeof(__pyx_k_xrange), 0, 0, 1, 1},
  {&__pyx_n_s_zip, __pyx_k_zip, sizeof(__pyx_k_zip), 0, 0, 1, 1},
  {&__pyx_n_s_zip_open, __pyx_k_zip_open, sizeof(__pyx_k_zip_open), 0, 0, 1, 1},
  {&__pyx_n_s_zipfile, __pyx_k_zipfile, sizeof(__pyx_k_zipfile), 0, 0, 1, 1},
  {0, 0, 0, 0, 0, 0, 0}
};
static int __Pyx_InitCachedBuiltins(void) {
  #if PY_MAJOR_VERSION >= 3
  __pyx_builtin_xrange = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_xrange) __PYX_ERR(0, 159, __pyx_L1_error)
  #else
  __pyx_builtin_xrange = __Pyx_GetBuiltinName(__pyx_n_s_xrange); if (!__pyx_builtin_xrange) __PYX_ERR(0, 159, __pyx_L1_error)
  #endif
  __pyx_builtin_KeyError = __Pyx_GetBuiltinName(__pyx_n_s_KeyError); if (!__pyx_builtin_KeyError) __PYX_ERR(0, 202, __pyx_L1_error)
  __pyx_builtin_AttributeError = __Pyx_GetBuiltinName(__pyx_n_s_AttributeError); if (!__pyx_builtin_AttributeError) __PYX_ERR(0, 204, __pyx_L1_error)
  __pyx_builtin_open = __Pyx_GetBuiltinName(__pyx_n_s_open); if (!__pyx_builtin_open) __PYX_ERR(0, 222, __pyx_L1_error)
  return 0;
  __pyx_L1_error:;
  return -1;
}

static int __Pyx_InitCachedConstants(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);

  /* "punyverse/_model.pyx":48
 *     cdef public double shininess
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),             # <<<<<<<<<<<<<<
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):
 *         self.name = name
 */
  __pyx_tuple_ = PyTuple_Pack(3, __pyx_int_0, __pyx_int_0, __pyx_int_0); if (unlikely(!__pyx_tuple_)) __PYX_ERR(0, 48, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple_);
  __Pyx_GIVEREF(__pyx_tuple_);

  /* "punyverse/_model.pyx":49
 * 
 *     def __init__(self, str name, str texture=None, tuple Ka=(0, 0, 0),
 *                  tuple Kd=(0, 0, 0), tuple Ks=(0, 0, 0), double shininess=0.0):             # <<<<<<<<<<<<<<
 *         self.name = name
 *         self.texture = texture
 */
  __pyx_tuple__2 = PyTuple_Pack(3, __pyx_int_0, __pyx_int_0, __pyx_int_0); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(0, 49, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__2);
  __Pyx_GIVEREF(__pyx_tuple__2);
  __pyx_tuple__3 = PyTuple_Pack(3, __pyx_int_0, __pyx_int_0, __pyx_int_0); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(0, 49, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__3);
  __Pyx_GIVEREF(__pyx_tuple__3);

  /* "punyverse/_model.pyx":160
 * 
 *         for i in xrange(1, vertex_count + 1):
 *             raw_faces = words[i].split('/')             # <<<<<<<<<<<<<<
 *             l = len(raw_faces)
 * 
 */
  __pyx_tuple__5 = PyTuple_Pack(1, __pyx_kp_s__4); if (unlikely(!__pyx_tuple__5)) __PYX_ERR(0, 160, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__5);
  __Pyx_GIVEREF(__pyx_tuple__5);

  /* "punyverse/_model.pyx":221
 *         cdef int hash, length
 * 
 *         ext = os.path.splitext(file)[1].lstrip('.')             # <<<<<<<<<<<<<<
 *         reader = openers.get(ext, open)(file)
 *         with reader:
 */
  __pyx_tuple__7 = PyTuple_Pack(1, __pyx_kp_s__6); if (unlikely(!__pyx_tuple__7)) __PYX_ERR(0, 221, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__7);
  __Pyx_GIVEREF(__pyx_tuple__7);

  /* "punyverse/_model.pyx":225
 *         with reader:
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):             # <<<<<<<<<<<<<<
 *                     continue # Empty or comment
 *                 words = buf.split()
 */
  __pyx_tuple__11 = PyTuple_Pack(3, __pyx_kp_s__8, __pyx_kp_s__9, __pyx_kp_s__10); if (unlikely(!__pyx_tuple__11)) __PYX_ERR(0, 225, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__11);
  __Pyx_GIVEREF(__pyx_tuple__11);
  __pyx_tuple__12 = PyTuple_Pack(1, __pyx_tuple__11); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 225, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__12);
  __Pyx_GIVEREF(__pyx_tuple__12);

  /* "punyverse/_model.pyx":223
 *         ext = os.path.splitext(file)[1].lstrip('.')
 *         reader = openers.get(ext, open)(file)
 *         with reader:             # <<<<<<<<<<<<<<
 *             for buf in reader:
 *                 if not buf or buf.startswith(('\r', '\n', '#')):
 */
  __pyx_tuple__13 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__13)) __PYX_ERR(0, 223, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__13);
  __Pyx_GIVEREF(__pyx_tuple__13);

  /* "punyverse/_model.pyx":278
 *         path = os.path.join(model_base, path)
 *     if not isinstance(path, unicode):
 *         path = path.decode('mbcs')             # <<<<<<<<<<<<<<
 *     return WavefrontObject(path)
 * 
 */
  __pyx_tuple__14 = PyTuple_Pack(1, __pyx_n_s_mbcs); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 278, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__14);
  __Pyx_GIVEREF(__pyx_tuple__14);

  /* "punyverse/_model.pyx":295
 *     glVertex3f(x * sx, y * sy, z * sz)
 * 
 * cpdef int model_list(WavefrontObject model, float sx=1, float sy=1, float sz=1, object rotation=(0, 0, 0)):             # <<<<<<<<<<<<<<
 *     for m, text in model.materials.iteritems():
 *         if text.texture:
 */
  __pyx_tuple__15 = PyTuple_Pack(3, __pyx_int_0, __pyx_int_0, __pyx_int_0); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(0, 295, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__15);
  __Pyx_GIVEREF(__pyx_tuple__15);
  __pyx_tuple__16 = PyTuple_Pack(3, __pyx_int_0, __pyx_int_0, __pyx_int_0); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(0, 295, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__16);
  __Pyx_GIVEREF(__pyx_tuple__16);

  /* "punyverse/_model.pyx":14
 * import zipfile
 * 
 * def zip_open(file):             # <<<<<<<<<<<<<<
 *     zip = zipfile.ZipFile(file)
 *     return zip.open(zip.namelist()[0])
 */
  __pyx_tuple__17 = PyTuple_Pack(2, __pyx_n_s_file_2, __pyx_n_s_zip); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__17);
  __Pyx_GIVEREF(__pyx_tuple__17);
  __pyx_codeobj__18 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__17, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_punyverse__model_pyx, __pyx_n_s_zip_open, 14, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__18)) __PYX_ERR(0, 14, __pyx_L1_error)

  /* "punyverse/_model.pyx":267
 * model_base = None
 * 
 * def load_model(path):             # <<<<<<<<<<<<<<
 *     global model_base
 *     if model_base is None:
 */
  __pyx_tuple__19 = PyTuple_Pack(2, __pyx_n_s_path, __pyx_n_s_sys); if (unlikely(!__pyx_tuple__19)) __PYX_ERR(0, 267, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__19);
  __Pyx_GIVEREF(__pyx_tuple__19);
  __pyx_codeobj__20 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__19, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_punyverse__model_pyx, __pyx_n_s_load_model, 267, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__20)) __PYX_ERR(0, 267, __pyx_L1_error)

  /* "(tree fragment)":1
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x87a431c:
 *         from pickle import PickleError as __pyx_PickleError
 */
  __pyx_tuple__21 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__21);
  __Pyx_GIVEREF(__pyx_tuple__21);
  __pyx_codeobj__22 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__21, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Face, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__22)) __PYX_ERR(1, 1, __pyx_L1_error)
  __pyx_tuple__23 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__23);
  __Pyx_GIVEREF(__pyx_tuple__23);
  __pyx_codeobj__24 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__23, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Material, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__24)) __PYX_ERR(1, 1, __pyx_L1_error)
  __pyx_tuple__25 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__25);
  __Pyx_GIVEREF(__pyx_tuple__25);
  __pyx_codeobj__26 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__25, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Group, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__26)) __PYX_ERR(1, 1, __pyx_L1_error)
  __pyx_tuple__27 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_tuple__27);
  __Pyx_GIVEREF(__pyx_tuple__27);
  __pyx_codeobj__28 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__27, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_WavefrontObject, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__28)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_RefNannyFinishContext();
  return 0;
  __pyx_L1_error:;
  __Pyx_RefNannyFinishContext();
  return -1;
}

static int __Pyx_InitGlobals(void) {
  if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(0, 1, __pyx_L1_error);
  __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_2 = PyInt_FromLong(2); if (unlikely(!__pyx_int_2)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_3 = PyInt_FromLong(3); if (unlikely(!__pyx_int_3)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_28589906 = PyInt_FromLong(28589906L); if (unlikely(!__pyx_int_28589906)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_142230300 = PyInt_FromLong(142230300L); if (unlikely(!__pyx_int_142230300)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_173792776 = PyInt_FromLong(173792776L); if (unlikely(!__pyx_int_173792776)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_int_242544120 = PyInt_FromLong(242544120L); if (unlikely(!__pyx_int_242544120)) __PYX_ERR(0, 1, __pyx_L1_error)
  return 0;
  __pyx_L1_error:;
  return -1;
}

static int __Pyx_modinit_global_init_code(void); /*proto*/
static int __Pyx_modinit_variable_export_code(void); /*proto*/
static int __Pyx_modinit_function_export_code(void); /*proto*/
static int __Pyx_modinit_type_init_code(void); /*proto*/
static int __Pyx_modinit_type_import_code(void); /*proto*/
static int __Pyx_modinit_variable_import_code(void); /*proto*/
static int __Pyx_modinit_function_import_code(void); /*proto*/

static int __Pyx_modinit_global_init_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_global_init_code", 0);
  /*--- Global init code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_variable_export_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_variable_export_code", 0);
  /*--- Variable export code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_function_export_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_function_export_code", 0);
  /*--- Function export code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_type_init_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_type_init_code", 0);
  /*--- Type init code ---*/
  if (PyType_Ready(&__pyx_type_9punyverse_6_model_Face) < 0) __PYX_ERR(0, 29, __pyx_L1_error)
  __pyx_type_9punyverse_6_model_Face.tp_print = 0;
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_9punyverse_6_model_Face.tp_dictoffset && __pyx_type_9punyverse_6_model_Face.tp_getattro == PyObject_GenericGetAttr)) {
    __pyx_type_9punyverse_6_model_Face.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  }
  if (PyObject_SetAttrString(__pyx_m, "Face", (PyObject *)&__pyx_type_9punyverse_6_model_Face) < 0) __PYX_ERR(0, 29, __pyx_L1_error)
  if (__Pyx_setup_reduce((PyObject*)&__pyx_type_9punyverse_6_model_Face) < 0) __PYX_ERR(0, 29, __pyx_L1_error)
  __pyx_ptype_9punyverse_6_model_Face = &__pyx_type_9punyverse_6_model_Face;
  if (PyType_Ready(&__pyx_type_9punyverse_6_model_Material) < 0) __PYX_ERR(0, 43, __pyx_L1_error)
  __pyx_type_9punyverse_6_model_Material.tp_print = 0;
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_9punyverse_6_model_Material.tp_dictoffset && __pyx_type_9punyverse_6_model_Material.tp_getattro == PyObject_GenericGetAttr)) {
    __pyx_type_9punyverse_6_model_Material.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  }
  if (PyObject_SetAttrString(__pyx_m, "Material", (PyObject *)&__pyx_type_9punyverse_6_model_Material) < 0) __PYX_ERR(0, 43, __pyx_L1_error)
  if (__Pyx_setup_reduce((PyObject*)&__pyx_type_9punyverse_6_model_Material) < 0) __PYX_ERR(0, 43, __pyx_L1_error)
  __pyx_ptype_9punyverse_6_model_Material = &__pyx_type_9punyverse_6_model_Material;
  if (PyType_Ready(&__pyx_type_9punyverse_6_model_Group) < 0) __PYX_ERR(0, 57, __pyx_L1_error)
  __pyx_type_9punyverse_6_model_Group.tp_print = 0;
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_9punyverse_6_model_Group.tp_dictoffset && __pyx_type_9punyverse_6_model_Group.tp_getattro == PyObject_GenericGetAttr)) {
    __pyx_type_9punyverse_6_model_Group.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  }
  if (PyObject_SetAttrString(__pyx_m, "Group", (PyObject *)&__pyx_type_9punyverse_6_model_Group) < 0) __PYX_ERR(0, 57, __pyx_L1_error)
  if (__Pyx_setup_reduce((PyObject*)&__pyx_type_9punyverse_6_model_Group) < 0) __PYX_ERR(0, 57, __pyx_L1_error)
  __pyx_ptype_9punyverse_6_model_Group = &__pyx_type_9punyverse_6_model_Group;
  __pyx_vtabptr_9punyverse_6_model_WavefrontObject = &__pyx_vtable_9punyverse_6_model_WavefrontObject;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.new_material = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_new_material;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.Ka = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_Ka;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.Kd = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_Kd;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.Ks = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_Ks;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.material_shininess = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_material_shininess;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.material_texture = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_material_texture;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.vertex = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_vertex;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.normal = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_normal;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.texture = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_texture;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.face = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_face;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.material = (int (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_material;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.use_material = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_use_material;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.group = (void (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_group;
  __pyx_vtable_9punyverse_6_model_WavefrontObject.perform_io = (int (*)(struct __pyx_obj_9punyverse_6_model_WavefrontObject *, PyObject *))__pyx_f_9punyverse_6_model_15WavefrontObject_perform_io;
  if (PyType_Ready(&__pyx_type_9punyverse_6_model_WavefrontObject) < 0) __PYX_ERR(0, 87, __pyx_L1_error)
  __pyx_type_9punyverse_6_model_WavefrontObject.tp_print = 0;
  if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_9punyverse_6_model_WavefrontObject.tp_dictoffset && __pyx_type_9punyverse_6_model_WavefrontObject.tp_getattro == PyObject_GenericGetAttr)) {
    __pyx_type_9punyverse_6_model_WavefrontObject.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  }
  if (__Pyx_SetVtable(__pyx_type_9punyverse_6_model_WavefrontObject.tp_dict, __pyx_vtabptr_9punyverse_6_model_WavefrontObject) < 0) __PYX_ERR(0, 87, __pyx_L1_error)
  if (PyObject_SetAttrString(__pyx_m, "WavefrontObject", (PyObject *)&__pyx_type_9punyverse_6_model_WavefrontObject) < 0) __PYX_ERR(0, 87, __pyx_L1_error)
  if (__Pyx_setup_reduce((PyObject*)&__pyx_type_9punyverse_6_model_WavefrontObject) < 0) __PYX_ERR(0, 87, __pyx_L1_error)
  __pyx_ptype_9punyverse_6_model_WavefrontObject = &__pyx_type_9punyverse_6_model_WavefrontObject;
  __Pyx_RefNannyFinishContext();
  return 0;
  __pyx_L1_error:;
  __Pyx_RefNannyFinishContext();
  return -1;
}

static int __Pyx_modinit_type_import_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_type_import_code", 0);
  /*--- Type import code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_variable_import_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_variable_import_code", 0);
  /*--- Variable import code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}

static int __Pyx_modinit_function_import_code(void) {
  __Pyx_RefNannyDeclarations
  __Pyx_RefNannySetupContext("__Pyx_modinit_function_import_code", 0);
  /*--- Function import code ---*/
  __Pyx_RefNannyFinishContext();
  return 0;
}


#if PY_MAJOR_VERSION < 3
#ifdef CYTHON_NO_PYINIT_EXPORT
#define __Pyx_PyMODINIT_FUNC void
#else
#define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
#endif
#else
#ifdef CYTHON_NO_PYINIT_EXPORT
#define __Pyx_PyMODINIT_FUNC PyObject *
#else
#define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
#endif
#endif
#ifndef CYTHON_SMALL_CODE
#if defined(__clang__)
    #define CYTHON_SMALL_CODE
#elif defined(__GNUC__) && (!(defined(__cplusplus)) || (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 4)))
    #define CYTHON_SMALL_CODE __attribute__((cold))
#else
    #define CYTHON_SMALL_CODE
#endif
#endif


#if PY_MAJOR_VERSION < 3
__Pyx_PyMODINIT_FUNC init_model(void) CYTHON_SMALL_CODE; /*proto*/
__Pyx_PyMODINIT_FUNC init_model(void)
#else
__Pyx_PyMODINIT_FUNC PyInit__model(void) CYTHON_SMALL_CODE; /*proto*/
__Pyx_PyMODINIT_FUNC PyInit__model(void)
#if CYTHON_PEP489_MULTI_PHASE_INIT
{
  return PyModuleDef_Init(&__pyx_moduledef);
}
static int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *moddict, const char* from_name, const char* to_name) {
    PyObject *value = PyObject_GetAttrString(spec, from_name);
    int result = 0;
    if (likely(value)) {
        result = PyDict_SetItemString(moddict, to_name, value);
        Py_DECREF(value);
    } else if (PyErr_ExceptionMatches(PyExc_AttributeError)) {
        PyErr_Clear();
    } else {
        result = -1;
    }
    return result;
}
static PyObject* __pyx_pymod_create(PyObject *spec, CYTHON_UNUSED PyModuleDef *def) {
    PyObject *module = NULL, *moddict, *modname;
    if (__pyx_m)
        return __Pyx_NewRef(__pyx_m);
    modname = PyObject_GetAttrString(spec, "name");
    if (unlikely(!modname)) goto bad;
    module = PyModule_NewObject(modname);
    Py_DECREF(modname);
    if (unlikely(!module)) goto bad;
    moddict = PyModule_GetDict(module);
    if (unlikely(!moddict)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "loader", "__loader__") < 0)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "origin", "__file__") < 0)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "parent", "__package__") < 0)) goto bad;
    if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "submodule_search_locations", "__path__") < 0)) goto bad;
    return module;
bad:
    Py_XDECREF(module);
    return NULL;
}


static int __pyx_pymod_exec__model(PyObject *__pyx_pyinit_module)
#endif
#endif
{
  PyObject *__pyx_t_1 = NULL;
  PyObject *__pyx_t_2 = NULL;
  PyObject *__pyx_t_3 = NULL;
  __Pyx_RefNannyDeclarations
  #if CYTHON_PEP489_MULTI_PHASE_INIT
  if (__pyx_m && __pyx_m == __pyx_pyinit_module) return 0;
  #elif PY_MAJOR_VERSION >= 3
  if (__pyx_m) return __Pyx_NewRef(__pyx_m);
  #endif
  #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("__Pyx_PyMODINIT_FUNC PyInit__model(void)", 0);
  if (__Pyx_check_binary_version() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(0, 1, __pyx_L1_error)
  #ifdef __Pyx_CyFunction_USED
  if (__pyx_CyFunction_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_FusedFunction_USED
  if (__pyx_FusedFunction_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_Coroutine_USED
  if (__pyx_Coroutine_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_Generator_USED
  if (__pyx_Generator_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_AsyncGen_USED
  if (__pyx_AsyncGen_init() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  #ifdef __Pyx_StopAsyncIteration_USED
  if (__pyx_StopAsyncIteration_init() < 0) __PYX_ERR(0, 1, __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 CYTHON_PEP489_MULTI_PHASE_INIT
  __pyx_m = __pyx_pyinit_module;
  Py_INCREF(__pyx_m);
  #else
  #if PY_MAJOR_VERSION < 3
  __pyx_m = Py_InitModule4("_model", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
  #else
  __pyx_m = PyModule_Create(&__pyx_moduledef);
  #endif
  if (unlikely(!__pyx_m)) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) __PYX_ERR(0, 1, __pyx_L1_error)
  Py_INCREF(__pyx_d);
  __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) __PYX_ERR(0, 1, __pyx_L1_error)
  __pyx_cython_runtime = PyImport_AddModule((char *) "cython_runtime"); if (unlikely(!__pyx_cython_runtime)) __PYX_ERR(0, 1, __pyx_L1_error)
  #if CYTHON_COMPILING_IN_PYPY
  Py_INCREF(__pyx_b);
  #endif
  if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) __PYX_ERR(0, 1, __pyx_L1_error);
  /*--- Initialize various global constants etc. ---*/
  if (__Pyx_InitGlobals() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
  if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif
  if (__pyx_module_is_main_punyverse___model) {
    if (PyObject_SetAttrString(__pyx_m, "__name__", __pyx_n_s_main) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  }
  #if PY_MAJOR_VERSION >= 3
  {
    PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(0, 1, __pyx_L1_error)
    if (!PyDict_GetItemString(modules, "punyverse._model")) {
      if (unlikely(PyDict_SetItemString(modules, "punyverse._model", __pyx_m) < 0)) __PYX_ERR(0, 1, __pyx_L1_error)
    }
  }
  #endif
  /*--- Builtin init code ---*/
  if (__Pyx_InitCachedBuiltins() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  /*--- Constants init code ---*/
  if (__Pyx_InitCachedConstants() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  /*--- Global type/function init code ---*/
  (void)__Pyx_modinit_global_init_code();
  (void)__Pyx_modinit_variable_export_code();
  (void)__Pyx_modinit_function_export_code();
  if (unlikely(__Pyx_modinit_type_init_code() != 0)) goto __pyx_L1_error;
  (void)__Pyx_modinit_type_import_code();
  (void)__Pyx_modinit_variable_import_code();
  (void)__Pyx_modinit_function_import_code();
  /*--- Execution code ---*/
  #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
  if (__Pyx_patch_abc() < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  #endif

  /* "punyverse/_model.pyx":6
 * cimport cython
 * 
 * from punyverse.texture import load_texture             # <<<<<<<<<<<<<<
 * include "_cyopengl.pxi"
 * from uuid import uuid4
 */
  __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 6, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_INCREF(__pyx_n_s_load_texture);
  __Pyx_GIVEREF(__pyx_n_s_load_texture);
  PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_load_texture);
  __pyx_t_2 = __Pyx_Import(__pyx_n_s_punyverse_texture, __pyx_t_1, -1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 6, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_load_texture); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 6, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_load_texture, __pyx_t_1) < 0) __PYX_ERR(0, 6, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

  /* "punyverse/_cyopengl.pxi":1209
 *     GLU_TESS_WINDING_ABS_GEQ_TWO =     100134
 * 
 * cdef float GLU_TESS_MAX_COORD = 1.0e150             # <<<<<<<<<<<<<<
 */
  __pyx_v_9punyverse_6_model_GLU_TESS_MAX_COORD = 1.0e150;

  /* "punyverse/_model.pyx":8
 * from punyverse.texture import load_texture
 * include "_cyopengl.pxi"
 * from uuid import uuid4             # <<<<<<<<<<<<<<
 * import os
 * import gzip
 */
  __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 8, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_INCREF(__pyx_n_s_uuid4);
  __Pyx_GIVEREF(__pyx_n_s_uuid4);
  PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_uuid4);
  __pyx_t_1 = __Pyx_Import(__pyx_n_s_uuid, __pyx_t_2, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 8, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_1, __pyx_n_s_uuid4); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 8, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_uuid4, __pyx_t_2) < 0) __PYX_ERR(0, 8, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":9
 * include "_cyopengl.pxi"
 * from uuid import uuid4
 * import os             # <<<<<<<<<<<<<<
 * import gzip
 * import bz2
 */
  __pyx_t_1 = __Pyx_Import(__pyx_n_s_os, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 9, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_os, __pyx_t_1) < 0) __PYX_ERR(0, 9, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":10
 * from uuid import uuid4
 * import os
 * import gzip             # <<<<<<<<<<<<<<
 * import bz2
 * import zipfile
 */
  __pyx_t_1 = __Pyx_Import(__pyx_n_s_gzip, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 10, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_gzip, __pyx_t_1) < 0) __PYX_ERR(0, 10, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":11
 * import os
 * import gzip
 * import bz2             # <<<<<<<<<<<<<<
 * import zipfile
 * 
 */
  __pyx_t_1 = __Pyx_Import(__pyx_n_s_bz2, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 11, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_bz2, __pyx_t_1) < 0) __PYX_ERR(0, 11, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":12
 * import gzip
 * import bz2
 * import zipfile             # <<<<<<<<<<<<<<
 * 
 * def zip_open(file):
 */
  __pyx_t_1 = __Pyx_Import(__pyx_n_s_zipfile, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 12, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_zipfile, __pyx_t_1) < 0) __PYX_ERR(0, 12, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":14
 * import zipfile
 * 
 * def zip_open(file):             # <<<<<<<<<<<<<<
 *     zip = zipfile.ZipFile(file)
 *     return zip.open(zip.namelist()[0])
 */
  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_9punyverse_6_model_1zip_open, NULL, __pyx_n_s_punyverse__model); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_zip_open, __pyx_t_1) < 0) __PYX_ERR(0, 14, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":19
 * 
 * openers = {
 *     'gz': gzip.open,             # <<<<<<<<<<<<<<
 *     'bz2': bz2.BZ2File,
 *     'zip': zip_open,
 */
  __pyx_t_1 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 19, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_gzip); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 19, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_open); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 19, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_gz, __pyx_t_3) < 0) __PYX_ERR(0, 19, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;

  /* "punyverse/_model.pyx":20
 * openers = {
 *     'gz': gzip.open,
 *     'bz2': bz2.BZ2File,             # <<<<<<<<<<<<<<
 *     'zip': zip_open,
 * }
 */
  __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_bz2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 20, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_3);
  __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_BZ2File); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 20, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_bz2, __pyx_t_2) < 0) __PYX_ERR(0, 19, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;

  /* "punyverse/_model.pyx":21
 *     'gz': gzip.open,
 *     'bz2': bz2.BZ2File,
 *     'zip': zip_open,             # <<<<<<<<<<<<<<
 * }
 * 
 */
  __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_zip_open); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 21, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_2);
  if (PyDict_SetItem(__pyx_t_1, __pyx_n_s_zip, __pyx_t_2) < 0) __PYX_ERR(0, 19, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_openers, __pyx_t_1) < 0) __PYX_ERR(0, 18, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":265
 *         return True
 * 
 * model_base = None             # <<<<<<<<<<<<<<
 * 
 * def load_model(path):
 */
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_model_base, Py_None) < 0) __PYX_ERR(0, 265, __pyx_L1_error)

  /* "punyverse/_model.pyx":267
 * model_base = None
 * 
 * def load_model(path):             # <<<<<<<<<<<<<<
 *     global model_base
 *     if model_base is None:
 */
  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_9punyverse_6_model_3load_model, NULL, __pyx_n_s_punyverse__model); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 267, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_load_model, __pyx_t_1) < 0) __PYX_ERR(0, 267, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":1
 * def __pyx_unpickle_Face(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x87a431c:
 *         from pickle import PickleError as __pyx_PickleError
 */
  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_9punyverse_6_model_7__pyx_unpickle_Face, NULL, __pyx_n_s_punyverse__model); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Face, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":9
 *         __pyx_unpickle_Face__set_state(<Face> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Face__set_state(Face __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.normals = __pyx_state[0]; __pyx_result.norms = __pyx_state[1]; __pyx_result.texs = __pyx_state[2]; __pyx_result.textures = __pyx_state[3]; __pyx_result.type = __pyx_state[4]; __pyx_result.vertices = __pyx_state[5]; __pyx_result.verts = __pyx_state[6]
 *     if len(__pyx_state) > 7 and hasattr(__pyx_result, '__dict__'):
 */
  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_9punyverse_6_model_9__pyx_unpickle_Material, NULL, __pyx_n_s_punyverse__model); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Material, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":1
 * def __pyx_unpickle_Group(__pyx_type, long __pyx_checksum, __pyx_state):             # <<<<<<<<<<<<<<
 *     if __pyx_checksum != 0x1b43f52:
 *         from pickle import PickleError as __pyx_PickleError
 */
  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_9punyverse_6_model_11__pyx_unpickle_Group, NULL, __pyx_n_s_punyverse__model); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Group, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "(tree fragment)":9
 *         __pyx_unpickle_Group__set_state(<Group> __pyx_result, __pyx_state)
 *     return __pyx_result
 * cdef __pyx_unpickle_Group__set_state(Group __pyx_result, tuple __pyx_state):             # <<<<<<<<<<<<<<
 *     __pyx_result.faces = __pyx_state[0]; __pyx_result.idx_count = __pyx_state[1]; __pyx_result.indices = __pyx_state[2]; __pyx_result.material = __pyx_state[3]; __pyx_result.min = __pyx_state[4]; __pyx_result.name = __pyx_state[5]; __pyx_result.normals = __pyx_state[6]; __pyx_result.textures = __pyx_state[7]; __pyx_result.vertices = __pyx_state[8]
 *     if len(__pyx_state) > 9 and hasattr(__pyx_result, '__dict__'):
 */
  __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_9punyverse_6_model_13__pyx_unpickle_WavefrontObject, NULL, __pyx_n_s_punyverse__model); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_WavefrontObject, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /* "punyverse/_model.pyx":1
 * from libc.string cimport strcmp, strlen             # <<<<<<<<<<<<<<
 * from libc.stdlib cimport malloc, free, atof
 * from libc.stdio cimport fopen, fclose, fgets, FILE
 */
  __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1, __pyx_L1_error)
  __Pyx_GOTREF(__pyx_t_1);
  if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_1) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
  __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;

  /*--- Wrapped vars code ---*/

  goto __pyx_L0;
  __pyx_L1_error:;
  __Pyx_XDECREF(__pyx_t_1);
  __Pyx_XDECREF(__pyx_t_2);
  __Pyx_XDECREF(__pyx_t_3);
  if (__pyx_m) {
    if (__pyx_d) {
      __Pyx_AddTraceback("init punyverse._model", 0, __pyx_lineno, __pyx_filename);
    }
    Py_DECREF(__pyx_m); __pyx_m = 0;
  } else if (!PyErr_Occurred()) {
    PyErr_SetString(PyExc_ImportError, "init punyverse._model");
  }
  __pyx_L0:;
  __Pyx_RefNannyFinishContext();
  #if CYTHON_PEP489_MULTI_PHASE_INIT
  return (__pyx_m != NULL) ? 0 : -1;
  #elif PY_MAJOR_VERSION >= 3
  return __pyx_m;
  #else
  return;
  #endif
}

/* --- Runtime support code --- */
/* Refnanny */
#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

/* PyObjectGetAttrStr */
#if CYTHON_USE_TYPE_SLOTS
static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
    PyTypeObject* tp = Py_TYPE(obj);
    if (likely(tp->tp_getattro))
        return tp->tp_getattro(obj, attr_name);
#if PY_MAJOR_VERSION < 3
    if (likely(tp->tp_getattr))
        return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
#endif
    return PyObject_GetAttr(obj, attr_name);
}
#endif

/* GetBuiltinName */
static PyObject *__Pyx_GetBuiltinName(PyObject *name) {
    PyObject* result = __Pyx_PyObject_GetAttrStr(__pyx_b, name);
    if (unlikely(!result)) {
        PyErr_Format(PyExc_NameError,
#if PY_MAJOR_VERSION >= 3
            "name '%U' is not defined", name);
#else
            "name '%.200s' is not defined", PyString_AS_STRING(name));
#endif
    }
    return result;
}

/* GetModuleGlobalName */
static CYTHON_INLINE PyObject *__Pyx_GetModuleGlobalName(PyObject *name) {
    PyObject *result;
#if !CYTHON_AVOID_BORROWED_REFS
#if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1
    result = _PyDict_GetItem_KnownHash(__pyx_d, name, ((PyASCIIObject *) name)->hash);
    if (likely(result)) {
        Py_INCREF(result);
    } else if (unlikely(PyErr_Occurred())) {
        result = NULL;
    } else {
#else
    result = PyDict_GetItem(__pyx_d, name);
    if (likely(result)) {
        Py_INCREF(result);
    } else {
#endif
#else
    result = PyObject_GetItem(__pyx_d, name);
    if (!result) {
        PyErr_Clear();
#endif
        result = __Pyx_GetBuiltinName(name);
    }
    return result;
}

/* PyCFunctionFastCall */
    #if CYTHON_FAST_PYCCALL
static CYTHON_INLINE PyObject * __Pyx_PyCFunction_FastCall(PyObject *func_obj, PyObject **args, Py_ssize_t nargs) {
    PyCFunctionObject *func = (PyCFunctionObject*)func_obj;
    PyCFunction meth = PyCFunction_GET_FUNCTION(func);
    PyObject *self = PyCFunction_GET_SELF(func);
    int flags = PyCFunction_GET_FLAGS(func);
    assert(PyCFunction_Check(func));
    assert(METH_FASTCALL == (flags & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS)));
    assert(nargs >= 0);
    assert(nargs == 0 || args != NULL);
    /* _PyCFunction_FastCallDict() must not be called with an exception set,
       because it may clear it (directly or indirectly) and so the
       caller loses its exception */
    assert(!PyErr_Occurred());
    if ((PY_VERSION_HEX < 0x030700A0) || unlikely(flags & METH_KEYWORDS)) {
        return (*((__Pyx_PyCFunctionFastWithKeywords)meth)) (self, args, nargs, NULL);
    } else {
        return (*((__Pyx_PyCFunctionFast)meth)) (self, args, nargs);
    }
}
#endif

/* PyFunctionFastCall */
    #if CYTHON_FAST_PYCALL
#include "frameobject.h"
static PyObject* __Pyx_PyFunction_FastCallNoKw(PyCodeObject *co, PyObject **args, Py_ssize_t na,
                                               PyObject *globals) {
    PyFrameObject *f;
    PyThreadState *tstate = __Pyx_PyThreadState_Current;
    PyObject **fastlocals;
    Py_ssize_t i;
    PyObject *result;
    assert(globals != NULL);
    /* XXX Perhaps we should create a specialized
       PyFrame_New() that doesn't take locals, but does
       take builtins without sanity checking them.
       */
    assert(tstate != NULL);
    f = PyFrame_New(tstate, co, globals, NULL);
    if (f == NULL) {
        return NULL;
    }
    fastlocals = f->f_localsplus;
    for (i = 0; i < na; i++) {
        Py_INCREF(*args);
        fastlocals[i] = *args++;
    }
    result = PyEval_EvalFrameEx(f,0);
    ++tstate->recursion_depth;
    Py_DECREF(f);
    --tstate->recursion_depth;
    return result;
}
#if 1 || PY_VERSION_HEX < 0x030600B1
static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, int nargs, PyObject *kwargs) {
    PyCodeObject *co = (PyCodeObject *)PyFunction_GET_CODE(func);
    PyObject *globals = PyFunction_GET_GLOBALS(func);
    PyObject *argdefs = PyFunction_GET_DEFAULTS(func);
    PyObject *closure;
#if PY_MAJOR_VERSION >= 3
    PyObject *kwdefs;
#endif
    PyObject *kwtuple, **k;
    PyObject **d;
    Py_ssize_t nd;
    Py_ssize_t nk;
    PyObject *result;
    assert(kwargs == NULL || PyDict_Check(kwargs));
    nk = kwargs ? PyDict_Size(kwargs) : 0;
    if (Py_EnterRecursiveCall((char*)" while calling a Python object")) {
        return NULL;
    }
    if (
#if PY_MAJOR_VERSION >= 3
            co->co_kwonlyargcount == 0 &&
#endif
            likely(kwargs == NULL || nk == 0) &&
            co->co_flags == (CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE)) {
        if (argdefs == NULL && co->co_argcount == nargs) {
            result = __Pyx_PyFunction_FastCallNoKw(co, args, nargs, globals);
            goto done;
        }
        else if (nargs == 0 && argdefs != NULL
                 && co->co_argcount == Py_SIZE(argdefs)) {
            /* function called with no arguments, but all parameters have
               a default value: use default values as arguments .*/
            args = &PyTuple_GET_ITEM(argdefs, 0);
            result =__Pyx_PyFunction_FastCallNoKw(co, args, Py_SIZE(argdefs), globals);
            goto done;
        }
    }
    if (kwargs != NULL) {
        Py_ssize_t pos, i;
        kwtuple = PyTuple_New(2 * nk);
        if (kwtuple == NULL) {
            result = NULL;
            goto done;
        }
        k = &PyTuple_GET_ITEM(kwtuple, 0);
        pos = i = 0;
        while (PyDict_Next(kwargs, &pos, &k[i], &k[i+1])) {
            Py_INCREF(k[i]);
            Py_INCREF(k[i+1]);
            i += 2;
        }
        nk = i / 2;
    }
    else {
        kwtuple = NULL;
        k = NULL;
    }
    closure = PyFunction_GET_CLOSURE(func);
#if PY_MAJOR_VERSION >= 3
    kwdefs = PyFunction_GET_KW_DEFAULTS(func);
#endif
    if (argdefs != NULL) {
        d = &PyTuple_GET_ITEM(argdefs, 0);
        nd = Py_SIZE(argdefs);
    }
    else {
        d = NULL;
        nd = 0;
    }
#if PY_MAJOR_VERSION >= 3
    result = PyEval_EvalCodeEx((PyObject*)co, globals, (PyObject *)NULL,
                               args, nargs,
                               k, (int)nk,
                               d, (int)nd, kwdefs, closure);
#else
    result = PyEval_EvalCodeEx(co, globals, (PyObject *)NULL,
                               args, nargs,
                               k, (int)nk,
                               d, (int)nd, closure);
#endif
    Py_XDECREF(kwtuple);
done:
    Py_LeaveRecursiveCall();
    return result;
}
#endif
#endif

/* PyObjectCall */
    #if CYTHON_COMPILING_IN_CPYTHON
static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) {
    PyObject *result;
    ternaryfunc call = func->ob_type->tp_call;
    if (unlikely(!call))
        return PyObject_Call(func, arg, kw);
    if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
        return NULL;
    result = (*call)(func, arg, kw);
    Py_LeaveRecursiveCall();
    if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
        PyErr_SetString(
            PyExc_SystemError,
            "NULL result without error in PyObject_Call");
    }
    return result;
}
#endif

/* PyObjectCallMethO */
    #if CYTHON_COMPILING_IN_CPYTHON
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg) {
    PyObject *self, *result;
    PyCFunction cfunc;
    cfunc = PyCFunction_GET_FUNCTION(func);
    self = PyCFunction_GET_SELF(func);
    if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
        return NULL;
    result = cfunc(self, arg);
    Py_LeaveRecursiveCall();
    if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
        PyErr_SetString(
            PyExc_SystemError,
            "NULL result without error in PyObject_Call");
    }
    return result;
}
#endif

/* PyObjectCallOneArg */
    #if CYTHON_COMPILING_IN_CPYTHON
static PyObject* __Pyx__PyObject_CallOneArg(PyObject *func, PyObject *arg) {
    PyObject *result;
    PyObject *args = PyTuple_New(1);
    if (unlikely(!args)) return NULL;
    Py_INCREF(arg);
    PyTuple_SET_ITEM(args, 0, arg);
    result = __Pyx_PyObject_Call(func, args, NULL);
    Py_DECREF(args);
    return result;
}
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
#if CYTHON_FAST_PYCALL
    if (PyFunction_Check(func)) {
        return __Pyx_PyFunction_FastCall(func, &arg, 1);
    }
#endif
    if (likely(PyCFunction_Check(func))) {
        if (likely(PyCFunction_GET_FLAGS(func) & METH_O)) {
            return __Pyx_PyObject_CallMethO(func, arg);
#if CYTHON_FAST_PYCCALL
        } else if (PyCFunction_GET_FLAGS(func) & METH_FASTCALL) {
            return __Pyx_PyCFunction_FastCall(func, &arg, 1);
#endif
        }
    }
    return __Pyx__PyObject_CallOneArg(func, arg);
}
#else
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
    PyObject *result;
    PyObject *args = PyTuple_Pack(1, arg);
    if (unlikely(!args)) return NULL;
    result = __Pyx_PyObject_Call(func, args, NULL);
    Py_DECREF(args);
    return result;
}
#endif

/* PyObjectCallNoArg */
    #if CYTHON_COMPILING_IN_CPYTHON
static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func) {
#if CYTHON_FAST_PYCALL
    if (PyFunction_Check(func)) {
        return __Pyx_PyFunction_FastCall(func, NULL, 0);
    }
#endif
#ifdef __Pyx_CyFunction_USED
    if (likely(PyCFunction_Check(func) || __Pyx_TypeCheck(func, __pyx_CyFunctionType))) {
#else
    if (likely(PyCFunction_Check(func))) {
#endif
        if (likely(PyCFunction_GET_FLAGS(func) & METH_NOARGS)) {
            return __Pyx_PyObject_CallMethO(func, NULL);
        }
    }
    return __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL);
}
#endif

/* GetItemInt */
      static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) {
    PyObject *r;
    if (!j) return NULL;
    r = PyObject_GetItem(o, j);
    Py_DECREF(j);
    return r;
}
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
                                                              CYTHON_NCP_UNUSED int wraparound,
                                                              CYTHON_NCP_UNUSED int boundscheck) {
#if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    Py_ssize_t wrapped_i = i;
    if (wraparound & unlikely(i < 0)) {
        wrapped_i += PyList_GET_SIZE(o);
    }
    if ((!boundscheck) || likely((0 <= wrapped_i) & (wrapped_i < PyList_GET_SIZE(o)))) {
        PyObject *r = PyList_GET_ITEM(o, wrapped_i);
        Py_INCREF(r);
        return r;
    }
    return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
#else
    return PySequence_GetItem(o, i);
#endif
}
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
                                                              CYTHON_NCP_UNUSED int wraparound,
                                                              CYTHON_NCP_UNUSED int boundscheck) {
#if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
    Py_ssize_t wrapped_i = i;
    if (wraparound & unlikely(i < 0)) {
        wrapped_i += PyTuple_GET_SIZE(o);
    }
    if ((!boundscheck) || likely((0 <= wrapped_i) & (wrapped_i < PyTuple_GET_SIZE(o)))) {
        PyObject *r = PyTuple_GET_ITEM(o, wrapped_i);
        Py_INCREF(r);
        return r;
    }
    return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
#else
    return PySequence_GetItem(o, i);
#endif
}
static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i, int is_list,
                                                     CYTHON_NCP_UNUSED int wraparound,
                                                     CYTHON_NCP_UNUSED int boundscheck) {
#if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS
    if (is_list || PyList_CheckExact(o)) {
        Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
        if ((!boundscheck) || (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 = ((!wraparound) | likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o);
        if ((!boundscheck) || likely((n >= 0) & (n < PyTuple_GET_SIZE(o)))) {
            PyObject *r = PyTuple_GET_ITEM(o, n);
            Py_INCREF(r);
            return r;
        }
    } else {
        PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
        if (likely(m && m->sq_item)) {
            if (wraparound && unlikely(i < 0) && likely(m->sq_length)) {
                Py_ssize_t l = m->sq_length(o);
                if (likely(l >= 0)) {
                    i += l;
                } else {
                    if (!PyErr_ExceptionMatches(PyExc_OverflowError))
                        return NULL;
                    PyErr_Clear();
                }
            }
            return m->sq_item(o, i);
        }
    }
#else
    if (is_list || PySequence_Check(o)) {
        return PySequence_GetItem(o, i);
    }
#endif
    return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
}

/* RaiseArgTupleInvalid */
      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,
                 "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T "d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T "d given)",
                 func_name, more_or_less, num_expected,
                 (num_expected == 1) ? "" : "s", num_found);
}

/* RaiseDoubleKeywords */
      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_AsString(kw_name));
        #endif
}

/* ParseKeywords */
      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;
            continue;
        }
        name = first_kw_arg;
        #if PY_MAJOR_VERSION < 3
        if (likely(PyString_CheckExact(key)) || likely(PyString_Check(key))) {
            while (*name) {
                if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key))
                        && _PyString_Eq(**name, key)) {
                    values[name-argnames] = value;
                    break;
                }
                name++;
            }
            if (*name) continue;
            else {
                PyObject*** argname = argnames;
                while (argname != first_kw_arg) {
                    if ((**argname == key) || (
                            (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key))
                             && _PyString_Eq(**argname, key))) {
                        goto arg_passed_twice;
                    }
                    argname++;
                }
            }
        } else
        #endif
        if (likely(PyUnicode_Check(key))) {
            while (*name) {
                int cmp = (**name == key) ? 0 :
                #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
                    (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
                #endif
                    PyUnicode_Compare(**name, key);
                if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
                if (cmp == 0) {
                    values[name-argnames] = value;
                    break;
                }
                name++;
            }
            if (*name) continue;
            else {
                PyObject*** argname = argnames;
                while (argname != first_kw_arg) {
                    int cmp = (**argname == key) ? 0 :
                    #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
                        (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
                    #endif
                        PyUnicode_Compare(**argname, key);
                    if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
                    if (cmp == 0) goto arg_passed_twice;
                    argname++;
                }
            }
        } else
            goto invalid_keyword_type;
        if (kwds2) {
            if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad;
        } else {
            goto invalid_keyword;
        }
    }
    return 0;
arg_passed_twice:
    __Pyx_RaiseDoubleKeywordsError(function_name, key);
    goto bad;
invalid_keyword_type:
    PyErr_Format(PyExc_TypeError,
        "%.200s() keywords must be strings", function_name);
    goto bad;
invalid_keyword:
    PyErr_Format(PyExc_TypeError,
    #if PY_MAJOR_VERSION < 3
        "%.200s() got an unexpected keyword argument '%.200s'",
        function_name, PyString_AsString(key));
    #else
        "%s() got an unexpected keyword argument '%U'",
        function_name, key);
    #endif
bad:
    return -1;
}

/* ArgTypeTest */
      static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type, const char *name, int exact)
{
    if (unlikely(!type)) {
        PyErr_SetString(PyExc_SystemError, "Missing type object");
        return 0;
    }
    else if (exact) {
        #if PY_MAJOR_VERSION == 2
        if ((type == &PyBaseString_Type) && likely(__Pyx_PyBaseString_CheckExact(obj))) return 1;
        #endif
    }
    else {
        if (likely(__Pyx_TypeCheck(obj, type))) return 1;
    }
    PyErr_Format(PyExc_TypeError,
        "Argument '%.200s' has incorrect type (expected %.200s, got %.200s)",
        name, type->tp_name, Py_TYPE(obj)->tp_name);
    return 0;
}

/* PyErrExceptionMatches */
      #if CYTHON_FAST_THREAD_STATE
static int __Pyx_PyErr_ExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
    Py_ssize_t i, n;
    n = PyTuple_GET_SIZE(tuple);
#if PY_MAJOR_VERSION >= 3
    for (i=0; i<n; i++) {
        if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
    }
#endif
    for (i=0; i<n; i++) {
        if (__Pyx_PyErr_GivenExceptionMatches(exc_type, PyTuple_GET_ITEM(tuple, i))) return 1;
    }
    return 0;
}
static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err) {
    PyObject *exc_type = tstate->curexc_type;
    if (exc_type == err) return 1;
    if (unlikely(!exc_type)) return 0;
    if (unlikely(PyTuple_Check(err)))
        return __Pyx_PyErr_ExceptionMatchesTuple(exc_type, err);
    return __Pyx_PyErr_GivenExceptionMatches(exc_type, err);
}
#endif

/* PyErrFetchRestore */
      #if CYTHON_FAST_THREAD_STATE
static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
    PyObject *tmp_type, *tmp_value, *tmp_tb;
    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);
}
static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
    *type = tstate->curexc_type;
    *value = tstate->curexc_value;
    *tb = tstate->curexc_traceback;
    tstate->curexc_type = 0;
    tstate->curexc_value = 0;
    tstate->curexc_traceback = 0;
}
#endif

/* GetAttr */
      static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *o, PyObject *n) {
#if CYTHON_USE_TYPE_SLOTS
#if PY_MAJOR_VERSION >= 3
    if (likely(PyUnicode_Check(n)))
#else
    if (likely(PyString_Check(n)))
#endif
        return __Pyx_PyObject_GetAttrStr(o, n);
#endif
    return PyObject_GetAttr(o, n);
}

/* GetAttr3 */
      static PyObject *__Pyx_GetAttr3Default(PyObject *d) {
    __Pyx_PyThreadState_declare
    __Pyx_PyThreadState_assign
    if (unlikely(!__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
        return NULL;
    __Pyx_PyErr_Clear();
    Py_INCREF(d);
    return d;
}
static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *o, PyObject *n, PyObject *d) {
    PyObject *r = __Pyx_GetAttr(o, n);
    return (likely(r)) ? r : __Pyx_GetAttr3Default(d);
}

/* RaiseTooManyValuesToUnpack */
      static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
    PyErr_Format(PyExc_ValueError,
                 "too many values to unpack (expected %" CYTHON_FORMAT_SSIZE_T "d)", expected);
}

/* RaiseNeedMoreValuesToUnpack */
      static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
    PyErr_Format(PyExc_ValueError,
                 "need more than %" CYTHON_FORMAT_SSIZE_T "d value%.1s to unpack",
                 index, (index == 1) ? "" : "s");
}

/* IterFinish */
      static CYTHON_INLINE int __Pyx_IterFinish(void) {
#if CYTHON_FAST_THREAD_STATE
    PyThreadState *tstate = __Pyx_PyThreadState_Current;
    PyObject* exc_type = tstate->curexc_type;
    if (unlikely(exc_type)) {
        if (likely(__Pyx_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
}

/* UnpackItemEndCheck */
      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;
}

/* py_abs */
      #if CYTHON_USE_PYLONG_INTERNALS
static PyObject *__Pyx_PyLong_AbsNeg(PyObject *n) {
    if (likely(Py_SIZE(n) == -1)) {
        return PyLong_FromLong(((PyLongObject*)n)->ob_digit[0]);
    }
#if CYTHON_COMPILING_IN_CPYTHON
    {
        PyObject *copy = _PyLong_Copy((PyLongObject*)n);
        if (likely(copy)) {
            Py_SIZE(copy) = -(Py_SIZE(copy));
        }
        return copy;
    }
#else
    return PyNumber_Negative(n);
#endif
}
#endif

/* ExtTypeTest */
      static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type) {
    if (unlikely(!type)) {
        PyErr_SetString(PyExc_SystemError, "Missing type object");
        return 0;
    }
    if (likely(__Pyx_TypeCheck(obj, type)))
        return 1;
    PyErr_Format(PyExc_TypeError, "Cannot convert %.200s to %.200s",
                 Py_TYPE(obj)->tp_name, type->tp_name);
    return 0;
}

/* WriteUnraisableException */
      static void __Pyx_WriteUnraisable(const char *name, CYTHON_UNUSED int clineno,
                                  CYTHON_UNUSED int lineno, CYTHON_UNUSED const char *filename,
                                  int full_traceback, CYTHON_UNUSED int nogil) {
    PyObject *old_exc, *old_val, *old_tb;
    PyObject *ctx;
    __Pyx_PyThreadState_declare
#ifdef WITH_THREAD
    PyGILState_STATE state;
    if (nogil)
        state = PyGILState_Ensure();
#ifdef _MSC_VER
    else state = (PyGILState_STATE)-1;
#endif
#endif
    __Pyx_PyThreadState_assign
    __Pyx_ErrFetch(&old_exc, &old_val, &old_tb);
    if (full_traceback) {
        Py_XINCREF(old_exc);
        Py_XINCREF(old_val);
        Py_XINCREF(old_tb);
        __Pyx_ErrRestore(old_exc, old_val, old_tb);
        PyErr_PrintEx(1);
    }
    #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);
    }
#ifdef WITH_THREAD
    if (nogil)
        PyGILState_Release(state);
#endif
}

/* pyobject_as_double */
      static double __Pyx__PyObject_AsDouble(PyObject* obj) {
    PyObject* float_value;
#if !CYTHON_USE_TYPE_SLOTS
    float_value = PyNumber_Float(obj);  if (0) goto bad;
#else
    PyNumberMethods *nb = Py_TYPE(obj)->tp_as_number;
    if (likely(nb) && likely(nb->nb_float)) {
        float_value = nb->nb_float(obj);
        if (likely(float_value) && unlikely(!PyFloat_Check(float_value))) {
            PyErr_Format(PyExc_TypeError,
                "__float__ returned non-float (type %.200s)",
                Py_TYPE(float_value)->tp_name);
            Py_DECREF(float_value);
            goto bad;
        }
    } else if (PyUnicode_CheckExact(obj) || PyBytes_CheckExact(obj)) {
#if PY_MAJOR_VERSION >= 3
        float_value = PyFloat_FromString(obj);
#else
        float_value = PyFloat_FromString(obj, 0);
#endif
    } else {
        PyObject* args = PyTuple_New(1);
        if (unlikely(!args)) goto bad;
        PyTuple_SET_ITEM(args, 0, obj);
        float_value = PyObject_Call((PyObject*)&PyFloat_Type, args, 0);
        PyTuple_SET_ITEM(args, 0, 0);
        Py_DECREF(args);
    }
#endif
    if (likely(float_value)) {
        double value = PyFloat_AS_DOUBLE(float_value);
        Py_DECREF(float_value);
        return value;
    }
bad:
    return (double)-1;
}

/* PyIntBinop */
      #if !CYTHON_COMPILING_IN_PYPY
static PyObject* __Pyx_PyInt_AddObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED int inplace) {
    #if PY_MAJOR_VERSION < 3
    if (likely(PyInt_CheckExact(op1))) {
        const long b = intval;
        long x;
        long a = PyInt_AS_LONG(op1);
            x = (long)((unsigned long)a + b);
            if (likely((x^a) >= 0 || (x^b) >= 0))
                return PyInt_FromLong(x);
            return PyLong_Type.tp_as_number->nb_add(op1, op2);
    }
    #endif
    #if CYTHON_USE_PYLONG_INTERNALS
    if (likely(PyLong_CheckExact(op1))) {
        const long b = intval;
        long a, x;
#ifdef HAVE_LONG_LONG
        const PY_LONG_LONG llb = intval;
        PY_LONG_LONG lla, llx;
#endif
        const digit* digits = ((PyLongObject*)op1)->ob_digit;
        const Py_ssize_t size = Py_SIZE(op1);
        if (likely(__Pyx_sst_abs(size) <= 1)) {
            a = likely(size) ? digits[0] : 0;
            if (size == -1) a = -a;
        } else {
            switch (size) {
                case -2:
                    if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                        a = -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
                        break;
#ifdef HAVE_LONG_LONG
                    } else if (8 * sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
                        lla = -(PY_LONG_LONG) (((((unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
                        goto long_long;
#endif
                    }
                    CYTHON_FALLTHROUGH;
                case 2:
                    if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                        a = (long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
                        break;
#ifdef HAVE_LONG_LONG
                    } else if (8 * sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
                        lla = (PY_LONG_LONG) (((((unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
                        goto long_long;
#endif
                    }
                    CYTHON_FALLTHROUGH;
                case -3:
                    if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                        a = -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
                        break;
#ifdef HAVE_LONG_LONG
                    } else if (8 * sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
                        lla = -(PY_LONG_LONG) (((((((unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
                        goto long_long;
#endif
                    }
                    CYTHON_FALLTHROUGH;
                case 3:
                    if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                        a = (long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
                        break;
#ifdef HAVE_LONG_LONG
                    } else if (8 * sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
                        lla = (PY_LONG_LONG) (((((((unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
                        goto long_long;
#endif
                    }
                    CYTHON_FALLTHROUGH;
                case -4:
                    if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
                        a = -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
                        break;
#ifdef HAVE_LONG_LONG
                    } else if (8 * sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
                        lla = -(PY_LONG_LONG) (((((((((unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
                        goto long_long;
#endif
                    }
                    CYTHON_FALLTHROUGH;
                case 4:
                    if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
                        a = (long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]));
                        break;
#ifdef HAVE_LONG_LONG
                    } else if (8 * sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
                        lla = (PY_LONG_LONG) (((((((((unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0]));
                        goto long_long;
#endif
                    }
                    CYTHON_FALLTHROUGH;
                default: return PyLong_Type.tp_as_number->nb_add(op1, op2);
            }
        }
                x = a + b;
            return PyLong_FromLong(x);
#ifdef HAVE_LONG_LONG
        long_long:
                llx = lla + llb;
            return PyLong_FromLongLong(llx);
#endif
        
        
    }
    #endif
    if (PyFloat_CheckExact(op1)) {
        const long b = intval;
        double a = PyFloat_AS_DOUBLE(op1);
            double result;
            PyFPE_START_PROTECT("add", return NULL)
            result = ((double)a) + (double)b;
            PyFPE_END_PROTECT(result)
            return PyFloat_FromDouble(result);
    }
    return (inplace ? PyNumber_InPlaceAdd : PyNumber_Add)(op1, op2);
}
#endif

/* DictGetItem */
      #if PY_MAJOR_VERSION >= 3 && !CYTHON_COMPILING_IN_PYPY
static PyObject *__Pyx_PyDict_GetItem(PyObject *d, PyObject* key) {
    PyObject *value;
    value = PyDict_GetItemWithError(d, key);
    if (unlikely(!value)) {
        if (!PyErr_Occurred()) {
            PyObject* args = PyTuple_Pack(1, key);
            if (likely(args))
                PyErr_SetObject(PyExc_KeyError, args);
            Py_XDECREF(args);
        }
        return NULL;
    }
    Py_INCREF(value);
    return value;
}
#endif

/* SaveResetException */
      #if CYTHON_FAST_THREAD_STATE
static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
    #if PY_VERSION_HEX >= 0x030700A3
    *type = tstate->exc_state.exc_type;
    *value = tstate->exc_state.exc_value;
    *tb = tstate->exc_state.exc_traceback;
    #else
    *type = tstate->exc_type;
    *value = tstate->exc_value;
    *tb = tstate->exc_traceback;
    #endif
    Py_XINCREF(*type);
    Py_XINCREF(*value);
    Py_XINCREF(*tb);
}
static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
    PyObject *tmp_type, *tmp_value, *tmp_tb;
    #if PY_VERSION_HEX >= 0x030700A3
    tmp_type = tstate->exc_state.exc_type;
    tmp_value = tstate->exc_state.exc_value;
    tmp_tb = tstate->exc_state.exc_traceback;
    tstate->exc_state.exc_type = type;
    tstate->exc_state.exc_value = value;
    tstate->exc_state.exc_traceback = tb;
    #else
    tmp_type = tstate->exc_type;
    tmp_value = tstate->exc_value;
    tmp_tb = tstate->exc_traceback;
    tstate->exc_type = type;
    tstate->exc_value = value;
    tstate->exc_traceback = tb;
    #endif
    Py_XDECREF(tmp_type);
    Py_XDECREF(tmp_value);
    Py_XDECREF(tmp_tb);
}
#endif

/* GetException */
      #if CYTHON_FAST_THREAD_STATE
static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
#else
static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb) {
#endif
    PyObject *local_type, *local_value, *local_tb;
#if CYTHON_FAST_THREAD_STATE
    PyObject *tmp_type, *tmp_value, *tmp_tb;
    local_type = tstate->curexc_type;
    local_value = tstate->curexc_value;
    local_tb = tstate->curexc_traceback;
    tstate->curexc_type = 0;
    tstate->curexc_value = 0;
    tstate->curexc_traceback = 0;
#else
    PyErr_Fetch(&local_type, &local_value, &local_tb);
#endif
    PyErr_NormalizeException(&local_type, &local_value, &local_tb);
#if CYTHON_FAST_THREAD_STATE
    if (unlikely(tstate->curexc_type))
#else
    if (unlikely(PyErr_Occurred()))
#endif
        goto bad;
    #if PY_MAJOR_VERSION >= 3
    if (local_tb) {
        if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0))
            goto bad;
    }
    #endif
    Py_XINCREF(local_tb);
    Py_XINCREF(local_type);
    Py_XINCREF(local_value);
    *type = local_type;
    *value = local_value;
    *tb = local_tb;
#if CYTHON_FAST_THREAD_STATE
    #if PY_VERSION_HEX >= 0x030700A3
    tmp_type = tstate->exc_state.exc_type;
    tmp_value = tstate->exc_state.exc_value;
    tmp_tb = tstate->exc_state.exc_traceback;
    tstate->exc_state.exc_type = local_type;
    tstate->exc_state.exc_value = local_value;
    tstate->exc_state.exc_traceback = local_tb;
    #else
    tmp_type = tstate->exc_type;
    tmp_value = tstate->exc_value;
    tmp_tb = tstate->exc_traceback;
    tstate->exc_type = local_type;
    tstate->exc_value = local_value;
    tstate->exc_traceback = local_tb;
    #endif
    Py_XDECREF(tmp_type);
    Py_XDECREF(tmp_value);
    Py_XDECREF(tmp_tb);
#else
    PyErr_SetExcInfo(local_type, local_value, local_tb);
#endif
    return 0;
bad:
    *type = 0;
    *value = 0;
    *tb = 0;
    Py_XDECREF(local_type);
    Py_XDECREF(local_value);
    Py_XDECREF(local_tb);
    return -1;
}

/* Import */
        static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) {
    PyObject *empty_list = 0;
    PyObject *module = 0;
    PyObject *global_dict = 0;
    PyObject *empty_dict = 0;
    PyObject *list;
    #if PY_MAJOR_VERSION < 3
    PyObject *py_import;
    py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import);
    if (!py_import)
        goto bad;
    #endif
    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_MAJOR_VERSION >= 3
        if (level == -1) {
            if (strchr(__Pyx_MODULE_NAME, '.')) {
                module = PyImport_ImportModuleLevelObject(
                    name, global_dict, empty_dict, list, 1);
                if (!module) {
                    if (!PyErr_ExceptionMatches(PyExc_ImportError))
                        goto bad;
                    PyErr_Clear();
                }
            }
            level = 0;
        }
        #endif
        if (!module) {
            #if PY_MAJOR_VERSION < 3
            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
            module = PyImport_ImportModuleLevelObject(
                name, global_dict, empty_dict, list, level);
            #endif
        }
    }
bad:
    #if PY_MAJOR_VERSION < 3
    Py_XDECREF(py_import);
    #endif
    Py_XDECREF(empty_list);
    Py_XDECREF(empty_dict);
    return module;
}

/* HasAttr */
        static CYTHON_INLINE int __Pyx_HasAttr(PyObject *o, PyObject *n) {
    PyObject *r;
    if (unlikely(!__Pyx_PyBaseString_Check(n))) {
        PyErr_SetString(PyExc_TypeError,
                        "hasattr(): attribute name must be string");
        return -1;
    }
    r = __Pyx_GetAttr(o, n);
    if (unlikely(!r)) {
        PyErr_Clear();
        return 0;
    } else {
        Py_DECREF(r);
        return 1;
    }
}

/* ObjectGetItem */
        #if CYTHON_USE_TYPE_SLOTS
static PyObject *__Pyx_PyObject_GetIndex(PyObject *obj, PyObject* index) {
    PyObject *runerr;
    Py_ssize_t key_value;
    PySequenceMethods *m = Py_TYPE(obj)->tp_as_sequence;
    if (unlikely(!(m && m->sq_item))) {
        PyErr_Format(PyExc_TypeError, "'%.200s' object is not subscriptable", Py_TYPE(obj)->tp_name);
        return NULL;
    }
    key_value = __Pyx_PyIndex_AsSsize_t(index);
    if (likely(key_value != -1 || !(runerr = PyErr_Occurred()))) {
        return __Pyx_GetItemInt_Fast(obj, key_value, 0, 1, 1);
    }
    if (PyErr_GivenExceptionMatches(runerr, PyExc_OverflowError)) {
        PyErr_Clear();
        PyErr_Format(PyExc_IndexError, "cannot fit '%.200s' into an index-sized integer", Py_TYPE(index)->tp_name);
    }
    return NULL;
}
static PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key) {
    PyMappingMethods *m = Py_TYPE(obj)->tp_as_mapping;
    if (likely(m && m->mp_subscript)) {
        return m->mp_subscript(obj, key);
    }
    return __Pyx_PyObject_GetIndex(obj, key);
}
#endif

/* PyObjectCallMethod0 */
        static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name) {
    PyObject *method, *result = NULL;
    method = __Pyx_PyObject_GetAttrStr(obj, method_name);
    if (unlikely(!method)) goto bad;
#if CYTHON_UNPACK_METHODS
    if (likely(PyMethod_Check(method))) {
        PyObject *self = PyMethod_GET_SELF(method);
        if (likely(self)) {
            PyObject *function = PyMethod_GET_FUNCTION(method);
            result = __Pyx_PyObject_CallOneArg(function, self);
            Py_DECREF(method);
            return result;
        }
    }
#endif
    result = __Pyx_PyObject_CallNoArg(method);
    Py_DECREF(method);
bad:
    return result;
}

/* RaiseNoneIterError */
        static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void) {
    PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
}

/* UnpackTupleError */
        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);
    }
}

/* UnpackTuple2 */
        static CYTHON_INLINE int __Pyx_unpack_tuple2_exact(
        PyObject* tuple, PyObject** pvalue1, PyObject** pvalue2, int decref_tuple) {
    PyObject *value1 = NULL, *value2 = NULL;
#if CYTHON_COMPILING_IN_PYPY
    value1 = PySequence_ITEM(tuple, 0);  if (unlikely(!value1)) goto bad;
    value2 = PySequence_ITEM(tuple, 1);  if (unlikely(!value2)) goto bad;
#else
    value1 = PyTuple_GET_ITEM(tuple, 0);  Py_INCREF(value1);
    value2 = PyTuple_GET_ITEM(tuple, 1);  Py_INCREF(value2);
#endif
    if (decref_tuple) {
        Py_DECREF(tuple);
    }
    *pvalue1 = value1;
    *pvalue2 = value2;
    return 0;
#if CYTHON_COMPILING_IN_PYPY
bad:
    Py_XDECREF(value1);
    Py_XDECREF(value2);
    if (decref_tuple) { Py_XDECREF(tuple); }
    return -1;
#endif
}
static int __Pyx_unpack_tuple2_generic(PyObject* tuple, PyObject** pvalue1, PyObject** pvalue2,
                                       int has_known_size, int decref_tuple) {
    Py_ssize_t index;
    PyObject *value1 = NULL, *value2 = NULL, *iter = NULL;
    iternextfunc iternext;
    iter = PyObject_GetIter(tuple);
    if (unlikely(!iter)) goto bad;
    if (decref_tuple) { Py_DECREF(tuple); tuple = NULL; }
    iternext = Py_TYPE(iter)->tp_iternext;
    value1 = iternext(iter); if (unlikely(!value1)) { index = 0; goto unpacking_failed; }
    value2 = iternext(iter); if (unlikely(!value2)) { index = 1; goto unpacking_failed; }
    if (!has_known_size && unlikely(__Pyx_IternextUnpackEndCheck(iternext(iter), 2))) goto bad;
    Py_DECREF(iter);
    *pvalue1 = value1;
    *pvalue2 = value2;
    return 0;
unpacking_failed:
    if (!has_known_size && __Pyx_IterFinish() == 0)
        __Pyx_RaiseNeedMoreValuesError(index);
bad:
    Py_XDECREF(iter);
    Py_XDECREF(value1);
    Py_XDECREF(value2);
    if (decref_tuple) { Py_XDECREF(tuple); }
    return -1;
}

/* dict_iter */
        static CYTHON_INLINE PyObject* __Pyx_dict_iterator(PyObject* iterable, int is_dict, PyObject* method_name,
                                                   Py_ssize_t* p_orig_length, int* p_source_is_dict) {
    is_dict = is_dict || likely(PyDict_CheckExact(iterable));
    *p_source_is_dict = is_dict;
    if (is_dict) {
#if !CYTHON_COMPILING_IN_PYPY
        *p_orig_length = PyDict_Size(iterable);
        Py_INCREF(iterable);
        return iterable;
#elif PY_MAJOR_VERSION >= 3
        static PyObject *py_items = NULL, *py_keys = NULL, *py_values = NULL;
        PyObject **pp = NULL;
        if (method_name) {
            const char *name = PyUnicode_AsUTF8(method_name);
            if (strcmp(name, "iteritems") == 0) pp = &py_items;
            else if (strcmp(name, "iterkeys") == 0) pp = &py_keys;
            else if (strcmp(name, "itervalues") == 0) pp = &py_values;
            if (pp) {
                if (!*pp) {
                    *pp = PyUnicode_FromString(name + 4);
                    if (!*pp)
                        return NULL;
                }
                method_name = *pp;
            }
        }
#endif
    }
    *p_orig_length = 0;
    if (method_name) {
        PyObject* iter;
        iterable = __Pyx_PyObject_CallMethod0(iterable, method_name);
        if (!iterable)
            return NULL;
#if !CYTHON_COMPILING_IN_PYPY
        if (PyTuple_CheckExact(iterable) || PyList_CheckExact(iterable))
            return iterable;
#endif
        iter = PyObject_GetIter(iterable);
        Py_DECREF(iterable);
        return iter;
    }
    return PyObject_GetIter(iterable);
}
static CYTHON_INLINE int __Pyx_dict_iter_next(
        PyObject* iter_obj, CYTHON_NCP_UNUSED Py_ssize_t orig_length, CYTHON_NCP_UNUSED Py_ssize_t* ppos,
        PyObject** pkey, PyObject** pvalue, PyObject** pitem, int source_is_dict) {
    PyObject* next_item;
#if !CYTHON_COMPILING_IN_PYPY
    if (source_is_dict) {
        PyObject *key, *value;
        if (unlikely(orig_length != PyDict_Size(iter_obj))) {
            PyErr_SetString(PyExc_RuntimeError, "dictionary changed size during iteration");
            return -1;
        }
        if (unlikely(!PyDict_Next(iter_obj, ppos, &key, &value))) {
            return 0;
        }
        if (pitem) {
            PyObject* tuple = PyTuple_New(2);
            if (unlikely(!tuple)) {
                return -1;
            }
            Py_INCREF(key);
            Py_INCREF(value);
            PyTuple_SET_ITEM(tuple, 0, key);
            PyTuple_SET_ITEM(tuple, 1, value);
            *pitem = tuple;
        } else {
            if (pkey) {
                Py_INCREF(key);
                *pkey = key;
            }
            if (pvalue) {
                Py_INCREF(value);
                *pvalue = value;
            }
        }
        return 1;
    } else if (PyTuple_CheckExact(iter_obj)) {
        Py_ssize_t pos = *ppos;
        if (unlikely(pos >= PyTuple_GET_SIZE(iter_obj))) return 0;
        *ppos = pos + 1;
        next_item = PyTuple_GET_ITEM(iter_obj, pos);
        Py_INCREF(next_item);
    } else if (PyList_CheckExact(iter_obj)) {
        Py_ssize_t pos = *ppos;
        if (unlikely(pos >= PyList_GET_SIZE(iter_obj))) return 0;
        *ppos = pos + 1;
        next_item = PyList_GET_ITEM(iter_obj, pos);
        Py_INCREF(next_item);
    } else
#endif
    {
        next_item = PyIter_Next(iter_obj);
        if (unlikely(!next_item)) {
            return __Pyx_IterFinish();
        }
    }
    if (pitem) {
        *pitem = next_item;
    } else if (pkey && pvalue) {
        if (__Pyx_unpack_tuple2(next_item, pkey, pvalue, source_is_dict, source_is_dict, 1))
            return -1;
    } else if (pkey) {
        *pkey = next_item;
    } else {
        *pvalue = next_item;
    }
    return 1;
}

/* ImportFrom */
        static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name) {
    PyObject* value = __Pyx_PyObject_GetAttrStr(module, name);
    if (unlikely(!value) && PyErr_ExceptionMatches(PyExc_AttributeError)) {
        PyErr_Format(PyExc_ImportError,
        #if PY_MAJOR_VERSION < 3
            "cannot import name %.230s", PyString_AS_STRING(name));
        #else
            "cannot import name %S", name);
        #endif
    }
    return value;
}

/* RaiseException */
        #if PY_MAJOR_VERSION < 3
static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb,
                        CYTHON_UNUSED PyObject *cause) {
    __Pyx_PyThreadState_declare
    Py_XINCREF(type);
    if (!value || value == Py_None)
        value = NULL;
    else
        Py_INCREF(value);
    if (!tb || tb == Py_None)
        tb = NULL;
    else {
        Py_INCREF(tb);
        if (!PyTraceBack_Check(tb)) {
            PyErr_SetString(PyExc_TypeError,
                "raise: arg 3 must be a traceback or None");
            goto raise_error;
        }
    }
    if (PyType_Check(type)) {
#if CYTHON_COMPILING_IN_PYPY
        if (!value) {
            Py_INCREF(Py_None);
            value = Py_None;
        }
#endif
        PyErr_NormalizeException(&type, &value, &tb);
    } else {
        if (value) {
            PyErr_SetString(PyExc_TypeError,
                "instance exception may not have a separate value");
            goto raise_error;
        }
        value = type;
        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;
        }
    }
    __Pyx_PyThreadState_assign
    __Pyx_ErrRestore(type, value, tb);
    return;
raise_error:
    Py_XDECREF(value);
    Py_XDECREF(type);
    Py_XDECREF(tb);
    return;
}
#else
static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
    PyObject* owned_instance = NULL;
    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)) {
        PyObject *instance_class = NULL;
        if (value && PyExceptionInstance_Check(value)) {
            instance_class = (PyObject*) Py_TYPE(value);
            if (instance_class != type) {
                int is_subclass = PyObject_IsSubclass(instance_class, type);
                if (!is_subclass) {
                    instance_class = NULL;
                } else if (unlikely(is_subclass == -1)) {
                    goto bad;
                } else {
                    type = instance_class;
                }
            }
        }
        if (!instance_class) {
            PyObject *args;
            if (!value)
                args = PyTuple_New(0);
            else if (PyTuple_Check(value)) {
                Py_INCREF(value);
                args = value;
            } else
                args = PyTuple_Pack(1, value);
            if (!args)
                goto bad;
            owned_instance = PyObject_Call(type, args, NULL);
            Py_DECREF(args);
            if (!owned_instance)
                goto bad;
            value = owned_instance;
            if (!PyExceptionInstance_Check(value)) {
                PyErr_Format(PyExc_TypeError,
                             "calling %R should have returned an instance of "
                             "BaseException, not %R",
                             type, Py_TYPE(value));
                goto bad;
            }
        }
    } else {
        PyErr_SetString(PyExc_TypeError,
            "raise: exception class must be a subclass of BaseException");
        goto bad;
    }
    if (cause) {
        PyObject *fixed_cause;
        if (cause == Py_None) {
            fixed_cause = NULL;
        } else 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;
        }
        PyException_SetCause(value, fixed_cause);
    }
    PyErr_SetObject(type, value);
    if (tb) {
#if CYTHON_COMPILING_IN_PYPY
        PyObject *tmp_type, *tmp_value, *tmp_tb;
        PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb);
        Py_INCREF(tb);
        PyErr_Restore(tmp_type, tmp_value, tb);
        Py_XDECREF(tmp_tb);
#else
        PyThreadState *tstate = __Pyx_PyThreadState_Current;
        PyObject* tmp_tb = tstate->curexc_traceback;
        if (tb != tmp_tb) {
            Py_INCREF(tb);
            tstate->curexc_traceback = tb;
            Py_XDECREF(tmp_tb);
        }
#endif
    }
bad:
    Py_XDECREF(owned_instance);
    return;
}
#endif

/* PyObject_GenericGetAttrNoDict */
        #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) {
    PyErr_Format(PyExc_AttributeError,
#if PY_MAJOR_VERSION >= 3
                 "'%.50s' object has no attribute '%U'",
                 tp->tp_name, attr_name);
#else
                 "'%.50s' object has no attribute '%.400s'",
                 tp->tp_name, PyString_AS_STRING(attr_name));
#endif
    return NULL;
}
static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) {
    PyObject *descr;
    PyTypeObject *tp = Py_TYPE(obj);
    if (unlikely(!PyString_Check(attr_name))) {
        return PyObject_GenericGetAttr(obj, attr_name);
    }
    assert(!tp->tp_dictoffset);
    descr = _PyType_Lookup(tp, attr_name);
    if (unlikely(!descr)) {
        return __Pyx_RaiseGenericGetAttributeError(tp, attr_name);
    }
    Py_INCREF(descr);
    #if PY_MAJOR_VERSION < 3
    if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS)))
    #endif
    {
        descrgetfunc f = Py_TYPE(descr)->tp_descr_get;
        if (unlikely(f)) {
            PyObject *res = f(descr, obj, (PyObject *)tp);
            Py_DECREF(descr);
            return res;
        }
    }
    return descr;
}
#endif

/* PyObject_GenericGetAttr */
        #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) {
    if (unlikely(Py_TYPE(obj)->tp_dictoffset)) {
        return PyObject_GenericGetAttr(obj, attr_name);
    }
    return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name);
}
#endif

/* SetupReduce */
        static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) {
  int ret;
  PyObject *name_attr;
  name_attr = __Pyx_PyObject_GetAttrStr(meth, __pyx_n_s_name_2);
  if (likely(name_attr)) {
      ret = PyObject_RichCompareBool(name_attr, name, Py_EQ);
  } else {
      ret = -1;
  }
  if (unlikely(ret < 0)) {
      PyErr_Clear();
      ret = 0;
  }
  Py_XDECREF(name_attr);
  return ret;
}
static int __Pyx_setup_reduce(PyObject* type_obj) {
    int ret = 0;
    PyObject *object_reduce = NULL;
    PyObject *object_reduce_ex = NULL;
    PyObject *reduce = NULL;
    PyObject *reduce_ex = NULL;
    PyObject *reduce_cython = NULL;
    PyObject *setstate = NULL;
    PyObject *setstate_cython = NULL;
#if CYTHON_USE_PYTYPE_LOOKUP
    if (_PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate)) goto GOOD;
#else
    if (PyObject_HasAttr(type_obj, __pyx_n_s_getstate)) goto GOOD;
#endif
#if CYTHON_USE_PYTYPE_LOOKUP
    object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto BAD;
#else
    object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto BAD;
#endif
    reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex); if (unlikely(!reduce_ex)) goto BAD;
    if (reduce_ex == object_reduce_ex) {
#if CYTHON_USE_PYTYPE_LOOKUP
        object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto BAD;
#else
        object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto BAD;
#endif
        reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce); if (unlikely(!reduce)) goto BAD;
        if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) {
            reduce_cython = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_cython); if (unlikely(!reduce_cython)) goto BAD;
            ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython); if (unlikely(ret < 0)) goto BAD;
            ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython); if (unlikely(ret < 0)) goto BAD;
            setstate = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate);
            if (!setstate) PyErr_Clear();
            if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) {
                setstate_cython = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate_cython); if (unlikely(!setstate_cython)) goto BAD;
                ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython); if (unlikely(ret < 0)) goto BAD;
                ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython); if (unlikely(ret < 0)) goto BAD;
            }
            PyType_Modified((PyTypeObject*)type_obj);
        }
    }
    goto GOOD;
BAD:
    if (!PyErr_Occurred())
        PyErr_Format(PyExc_RuntimeError, "Unable to initialize pickling for %s", ((PyTypeObject*)type_obj)->tp_name);
    ret = -1;
GOOD:
#if !CYTHON_USE_PYTYPE_LOOKUP
    Py_XDECREF(object_reduce);
    Py_XDECREF(object_reduce_ex);
#endif
    Py_XDECREF(reduce);
    Py_XDECREF(reduce_ex);
    Py_XDECREF(reduce_cython);
    Py_XDECREF(setstate);
    Py_XDECREF(setstate_cython);
    return ret;
}

/* SetVTable */
        static int __Pyx_SetVtable(PyObject *dict, void *vtable) {
#if PY_VERSION_HEX >= 0x02070000
    PyObject *ob = PyCapsule_New(vtable, 0, 0);
#else
    PyObject *ob = PyCObject_FromVoidPtr(vtable, 0);
#endif
    if (!ob)
        goto bad;
    if (PyDict_SetItem(dict, __pyx_n_s_pyx_vtable, ob) < 0)
        goto bad;
    Py_DECREF(ob);
    return 0;
bad:
    Py_XDECREF(ob);
    return -1;
}

/* CLineInTraceback */
        #ifndef CYTHON_CLINE_IN_TRACEBACK
static int __Pyx_CLineForTraceback(CYTHON_UNUSED PyThreadState *tstate, int c_line) {
    PyObject *use_cline;
    PyObject *ptype, *pvalue, *ptraceback;
#if CYTHON_COMPILING_IN_CPYTHON
    PyObject **cython_runtime_dict;
#endif
    if (unlikely(!__pyx_cython_runtime)) {
        return c_line;
    }
    __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
#if CYTHON_COMPILING_IN_CPYTHON
    cython_runtime_dict = _PyObject_GetDictPtr(__pyx_cython_runtime);
    if (likely(cython_runtime_dict)) {
      use_cline = __Pyx_PyDict_GetItemStr(*cython_runtime_dict, __pyx_n_s_cline_in_traceback);
    } else
#endif
    {
      PyObject *use_cline_obj = __Pyx_PyObject_GetAttrStr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback);
      if (use_cline_obj) {
        use_cline = PyObject_Not(use_cline_obj) ? Py_False : Py_True;
        Py_DECREF(use_cline_obj);
      } else {
        PyErr_Clear();
        use_cline = NULL;
      }
    }
    if (!use_cline) {
        c_line = 0;
        PyObject_SetAttr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback, Py_False);
    }
    else if (PyObject_Not(use_cline) != 0) {
        c_line = 0;
    }
    __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
    return c_line;
}
#endif

/* CodeObjectCache */
        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 - start) / 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, (size_t)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);
}

/* AddTraceback */
        #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,
        0,
        0,
        0,
        0,
        __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,
        __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;
    PyFrameObject *py_frame = 0;
    PyThreadState *tstate = __Pyx_PyThreadState_Current;
    if (c_line) {
        c_line = __Pyx_CLineForTraceback(tstate, c_line);
    }
    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_frame = PyFrame_New(
        tstate,            /*PyThreadState *tstate,*/
        py_code,           /*PyCodeObject *code,*/
        __pyx_d,    /*PyObject *globals,*/
        0                  /*PyObject *locals*/
    );
    if (!py_frame) goto bad;
    __Pyx_PyFrame_SetLineNumber(py_frame, py_line);
    PyTraceBack_Here(py_frame);
bad:
    Py_XDECREF(py_code);
    Py_XDECREF(py_frame);
}

/* CIntToPy */
        static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value) {
    const int neg_one = (int) -1, const_zero = (int) 0;
    const int is_unsigned = neg_one > const_zero;
    if (is_unsigned) {
        if (sizeof(int) < sizeof(long)) {
            return PyInt_FromLong((long) value);
        } else if (sizeof(int) <= sizeof(unsigned long)) {
            return PyLong_FromUnsignedLong((unsigned long) value);
#ifdef HAVE_LONG_LONG
        } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
            return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
#endif
        }
    } else {
        if (sizeof(int) <= sizeof(long)) {
            return PyInt_FromLong((long) value);
#ifdef HAVE_LONG_LONG
        } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
            return PyLong_FromLongLong((PY_LONG_LONG) value);
#endif
        }
    }
    {
        int one = 1; int little = (int)*(unsigned char *)&one;
        unsigned char *bytes = (unsigned char *)&value;
        return _PyLong_FromByteArray(bytes, sizeof(int),
                                     little, !is_unsigned);
    }
}

/* CIntFromPyVerify */
        #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
    __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
#define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
    __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
#define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
    {\
        func_type value = func_value;\
        if (sizeof(target_type) < sizeof(func_type)) {\
            if (unlikely(value != (func_type) (target_type) value)) {\
                func_type zero = 0;\
                if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
                    return (target_type) -1;\
                if (is_unsigned && unlikely(value < zero))\
                    goto raise_neg_overflow;\
                else\
                    goto raise_overflow;\
            }\
        }\
        return (target_type) value;\
    }

/* CIntToPy */
        static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) {
    const long neg_one = (long) -1, const_zero = (long) 0;
    const int is_unsigned = neg_one > const_zero;
    if (is_unsigned) {
        if (sizeof(long) < sizeof(long)) {
            return PyInt_FromLong((long) value);
        } else if (sizeof(long) <= sizeof(unsigned long)) {
            return PyLong_FromUnsignedLong((unsigned long) value);
#ifdef HAVE_LONG_LONG
        } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
            return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
#endif
        }
    } else {
        if (sizeof(long) <= sizeof(long)) {
            return PyInt_FromLong((long) value);
#ifdef HAVE_LONG_LONG
        } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
            return PyLong_FromLongLong((PY_LONG_LONG) value);
#endif
        }
    }
    {
        int one = 1; int little = (int)*(unsigned char *)&one;
        unsigned char *bytes = (unsigned char *)&value;
        return _PyLong_FromByteArray(bytes, sizeof(long),
                                     little, !is_unsigned);
    }
}

/* Print */
        #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION < 3
static PyObject *__Pyx_GetStdout(void) {
    PyObject *f = PySys_GetObject((char *)"stdout");
    if (!f) {
        PyErr_SetString(PyExc_RuntimeError, "lost sys.stdout");
    }
    return f;
}
static int __Pyx_Print(PyObject* f, PyObject *arg_tuple, int newline) {
    int i;
    if (!f) {
        if (!(f = __Pyx_GetStdout()))
            return -1;
    }
    Py_INCREF(f);
    for (i=0; i < PyTuple_GET_SIZE(arg_tuple); i++) {
        PyObject* v;
        if (PyFile_SoftSpace(f, 1)) {
            if (PyFile_WriteString(" ", f) < 0)
                goto error;
        }
        v = PyTuple_GET_ITEM(arg_tuple, i);
        if (PyFile_WriteObject(v, f, Py_PRINT_RAW) < 0)
            goto error;
        if (PyString_Check(v)) {
            char *s = PyString_AsString(v);
            Py_ssize_t len = PyString_Size(v);
            if (len > 0) {
                switch (s[len-1]) {
                    case ' ': break;
                    case '\f': case '\r': case '\n': case '\t': case '\v':
                        PyFile_SoftSpace(f, 0);
                        break;
                    default:  break;
                }
            }
        }
    }
    if (newline) {
        if (PyFile_WriteString("\n", f) < 0)
            goto error;
        PyFile_SoftSpace(f, 0);
    }
    Py_DECREF(f);
    return 0;
error:
    Py_DECREF(f);
    return -1;
}
#else
static int __Pyx_Print(PyObject* stream, PyObject *arg_tuple, int newline) {
    PyObject* kwargs = 0;
    PyObject* result = 0;
    PyObject* end_string;
    if (unlikely(!__pyx_print)) {
        __pyx_print = PyObject_GetAttr(__pyx_b, __pyx_n_s_print);
        if (!__pyx_print)
            return -1;
    }
    if (stream) {
        kwargs = PyDict_New();
        if (unlikely(!kwargs))
            return -1;
        if (unlikely(PyDict_SetItem(kwargs, __pyx_n_s_file_2, stream) < 0))
            goto bad;
        if (!newline) {
            end_string = PyUnicode_FromStringAndSize(" ", 1);
            if (unlikely(!end_string))
                goto bad;
            if (PyDict_SetItem(kwargs, __pyx_n_s_end, end_string) < 0) {
                Py_DECREF(end_string);
                goto bad;
            }
            Py_DECREF(end_string);
        }
    } else if (!newline) {
        if (unlikely(!__pyx_print_kwargs)) {
            __pyx_print_kwargs = PyDict_New();
            if (unlikely(!__pyx_print_kwargs))
                return -1;
            end_string = PyUnicode_FromStringAndSize(" ", 1);
            if (unlikely(!end_string))
                return -1;
            if (PyDict_SetItem(__pyx_print_kwargs, __pyx_n_s_end, end_string) < 0) {
                Py_DECREF(end_string);
                return -1;
            }
            Py_DECREF(end_string);
        }
        kwargs = __pyx_print_kwargs;
    }
    result = PyObject_Call(__pyx_print, arg_tuple, kwargs);
    if (unlikely(kwargs) && (kwargs != __pyx_print_kwargs))
        Py_DECREF(kwargs);
    if (!result)
        return -1;
    Py_DECREF(result);
    return 0;
bad:
    if (kwargs != __pyx_print_kwargs)
        Py_XDECREF(kwargs);
    return -1;
}
#endif

/* CIntFromPy */
        static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
    const int neg_one = (int) -1, const_zero = (int) 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_MAJOR_VERSION < 3
    if (likely(PyInt_Check(x))) {
        if (sizeof(int) < sizeof(long)) {
            __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x))
        } else {
            long val = PyInt_AS_LONG(x);
            if (is_unsigned && unlikely(val < 0)) {
                goto raise_neg_overflow;
            }
            return (int) val;
        }
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (int) 0;
                case  1: __PYX_VERIFY_RETURN_INT(int, digit, digits[0])
                case 2:
                    if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) >= 2 * PyLong_SHIFT) {
                            return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) >= 3 * PyLong_SHIFT) {
                            return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) >= 4 * PyLong_SHIFT) {
                            return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
                        }
                    }
                    break;
            }
#endif
#if CYTHON_COMPILING_IN_CPYTHON
            if (unlikely(Py_SIZE(x) < 0)) {
                goto raise_neg_overflow;
            }
#else
            {
                int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
                if (unlikely(result < 0))
                    return (int) -1;
                if (unlikely(result == 1))
                    goto raise_neg_overflow;
            }
#endif
            if (sizeof(int) <= sizeof(unsigned long)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
#endif
            }
        } else {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (int) 0;
                case -1: __PYX_VERIFY_RETURN_INT(int, sdigit, (sdigit) (-(sdigit)digits[0]))
                case  1: __PYX_VERIFY_RETURN_INT(int,  digit, +digits[0])
                case -2:
                    if (8 * sizeof(int) - 1 > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
                            return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case 2:
                    if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
                            return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case -3:
                    if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
                            return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
                            return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case -4:
                    if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
                            return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
                            return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
                        }
                    }
                    break;
            }
#endif
            if (sizeof(int) <= sizeof(long)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x))
#endif
            }
        }
        {
#if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
            PyErr_SetString(PyExc_RuntimeError,
                            "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
#else
            int val;
            PyObject *v = __Pyx_PyNumber_IntOrLong(x);
 #if PY_MAJOR_VERSION < 3
            if (likely(v) && !PyLong_Check(v)) {
                PyObject *tmp = v;
                v = PyNumber_Long(tmp);
                Py_DECREF(tmp);
            }
 #endif
            if (likely(v)) {
                int one = 1; int is_little = (int)*(unsigned char *)&one;
                unsigned char *bytes = (unsigned char *)&val;
                int ret = _PyLong_AsByteArray((PyLongObject *)v,
                                              bytes, sizeof(val),
                                              is_little, !is_unsigned);
                Py_DECREF(v);
                if (likely(!ret))
                    return val;
            }
#endif
            return (int) -1;
        }
    } else {
        int val;
        PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
        if (!tmp) return (int) -1;
        val = __Pyx_PyInt_As_int(tmp);
        Py_DECREF(tmp);
        return val;
    }
raise_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "value too large to convert to int");
    return (int) -1;
raise_neg_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "can't convert negative value to int");
    return (int) -1;
}

/* CIntFromPy */
        static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) {
    const long neg_one = (long) -1, const_zero = (long) 0;
    const int is_unsigned = neg_one > const_zero;
#if PY_MAJOR_VERSION < 3
    if (likely(PyInt_Check(x))) {
        if (sizeof(long) < sizeof(long)) {
            __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x))
        } else {
            long val = PyInt_AS_LONG(x);
            if (is_unsigned && unlikely(val < 0)) {
                goto raise_neg_overflow;
            }
            return (long) val;
        }
    } else
#endif
    if (likely(PyLong_Check(x))) {
        if (is_unsigned) {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (long) 0;
                case  1: __PYX_VERIFY_RETURN_INT(long, digit, digits[0])
                case 2:
                    if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) >= 2 * PyLong_SHIFT) {
                            return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) >= 3 * PyLong_SHIFT) {
                            return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) >= 4 * PyLong_SHIFT) {
                            return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
                        }
                    }
                    break;
            }
#endif
#if CYTHON_COMPILING_IN_CPYTHON
            if (unlikely(Py_SIZE(x) < 0)) {
                goto raise_neg_overflow;
            }
#else
            {
                int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
                if (unlikely(result < 0))
                    return (long) -1;
                if (unlikely(result == 1))
                    goto raise_neg_overflow;
            }
#endif
            if (sizeof(long) <= sizeof(unsigned long)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
#endif
            }
        } else {
#if CYTHON_USE_PYLONG_INTERNALS
            const digit* digits = ((PyLongObject*)x)->ob_digit;
            switch (Py_SIZE(x)) {
                case  0: return (long) 0;
                case -1: __PYX_VERIFY_RETURN_INT(long, sdigit, (sdigit) (-(sdigit)digits[0]))
                case  1: __PYX_VERIFY_RETURN_INT(long,  digit, +digits[0])
                case -2:
                    if (8 * sizeof(long) - 1 > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                            return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case 2:
                    if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                            return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case -3:
                    if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                            return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case 3:
                    if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                            return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case -4:
                    if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
                            return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
                case 4:
                    if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
                        if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
                            __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
                        } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
                            return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
                        }
                    }
                    break;
            }
#endif
            if (sizeof(long) <= sizeof(long)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x))
#ifdef HAVE_LONG_LONG
            } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
                __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x))
#endif
            }
        }
        {
#if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
            PyErr_SetString(PyExc_RuntimeError,
                            "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
#else
            long val;
            PyObject *v = __Pyx_PyNumber_IntOrLong(x);
 #if PY_MAJOR_VERSION < 3
            if (likely(v) && !PyLong_Check(v)) {
                PyObject *tmp = v;
                v = PyNumber_Long(tmp);
                Py_DECREF(tmp);
            }
 #endif
            if (likely(v)) {
                int one = 1; int is_little = (int)*(unsigned char *)&one;
                unsigned char *bytes = (unsigned char *)&val;
                int ret = _PyLong_AsByteArray((PyLongObject *)v,
                                              bytes, sizeof(val),
                                              is_little, !is_unsigned);
                Py_DECREF(v);
                if (likely(!ret))
                    return val;
            }
#endif
            return (long) -1;
        }
    } else {
        long val;
        PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
        if (!tmp) return (long) -1;
        val = __Pyx_PyInt_As_long(tmp);
        Py_DECREF(tmp);
        return val;
    }
raise_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "value too large to convert to long");
    return (long) -1;
raise_neg_overflow:
    PyErr_SetString(PyExc_OverflowError,
        "can't convert negative value to long");
    return (long) -1;
}

/* PrintOne */
        #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION < 3
static int __Pyx_PrintOne(PyObject* f, PyObject *o) {
    if (!f) {
        if (!(f = __Pyx_GetStdout()))
            return -1;
    }
    Py_INCREF(f);
    if (PyFile_SoftSpace(f, 0)) {
        if (PyFile_WriteString(" ", f) < 0)
            goto error;
    }
    if (PyFile_WriteObject(o, f, Py_PRINT_RAW) < 0)
        goto error;
    if (PyFile_WriteString("\n", f) < 0)
        goto error;
    Py_DECREF(f);
    return 0;
error:
    Py_DECREF(f);
    return -1;
    /* the line below is just to avoid C compiler
     * warnings about unused functions */
    return __Pyx_Print(f, NULL, 0);
}
#else
static int __Pyx_PrintOne(PyObject* stream, PyObject *o) {
    int res;
    PyObject* arg_tuple = PyTuple_Pack(1, o);
    if (unlikely(!arg_tuple))
        return -1;
    res = __Pyx_Print(stream, arg_tuple, 1);
    Py_DECREF(arg_tuple);
    return res;
}
#endif

/* FastTypeChecks */
        #if CYTHON_COMPILING_IN_CPYTHON
static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) {
    while (a) {
        a = a->tp_base;
        if (a == b)
            return 1;
    }
    return b == &PyBaseObject_Type;
}
static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) {
    PyObject *mro;
    if (a == b) return 1;
    mro = a->tp_mro;
    if (likely(mro)) {
        Py_ssize_t i, n;
        n = PyTuple_GET_SIZE(mro);
        for (i = 0; i < n; i++) {
            if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b)
                return 1;
        }
        return 0;
    }
    return __Pyx_InBases(a, b);
}
#if PY_MAJOR_VERSION == 2
static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) {
    PyObject *exception, *value, *tb;
    int res;
    __Pyx_PyThreadState_declare
    __Pyx_PyThreadState_assign
    __Pyx_ErrFetch(&exception, &value, &tb);
    res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0;
    if (unlikely(res == -1)) {
        PyErr_WriteUnraisable(err);
        res = 0;
    }
    if (!res) {
        res = PyObject_IsSubclass(err, exc_type2);
        if (unlikely(res == -1)) {
            PyErr_WriteUnraisable(err);
            res = 0;
        }
    }
    __Pyx_ErrRestore(exception, value, tb);
    return res;
}
#else
static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) {
    int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0;
    if (!res) {
        res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2);
    }
    return res;
}
#endif
static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
    Py_ssize_t i, n;
    assert(PyExceptionClass_Check(exc_type));
    n = PyTuple_GET_SIZE(tuple);
#if PY_MAJOR_VERSION >= 3
    for (i=0; i<n; i++) {
        if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
    }
#endif
    for (i=0; i<n; i++) {
        PyObject *t = PyTuple_GET_ITEM(tuple, i);
        #if PY_MAJOR_VERSION < 3
        if (likely(exc_type == t)) return 1;
        #endif
        if (likely(PyExceptionClass_Check(t))) {
            if (__Pyx_inner_PyErr_GivenExceptionMatches2(exc_type, NULL, t)) return 1;
        } else {
        }
    }
    return 0;
}
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject* exc_type) {
    if (likely(err == exc_type)) return 1;
    if (likely(PyExceptionClass_Check(err))) {
        if (likely(PyExceptionClass_Check(exc_type))) {
            return __Pyx_inner_PyErr_GivenExceptionMatches2(err, NULL, exc_type);
        } else if (likely(PyTuple_Check(exc_type))) {
            return __Pyx_PyErr_GivenExceptionMatchesTuple(err, exc_type);
        } else {
        }
    }
    return PyErr_GivenExceptionMatches(err, exc_type);
}
static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *exc_type1, PyObject *exc_type2) {
    assert(PyExceptionClass_Check(exc_type1));
    assert(PyExceptionClass_Check(exc_type2));
    if (likely(err == exc_type1 || err == exc_type2)) return 1;
    if (likely(PyExceptionClass_Check(err))) {
        return __Pyx_inner_PyErr_GivenExceptionMatches2(err, exc_type1, exc_type2);
    }
    return (PyErr_GivenExceptionMatches(err, exc_type1) || PyErr_GivenExceptionMatches(err, exc_type2));
}
#endif

/* CheckBinaryVersion */
        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);
        return PyErr_WarnEx(NULL, message, 1);
    }
    return 0;
}

/* InitStrings */
        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
        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;
        if (PyObject_Hash(*t->p) == -1)
            return -1;
        ++t;
    }
    return 0;
}

static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
    return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str));
}
static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject* o) {
    Py_ssize_t ignore;
    return __Pyx_PyObject_AsStringAndSize(o, &ignore);
}
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
#if !CYTHON_PEP393_ENABLED
static const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
    char* defenc_c;
    PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
    if (!defenc) return NULL;
    defenc_c = PyBytes_AS_STRING(defenc);
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
    {
        char* end = defenc_c + PyBytes_GET_SIZE(defenc);
        char* c;
        for (c = defenc_c; c < end; c++) {
            if ((unsigned char) (*c) >= 128) {
                PyUnicode_AsASCIIString(o);
                return NULL;
            }
        }
    }
#endif
    *length = PyBytes_GET_SIZE(defenc);
    return defenc_c;
}
#else
static CYTHON_INLINE const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
    if (unlikely(__Pyx_PyUnicode_READY(o) == -1)) return NULL;
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
    if (likely(PyUnicode_IS_ASCII(o))) {
        *length = PyUnicode_GET_LENGTH(o);
        return PyUnicode_AsUTF8(o);
    } else {
        PyUnicode_AsASCIIString(o);
        return NULL;
    }
#else
    return PyUnicode_AsUTF8AndSize(o, length);
#endif
}
#endif
#endif
static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
#if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
    if (
#if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
            __Pyx_sys_getdefaultencoding_not_ascii &&
#endif
            PyUnicode_Check(o)) {
        return __Pyx_PyUnicode_AsStringAndSize(o, length);
    } else
#endif
#if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
    if (PyByteArray_Check(o)) {
        *length = PyByteArray_GET_SIZE(o);
        return PyByteArray_AS_STRING(o);
    } else
#endif
    {
        char* result;
        int r = PyBytes_AsStringAndSize(o, &result, length);
        if (unlikely(r < 0)) {
            return NULL;
        } else {
            return result;
        }
    }
}
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 PyObject* __Pyx_PyNumber_IntOrLongWrongResultType(PyObject* result, const char* type_name) {
#if PY_MAJOR_VERSION >= 3
    if (PyLong_Check(result)) {
        if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
                "__int__ returned non-int (type %.200s).  "
                "The ability to return an instance of a strict subclass of int "
                "is deprecated, and may be removed in a future version of Python.",
                Py_TYPE(result)->tp_name)) {
            Py_DECREF(result);
            return NULL;
        }
        return result;
    }
#endif
    PyErr_Format(PyExc_TypeError,
                 "__%.4s__ returned non-%.4s (type %.200s)",
                 type_name, type_name, Py_TYPE(result)->tp_name);
    Py_DECREF(result);
    return NULL;
}
static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) {
#if CYTHON_USE_TYPE_SLOTS
  PyNumberMethods *m;
#endif
  const char *name = NULL;
  PyObject *res = NULL;
#if PY_MAJOR_VERSION < 3
  if (likely(PyInt_Check(x) || PyLong_Check(x)))
#else
  if (likely(PyLong_Check(x)))
#endif
    return __Pyx_NewRef(x);
#if CYTHON_USE_TYPE_SLOTS
  m = Py_TYPE(x)->tp_as_number;
  #if PY_MAJOR_VERSION < 3
  if (m && m->nb_int) {
    name = "int";
    res = m->nb_int(x);
  }
  else if (m && m->nb_long) {
    name = "long";
    res = m->nb_long(x);
  }
  #else
  if (likely(m && m->nb_int)) {
    name = "int";
    res = m->nb_int(x);
  }
  #endif
#else
  if (!PyBytes_CheckExact(x) && !PyUnicode_CheckExact(x)) {
    res = PyNumber_Int(x);
  }
#endif
  if (likely(res)) {
#if PY_MAJOR_VERSION < 3
    if (unlikely(!PyInt_Check(res) && !PyLong_Check(res))) {
#else
    if (unlikely(!PyLong_CheckExact(res))) {
#endif
        return __Pyx_PyNumber_IntOrLongWrongResultType(res, name);
    }
  }
  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;
#if PY_MAJOR_VERSION < 3
  if (likely(PyInt_CheckExact(b))) {
    if (sizeof(Py_ssize_t) >= sizeof(long))
        return PyInt_AS_LONG(b);
    else
        return PyInt_AsSsize_t(x);
  }
#endif
  if (likely(PyLong_CheckExact(b))) {
    #if CYTHON_USE_PYLONG_INTERNALS
    const digit* digits = ((PyLongObject*)b)->ob_digit;
    const Py_ssize_t size = Py_SIZE(b);
    if (likely(__Pyx_sst_abs(size) <= 1)) {
        ival = likely(size) ? digits[0] : 0;
        if (size == -1) ival = -ival;
        return ival;
    } else {
      switch (size) {
         case 2:
           if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
             return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case -2:
           if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
             return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case 3:
           if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
             return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case -3:
           if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
             return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case 4:
           if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
             return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
         case -4:
           if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
             return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
           }
           break;
      }
    }
    #endif
    return PyLong_AsSsize_t(b);
  }
  x = PyNumber_Index(b);
  if (!x) return -1;
  ival = PyInt_AsSsize_t(x);
  Py_DECREF(x);
  return ival;
}
static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b) {
  return b ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False);
}
static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
    return PyInt_FromSize_t(ival);
}


#endif /* Py_PYTHON_H */
