/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (http://www.swig.org).
 * Version 1.3u-20000712-1502 (Alpha 3)
 * 
 * This file is not intended to be easily readable and contains a number of 
 * coding conventions designed to improve portability and efficiency. Do not make
 * changes to this file unless you know what you are doing--modify the SWIG 
 * interface file instead. 
 * ----------------------------------------------------------------------------- */

#define SWIGPYTHON
/***********************************************************************
 * common.swg
 *
 *     This file contains generic SWIG runtime support for pointer
 *     type checking as well as a few commonly used macros to control
 *     external linkage.
 *
 * Author : David Beazley (beazley@cs.uchicago.edu)
 *
 * Copyright (c) 1999-2000, The University of Chicago
 * 
 * This file may be freely redistributed without license or fee provided
 * this copyright message remains intact.
 ************************************************************************/

#include <string.h>

#if defined(_WIN32) || defined(__WIN32__)
#       if defined(_MSC_VER)
#               if defined(STATIC_LINKED)
#                       define SWIGEXPORT(a) a
#               else
#                       define SWIGEXPORT(a) __declspec(dllexport) a
#               endif
#       else
#               if defined(__BORLANDC__)
#                       define SWIGEXPORT(a) a _export
#               else
#                       define SWIGEXPORT(a) a
#       endif
#endif
#else
#       define SWIGEXPORT(a) a
#endif

#ifdef SWIG_GLOBAL
#define SWIGRUNTIME(a) SWIGEXPORT(a)
#else
#define SWIGRUNTIME(a) static a
#endif

#ifdef __cplusplus
extern "C" {
#endif

typedef struct swig_type_info {
  char  *name;                 
  void *(*converter)(void *);
  char  *str;
  struct swig_type_info  *next;
  struct swig_type_info  *prev;
} swig_type_info;

#ifdef SWIG_NOINCLUDE
SWIGEXPORT(swig_type_info *) SWIG_TypeRegister(swig_type_info *);
SWIGEXPORT(swig_type_info *) SWIG_TypeCheck(char *c, swig_type_info *);
SWIGEXPORT(void *) SWIG_TypeCast(swig_type_info *, void *);
#else

static swig_type_info *swig_type_list = 0;

/* Register a type mapping with the type-checking */
SWIGRUNTIME(swig_type_info *)
SWIG_TypeRegister(swig_type_info *ti)
{
  swig_type_info *tc, *head, *ret, *next;
  /* Check to see if this type has already been registered */
  tc = swig_type_list;
  while (tc) {
    if (strcmp(tc->name, ti->name) == 0) {
      /* Already exists in the table.  Just add additional types to the list */
      head = tc;
      next = tc->next;
      goto l1;
    }
    tc = tc->prev;
  }
  head = ti;
  next = 0;

  /* Place in list */
  ti->prev = swig_type_list;
  swig_type_list = ti;

  /* Build linked lists */
 l1:
  ret = head;
  tc = ti + 1;
  /* Patch up the rest of the links */
  while (tc->name) {
    head->next = tc;
    tc->prev = head;
    head = tc;
    tc++;
  }
  head->next = next;
  return ret;
}

/* Check the typename */
SWIGRUNTIME(swig_type_info *) 
SWIG_TypeCheck(char *c, swig_type_info *ty)
{
  swig_type_info *s;
  if (!ty) return 0;        /* Void pointer */
  s = ty->next;             /* First element always just a name */
  while (s) {
    if (strcmp(s->name,c) == 0) {
      if (s == ty->next) return s;
      /* Move s to the top of the linked list */
      s->prev->next = s->next;
      if (s->next) {
	s->next->prev = s->prev;
      }
      /* Insert s as second element in the list */
      s->next = ty->next;
      if (ty->next) ty->next->prev = s;
      ty->next = s;
      return s;
    }
    s = s->next;
  }
  return 0;
}

/* Cast a pointer (needed for C++ inheritance */
SWIGRUNTIME(void *) 
SWIG_TypeCast(swig_type_info *ty, void *ptr) 
{
  if ((!ty) || (!ty->converter)) return ptr;
  return (*ty->converter)(ptr);
}

/* Search for a swig_type_info structure */
SWIGRUNTIME(void *)
SWIG_TypeQuery(const char *name) {
  swig_type_info *ty = swig_type_list;
  while (ty) {
    if (ty->str && (strcmp(name,ty->str) == 0)) return ty;
    if (ty->name && (strcmp(name,ty->name) == 0)) return ty;
    ty = ty->prev;
  }
  return 0;
}

#endif

#ifdef __cplusplus
}
#endif



/***********************************************************************
 * python.swg
 *
 *     This file contains the runtime support for Python modules
 *     and includes code for managing global variables and pointer
 *     type checking.
 *
 * Author : David Beazley (beazley@cs.uchicago.edu)
 ************************************************************************/

#include <stdlib.h>
#include "Python.h"

#ifdef __cplusplus
extern "C" {
#endif

#define SWIG_PY_INT     1
#define SWIG_PY_FLOAT   2
#define SWIG_PY_STRING  3
#define SWIG_PY_POINTER 4

/* Constant information structure */
typedef struct swig_const_info {
    int type;
    char *name;
    long lvalue;
    double dvalue;
    void   *pvalue;
    swig_type_info **ptype;
} swig_const_info;

#ifdef SWIG_NOINCLUDE

SWIGEXPORT(PyObject *)        SWIG_newvarlink();
SWIGEXPORT(void)              SWIG_addvarlink(PyObject *, char *, PyObject *(*)(void), int (*)(PyObject *));
SWIGEXPORT(int)               SWIG_ConvertPtr(PyObject *, void **, swig_type_info *, int);
SWIGEXPORT(void)              SWIG_MakePtr(char *c, void *, swig_type_info *);
SWIGEXPORT(PyObject *)        SWIG_NewPointerObj(void *, swig_type_info *);
SWIGEXPORT(void)              SWIG_InstallConstants(PyObject *d, swig_const_info constants[]);

#else

/* -----------------------------------------------------------------------------
 * global variable support code.
 * ----------------------------------------------------------------------------- */

typedef struct swig_globalvar {   
  char       *name;                  /* Name of global variable */
  PyObject *(*get_attr)(void);       /* Return the current value */
  int       (*set_attr)(PyObject *); /* Set the value */
  struct swig_globalvar *next;
} swig_globalvar;

typedef struct swig_varlinkobject {
  PyObject_HEAD
  swig_globalvar *vars;
} swig_varlinkobject;

static PyObject *
swig_varlink_repr(swig_varlinkobject *v) {
  v = v;
  return PyString_FromString("<Global variables>");
}

static int
swig_varlink_print(swig_varlinkobject *v, FILE *fp, int flags) {
  swig_globalvar  *var;
  flags = flags;
  fprintf(fp,"Global variables { ");
  for (var = v->vars; var; var=var->next) {
    fprintf(fp,"%s", var->name);
    if (var->next) fprintf(fp,", ");
  }
  fprintf(fp," }\n");
  return 0;
}

static PyObject *
swig_varlink_getattr(swig_varlinkobject *v, char *n) {
  swig_globalvar *var = v->vars;
  while (var) {
    if (strcmp(var->name,n) == 0) {
      return (*var->get_attr)();
    }
    var = var->next;
  }
  PyErr_SetString(PyExc_NameError,"Unknown C global variable");
  return NULL;
}

static int
swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
  swig_globalvar *var = v->vars;
  while (var) {
    if (strcmp(var->name,n) == 0) {
      return (*var->set_attr)(p);
    }
    var = var->next;
  }
  PyErr_SetString(PyExc_NameError,"Unknown C global variable");
  return 1;
}

statichere PyTypeObject varlinktype = {
  PyObject_HEAD_INIT(0)              
  0,
  "swigvarlink",                      /* Type name    */
  sizeof(swig_varlinkobject),         /* Basic size   */
  0,                                  /* Itemsize     */
  0,                                  /* Deallocator  */ 
  (printfunc) swig_varlink_print,     /* Print        */
  (getattrfunc) swig_varlink_getattr, /* get attr     */
  (setattrfunc) swig_varlink_setattr, /* Set attr     */
  0,                                  /* tp_compare   */
  (reprfunc) swig_varlink_repr,       /* tp_repr      */    
  0,                                  /* tp_as_number */
  0,                                  /* tp_as_mapping*/
  0,                                  /* tp_hash      */
};

/* Create a variable linking object for use later */
SWIGRUNTIME(PyObject *)
SWIG_newvarlink(void) {
  swig_varlinkobject *result = 0;
  result = PyMem_NEW(swig_varlinkobject,1);
  varlinktype.ob_type = &PyType_Type;    /* Patch varlinktype into a PyType */
  result->ob_type = &varlinktype;
  result->vars = 0;
  result->ob_refcnt = 0;
  Py_XINCREF((PyObject *) result);
  return ((PyObject*) result);
}

SWIGRUNTIME(void)
SWIG_addvarlink(PyObject *p, char *name,
	   PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
  swig_varlinkobject *v;
  swig_globalvar *gv;
  v= (swig_varlinkobject *) p;
  gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
  gv->name = (char *) malloc(strlen(name)+1);
  strcpy(gv->name,name);
  gv->get_attr = get_attr;
  gv->set_attr = set_attr;
  gv->next = v->vars;
  v->vars = gv;
}
/* Convert a pointer value */
SWIGRUNTIME(int)
SWIG_ConvertPtr(PyObject *obj, void **ptr, swig_type_info *ty, int flags) {
  unsigned long p;
  register int d;
  swig_type_info *tc;
  char  *c;
  static PyObject *SWIG_this = 0;
  int    newref = 0;

  if (!obj || (obj == Py_None)) {
    *ptr = 0;
    return 0;
  }
#ifdef SWIG_COBJECT_TYPES
  if (!(PyCObject_Check(obj))) {
    if (!SWIG_this)
      SWIG_this = PyString_InternFromString("this");
    obj = PyObject_GetAttr(obj,SWIG_this);
    newref = 1;
    if (!obj) goto type_error;
    if (!PyCObject_Check(obj)) {
      Py_DECREF(obj);
      goto type_error;
    }
  } 
  *ptr = PyCObject_AsVoidPtr(obj);
  c = (char *) PyCObject_GetDesc(obj);
  if (newref) Py_DECREF(obj);
  goto cobject;
#else
  if (!(PyString_Check(obj))) {
    if (!SWIG_this)
      SWIG_this = PyString_InternFromString("this");
    obj = PyObject_GetAttr(obj,SWIG_this);
    newref = 1;
    if (!obj) goto type_error;
    if (!PyString_Check(obj)) {
      Py_DECREF(obj);
      goto type_error;
    }
  } 
  c = PyString_AsString(obj);
  p = 0;
  /* Pointer values must start with leading underscore */
  if (*c != '_') {
    *ptr = (void *) 0;
    if (strcmp(c,"NULL") == 0) {
      if (newref) Py_DECREF(obj);
      return 0;
    } else {
      if (newref) Py_DECREF(obj);
      goto type_error;
    }
  }
  c++;
  /* Extract hex value from pointer */
  while ((d = *c)) {
    if ((d >= '0') && (d <= '9'))
      p = (p << 4) + (d - '0');
    else if ((d >= 'a') && (d <= 'f'))
      p = (p << 4) + (d - ('a'-10));
    else
      break; 
    c++;
  }
  *ptr = (void *) p;
  if (newref) Py_DECREF(obj);
#endif

#ifdef SWIG_COBJECT_TYPES
cobject:
#endif

  if (ty) {
    tc = SWIG_TypeCheck(c,ty);
    if (!tc) goto type_error;
    *ptr = SWIG_TypeCast(tc,(void*)p);
  }
  return 0;

type_error:

  if (flags) {
    if (ty) {
      char *temp = (char *) malloc(64+strlen(ty->name));
      sprintf(temp,"Type error. Expected %s", ty->name);
      PyErr_SetString(PyExc_TypeError, temp);
      free((char *) temp);
    } else {
      PyErr_SetString(PyExc_TypeError,"Expected a pointer");
    }
  }
  return -1;
}

/* Take a pointer and convert it to a string */
SWIGRUNTIME(void) 
SWIG_MakePtr(char *c, void *ptr, swig_type_info *ty) {
  static char hex[17] = "0123456789abcdef";
  unsigned long p, s;
  char result[32], *r; 
  r = result;
  p = (unsigned long) ptr;
  if (p > 0) {
    while (p > 0) {
      s = p & 0xf;
      *(r++) = hex[s];
      p = p >> 4;
    }
    *r = '_';
    while (r >= result)
      *(c++) = *(r--);
    strcpy (c, ty->name);
  } else {
    strcpy (c, "NULL");
  }
}

/* Create a new pointer object */
SWIGRUNTIME(PyObject *)
SWIG_NewPointerObj(void *ptr, swig_type_info *type) {
  char result[512];
  PyObject *robj;
  if (!ptr) {
    Py_INCREF(Py_None);
    return Py_None;
  }
#ifdef SWIG_COBJECT_TYPES
  robj = PyCObject_FromVoidPtrAndDesc((void *) ptr, type->name, NULL);
#else
  SWIG_MakePtr(result,ptr,type);
  robj = PyString_FromString(result);
#endif
  return robj;
}

/* Install Constants */
SWIGRUNTIME(void)
SWIG_InstallConstants(PyObject *d, swig_const_info constants[]) {
  int i;
  PyObject *obj;
  for (i = 0; constants[i].type; i++) {
    switch(constants[i].type) {
    case SWIG_PY_INT:
      obj = PyInt_FromLong(constants[i].lvalue);
      break;
    case SWIG_PY_FLOAT:
      obj = PyFloat_FromDouble(constants[i].dvalue);
      break;
    case SWIG_PY_STRING:
      obj = PyString_FromString((char *) constants[i].pvalue);
      break;
    case SWIG_PY_POINTER:
      obj = SWIG_NewPointerObj(constants[i].pvalue, *(constants[i]).ptype);
      break;
    default:
      obj = 0;
      break;
    }
    if (obj) {
      PyDict_SetItemString(d,constants[i].name,obj);
      Py_DECREF(obj);
    }
  }
}

#endif

#ifdef __cplusplus
}
#endif



/* -------- TYPES TABLE (BEGIN) -------- */

static swig_type_info *swig_types[1];

/* -------- TYPES TABLE (END) -------- */

#define SWIG_init    initfragment_lighting

#define SWIG_name    "fragment_lighting"

/**
 *
 * GL.EXT.fragment_lighting Module for PyOpenGL
 * 
 * Date: May 2000
 *
 * Authors: Tarn Weisner Burton <twburton@users.sourceforge.net>
 * 
***/


int __PyObject_AsArray_Size(PyObject* x);

#ifdef NUMERIC

#define _PyObject_AsArray_Size(x) ((x == Py_None) ? 0 : ((PyArray_Check(x)) ? PyArray_Size(x) : __PyObject_AsArray_Size(x)))

#else /* NUMERIC */

#define _PyObject_AsArray_Size(x) ((x == Py_None) ? 0 : __PyObject_AsArray_Size(x))

#endif /* NUMERIC */


#define _PyObject_As(NAME, BASE) BASE* _PyObject_As##NAME(PyObject* source, PyObject** temp, int* len);

#define _PyObject_AsArray_Cleanup(target, temp) if (temp) Py_XDECREF(temp); else PyMem_Del(target)

_PyObject_As(FloatArray, float)

_PyObject_As(DoubleArray, double)

_PyObject_As(CharArray, signed char)

_PyObject_As(UnsignedCharArray, unsigned char)

_PyObject_As(ShortArray, short)

_PyObject_As(UnsignedShortArray, unsigned short)

_PyObject_As(IntArray, int)

_PyObject_As(UnsignedIntArray, unsigned int)

void* _PyObject_AsArray(GLenum type, PyObject* source, PyObject** temp, int* len);



#define PyErr_XPrint() if (PyErr_Occurred()) PyErr_Print()


#if HAS_DYNAMIC_EXT

#define DECLARE_EXT(PROC_NAME, RET, ERROR_RET, PROTO, CALL)\
RET PROC_NAME PROTO\
{\
	typedef RET (APIENTRY *proc_##PROC_NAME) PROTO;\
	proc_##PROC_NAME proc = (proc_##PROC_NAME)GL_GetProcAddress(#PROC_NAME);\
	if (proc) return proc CALL;\
	PyErr_SetGLerror(GL_INVALID_OPERATION);\
	return ERROR_RET;\
}

#define DECLARE_VOID_EXT(PROC_NAME, PROTO, CALL)\
void PROC_NAME PROTO\
{\
	typedef void (APIENTRY *proc_##PROC_NAME) PROTO;\
	proc_##PROC_NAME proc = (proc_##PROC_NAME)GL_GetProcAddress(#PROC_NAME);\
	if (proc) proc CALL;\
	else PyErr_SetGLerror(GL_INVALID_OPERATION);\
}

#else

#define DECLARE_EXT(PROC_NAME, RET, ERROR_RET, PROTO, CALL)\
RET PROC_NAME PROTO\
{\
	PyErr_SetGLerror(GL_INVALID_OPERATION);\
	return ERROR_RET;\
}

#define DECLARE_VOID_EXT(PROC_NAME, PROTO, CALL)\
void PROC_NAME PROTO\
{\
	PyErr_SetGLerror(GL_INVALID_OPERATION);\
}

#endif


#define _PyTuple_From(NAME, BASE) PyObject* _PyTuple_From##NAME(int len, BASE* data);

_PyTuple_From(UnsignedCharArray, unsigned char)

_PyTuple_From(CharArray, signed char)

_PyTuple_From(UnsignedShortArray, unsigned short)

_PyTuple_From(ShortArray, short)

_PyTuple_From(UnsignedIntArray, unsigned int)

_PyTuple_From(IntArray, int)

_PyTuple_From(FloatArray, float)

_PyTuple_From(DoubleArray, double)


#define _PyObject_From(NAME, BASE) PyObject* _PyObject_From##NAME(int nd, int* dims, BASE* data, int own);

_PyObject_From(UnsignedCharArray, unsigned char)

_PyObject_From(CharArray, signed char)

_PyObject_From(UnsignedShortArray, unsigned short)

_PyObject_From(ShortArray, short)

_PyObject_From(UnsignedIntArray, unsigned int)

_PyObject_From(IntArray, int)

_PyObject_From(FloatArray, float)

_PyObject_From(DoubleArray, double)


PyObject* _PyObject_FromArray(GLenum type, int nd, int *dims, void* data, int own);

void* SetupPixelRead(int rank, GLenum format, GLenum type, int *dims);

void SetupPixelWrite(int rank);

void* SetupRawPixelRead(GLenum format, GLenum type, int n, const int *dims, int* size);

void* _PyObject_AsPointer(PyObject* x);

void init_util();

typedef void *PTR;

typedef struct
{
	void (*_decrement)(void* pointer);
	void (*_decrementPointer)(GLenum pname);
	int (*_incrementLock)(void *pointer);
	int (*_incrementPointerLock)(GLenum pname);
	void (*_acquire)(void* pointer);
	void (*_acquirePointer)(GLenum pname);
#if HAS_DYNAMIC_EXT
	PTR (*GL_GetProcAddress)(const char* name);
#endif
	int (*InitExtension)(const char *name, const char** procs);
	PyObject *_GLerror;
	PyObject *_GLUerror;
}  util_API;


static util_API *_util_API = NULL;

#define decrementLock(x) (*_util_API)._decrement(x)
#define decrementPointerLock(x) (*_util_API)._decrementPointer(x)
#define incrementLock(x) (*_util_API)._incrementLock(x)
#define incrementPointerLock(x) (*_util_API)._incrementPointerLock(x)
#define acquire(x) (*_util_API)._acquire(x)
#define acquirePointer(x) (*_util_API)._acquirePointer(x)
#define GLerror (*_util_API)._GLerror
#define GLUerror (*_util_API)._GLUerror
#if HAS_DYNAMIC_EXT
#define GL_GetProcAddress(x) (*_util_API).GL_GetProcAddress(x)
#endif
#define InitExtension(x, y) (*_util_API).InitExtension(x, (const char**)y)


#define PyErr_SetGLerror(code) PyErr_SetObject(GLerror, Py_BuildValue("is", code, gluErrorString(code)));
#define PyErr_SetGLUerror(code) PyErr_SetObject(GLUerror, Py_BuildValue("is", code, gluErrorString(code)));

int _PyObject_Dimension(PyObject* x, int rank);

#define ERROR_MSG_SEP ", "
#define ERROR_MSG_SEP_LEN 2

int GLErrOccurred()
{
	if (PyErr_Occurred()) return 1;

	if (CurrentContextIsValid())
	{
		GLenum error, *errors = NULL;
		char *msg = NULL;
		const char *this_msg;
		int count = 0;
	
		error = glGetError();

		while (error != GL_NO_ERROR)
		{
			this_msg = gluErrorString(error);
			if (count)
			{
				msg = realloc(msg, (strlen(msg) + strlen(this_msg) + ERROR_MSG_SEP_LEN + 1)*sizeof(char));
				strcat(msg, ERROR_MSG_SEP);
				strcat(msg, this_msg);
				
				errors = realloc(errors, (count + 1)*sizeof(GLenum));
			}
			else
			{
				msg = malloc((strlen(this_msg) + 1)*sizeof(char));
				strcpy(msg, this_msg);
				
				errors = malloc(sizeof(GLenum));
			}
			
			errors[count++] = error;
			error = glGetError();
		}
		
		if (count)
		{
			PyErr_SetObject(GLerror, Py_BuildValue("Os", _PyTuple_FromIntArray(count, (int*)errors), msg));
			free(errors);
			free(msg);
			return 1;
		}
	}

	return 0;
}


#if !EXT_DEFINES_PROTO || !defined(GL_EXT_fragment_lighting)
DECLARE_VOID_EXT(glFragmentMaterialfEXT, (GLenum face, GLenum pname, GLfloat param), (face, pname, param))
DECLARE_VOID_EXT(glFragmentMaterialfvEXT, (GLenum face, GLenum pname, const GLfloat *v), (face, pname, v))
DECLARE_VOID_EXT(glFragmentMaterialiEXT, (GLenum face, GLenum pname, GLint param), (face, pname, param))
DECLARE_VOID_EXT(glFragmentMaterialivEXT, (GLenum face, GLenum pname, const GLint *v), (face, pname, v))
DECLARE_VOID_EXT(glFragmentLightModelfEXT, (GLenum pname, GLfloat param), (pname, param))
DECLARE_VOID_EXT(glFragmentLightModelfvEXT, (GLenum pname, const GLfloat *v), (pname, v))
DECLARE_VOID_EXT(glFragmentLightModeliEXT, (GLenum pname, GLint param), (pname, param))
DECLARE_VOID_EXT(glFragmentLightModelivEXT, (GLenum pname, const GLint *v), (pname, v))
DECLARE_VOID_EXT(glFragmentLightfEXT, (GLenum light, GLenum pname, GLfloat param), (light, pname, param))
DECLARE_VOID_EXT(glFragmentLightfvEXT, (GLenum light, GLenum pname, const GLfloat *v), (light, pname, v))
DECLARE_VOID_EXT(glFragmentLightiEXT, (GLenum light, GLenum pname, GLint param), (light, pname, param))
DECLARE_VOID_EXT(glFragmentLightivEXT, (GLenum light, GLenum pname, const GLint *v), (light, pname, v))
DECLARE_VOID_EXT(glGetFragmentLightfvEXT, (GLenum light, GLenum pname, GLfloat *params), (light, pname, params))
DECLARE_VOID_EXT(glGetFragmentLightivEXT, (GLenum light, GLenum pname, GLint *params), (light, pname, params))
DECLARE_VOID_EXT(glFragmentColorMaterialEXT, (GLenum face, GLenum mode), (face, mode))
DECLARE_VOID_EXT(glGetFragmentMaterialfvEXT, (GLenum face, GLenum pname, GLfloat *params), (face, pname, params))
DECLARE_VOID_EXT(glGetFragmentMaterialivEXT, (GLenum face, GLenum pname, GLint *params), (face, pname, params))
DECLARE_VOID_EXT(glLightEnviEXT, (GLenum pname, GLint param), (pname, param))
#endif
 static char _doc_glFragmentMaterialfEXT[] = "glFragmentMaterialfEXT(face, pname, param) -> None";
 static char _doc_glFragmentMaterialfvEXT[] = "glFragmentMaterialfvEXT(face, pname, params) -> None";
 static char _doc_glFragmentMaterialiEXT[] = "glFragmentMaterialiEXT(face, pname, param) -> None";
 static char _doc_glFragmentMaterialivEXT[] = "glFragmentMaterialivEXT(face, pname, params) -> None";
 static char _doc_glFragmentLightModelfEXT[] = "glFragmentLightModelfEXT(pname, param) -> None";
 static char _doc_glFragmentLightModelfvEXT[] = "glFragmentLightModelfvEXT(pname, params) -> None";
 static char _doc_glFragmentLightModeliEXT[] = "glFragmentLightModeliEXT(pname, param) -> None";
 static char _doc_glFragmentLightModelivEXT[] = "glFragmentLightModelivEXT(pname, params) -> None";
 static char _doc_glFragmentLightfEXT[] = "glFragmentLightfEXT(light, pname, param) -> None";
 static char _doc_glFragmentLightfvEXT[] = "glFragmentLightfvEXT(light, pname, params) -> None";
 static char _doc_glFragmentLightiEXT[] = "glFragmentLightiEXT(light, pname, param) -> None";
 static char _doc_glFragmentLightivEXT[] = "glFragmentLightivEXT(light, pname, params) -> None";
 static char _doc_glGetFragmentLightfvEXT[] = "glGetFragmentLightfvEXT(light, pname) -> params";
 static char _doc_glGetFragmentLightivEXT[] = "glGetFragmentLightivEXT(light, pname) -> params";
 static char _doc_glFragmentColorMaterialEXT[] = "glFragmentColorMaterialEXT(face, mode) -> None";
 static char _doc_glGetFragmentMaterialfvEXT[] = "glGetFragmentMaterialfvEXT(face, pname) -> params";
 static char _doc_glGetFragmentMaterialivEXT[] = "glGetFragmentMaterialivEXT(face, pname) -> params";
 static char _doc_glLightEnviEXT[] = "glLightEnviEXT(pname, param) -> None";

static char *proc_names[] =
{
#if !EXT_DEFINES_PROTO || !defined(GL_EXT_fragment_lighting)
	"glFragmentMaterialfEXT",
	"glFragmentMaterialfvEXT",
	"glFragmentMaterialiEXT",
	"glFragmentMaterialivEXT",
	"glFragmentLightModelfEXT",
	"glFragmentLightModelfvEXT",
	"glFragmentLightModeliEXT",
	"glFragmentLightModelivEXT",
	"glFragmentLightfEXT",
	"glFragmentLightfvEXT",
	"glFragmentLightiEXT",
	"glFragmentLightivEXT",
	"glGetFragmentLightfvEXT",
	"glGetFragmentLightivEXT",
	"glFragmentColorMaterialEXT",
	"glGetFragmentMaterialfvEXT",
	"glGetFragmentMaterialivEXT",
	"glLightEnviEXT",
#endif
	NULL
};

#define glInitFragmentLightingEXT() InitExtension("GL_EXT_fragment_lighting", proc_names)
 static char _doc_glInitFragmentLightingEXT[] = "glInitFragmentLightingEXT() -> bool";

#ifndef GL_EXT_fragment_lighting
#define GL_MAX_FRAGMENT_LIGHTS_EXT                             0x8404
#define GL_MAX_ACTIVE_LIGHTS_EXT                               0x8405
#endif

PyObject *__info()
{
	if (glInitFragmentLightingEXT())
	{
		PyObject *info = PyList_New(0);
		PyList_Append(info, Py_BuildValue("sis", "GL_MAX_FRAGMENT_LIGHTS_EXT", GL_MAX_FRAGMENT_LIGHTS_EXT, "i"));
		PyList_Append(info, Py_BuildValue("sis", "GL_MAX_ACTIVE_LIGHTS_EXT", GL_MAX_ACTIVE_LIGHTS_EXT, "i"));
		return info;
	}
	
	Py_INCREF(Py_None);
	return Py_None;
}
#ifdef __cplusplus
extern "C" {
#endif
static PyObject *_wrap_glFragmentMaterialfEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLfloat arg2 ;
    
    if(!PyArg_ParseTuple(args,"iif:glFragmentMaterialfEXT",&arg0,&arg1,&arg2)) return NULL;
    {
        glFragmentMaterialfEXT(arg0,arg1,arg2);
        if (PyErr_Occurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glFragmentMaterialfvEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLfloat *arg2 ;
    PyObject *temp_v ;
    PyObject * obj2  = 0 ;
    
    if(!PyArg_ParseTuple(args,"iiO:glFragmentMaterialfvEXT",&arg0,&arg1,&obj2)) return NULL;
    {
        arg2 = _PyObject_AsFloatArray(obj2, &temp_v, NULL); 
    }
    {
        glFragmentMaterialfvEXT(arg0,arg1,(GLfloat const *)arg2);
        if (PyErr_Occurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        _PyObject_AsArray_Cleanup(arg2, temp_v); 
    }
    return resultobj;
}


static PyObject *_wrap_glFragmentMaterialiEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLint arg2 ;
    
    if(!PyArg_ParseTuple(args,"iii:glFragmentMaterialiEXT",&arg0,&arg1,&arg2)) return NULL;
    {
        glFragmentMaterialiEXT(arg0,arg1,arg2);
        if (PyErr_Occurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glFragmentMaterialivEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLint *arg2 ;
    PyObject *temp_v ;
    PyObject * obj2  = 0 ;
    
    if(!PyArg_ParseTuple(args,"iiO:glFragmentMaterialivEXT",&arg0,&arg1,&obj2)) return NULL;
    {
        arg2 = _PyObject_AsIntArray(obj2, &temp_v, NULL); 
    }
    {
        glFragmentMaterialivEXT(arg0,arg1,(GLint const *)arg2);
        if (PyErr_Occurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        _PyObject_AsArray_Cleanup(arg2, temp_v); 
    }
    return resultobj;
}


static PyObject *_wrap_glFragmentLightModelfEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLfloat arg1 ;
    
    if(!PyArg_ParseTuple(args,"if:glFragmentLightModelfEXT",&arg0,&arg1)) return NULL;
    {
        glFragmentLightModelfEXT(arg0,arg1);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glFragmentLightModelfvEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLfloat *arg1 ;
    PyObject *temp_v ;
    PyObject * obj1  = 0 ;
    
    if(!PyArg_ParseTuple(args,"iO:glFragmentLightModelfvEXT",&arg0,&obj1)) return NULL;
    {
        arg1 = _PyObject_AsFloatArray(obj1, &temp_v, NULL); 
    }
    {
        glFragmentLightModelfvEXT(arg0,(GLfloat const *)arg1);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        _PyObject_AsArray_Cleanup(arg1, temp_v); 
    }
    return resultobj;
}


static PyObject *_wrap_glFragmentLightModeliEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLint arg1 ;
    
    if(!PyArg_ParseTuple(args,"ii:glFragmentLightModeliEXT",&arg0,&arg1)) return NULL;
    {
        glFragmentLightModeliEXT(arg0,arg1);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glFragmentLightModelivEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLint *arg1 ;
    PyObject *temp_v ;
    PyObject * obj1  = 0 ;
    
    if(!PyArg_ParseTuple(args,"iO:glFragmentLightModelivEXT",&arg0,&obj1)) return NULL;
    {
        arg1 = _PyObject_AsIntArray(obj1, &temp_v, NULL); 
    }
    {
        glFragmentLightModelivEXT(arg0,(GLint const *)arg1);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        _PyObject_AsArray_Cleanup(arg1, temp_v); 
    }
    return resultobj;
}


static PyObject *_wrap_glFragmentLightfEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLfloat arg2 ;
    
    if(!PyArg_ParseTuple(args,"iif:glFragmentLightfEXT",&arg0,&arg1,&arg2)) return NULL;
    {
        glFragmentLightfEXT(arg0,arg1,arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glFragmentLightfvEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLfloat *arg2 ;
    PyObject *temp_v ;
    PyObject * obj2  = 0 ;
    
    if(!PyArg_ParseTuple(args,"iiO:glFragmentLightfvEXT",&arg0,&arg1,&obj2)) return NULL;
    {
        arg2 = _PyObject_AsFloatArray(obj2, &temp_v, NULL); 
    }
    {
        glFragmentLightfvEXT(arg0,arg1,(GLfloat const *)arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        _PyObject_AsArray_Cleanup(arg2, temp_v); 
    }
    return resultobj;
}


static PyObject *_wrap_glFragmentLightiEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLint arg2 ;
    
    if(!PyArg_ParseTuple(args,"iii:glFragmentLightiEXT",&arg0,&arg1,&arg2)) return NULL;
    {
        glFragmentLightiEXT(arg0,arg1,arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glFragmentLightivEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    GLint *arg2 ;
    PyObject *temp_v ;
    PyObject * obj2  = 0 ;
    
    if(!PyArg_ParseTuple(args,"iiO:glFragmentLightivEXT",&arg0,&arg1,&obj2)) return NULL;
    {
        arg2 = _PyObject_AsIntArray(obj2, &temp_v, NULL); 
    }
    {
        glFragmentLightivEXT(arg0,arg1,(GLint const *)arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        _PyObject_AsArray_Cleanup(arg2, temp_v); 
    }
    return resultobj;
}


static PyObject *_wrap_glGetFragmentLightfvEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    float *arg2 ;
    float temp_params[4] ;
    
    {
        int i; 	arg2 = temp_params; 	for (i = 0; i < 4; i++) arg2[i] = -FLT_MAX; 
    }
    if(!PyArg_ParseTuple(args,"ii:glGetFragmentLightfvEXT",&arg0,&arg1)) return NULL;
    {
        glGetFragmentLightfvEXT(arg0,arg1,arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        int n, dims[2]; 	Py_XDECREF(resultobj); 	for (n = 0; n < 4 && arg2[n] != -FLT_MAX; n++); 	switch (n) 	{
            case 0: 		Py_INCREF(Py_None); 		resultobj = Py_None; 		break; 	case 1: 		resultobj = PyFloat_FromDouble(arg2[0]); 		break; 	case 16: 		dims[0] = 4; 		dims[1] = 4; 		resultobj = _PyObject_FromFloatArray(2, dims, arg2, 0); 		break; 	default: 		resultobj = _PyTuple_FromFloatArray(n, arg2); 	
        } 
    }
    return resultobj;
}


static PyObject *_wrap_glGetFragmentLightivEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    int *arg2 ;
    int temp_params[4] ;
    
    {
        int i; 	arg2 = temp_params; 	for (i = 0; i < 4; i++) arg2[i] = INT_MIN; 
    }
    if(!PyArg_ParseTuple(args,"ii:glGetFragmentLightivEXT",&arg0,&arg1)) return NULL;
    {
        glGetFragmentLightivEXT(arg0,arg1,arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        int n, dims[2]; 	Py_XDECREF(resultobj); 	for (n = 0; n < 4 && arg2[n] != INT_MIN; n++); 	switch (n) 	{
            case 0: 		Py_INCREF(Py_None); 		resultobj = Py_None; 		break; 	case 1: 		resultobj = PyInt_FromLong(arg2[0]); 		break; 	case 16: 		dims[0] = 4; 		dims[1] = 4; 		resultobj = _PyObject_FromIntArray(2, dims, arg2, 0); 		break; 	default: 		resultobj = _PyTuple_FromIntArray(n, arg2); 	
        } 
    }
    return resultobj;
}


static PyObject *_wrap_glFragmentColorMaterialEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    
    if(!PyArg_ParseTuple(args,"ii:glFragmentColorMaterialEXT",&arg0,&arg1)) return NULL;
    {
        glFragmentColorMaterialEXT(arg0,arg1);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glGetFragmentMaterialfvEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    float *arg2 ;
    float temp_params[4] ;
    
    {
        int i; 	arg2 = temp_params; 	for (i = 0; i < 4; i++) arg2[i] = -FLT_MAX; 
    }
    if(!PyArg_ParseTuple(args,"ii:glGetFragmentMaterialfvEXT",&arg0,&arg1)) return NULL;
    {
        glGetFragmentMaterialfvEXT(arg0,arg1,arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        int n, dims[2]; 	Py_XDECREF(resultobj); 	for (n = 0; n < 4 && arg2[n] != -FLT_MAX; n++); 	switch (n) 	{
            case 0: 		Py_INCREF(Py_None); 		resultobj = Py_None; 		break; 	case 1: 		resultobj = PyFloat_FromDouble(arg2[0]); 		break; 	case 16: 		dims[0] = 4; 		dims[1] = 4; 		resultobj = _PyObject_FromFloatArray(2, dims, arg2, 0); 		break; 	default: 		resultobj = _PyTuple_FromFloatArray(n, arg2); 	
        } 
    }
    return resultobj;
}


static PyObject *_wrap_glGetFragmentMaterialivEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLenum arg1 ;
    int *arg2 ;
    int temp_params[4] ;
    
    {
        int i; 	arg2 = temp_params; 	for (i = 0; i < 4; i++) arg2[i] = INT_MIN; 
    }
    if(!PyArg_ParseTuple(args,"ii:glGetFragmentMaterialivEXT",&arg0,&arg1)) return NULL;
    {
        glGetFragmentMaterialivEXT(arg0,arg1,arg2);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    {
        int n, dims[2]; 	Py_XDECREF(resultobj); 	for (n = 0; n < 4 && arg2[n] != INT_MIN; n++); 	switch (n) 	{
            case 0: 		Py_INCREF(Py_None); 		resultobj = Py_None; 		break; 	case 1: 		resultobj = PyInt_FromLong(arg2[0]); 		break; 	case 16: 		dims[0] = 4; 		dims[1] = 4; 		resultobj = _PyObject_FromIntArray(2, dims, arg2, 0); 		break; 	default: 		resultobj = _PyTuple_FromIntArray(n, arg2); 	
        } 
    }
    return resultobj;
}


static PyObject *_wrap_glLightEnviEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    GLenum arg0 ;
    GLint arg1 ;
    
    if(!PyArg_ParseTuple(args,"ii:glLightEnviEXT",&arg0,&arg1)) return NULL;
    {
        glLightEnviEXT(arg0,arg1);
        if (GLErrOccurred()) return NULL; 
    }    Py_INCREF(Py_None);
    resultobj = Py_None;
    return resultobj;
}


static PyObject *_wrap_glInitFragmentLightingEXT(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    int result ;
    
    if(!PyArg_ParseTuple(args,":glInitFragmentLightingEXT")) return NULL;
    {
        result = (int )glInitFragmentLightingEXT();
        if (GLErrOccurred()) return NULL; 
    }    resultobj = PyInt_FromLong((long)result);
    return resultobj;
}


static PyObject *_wrap___info(PyObject *self, PyObject *args) {
    PyObject *resultobj;
    PyObject *result ;
    
    if(!PyArg_ParseTuple(args,":__info")) return NULL;
    {
        result = (PyObject *)__info();
        if (GLErrOccurred()) return NULL; 
    }{
        resultobj = result;
    }
    return resultobj;
}


static PyMethodDef fragment_lightingMethods[] = {
	 {"glFragmentMaterialfEXT", _wrap_glFragmentMaterialfEXT, METH_VARARGS , _doc_glFragmentMaterialfEXT},
	 {"glFragmentMaterialfvEXT", _wrap_glFragmentMaterialfvEXT, METH_VARARGS , _doc_glFragmentMaterialfvEXT},
	 {"glFragmentMaterialiEXT", _wrap_glFragmentMaterialiEXT, METH_VARARGS , _doc_glFragmentMaterialiEXT},
	 {"glFragmentMaterialivEXT", _wrap_glFragmentMaterialivEXT, METH_VARARGS , _doc_glFragmentMaterialivEXT},
	 {"glFragmentLightModelfEXT", _wrap_glFragmentLightModelfEXT, METH_VARARGS , _doc_glFragmentLightModelfEXT},
	 {"glFragmentLightModelfvEXT", _wrap_glFragmentLightModelfvEXT, METH_VARARGS , _doc_glFragmentLightModelfvEXT},
	 {"glFragmentLightModeliEXT", _wrap_glFragmentLightModeliEXT, METH_VARARGS , _doc_glFragmentLightModeliEXT},
	 {"glFragmentLightModelivEXT", _wrap_glFragmentLightModelivEXT, METH_VARARGS , _doc_glFragmentLightModelivEXT},
	 {"glFragmentLightfEXT", _wrap_glFragmentLightfEXT, METH_VARARGS , _doc_glFragmentLightfEXT},
	 {"glFragmentLightfvEXT", _wrap_glFragmentLightfvEXT, METH_VARARGS , _doc_glFragmentLightfvEXT},
	 {"glFragmentLightiEXT", _wrap_glFragmentLightiEXT, METH_VARARGS , _doc_glFragmentLightiEXT},
	 {"glFragmentLightivEXT", _wrap_glFragmentLightivEXT, METH_VARARGS , _doc_glFragmentLightivEXT},
	 {"glGetFragmentLightfvEXT", _wrap_glGetFragmentLightfvEXT, METH_VARARGS , _doc_glGetFragmentLightfvEXT},
	 {"glGetFragmentLightivEXT", _wrap_glGetFragmentLightivEXT, METH_VARARGS , _doc_glGetFragmentLightivEXT},
	 {"glFragmentColorMaterialEXT", _wrap_glFragmentColorMaterialEXT, METH_VARARGS , _doc_glFragmentColorMaterialEXT},
	 {"glGetFragmentMaterialfvEXT", _wrap_glGetFragmentMaterialfvEXT, METH_VARARGS , _doc_glGetFragmentMaterialfvEXT},
	 {"glGetFragmentMaterialivEXT", _wrap_glGetFragmentMaterialivEXT, METH_VARARGS , _doc_glGetFragmentMaterialivEXT},
	 {"glLightEnviEXT", _wrap_glLightEnviEXT, METH_VARARGS , _doc_glLightEnviEXT},
	 {"glInitFragmentLightingEXT", _wrap_glInitFragmentLightingEXT, METH_VARARGS , _doc_glInitFragmentLightingEXT},
	 { "__info", _wrap___info, METH_VARARGS },
	 { NULL, NULL }
};

#ifdef __cplusplus
}
#endif

/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */


static swig_type_info *swig_types_initial[] = {
0
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */

static swig_const_info swig_const_table[] = {
    { SWIG_PY_STRING, "__version__", 0, 0, (void *) "1.16", 0 }, 
    { SWIG_PY_STRING, "__date__", 0, 0, (void *) "2001/08/17 16:54:05", 0 }, 
    { SWIG_PY_INT,     "__api_version__", (long) 257, 0, 0, 0},
    { SWIG_PY_STRING, "__author__", 0, 0, (void *) "Tarn Weisner Burton <twburton@users.sourceforge.net>", 0 }, 
    { SWIG_PY_STRING, "__doc__", 0, 0, (void *) "http://oss.sgi.com/projects/ogl-sample/registry/EXT/fragment_lighting.txt", 0 }, 
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHTING_EXT", (long) 0x8400, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_COLOR_MATERIAL_EXT", (long) 0x8401, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_COLOR_MATERIAL_FACE_EXT", (long) 0x8402, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_EXT", (long) 0x8403, 0, 0, 0},
    { SWIG_PY_INT,     "GL_MAX_FRAGMENT_LIGHTS_EXT", (long) 0x8404, 0, 0, 0},
    { SWIG_PY_INT,     "GL_MAX_ACTIVE_LIGHTS_EXT", (long) 0x8405, 0, 0, 0},
    { SWIG_PY_INT,     "GL_CURRENT_RASTER_NORMAL_EXT", (long) 0x8406, 0, 0, 0},
    { SWIG_PY_INT,     "GL_LIGHT_ENV_MODE_EXT", (long) 0x8407, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_EXT", (long) 0x8408, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_EXT", (long) 0x8409, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT_MODEL_AMBIENT_EXT", (long) 0x840A, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_EXT", (long) 0x840B, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT0_EXT", (long) 0x840C, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT1_EXT", (long) 0x840C+1, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT2_EXT", (long) 0x840C+2, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT3_EXT", (long) 0x840C+3, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT4_EXT", (long) 0x840C+4, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT5_EXT", (long) 0x840C+5, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT6_EXT", (long) 0x840C+6, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT7_EXT", (long) 0x840C+7, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT8_EXT", (long) 0x840C+8, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT9_EXT", (long) 0x840C+9, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT10_EXT", (long) 0x840C+10, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT11_EXT", (long) 0x840C+11, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT12_EXT", (long) 0x840C+12, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT13_EXT", (long) 0x840C+13, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT14_EXT", (long) 0x840C+14, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT15_EXT", (long) 0x840C+15, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT16_EXT", (long) 0x840C+16, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT17_EXT", (long) 0x840C+17, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT18_EXT", (long) 0x840C+18, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT19_EXT", (long) 0x840C+19, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT20_EXT", (long) 0x840C+20, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT21_EXT", (long) 0x840C+21, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT22_EXT", (long) 0x840C+22, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT23_EXT", (long) 0x840C+23, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT24_EXT", (long) 0x840C+24, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT25_EXT", (long) 0x840C+25, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT26_EXT", (long) 0x840C+26, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT27_EXT", (long) 0x840C+27, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT28_EXT", (long) 0x840C+28, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT29_EXT", (long) 0x840C+29, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT30_EXT", (long) 0x840C+30, 0, 0, 0},
    { SWIG_PY_INT,     "GL_FRAGMENT_LIGHT31_EXT", (long) 0x840C+31, 0, 0, 0},
{0}};

static PyObject *SWIG_globals;
#ifdef __cplusplus
extern "C" 
#endif
SWIGEXPORT(void) initfragment_lighting(void) {
    PyObject *m, *d;
    int i;
    SWIG_globals = SWIG_newvarlink();
    m = Py_InitModule("fragment_lighting", fragment_lightingMethods);
    d = PyModule_GetDict(m);
    for (i = 0; swig_types_initial[i]; i++) {
        swig_types[i] = SWIG_TypeRegister(swig_types_initial[i]);
    }
    
    #ifdef NUMERIC
    PyArray_API = NULL;
    import_array();
    init_util();
    PyErr_Clear();
    #endif
    
    {
        PyObject *util = PyImport_ImportModule("OpenGL.GL.__init___");
        if (util)
        {
            PyObject *api_object = PyDict_GetItemString(PyModule_GetDict(util), "_util_API");
            if (PyCObject_Check(api_object)) _util_API = (util_API*)PyCObject_AsVoidPtr(api_object);
        }
    }
    SWIG_InstallConstants(d,swig_const_table);
}

