]> git.saurik.com Git - wxWidgets.git/blob - wxPython/contrib/glcanvas/msw/glcanvas_wrap.cpp
fixed paste error
[wxWidgets.git] / wxPython / contrib / glcanvas / msw / glcanvas_wrap.cpp
1 /* ----------------------------------------------------------------------------
2 * This file was automatically generated by SWIG (http://www.swig.org).
3 * Version 1.3.24
4 *
5 * This file is not intended to be easily readable and contains a number of
6 * coding conventions designed to improve portability and efficiency. Do not make
7 * changes to this file unless you know what you are doing--modify the SWIG
8 * interface file instead.
9 * ----------------------------------------------------------------------------- */
10
11 #define SWIGPYTHON
12
13 #ifdef __cplusplus
14 template<class T> class SwigValueWrapper {
15 T *tt;
16 public:
17 SwigValueWrapper() : tt(0) { }
18 SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
19 SwigValueWrapper(const T& t) : tt(new T(t)) { }
20 ~SwigValueWrapper() { delete tt; }
21 SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
22 operator T&() const { return *tt; }
23 T *operator&() { return tt; }
24 private:
25 SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
26 };
27 #endif
28
29
30 #ifndef SWIG_TEMPLATE_DISAMBIGUATOR
31 # if defined(__SUNPRO_CC)
32 # define SWIG_TEMPLATE_DISAMBIGUATOR template
33 # else
34 # define SWIG_TEMPLATE_DISAMBIGUATOR
35 # endif
36 #endif
37
38
39 #include <Python.h>
40
41 /***********************************************************************
42 * swigrun.swg
43 *
44 * This file contains generic CAPI SWIG runtime support for pointer
45 * type checking.
46 *
47 ************************************************************************/
48
49 /* This should only be incremented when either the layout of swig_type_info changes,
50 or for whatever reason, the runtime changes incompatibly */
51 #define SWIG_RUNTIME_VERSION "1"
52
53 /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
54 #ifdef SWIG_TYPE_TABLE
55 #define SWIG_QUOTE_STRING(x) #x
56 #define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
57 #define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
58 #else
59 #define SWIG_TYPE_TABLE_NAME
60 #endif
61
62 #include <string.h>
63
64 #ifndef SWIGINLINE
65 #if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
66 # define SWIGINLINE inline
67 #else
68 # define SWIGINLINE
69 #endif
70 #endif
71
72 /*
73 You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
74 creating a static or dynamic library from the swig runtime code.
75 In 99.9% of the cases, swig just needs to declare them as 'static'.
76
77 But only do this if is strictly necessary, ie, if you have problems
78 with your compiler or so.
79 */
80 #ifndef SWIGRUNTIME
81 #define SWIGRUNTIME static
82 #endif
83 #ifndef SWIGRUNTIMEINLINE
84 #define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
85 #endif
86
87 #ifdef __cplusplus
88 extern "C" {
89 #endif
90
91 typedef void *(*swig_converter_func)(void *);
92 typedef struct swig_type_info *(*swig_dycast_func)(void **);
93
94 typedef struct swig_type_info {
95 const char *name;
96 swig_converter_func converter;
97 const char *str;
98 void *clientdata;
99 swig_dycast_func dcast;
100 struct swig_type_info *next;
101 struct swig_type_info *prev;
102 } swig_type_info;
103
104 /*
105 Compare two type names skipping the space characters, therefore
106 "char*" == "char *" and "Class<int>" == "Class<int >", etc.
107
108 Return 0 when the two name types are equivalent, as in
109 strncmp, but skipping ' '.
110 */
111 SWIGRUNTIME int
112 SWIG_TypeNameComp(const char *f1, const char *l1,
113 const char *f2, const char *l2) {
114 for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
115 while ((*f1 == ' ') && (f1 != l1)) ++f1;
116 while ((*f2 == ' ') && (f2 != l2)) ++f2;
117 if (*f1 != *f2) return *f1 - *f2;
118 }
119 return (l1 - f1) - (l2 - f2);
120 }
121
122 /*
123 Check type equivalence in a name list like <name1>|<name2>|...
124 */
125 SWIGRUNTIME int
126 SWIG_TypeEquiv(const char *nb, const char *tb) {
127 int equiv = 0;
128 const char* te = tb + strlen(tb);
129 const char* ne = nb;
130 while (!equiv && *ne) {
131 for (nb = ne; *ne; ++ne) {
132 if (*ne == '|') break;
133 }
134 equiv = SWIG_TypeNameComp(nb, ne, tb, te) == 0;
135 if (*ne) ++ne;
136 }
137 return equiv;
138 }
139
140 /*
141 Register a type mapping with the type-checking
142 */
143 SWIGRUNTIME swig_type_info *
144 SWIG_TypeRegisterTL(swig_type_info **tl, swig_type_info *ti) {
145 swig_type_info *tc, *head, *ret, *next;
146 /* Check to see if this type has already been registered */
147 tc = *tl;
148 while (tc) {
149 /* check simple type equivalence */
150 int typeequiv = (strcmp(tc->name, ti->name) == 0);
151 /* check full type equivalence, resolving typedefs */
152 if (!typeequiv) {
153 /* only if tc is not a typedef (no '|' on it) */
154 if (tc->str && ti->str && !strstr(tc->str,"|")) {
155 typeequiv = SWIG_TypeEquiv(ti->str,tc->str);
156 }
157 }
158 if (typeequiv) {
159 /* Already exists in the table. Just add additional types to the list */
160 if (ti->clientdata) tc->clientdata = ti->clientdata;
161 head = tc;
162 next = tc->next;
163 goto l1;
164 }
165 tc = tc->prev;
166 }
167 head = ti;
168 next = 0;
169
170 /* Place in list */
171 ti->prev = *tl;
172 *tl = ti;
173
174 /* Build linked lists */
175 l1:
176 ret = head;
177 tc = ti + 1;
178 /* Patch up the rest of the links */
179 while (tc->name) {
180 head->next = tc;
181 tc->prev = head;
182 head = tc;
183 tc++;
184 }
185 if (next) next->prev = head;
186 head->next = next;
187
188 return ret;
189 }
190
191 /*
192 Check the typename
193 */
194 SWIGRUNTIME swig_type_info *
195 SWIG_TypeCheck(const char *c, swig_type_info *ty) {
196 swig_type_info *s;
197 if (!ty) return 0; /* Void pointer */
198 s = ty->next; /* First element always just a name */
199 do {
200 if (strcmp(s->name,c) == 0) {
201 if (s == ty->next) return s;
202 /* Move s to the top of the linked list */
203 s->prev->next = s->next;
204 if (s->next) {
205 s->next->prev = s->prev;
206 }
207 /* Insert s as second element in the list */
208 s->next = ty->next;
209 if (ty->next) ty->next->prev = s;
210 ty->next = s;
211 s->prev = ty;
212 return s;
213 }
214 s = s->next;
215 } while (s && (s != ty->next));
216 return 0;
217 }
218
219 /*
220 Cast a pointer up an inheritance hierarchy
221 */
222 SWIGRUNTIMEINLINE void *
223 SWIG_TypeCast(swig_type_info *ty, void *ptr) {
224 return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr);
225 }
226
227 /*
228 Dynamic pointer casting. Down an inheritance hierarchy
229 */
230 SWIGRUNTIME swig_type_info *
231 SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) {
232 swig_type_info *lastty = ty;
233 if (!ty || !ty->dcast) return ty;
234 while (ty && (ty->dcast)) {
235 ty = (*ty->dcast)(ptr);
236 if (ty) lastty = ty;
237 }
238 return lastty;
239 }
240
241 /*
242 Return the name associated with this type
243 */
244 SWIGRUNTIMEINLINE const char *
245 SWIG_TypeName(const swig_type_info *ty) {
246 return ty->name;
247 }
248
249 /*
250 Return the pretty name associated with this type,
251 that is an unmangled type name in a form presentable to the user.
252 */
253 SWIGRUNTIME const char *
254 SWIG_TypePrettyName(const swig_type_info *type) {
255 /* The "str" field contains the equivalent pretty names of the
256 type, separated by vertical-bar characters. We choose
257 to print the last name, as it is often (?) the most
258 specific. */
259 if (type->str != NULL) {
260 const char *last_name = type->str;
261 const char *s;
262 for (s = type->str; *s; s++)
263 if (*s == '|') last_name = s+1;
264 return last_name;
265 }
266 else
267 return type->name;
268 }
269
270 /*
271 Search for a swig_type_info structure
272 */
273 SWIGRUNTIME swig_type_info *
274 SWIG_TypeQueryTL(swig_type_info *tl, const char *name) {
275 swig_type_info *ty = tl;
276 while (ty) {
277 if (ty->str && (SWIG_TypeEquiv(ty->str,name))) return ty;
278 if (ty->name && (strcmp(name,ty->name) == 0)) return ty;
279 ty = ty->prev;
280 }
281 return 0;
282 }
283
284 /*
285 Set the clientdata field for a type
286 */
287 SWIGRUNTIME void
288 SWIG_TypeClientDataTL(swig_type_info *tl, swig_type_info *ti, void *clientdata) {
289 swig_type_info *tc, *equiv;
290 if (ti->clientdata) return;
291 /* if (ti->clientdata == clientdata) return; */
292 ti->clientdata = clientdata;
293 equiv = ti->next;
294 while (equiv) {
295 if (!equiv->converter) {
296 tc = tl;
297 while (tc) {
298 if ((strcmp(tc->name, equiv->name) == 0))
299 SWIG_TypeClientDataTL(tl,tc,clientdata);
300 tc = tc->prev;
301 }
302 }
303 equiv = equiv->next;
304 }
305 }
306
307 /*
308 Pack binary data into a string
309 */
310 SWIGRUNTIME char *
311 SWIG_PackData(char *c, void *ptr, size_t sz) {
312 static char hex[17] = "0123456789abcdef";
313 unsigned char *u = (unsigned char *) ptr;
314 const unsigned char *eu = u + sz;
315 register unsigned char uu;
316 for (; u != eu; ++u) {
317 uu = *u;
318 *(c++) = hex[(uu & 0xf0) >> 4];
319 *(c++) = hex[uu & 0xf];
320 }
321 return c;
322 }
323
324 /*
325 Unpack binary data from a string
326 */
327 SWIGRUNTIME const char *
328 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
329 register unsigned char *u = (unsigned char *) ptr;
330 register const unsigned char *eu = u + sz;
331 for (; u != eu; ++u) {
332 register int d = *(c++);
333 register unsigned char uu = 0;
334 if ((d >= '0') && (d <= '9'))
335 uu = ((d - '0') << 4);
336 else if ((d >= 'a') && (d <= 'f'))
337 uu = ((d - ('a'-10)) << 4);
338 else
339 return (char *) 0;
340 d = *(c++);
341 if ((d >= '0') && (d <= '9'))
342 uu |= (d - '0');
343 else if ((d >= 'a') && (d <= 'f'))
344 uu |= (d - ('a'-10));
345 else
346 return (char *) 0;
347 *u = uu;
348 }
349 return c;
350 }
351
352 /*
353 This function will propagate the clientdata field of type to any new
354 swig_type_info structures that have been added into the list of
355 equivalent types. It is like calling SWIG_TypeClientData(type,
356 clientdata) a second time.
357 */
358 SWIGRUNTIME void
359 SWIG_PropagateClientDataTL(swig_type_info *tl, swig_type_info *type) {
360 swig_type_info *equiv = type->next;
361 swig_type_info *tc;
362 if (!type->clientdata) return;
363 while (equiv) {
364 if (!equiv->converter) {
365 tc = tl;
366 while (tc) {
367 if ((strcmp(tc->name, equiv->name) == 0) && !tc->clientdata)
368 SWIG_TypeClientDataTL(tl,tc, type->clientdata);
369 tc = tc->prev;
370 }
371 }
372 equiv = equiv->next;
373 }
374 }
375
376 /*
377 Pack 'void *' into a string buffer.
378 */
379 SWIGRUNTIME char *
380 SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
381 char *r = buff;
382 if ((2*sizeof(void *) + 2) > bsz) return 0;
383 *(r++) = '_';
384 r = SWIG_PackData(r,&ptr,sizeof(void *));
385 if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
386 strcpy(r,name);
387 return buff;
388 }
389
390 SWIGRUNTIME const char *
391 SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
392 if (*c != '_') {
393 if (strcmp(c,"NULL") == 0) {
394 *ptr = (void *) 0;
395 return name;
396 } else {
397 return 0;
398 }
399 }
400 return SWIG_UnpackData(++c,ptr,sizeof(void *));
401 }
402
403 SWIGRUNTIME char *
404 SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
405 char *r = buff;
406 size_t lname = (name ? strlen(name) : 0);
407 if ((2*sz + 2 + lname) > bsz) return 0;
408 *(r++) = '_';
409 r = SWIG_PackData(r,ptr,sz);
410 if (lname) {
411 strncpy(r,name,lname+1);
412 } else {
413 *r = 0;
414 }
415 return buff;
416 }
417
418 SWIGRUNTIME const char *
419 SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
420 if (*c != '_') {
421 if (strcmp(c,"NULL") == 0) {
422 memset(ptr,0,sz);
423 return name;
424 } else {
425 return 0;
426 }
427 }
428 return SWIG_UnpackData(++c,ptr,sz);
429 }
430
431 #ifdef __cplusplus
432 }
433 #endif
434
435 /***********************************************************************
436 * common.swg
437 *
438 * This file contains generic SWIG runtime support for pointer
439 * type checking as well as a few commonly used macros to control
440 * external linkage.
441 *
442 * Author : David Beazley (beazley@cs.uchicago.edu)
443 *
444 * Copyright (c) 1999-2000, The University of Chicago
445 *
446 * This file may be freely redistributed without license or fee provided
447 * this copyright message remains intact.
448 ************************************************************************/
449
450
451 #if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
452 # if !defined(STATIC_LINKED)
453 # define SWIGEXPORT(a) __declspec(dllexport) a
454 # else
455 # define SWIGEXPORT(a) a
456 # endif
457 #else
458 # define SWIGEXPORT(a) a
459 #endif
460
461 #ifdef __cplusplus
462 extern "C" {
463 #endif
464
465
466 /*************************************************************************/
467
468
469 /* The static type info list */
470
471 static swig_type_info *swig_type_list = 0;
472 static swig_type_info **swig_type_list_handle = &swig_type_list;
473
474
475 /* Register a type mapping with the type-checking */
476 static swig_type_info *
477 SWIG_TypeRegister(swig_type_info *ti) {
478 return SWIG_TypeRegisterTL(swig_type_list_handle, ti);
479 }
480
481 /* Search for a swig_type_info structure */
482 static swig_type_info *
483 SWIG_TypeQuery(const char *name) {
484 return SWIG_TypeQueryTL(*swig_type_list_handle, name);
485 }
486
487 /* Set the clientdata field for a type */
488 static void
489 SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
490 SWIG_TypeClientDataTL(*swig_type_list_handle, ti, clientdata);
491 }
492
493 /* This function will propagate the clientdata field of type to
494 * any new swig_type_info structures that have been added into the list
495 * of equivalent types. It is like calling
496 * SWIG_TypeClientData(type, clientdata) a second time.
497 */
498 static void
499 SWIG_PropagateClientData(swig_type_info *type) {
500 SWIG_PropagateClientDataTL(*swig_type_list_handle, type);
501 }
502
503 #ifdef __cplusplus
504 }
505 #endif
506
507 /* -----------------------------------------------------------------------------
508 * SWIG API. Portion that goes into the runtime
509 * ----------------------------------------------------------------------------- */
510
511 #ifdef __cplusplus
512 extern "C" {
513 #endif
514
515 /* -----------------------------------------------------------------------------
516 * for internal method declarations
517 * ----------------------------------------------------------------------------- */
518
519 #ifndef SWIGINTERN
520 #define SWIGINTERN static
521 #endif
522
523 #ifndef SWIGINTERNSHORT
524 #ifdef __cplusplus
525 #define SWIGINTERNSHORT static inline
526 #else /* C case */
527 #define SWIGINTERNSHORT static
528 #endif /* __cplusplus */
529 #endif
530
531
532 /*
533 Exception handling in wrappers
534 */
535 #define SWIG_fail goto fail
536 #define SWIG_arg_fail(arg) SWIG_Python_ArgFail(arg)
537 #define SWIG_append_errmsg(msg) SWIG_Python_AddErrMesg(msg,0)
538 #define SWIG_preppend_errmsg(msg) SWIG_Python_AddErrMesg(msg,1)
539 #define SWIG_type_error(type,obj) SWIG_Python_TypeError(type,obj)
540 #define SWIG_null_ref(type) SWIG_Python_NullRef(type)
541
542 /*
543 Contract support
544 */
545 #define SWIG_contract_assert(expr, msg) \
546 if (!(expr)) { PyErr_SetString(PyExc_RuntimeError, (char *) msg ); goto fail; } else
547
548 /* -----------------------------------------------------------------------------
549 * Constant declarations
550 * ----------------------------------------------------------------------------- */
551
552 /* Constant Types */
553 #define SWIG_PY_INT 1
554 #define SWIG_PY_FLOAT 2
555 #define SWIG_PY_STRING 3
556 #define SWIG_PY_POINTER 4
557 #define SWIG_PY_BINARY 5
558
559 /* Constant information structure */
560 typedef struct swig_const_info {
561 int type;
562 char *name;
563 long lvalue;
564 double dvalue;
565 void *pvalue;
566 swig_type_info **ptype;
567 } swig_const_info;
568
569
570 /* -----------------------------------------------------------------------------
571 * Alloc. memory flags
572 * ----------------------------------------------------------------------------- */
573 #define SWIG_OLDOBJ 1
574 #define SWIG_NEWOBJ SWIG_OLDOBJ + 1
575 #define SWIG_PYSTR SWIG_NEWOBJ + 1
576
577 #ifdef __cplusplus
578 }
579 #endif
580
581
582 /***********************************************************************
583 * pyrun.swg
584 *
585 * This file contains the runtime support for Python modules
586 * and includes code for managing global variables and pointer
587 * type checking.
588 *
589 * Author : David Beazley (beazley@cs.uchicago.edu)
590 ************************************************************************/
591
592 /* Common SWIG API */
593 #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Python_ConvertPtr(obj, pp, type, flags)
594 #define SWIG_NewPointerObj(p, type, flags) SWIG_Python_NewPointerObj(p, type, flags)
595 #define SWIG_MustGetPtr(p, type, argnum, flags) SWIG_Python_MustGetPtr(p, type, argnum, flags)
596
597
598 /* Python-specific SWIG API */
599 #define SWIG_ConvertPacked(obj, ptr, sz, ty, flags) SWIG_Python_ConvertPacked(obj, ptr, sz, ty, flags)
600 #define SWIG_NewPackedObj(ptr, sz, type) SWIG_Python_NewPackedObj(ptr, sz, type)
601
602
603 /* -----------------------------------------------------------------------------
604 * Pointer declarations
605 * ----------------------------------------------------------------------------- */
606 /*
607 Use SWIG_NO_COBJECT_TYPES to force the use of strings to represent
608 C/C++ pointers in the python side. Very useful for debugging, but
609 not always safe.
610 */
611 #if !defined(SWIG_NO_COBJECT_TYPES) && !defined(SWIG_COBJECT_TYPES)
612 # define SWIG_COBJECT_TYPES
613 #endif
614
615 /* Flags for pointer conversion */
616 #define SWIG_POINTER_EXCEPTION 0x1
617 #define SWIG_POINTER_DISOWN 0x2
618
619
620 #ifdef __cplusplus
621 extern "C" {
622 #endif
623
624 /* -----------------------------------------------------------------------------
625 * Create a new pointer string
626 * ----------------------------------------------------------------------------- */
627
628 #ifndef SWIG_BUFFER_SIZE
629 #define SWIG_BUFFER_SIZE 1024
630 #endif
631
632 #if defined(SWIG_COBJECT_TYPES)
633 #if !defined(SWIG_COBJECT_PYTHON)
634 /* -----------------------------------------------------------------------------
635 * Implements a simple Swig Object type, and use it instead of PyCObject
636 * ----------------------------------------------------------------------------- */
637
638 typedef struct {
639 PyObject_HEAD
640 void *ptr;
641 const char *desc;
642 } PySwigObject;
643
644 /* Declarations for objects of type PySwigObject */
645
646 SWIGRUNTIME int
647 PySwigObject_print(PySwigObject *v, FILE *fp, int flags)
648 {
649 char result[SWIG_BUFFER_SIZE];
650 if (SWIG_PackVoidPtr(result, v->ptr, v->desc, sizeof(result))) {
651 fputs("<Swig Object at ", fp); fputs(result, fp); fputs(">", fp);
652 return 0;
653 } else {
654 return 1;
655 }
656 }
657
658 SWIGRUNTIME PyObject *
659 PySwigObject_repr(PySwigObject *v)
660 {
661 char result[SWIG_BUFFER_SIZE];
662 return SWIG_PackVoidPtr(result, v->ptr, v->desc, sizeof(result)) ?
663 PyString_FromFormat("<Swig Object at %s>", result) : 0;
664 }
665
666 SWIGRUNTIME PyObject *
667 PySwigObject_str(PySwigObject *v)
668 {
669 char result[SWIG_BUFFER_SIZE];
670 return SWIG_PackVoidPtr(result, v->ptr, v->desc, sizeof(result)) ?
671 PyString_FromString(result) : 0;
672 }
673
674 SWIGRUNTIME PyObject *
675 PySwigObject_long(PySwigObject *v)
676 {
677 return PyLong_FromUnsignedLong((unsigned long) v->ptr);
678 }
679
680 SWIGRUNTIME PyObject *
681 PySwigObject_oct(PySwigObject *v)
682 {
683 char buf[100];
684 unsigned long x = (unsigned long)v->ptr;
685 if (x == 0)
686 strcpy(buf, "0");
687 else
688 PyOS_snprintf(buf, sizeof(buf), "0%lo", x);
689 return PyString_FromString(buf);
690 }
691
692 SWIGRUNTIME PyObject *
693 PySwigObject_hex(PySwigObject *v)
694 {
695 char buf[100];
696 PyOS_snprintf(buf, sizeof(buf), "0x%lx", (unsigned long)v->ptr);
697 return PyString_FromString(buf);
698 }
699
700 SWIGRUNTIME int
701 PySwigObject_compare(PySwigObject *v, PySwigObject *w)
702 {
703 int c = strcmp(v->desc, w->desc);
704 if (c) {
705 return c;
706 } else {
707 void *i = v->ptr;
708 void *j = w->ptr;
709 return (i < j) ? -1 : (i > j) ? 1 : 0;
710 }
711 }
712
713 SWIGRUNTIME void
714 PySwigObject_dealloc(PySwigObject *self)
715 {
716 PyObject_DEL(self);
717 }
718
719 SWIGRUNTIME PyTypeObject*
720 PySwigObject_GetType() {
721 static char PySwigObject_Type__doc__[] =
722 "Swig object carries a C/C++ instance pointer";
723
724 static PyNumberMethods PySwigObject_as_number = {
725 (binaryfunc)0, /*nb_add*/
726 (binaryfunc)0, /*nb_subtract*/
727 (binaryfunc)0, /*nb_multiply*/
728 (binaryfunc)0, /*nb_divide*/
729 (binaryfunc)0, /*nb_remainder*/
730 (binaryfunc)0, /*nb_divmod*/
731 (ternaryfunc)0,/*nb_power*/
732 (unaryfunc)0, /*nb_negative*/
733 (unaryfunc)0, /*nb_positive*/
734 (unaryfunc)0, /*nb_absolute*/
735 (inquiry)0, /*nb_nonzero*/
736 0, /*nb_invert*/
737 0, /*nb_lshift*/
738 0, /*nb_rshift*/
739 0, /*nb_and*/
740 0, /*nb_xor*/
741 0, /*nb_or*/
742 (coercion)0, /*nb_coerce*/
743 (unaryfunc)PySwigObject_long, /*nb_int*/
744 (unaryfunc)PySwigObject_long, /*nb_long*/
745 (unaryfunc)0, /*nb_float*/
746 (unaryfunc)PySwigObject_oct, /*nb_oct*/
747 (unaryfunc)PySwigObject_hex, /*nb_hex*/
748 #if PY_VERSION_HEX >= 0x02000000
749 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_true_divide */
750 #endif
751 };
752
753 static int type_init = 0;
754 static PyTypeObject PySwigObject_Type;
755
756 if (!type_init) {
757 PyTypeObject tmp = {
758 PyObject_HEAD_INIT(&PyType_Type)
759 0, /*ob_size*/
760 "PySwigObject", /*tp_name*/
761 sizeof(PySwigObject), /*tp_basicsize*/
762 0, /*tp_itemsize*/
763 /* methods */
764 (destructor)PySwigObject_dealloc, /*tp_dealloc*/
765 (printfunc)PySwigObject_print, /*tp_print*/
766 (getattrfunc)0, /*tp_getattr*/
767 (setattrfunc)0, /*tp_setattr*/
768 (cmpfunc)PySwigObject_compare, /*tp_compare*/
769 (reprfunc)PySwigObject_repr, /*tp_repr*/
770 &PySwigObject_as_number, /*tp_as_number*/
771 0, /*tp_as_sequence*/
772 0, /*tp_as_mapping*/
773 (hashfunc)0, /*tp_hash*/
774 (ternaryfunc)0, /*tp_call*/
775 (reprfunc)PySwigObject_str, /*tp_str*/
776 /* Space for future expansion */
777 0L,0L,0L,0L,
778 PySwigObject_Type__doc__, /* Documentation string */
779 #if PY_VERSION_HEX >= 0x02000000
780 0, /* tp_traverse */
781 0, /* tp_clear */
782 #endif
783 #if PY_VERSION_HEX >= 0x02010000
784 0, /* tp_richcompare */
785 0, /* tp_weaklistoffset */
786 #endif
787 #if PY_VERSION_HEX >= 0x02020000
788 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
789 #endif
790 #if PY_VERSION_HEX >= 0x02030000
791 0, /* tp_del */
792 #endif
793 #ifdef COUNT_ALLOCS
794 0,0,0,0 /* tp_alloc -> tp_next */
795 #endif
796 };
797
798 PySwigObject_Type = tmp;
799 type_init = 1;
800 }
801
802 return &PySwigObject_Type;
803 }
804
805 SWIGRUNTIME PyObject *
806 PySwigObject_FromVoidPtrAndDesc(void *ptr, const char *desc)
807 {
808 PySwigObject *self = PyObject_NEW(PySwigObject, PySwigObject_GetType());
809 if (self == NULL) return NULL;
810 self->ptr = ptr;
811 self->desc = desc;
812 return (PyObject *)self;
813 }
814
815 SWIGRUNTIMEINLINE void *
816 PySwigObject_AsVoidPtr(PyObject *self)
817 {
818 return ((PySwigObject *)self)->ptr;
819 }
820
821 SWIGRUNTIMEINLINE const char *
822 PySwigObject_GetDesc(PyObject *self)
823 {
824 return ((PySwigObject *)self)->desc;
825 }
826
827 SWIGRUNTIMEINLINE int
828 PySwigObject_Check(PyObject *op) {
829 return ((op)->ob_type == PySwigObject_GetType())
830 || (strcmp((op)->ob_type->tp_name,"PySwigObject") == 0);
831 }
832
833 /* -----------------------------------------------------------------------------
834 * Implements a simple Swig Packed type, and use it instead of string
835 * ----------------------------------------------------------------------------- */
836
837 typedef struct {
838 PyObject_HEAD
839 void *pack;
840 const char *desc;
841 size_t size;
842 } PySwigPacked;
843
844 SWIGRUNTIME int
845 PySwigPacked_print(PySwigPacked *v, FILE *fp, int flags)
846 {
847 char result[SWIG_BUFFER_SIZE];
848 fputs("<Swig Packed ", fp);
849 if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
850 fputs("at ", fp);
851 fputs(result, fp);
852 }
853 fputs(v->desc,fp);
854 fputs(">", fp);
855 return 0;
856 }
857
858 SWIGRUNTIME PyObject *
859 PySwigPacked_repr(PySwigPacked *v)
860 {
861 char result[SWIG_BUFFER_SIZE];
862 if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
863 return PyString_FromFormat("<Swig Packed at %s%s>", result, v->desc);
864 } else {
865 return PyString_FromFormat("<Swig Packed %s>", v->desc);
866 }
867 }
868
869 SWIGRUNTIME PyObject *
870 PySwigPacked_str(PySwigPacked *v)
871 {
872 char result[SWIG_BUFFER_SIZE];
873 if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))){
874 return PyString_FromFormat("%s%s", result, v->desc);
875 } else {
876 return PyString_FromFormat("%s", v->desc);
877 }
878 }
879
880 SWIGRUNTIME int
881 PySwigPacked_compare(PySwigPacked *v, PySwigPacked *w)
882 {
883 int c = strcmp(v->desc, w->desc);
884 if (c) {
885 return c;
886 } else {
887 size_t i = v->size;
888 size_t j = w->size;
889 int s = (i < j) ? -1 : (i > j) ? 1 : 0;
890 return s ? s : strncmp((char *)v->pack, (char *)w->pack, 2*v->size);
891 }
892 }
893
894 SWIGRUNTIME void
895 PySwigPacked_dealloc(PySwigPacked *self)
896 {
897 free(self->pack);
898 PyObject_DEL(self);
899 }
900
901 SWIGRUNTIME PyTypeObject*
902 PySwigPacked_GetType() {
903 static char PySwigPacked_Type__doc__[] =
904 "Swig object carries a C/C++ instance pointer";
905 static int type_init = 0;
906
907 static PyTypeObject PySwigPacked_Type;
908 if (!type_init) {
909 PyTypeObject tmp = {
910 PyObject_HEAD_INIT(&PyType_Type)
911 0, /*ob_size*/
912 "PySwigPacked", /*tp_name*/
913 sizeof(PySwigPacked), /*tp_basicsize*/
914 0, /*tp_itemsize*/
915 /* methods */
916 (destructor)PySwigPacked_dealloc, /*tp_dealloc*/
917 (printfunc)PySwigPacked_print, /*tp_print*/
918 (getattrfunc)0, /*tp_getattr*/
919 (setattrfunc)0, /*tp_setattr*/
920 (cmpfunc)PySwigPacked_compare, /*tp_compare*/
921 (reprfunc)PySwigPacked_repr, /*tp_repr*/
922 0, /*tp_as_number*/
923 0, /*tp_as_sequence*/
924 0, /*tp_as_mapping*/
925 (hashfunc)0, /*tp_hash*/
926 (ternaryfunc)0, /*tp_call*/
927 (reprfunc)PySwigPacked_str, /*tp_str*/
928 /* Space for future expansion */
929 0L,0L,0L,0L,
930 PySwigPacked_Type__doc__, /* Documentation string */
931 #if PY_VERSION_HEX >= 0x02000000
932 0, /* tp_traverse */
933 0, /* tp_clear */
934 #endif
935 #if PY_VERSION_HEX >= 0x02010000
936 0, /* tp_richcompare */
937 0, /* tp_weaklistoffset */
938 #endif
939 #if PY_VERSION_HEX >= 0x02020000
940 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
941 #endif
942 #if PY_VERSION_HEX >= 0x02030000
943 0, /* tp_del */
944 #endif
945 #ifdef COUNT_ALLOCS
946 0,0,0,0 /* tp_alloc -> tp_next */
947 #endif
948 };
949
950 PySwigPacked_Type = tmp;
951 type_init = 1;
952 }
953
954
955
956 return &PySwigPacked_Type;
957 }
958
959 SWIGRUNTIME PyObject *
960 PySwigPacked_FromDataAndDesc(void *ptr, size_t size, const char *desc)
961 {
962 PySwigPacked *self = PyObject_NEW(PySwigPacked, PySwigPacked_GetType());
963 if (self == NULL) {
964 return NULL;
965 } else {
966 void *pack = malloc(size);
967 memcpy(pack, ptr, size);
968 self->pack = pack;
969 self->desc = desc;
970 self->size = size;
971 return (PyObject *) self;
972 }
973 }
974
975 SWIGRUNTIMEINLINE const char *
976 PySwigPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
977 {
978 PySwigPacked *self = (PySwigPacked *)obj;
979 if (self->size != size) return 0;
980 memcpy(ptr, self->pack, size);
981 return self->desc;
982 }
983
984 SWIGRUNTIMEINLINE const char *
985 PySwigPacked_GetDesc(PyObject *self)
986 {
987 return ((PySwigPacked *)self)->desc;
988 }
989
990 SWIGRUNTIMEINLINE int
991 PySwigPacked_Check(PyObject *op) {
992 return ((op)->ob_type == PySwigPacked_GetType())
993 || (strcmp((op)->ob_type->tp_name,"PySwigPacked") == 0);
994 }
995
996 #else
997 /* -----------------------------------------------------------------------------
998 * Use the old Python PyCObject instead of PySwigObject
999 * ----------------------------------------------------------------------------- */
1000
1001 #define PySwigObject_GetDesc(obj) PyCObject_GetDesc(obj)
1002 #define PySwigObject_Check(obj) PyCObject_Check(obj)
1003 #define PySwigObject_AsVoidPtr(obj) PyCObject_AsVoidPtr(obj)
1004 #define PySwigObject_FromVoidPtrAndDesc(p, d) PyCObject_FromVoidPtrAndDesc(p, d, NULL)
1005
1006 #endif
1007
1008 #endif
1009
1010 /* -----------------------------------------------------------------------------
1011 * errors manipulation
1012 * ----------------------------------------------------------------------------- */
1013
1014 SWIGRUNTIME void
1015 SWIG_Python_TypeError(const char *type, PyObject *obj)
1016 {
1017 if (type) {
1018 #if defined(SWIG_COBJECT_TYPES)
1019 if (PySwigObject_Check(obj)) {
1020 const char *otype = (const char *) PySwigObject_GetDesc(obj);
1021 if (otype) {
1022 PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'PySwigObject(%s)' is received",
1023 type, otype);
1024 return;
1025 }
1026 } else
1027 #endif
1028 {
1029 const char *otype = (obj ? obj->ob_type->tp_name : 0);
1030 if (otype) {
1031 PyObject *str = PyObject_Str(obj);
1032 const char *cstr = str ? PyString_AsString(str) : 0;
1033 if (cstr) {
1034 PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received",
1035 type, otype, cstr);
1036 } else {
1037 PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received",
1038 type, otype);
1039 }
1040 Py_DECREF(str);
1041 return;
1042 }
1043 }
1044 PyErr_Format(PyExc_TypeError, "a '%s' is expected", type);
1045 } else {
1046 PyErr_Format(PyExc_TypeError, "unexpected type is received");
1047 }
1048 }
1049
1050 SWIGRUNTIMEINLINE void
1051 SWIG_Python_NullRef(const char *type)
1052 {
1053 if (type) {
1054 PyErr_Format(PyExc_TypeError, "null reference of type '%s' was received",type);
1055 } else {
1056 PyErr_Format(PyExc_TypeError, "null reference was received");
1057 }
1058 }
1059
1060 SWIGRUNTIME int
1061 SWIG_Python_AddErrMesg(const char* mesg, int infront)
1062 {
1063 if (PyErr_Occurred()) {
1064 PyObject *type = 0;
1065 PyObject *value = 0;
1066 PyObject *traceback = 0;
1067 PyErr_Fetch(&type, &value, &traceback);
1068 if (value) {
1069 PyObject *old_str = PyObject_Str(value);
1070 Py_XINCREF(type);
1071 PyErr_Clear();
1072 if (infront) {
1073 PyErr_Format(type, "%s %s", mesg, PyString_AsString(old_str));
1074 } else {
1075 PyErr_Format(type, "%s %s", PyString_AsString(old_str), mesg);
1076 }
1077 Py_DECREF(old_str);
1078 }
1079 return 1;
1080 } else {
1081 return 0;
1082 }
1083 }
1084
1085 SWIGRUNTIME int
1086 SWIG_Python_ArgFail(int argnum)
1087 {
1088 if (PyErr_Occurred()) {
1089 /* add information about failing argument */
1090 char mesg[256];
1091 sprintf(mesg, "argument number %d:", argnum);
1092 return SWIG_Python_AddErrMesg(mesg, 1);
1093 } else {
1094 return 0;
1095 }
1096 }
1097
1098
1099 /* -----------------------------------------------------------------------------
1100 * pointers/data manipulation
1101 * ----------------------------------------------------------------------------- */
1102
1103 /* Convert a pointer value */
1104 SWIGRUNTIME int
1105 SWIG_Python_ConvertPtr(PyObject *obj, void **ptr, swig_type_info *ty, int flags) {
1106 swig_type_info *tc;
1107 const char *c = 0;
1108 static PyObject *SWIG_this = 0;
1109 int newref = 0;
1110 PyObject *pyobj = 0;
1111 void *vptr;
1112
1113 if (!obj) return 0;
1114 if (obj == Py_None) {
1115 *ptr = 0;
1116 return 0;
1117 }
1118
1119 #ifdef SWIG_COBJECT_TYPES
1120 if (!(PySwigObject_Check(obj))) {
1121 if (!SWIG_this)
1122 SWIG_this = PyString_FromString("this");
1123 pyobj = obj;
1124 obj = PyObject_GetAttr(obj,SWIG_this);
1125 newref = 1;
1126 if (!obj) goto type_error;
1127 if (!PySwigObject_Check(obj)) {
1128 Py_DECREF(obj);
1129 goto type_error;
1130 }
1131 }
1132 vptr = PySwigObject_AsVoidPtr(obj);
1133 c = (const char *) PySwigObject_GetDesc(obj);
1134 if (newref) { Py_DECREF(obj); }
1135 goto type_check;
1136 #else
1137 if (!(PyString_Check(obj))) {
1138 if (!SWIG_this)
1139 SWIG_this = PyString_FromString("this");
1140 pyobj = obj;
1141 obj = PyObject_GetAttr(obj,SWIG_this);
1142 newref = 1;
1143 if (!obj) goto type_error;
1144 if (!PyString_Check(obj)) {
1145 Py_DECREF(obj);
1146 goto type_error;
1147 }
1148 }
1149 c = PyString_AS_STRING(obj);
1150 /* Pointer values must start with leading underscore */
1151 c = SWIG_UnpackVoidPtr(c, &vptr, ty->name);
1152 if (newref) { Py_DECREF(obj); }
1153 if (!c) goto type_error;
1154 #endif
1155
1156 type_check:
1157
1158 if (ty) {
1159 tc = SWIG_TypeCheck(c,ty);
1160 if (!tc) goto type_error;
1161 *ptr = SWIG_TypeCast(tc,vptr);
1162 } else {
1163 *ptr = vptr;
1164 }
1165
1166 if ((pyobj) && (flags & SWIG_POINTER_DISOWN)) {
1167 PyObject_SetAttrString(pyobj,(char*)"thisown",Py_False);
1168 }
1169 return 0;
1170
1171 type_error:
1172 PyErr_Clear();
1173 if (pyobj && !obj) {
1174 obj = pyobj;
1175 if (PyCFunction_Check(obj)) {
1176 /* here we get the method pointer for callbacks */
1177 char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc);
1178 c = doc ? strstr(doc, "swig_ptr: ") : 0;
1179 if (c) {
1180 c = SWIG_UnpackVoidPtr(c + 10, &vptr, ty->name);
1181 if (!c) goto type_error;
1182 goto type_check;
1183 }
1184 }
1185 }
1186 if (flags & SWIG_POINTER_EXCEPTION) {
1187 if (ty) {
1188 SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
1189 } else {
1190 SWIG_Python_TypeError("C/C++ pointer", obj);
1191 }
1192 }
1193 return -1;
1194 }
1195
1196 /* Convert a pointer value, signal an exception on a type mismatch */
1197 SWIGRUNTIME void *
1198 SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int argnum, int flags) {
1199 void *result;
1200 if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) {
1201 PyErr_Clear();
1202 if (flags & SWIG_POINTER_EXCEPTION) {
1203 SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
1204 SWIG_Python_ArgFail(argnum);
1205 }
1206 }
1207 return result;
1208 }
1209
1210 /* Convert a packed value value */
1211 SWIGRUNTIME int
1212 SWIG_Python_ConvertPacked(PyObject *obj, void *ptr, size_t sz, swig_type_info *ty, int flags) {
1213 swig_type_info *tc;
1214 const char *c = 0;
1215
1216 #if defined(SWIG_COBJECT_TYPES) && !defined(SWIG_COBJECT_PYTHON)
1217 c = PySwigPacked_UnpackData(obj, ptr, sz);
1218 #else
1219 if ((!obj) || (!PyString_Check(obj))) goto type_error;
1220 c = PyString_AS_STRING(obj);
1221 /* Pointer values must start with leading underscore */
1222 c = SWIG_UnpackDataName(c, ptr, sz, ty->name);
1223 #endif
1224 if (!c) goto type_error;
1225 if (ty) {
1226 tc = SWIG_TypeCheck(c,ty);
1227 if (!tc) goto type_error;
1228 }
1229 return 0;
1230
1231 type_error:
1232 PyErr_Clear();
1233 if (flags & SWIG_POINTER_EXCEPTION) {
1234 if (ty) {
1235 SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
1236 } else {
1237 SWIG_Python_TypeError("C/C++ packed data", obj);
1238 }
1239 }
1240 return -1;
1241 }
1242
1243 /* Create a new array object */
1244 SWIGRUNTIME PyObject *
1245 SWIG_Python_NewPointerObj(void *ptr, swig_type_info *type, int own) {
1246 PyObject *robj = 0;
1247 if (!ptr) {
1248 Py_INCREF(Py_None);
1249 return Py_None;
1250 }
1251 #ifdef SWIG_COBJECT_TYPES
1252 robj = PySwigObject_FromVoidPtrAndDesc((void *) ptr, (char *)type->name);
1253 #else
1254 {
1255 char result[SWIG_BUFFER_SIZE];
1256 robj = SWIG_PackVoidPtr(result, ptr, type->name, sizeof(result)) ?
1257 PyString_FromString(result) : 0;
1258 }
1259 #endif
1260 if (!robj || (robj == Py_None)) return robj;
1261 if (type->clientdata) {
1262 PyObject *inst;
1263 PyObject *args = Py_BuildValue((char*)"(O)", robj);
1264 Py_DECREF(robj);
1265 inst = PyObject_CallObject((PyObject *) type->clientdata, args);
1266 Py_DECREF(args);
1267 if (inst) {
1268 if (own) {
1269 PyObject_SetAttrString(inst,(char*)"thisown",Py_True);
1270 }
1271 robj = inst;
1272 }
1273 }
1274 return robj;
1275 }
1276
1277 SWIGRUNTIME PyObject *
1278 SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) {
1279 PyObject *robj = 0;
1280 if (!ptr) {
1281 Py_INCREF(Py_None);
1282 return Py_None;
1283 }
1284 #if defined(SWIG_COBJECT_TYPES) && !defined(SWIG_COBJECT_PYTHON)
1285 robj = PySwigPacked_FromDataAndDesc((void *) ptr, sz, (char *)type->name);
1286 #else
1287 {
1288 char result[SWIG_BUFFER_SIZE];
1289 robj = SWIG_PackDataName(result, ptr, sz, type->name, sizeof(result)) ?
1290 PyString_FromString(result) : 0;
1291 }
1292 #endif
1293 return robj;
1294 }
1295
1296 /* -----------------------------------------------------------------------------*
1297 * Get type list
1298 * -----------------------------------------------------------------------------*/
1299
1300 #ifdef SWIG_LINK_RUNTIME
1301 void *SWIG_ReturnGlobalTypeList(void *);
1302 #endif
1303
1304 SWIGRUNTIME swig_type_info **
1305 SWIG_Python_GetTypeListHandle() {
1306 static void *type_pointer = (void *)0;
1307 /* first check if module already created */
1308 if (!type_pointer) {
1309 #ifdef SWIG_LINK_RUNTIME
1310 type_pointer = SWIG_ReturnGlobalTypeList((void *)0);
1311 #else
1312 type_pointer = PyCObject_Import((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION,
1313 (char*)"type_pointer" SWIG_TYPE_TABLE_NAME);
1314 if (PyErr_Occurred()) {
1315 PyErr_Clear();
1316 type_pointer = (void *)0;
1317 }
1318 }
1319 #endif
1320 return (swig_type_info **) type_pointer;
1321 }
1322
1323 /*
1324 Search for a swig_type_info structure
1325 */
1326 SWIGRUNTIMEINLINE swig_type_info *
1327 SWIG_Python_GetTypeList() {
1328 swig_type_info **tlh = SWIG_Python_GetTypeListHandle();
1329 return tlh ? *tlh : (swig_type_info*)0;
1330 }
1331
1332 #define SWIG_Runtime_GetTypeList SWIG_Python_GetTypeList
1333
1334 #ifdef __cplusplus
1335 }
1336 #endif
1337
1338
1339 /* -------- TYPES TABLE (BEGIN) -------- */
1340
1341 #define SWIGTYPE_p_wxGLCanvas swig_types[0]
1342 #define SWIGTYPE_p_wxObject swig_types[1]
1343 #define SWIGTYPE_p_unsigned_char swig_types[2]
1344 #define SWIGTYPE_p_wxGLContext swig_types[3]
1345 #define SWIGTYPE_p_wxWindow swig_types[4]
1346 #define SWIGTYPE_p_unsigned_long swig_types[5]
1347 #define SWIGTYPE_p_form_ops_t swig_types[6]
1348 #define SWIGTYPE_p_unsigned_int swig_types[7]
1349 #define SWIGTYPE_unsigned_int swig_types[8]
1350 #define SWIGTYPE_p_wxDuplexMode swig_types[9]
1351 #define SWIGTYPE_p_char swig_types[10]
1352 #define SWIGTYPE_p_wxEvtHandler swig_types[11]
1353 #define SWIGTYPE_p_wxPalette swig_types[12]
1354 #define SWIGTYPE_std__ptrdiff_t swig_types[13]
1355 #define SWIGTYPE_ptrdiff_t swig_types[14]
1356 #define SWIGTYPE_p_wxPaperSize swig_types[15]
1357 #define SWIGTYPE_p_int swig_types[16]
1358 static swig_type_info *swig_types[18];
1359
1360 /* -------- TYPES TABLE (END) -------- */
1361
1362
1363 /*-----------------------------------------------
1364 @(target):= _glcanvas.so
1365 ------------------------------------------------*/
1366 #define SWIG_init init_glcanvas
1367
1368 #define SWIG_name "_glcanvas"
1369
1370 #include "wx/wxPython/wxPython.h"
1371 #include "wx/wxPython/pyclasses.h"
1372
1373 #include <wx/glcanvas.h>
1374
1375
1376 static const wxString wxPyGLCanvasNameStr(wxT("GLCanvas"));
1377 static const wxString wxPyEmptyString(wxEmptyString);
1378
1379 #include <limits.h>
1380
1381
1382 SWIGINTERN int
1383 SWIG_CheckLongInRange(long value, long min_value, long max_value,
1384 const char *errmsg)
1385 {
1386 if (value < min_value) {
1387 if (errmsg) {
1388 PyErr_Format(PyExc_OverflowError,
1389 "value %ld is less than '%s' minimum %ld",
1390 value, errmsg, min_value);
1391 }
1392 return 0;
1393 } else if (value > max_value) {
1394 if (errmsg) {
1395 PyErr_Format(PyExc_OverflowError,
1396 "value %ld is greater than '%s' maximum %ld",
1397 value, errmsg, max_value);
1398 }
1399 return 0;
1400 }
1401 return 1;
1402 }
1403
1404
1405 SWIGINTERN int
1406 SWIG_AsVal_long(PyObject* obj, long* val)
1407 {
1408 if (PyNumber_Check(obj)) {
1409 if (val) *val = PyInt_AsLong(obj);
1410 return 1;
1411 }
1412 else {
1413 SWIG_type_error("number", obj);
1414 }
1415 return 0;
1416 }
1417
1418
1419 #if INT_MAX != LONG_MAX
1420 SWIGINTERN int
1421 SWIG_AsVal_int(PyObject *obj, int *val)
1422 {
1423 const char* errmsg = val ? "int" : (char*)0;
1424 long v;
1425 if (SWIG_AsVal_long(obj, &v)) {
1426 if (SWIG_CheckLongInRange(v, INT_MIN,INT_MAX, errmsg)) {
1427 if (val) *val = (int)(v);
1428 return 1;
1429 } else {
1430 return 0;
1431 }
1432 } else {
1433 PyErr_Clear();
1434 }
1435 if (val) {
1436 SWIG_type_error(errmsg, obj);
1437 }
1438 return 0;
1439 }
1440 #else
1441 SWIGINTERNSHORT int
1442 SWIG_AsVal_int(PyObject *obj, int *val)
1443 {
1444 return SWIG_AsVal_long(obj,(long*)val);
1445 }
1446 #endif
1447
1448
1449 SWIGINTERN int
1450 SWIG_AsVal_bool(PyObject *obj, bool *val)
1451 {
1452 if (obj == Py_True) {
1453 if (val) *val = true;
1454 return 1;
1455 }
1456 if (obj == Py_False) {
1457 if (val) *val = false;
1458 return 1;
1459 }
1460 int res = 0;
1461 if (SWIG_AsVal_int(obj, &res)) {
1462 if (val) *val = res ? true : false;
1463 return 1;
1464 } else {
1465 PyErr_Clear();
1466 }
1467 if (val) {
1468 SWIG_type_error("bool", obj);
1469 }
1470 return 0;
1471 }
1472
1473
1474 SWIGINTERNSHORT bool
1475 SWIG_As_bool(PyObject* obj)
1476 {
1477 bool v;
1478 if (!SWIG_AsVal_bool(obj, &v)) {
1479 /*
1480 this is needed to make valgrind/purify happier.
1481 */
1482 memset((void*)&v, 0, sizeof(bool));
1483 }
1484 return v;
1485 }
1486
1487
1488 SWIGINTERNSHORT int
1489 SWIG_Check_bool(PyObject* obj)
1490 {
1491 return SWIG_AsVal_bool(obj, (bool*)0);
1492 }
1493
1494
1495 /*@c:\\PROJECTS\\SWIG-cvs\\Lib\\python\\pymacros.swg,66,SWIG_define@*/
1496 #define SWIG_From_int PyInt_FromLong
1497 /*@@*/
1498
1499
1500 SWIGINTERNSHORT int
1501 SWIG_As_int(PyObject* obj)
1502 {
1503 int v;
1504 if (!SWIG_AsVal_int(obj, &v)) {
1505 /*
1506 this is needed to make valgrind/purify happier.
1507 */
1508 memset((void*)&v, 0, sizeof(int));
1509 }
1510 return v;
1511 }
1512
1513
1514 SWIGINTERNSHORT long
1515 SWIG_As_long(PyObject* obj)
1516 {
1517 long v;
1518 if (!SWIG_AsVal_long(obj, &v)) {
1519 /*
1520 this is needed to make valgrind/purify happier.
1521 */
1522 memset((void*)&v, 0, sizeof(long));
1523 }
1524 return v;
1525 }
1526
1527
1528 SWIGINTERNSHORT int
1529 SWIG_Check_int(PyObject* obj)
1530 {
1531 return SWIG_AsVal_int(obj, (int*)0);
1532 }
1533
1534
1535 SWIGINTERNSHORT int
1536 SWIG_Check_long(PyObject* obj)
1537 {
1538 return SWIG_AsVal_long(obj, (long*)0);
1539 }
1540
1541 #ifdef __cplusplus
1542 extern "C" {
1543 #endif
1544 static int _wrap_GLCanvasNameStr_set(PyObject *) {
1545 PyErr_SetString(PyExc_TypeError,"Variable GLCanvasNameStr is read-only.");
1546 return 1;
1547 }
1548
1549
1550 static PyObject *_wrap_GLCanvasNameStr_get(void) {
1551 PyObject *pyobj;
1552
1553 {
1554 #if wxUSE_UNICODE
1555 pyobj = PyUnicode_FromWideChar((&wxPyGLCanvasNameStr)->c_str(), (&wxPyGLCanvasNameStr)->Len());
1556 #else
1557 pyobj = PyString_FromStringAndSize((&wxPyGLCanvasNameStr)->c_str(), (&wxPyGLCanvasNameStr)->Len());
1558 #endif
1559 }
1560 return pyobj;
1561 }
1562
1563
1564 static PyObject *_wrap_new_GLContext(PyObject *, PyObject *args, PyObject *kwargs) {
1565 PyObject *resultobj;
1566 bool arg1 ;
1567 wxGLCanvas *arg2 = (wxGLCanvas *) 0 ;
1568 wxPalette const &arg3_defvalue = wxNullPalette ;
1569 wxPalette *arg3 = (wxPalette *) &arg3_defvalue ;
1570 wxGLContext *arg4 = (wxGLContext *) NULL ;
1571 wxGLContext *result;
1572 PyObject * obj0 = 0 ;
1573 PyObject * obj1 = 0 ;
1574 PyObject * obj2 = 0 ;
1575 PyObject * obj3 = 0 ;
1576 char *kwnames[] = {
1577 (char *) "isRGB",(char *) "win",(char *) "palette",(char *) "other", NULL
1578 };
1579
1580 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|OO:new_GLContext",kwnames,&obj0,&obj1,&obj2,&obj3)) goto fail;
1581 {
1582 arg1 = (bool)(SWIG_As_bool(obj0));
1583 if (SWIG_arg_fail(1)) SWIG_fail;
1584 }
1585 SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
1586 if (SWIG_arg_fail(2)) SWIG_fail;
1587 if (obj2) {
1588 {
1589 SWIG_Python_ConvertPtr(obj2, (void **)&arg3, SWIGTYPE_p_wxPalette, SWIG_POINTER_EXCEPTION | 0);
1590 if (SWIG_arg_fail(3)) SWIG_fail;
1591 if (arg3 == NULL) {
1592 SWIG_null_ref("wxPalette");
1593 }
1594 if (SWIG_arg_fail(3)) SWIG_fail;
1595 }
1596 }
1597 if (obj3) {
1598 SWIG_Python_ConvertPtr(obj3, (void **)&arg4, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1599 if (SWIG_arg_fail(4)) SWIG_fail;
1600 }
1601 {
1602 if (!wxPyCheckForApp()) SWIG_fail;
1603 PyThreadState* __tstate = wxPyBeginAllowThreads();
1604 result = (wxGLContext *)new wxGLContext(arg1,arg2,(wxPalette const &)*arg3,(wxGLContext const *)arg4);
1605
1606 wxPyEndAllowThreads(__tstate);
1607 if (PyErr_Occurred()) SWIG_fail;
1608 }
1609 resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_wxGLContext, 1);
1610 return resultobj;
1611 fail:
1612 return NULL;
1613 }
1614
1615
1616 static PyObject *_wrap_delete_GLContext(PyObject *, PyObject *args, PyObject *kwargs) {
1617 PyObject *resultobj;
1618 wxGLContext *arg1 = (wxGLContext *) 0 ;
1619 PyObject * obj0 = 0 ;
1620 char *kwnames[] = {
1621 (char *) "self", NULL
1622 };
1623
1624 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:delete_GLContext",kwnames,&obj0)) goto fail;
1625 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1626 if (SWIG_arg_fail(1)) SWIG_fail;
1627 {
1628 PyThreadState* __tstate = wxPyBeginAllowThreads();
1629 delete arg1;
1630
1631 wxPyEndAllowThreads(__tstate);
1632 if (PyErr_Occurred()) SWIG_fail;
1633 }
1634 Py_INCREF(Py_None); resultobj = Py_None;
1635 return resultobj;
1636 fail:
1637 return NULL;
1638 }
1639
1640
1641 static PyObject *_wrap_GLContext_SetCurrent(PyObject *, PyObject *args, PyObject *kwargs) {
1642 PyObject *resultobj;
1643 wxGLContext *arg1 = (wxGLContext *) 0 ;
1644 PyObject * obj0 = 0 ;
1645 char *kwnames[] = {
1646 (char *) "self", NULL
1647 };
1648
1649 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLContext_SetCurrent",kwnames,&obj0)) goto fail;
1650 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1651 if (SWIG_arg_fail(1)) SWIG_fail;
1652 {
1653 PyThreadState* __tstate = wxPyBeginAllowThreads();
1654 (arg1)->SetCurrent();
1655
1656 wxPyEndAllowThreads(__tstate);
1657 if (PyErr_Occurred()) SWIG_fail;
1658 }
1659 Py_INCREF(Py_None); resultobj = Py_None;
1660 return resultobj;
1661 fail:
1662 return NULL;
1663 }
1664
1665
1666 static PyObject *_wrap_GLContext_SetColour(PyObject *, PyObject *args, PyObject *kwargs) {
1667 PyObject *resultobj;
1668 wxGLContext *arg1 = (wxGLContext *) 0 ;
1669 wxString *arg2 = 0 ;
1670 bool temp2 = false ;
1671 PyObject * obj0 = 0 ;
1672 PyObject * obj1 = 0 ;
1673 char *kwnames[] = {
1674 (char *) "self",(char *) "colour", NULL
1675 };
1676
1677 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:GLContext_SetColour",kwnames,&obj0,&obj1)) goto fail;
1678 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1679 if (SWIG_arg_fail(1)) SWIG_fail;
1680 {
1681 arg2 = wxString_in_helper(obj1);
1682 if (arg2 == NULL) SWIG_fail;
1683 temp2 = true;
1684 }
1685 {
1686 PyThreadState* __tstate = wxPyBeginAllowThreads();
1687 (arg1)->SetColour((wxString const &)*arg2);
1688
1689 wxPyEndAllowThreads(__tstate);
1690 if (PyErr_Occurred()) SWIG_fail;
1691 }
1692 Py_INCREF(Py_None); resultobj = Py_None;
1693 {
1694 if (temp2)
1695 delete arg2;
1696 }
1697 return resultobj;
1698 fail:
1699 {
1700 if (temp2)
1701 delete arg2;
1702 }
1703 return NULL;
1704 }
1705
1706
1707 static PyObject *_wrap_GLContext_SwapBuffers(PyObject *, PyObject *args, PyObject *kwargs) {
1708 PyObject *resultobj;
1709 wxGLContext *arg1 = (wxGLContext *) 0 ;
1710 PyObject * obj0 = 0 ;
1711 char *kwnames[] = {
1712 (char *) "self", NULL
1713 };
1714
1715 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLContext_SwapBuffers",kwnames,&obj0)) goto fail;
1716 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1717 if (SWIG_arg_fail(1)) SWIG_fail;
1718 {
1719 PyThreadState* __tstate = wxPyBeginAllowThreads();
1720 (arg1)->SwapBuffers();
1721
1722 wxPyEndAllowThreads(__tstate);
1723 if (PyErr_Occurred()) SWIG_fail;
1724 }
1725 Py_INCREF(Py_None); resultobj = Py_None;
1726 return resultobj;
1727 fail:
1728 return NULL;
1729 }
1730
1731
1732 static PyObject *_wrap_GLContext_GetWindow(PyObject *, PyObject *args, PyObject *kwargs) {
1733 PyObject *resultobj;
1734 wxGLContext *arg1 = (wxGLContext *) 0 ;
1735 wxWindow *result;
1736 PyObject * obj0 = 0 ;
1737 char *kwnames[] = {
1738 (char *) "self", NULL
1739 };
1740
1741 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLContext_GetWindow",kwnames,&obj0)) goto fail;
1742 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1743 if (SWIG_arg_fail(1)) SWIG_fail;
1744 {
1745 PyThreadState* __tstate = wxPyBeginAllowThreads();
1746 result = (wxWindow *)(arg1)->GetWindow();
1747
1748 wxPyEndAllowThreads(__tstate);
1749 if (PyErr_Occurred()) SWIG_fail;
1750 }
1751 {
1752 resultobj = wxPyMake_wxObject(result, 0);
1753 }
1754 return resultobj;
1755 fail:
1756 return NULL;
1757 }
1758
1759
1760 static PyObject * GLContext_swigregister(PyObject *, PyObject *args) {
1761 PyObject *obj;
1762 if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
1763 SWIG_TypeClientData(SWIGTYPE_p_wxGLContext, obj);
1764 Py_INCREF(obj);
1765 return Py_BuildValue((char *)"");
1766 }
1767 static PyObject *_wrap_new_GLCanvas(PyObject *, PyObject *args, PyObject *kwargs) {
1768 PyObject *resultobj;
1769 wxWindow *arg1 = (wxWindow *) 0 ;
1770 int arg2 = (int) -1 ;
1771 wxPoint const &arg3_defvalue = wxDefaultPosition ;
1772 wxPoint *arg3 = (wxPoint *) &arg3_defvalue ;
1773 wxSize const &arg4_defvalue = wxDefaultSize ;
1774 wxSize *arg4 = (wxSize *) &arg4_defvalue ;
1775 long arg5 = (long) 0 ;
1776 wxString const &arg6_defvalue = wxPyGLCanvasNameStr ;
1777 wxString *arg6 = (wxString *) &arg6_defvalue ;
1778 int *arg7 = (int *) NULL ;
1779 wxPalette const &arg8_defvalue = wxNullPalette ;
1780 wxPalette *arg8 = (wxPalette *) &arg8_defvalue ;
1781 wxGLCanvas *result;
1782 wxPoint temp3 ;
1783 wxSize temp4 ;
1784 bool temp6 = false ;
1785 int *temp7 ;
1786 PyObject * obj0 = 0 ;
1787 PyObject * obj1 = 0 ;
1788 PyObject * obj2 = 0 ;
1789 PyObject * obj3 = 0 ;
1790 PyObject * obj4 = 0 ;
1791 PyObject * obj5 = 0 ;
1792 PyObject * obj6 = 0 ;
1793 PyObject * obj7 = 0 ;
1794 char *kwnames[] = {
1795 (char *) "parent",(char *) "id",(char *) "pos",(char *) "size",(char *) "style",(char *) "name",(char *) "attribList",(char *) "palette", NULL
1796 };
1797
1798 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|OOOOOOO:new_GLCanvas",kwnames,&obj0,&obj1,&obj2,&obj3,&obj4,&obj5,&obj6,&obj7)) goto fail;
1799 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxWindow, SWIG_POINTER_EXCEPTION | 0);
1800 if (SWIG_arg_fail(1)) SWIG_fail;
1801 if (obj1) {
1802 {
1803 arg2 = (int)(SWIG_As_int(obj1));
1804 if (SWIG_arg_fail(2)) SWIG_fail;
1805 }
1806 }
1807 if (obj2) {
1808 {
1809 arg3 = &temp3;
1810 if ( ! wxPoint_helper(obj2, &arg3)) SWIG_fail;
1811 }
1812 }
1813 if (obj3) {
1814 {
1815 arg4 = &temp4;
1816 if ( ! wxSize_helper(obj3, &arg4)) SWIG_fail;
1817 }
1818 }
1819 if (obj4) {
1820 {
1821 arg5 = (long)(SWIG_As_long(obj4));
1822 if (SWIG_arg_fail(5)) SWIG_fail;
1823 }
1824 }
1825 if (obj5) {
1826 {
1827 arg6 = wxString_in_helper(obj5);
1828 if (arg6 == NULL) SWIG_fail;
1829 temp6 = true;
1830 }
1831 }
1832 if (obj6) {
1833 {
1834 int i;
1835 if (PySequence_Check(obj6)) {
1836 int size = PyObject_Length(obj6);
1837 temp7 = new int[size+1]; // (int*)malloc((size + 1) * sizeof(int));
1838 for (i = 0; i < size; i++) {
1839 temp7[i] = PyInt_AsLong(PySequence_GetItem(obj6, i));
1840 }
1841 temp7[size] = 0;
1842 arg7 = temp7;
1843 }
1844 }
1845 }
1846 if (obj7) {
1847 {
1848 SWIG_Python_ConvertPtr(obj7, (void **)&arg8, SWIGTYPE_p_wxPalette, SWIG_POINTER_EXCEPTION | 0);
1849 if (SWIG_arg_fail(8)) SWIG_fail;
1850 if (arg8 == NULL) {
1851 SWIG_null_ref("wxPalette");
1852 }
1853 if (SWIG_arg_fail(8)) SWIG_fail;
1854 }
1855 }
1856 {
1857 if (!wxPyCheckForApp()) SWIG_fail;
1858 PyThreadState* __tstate = wxPyBeginAllowThreads();
1859 result = (wxGLCanvas *)new wxGLCanvas(arg1,arg2,(wxPoint const &)*arg3,(wxSize const &)*arg4,arg5,(wxString const &)*arg6,arg7,(wxPalette const &)*arg8);
1860
1861 wxPyEndAllowThreads(__tstate);
1862 if (PyErr_Occurred()) SWIG_fail;
1863 }
1864 resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_wxGLCanvas, 1);
1865 {
1866 if (temp6)
1867 delete arg6;
1868 }
1869 {
1870 delete [] arg7;
1871 }
1872 return resultobj;
1873 fail:
1874 {
1875 if (temp6)
1876 delete arg6;
1877 }
1878 {
1879 delete [] arg7;
1880 }
1881 return NULL;
1882 }
1883
1884
1885 static PyObject *_wrap_new_GLCanvasWithContext(PyObject *, PyObject *args, PyObject *kwargs) {
1886 PyObject *resultobj;
1887 wxWindow *arg1 = (wxWindow *) 0 ;
1888 wxGLContext *arg2 = (wxGLContext *) NULL ;
1889 int arg3 = (int) -1 ;
1890 wxPoint const &arg4_defvalue = wxDefaultPosition ;
1891 wxPoint *arg4 = (wxPoint *) &arg4_defvalue ;
1892 wxSize const &arg5_defvalue = wxDefaultSize ;
1893 wxSize *arg5 = (wxSize *) &arg5_defvalue ;
1894 long arg6 = (long) 0 ;
1895 wxString const &arg7_defvalue = wxPyGLCanvasNameStr ;
1896 wxString *arg7 = (wxString *) &arg7_defvalue ;
1897 int *arg8 = (int *) NULL ;
1898 wxPalette const &arg9_defvalue = wxNullPalette ;
1899 wxPalette *arg9 = (wxPalette *) &arg9_defvalue ;
1900 wxGLCanvas *result;
1901 wxPoint temp4 ;
1902 wxSize temp5 ;
1903 bool temp7 = false ;
1904 int *temp8 ;
1905 PyObject * obj0 = 0 ;
1906 PyObject * obj1 = 0 ;
1907 PyObject * obj2 = 0 ;
1908 PyObject * obj3 = 0 ;
1909 PyObject * obj4 = 0 ;
1910 PyObject * obj5 = 0 ;
1911 PyObject * obj6 = 0 ;
1912 PyObject * obj7 = 0 ;
1913 PyObject * obj8 = 0 ;
1914 char *kwnames[] = {
1915 (char *) "parent",(char *) "shared",(char *) "id",(char *) "pos",(char *) "size",(char *) "style",(char *) "name",(char *) "attribList",(char *) "palette", NULL
1916 };
1917
1918 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|OOOOOOOO:new_GLCanvasWithContext",kwnames,&obj0,&obj1,&obj2,&obj3,&obj4,&obj5,&obj6,&obj7,&obj8)) goto fail;
1919 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxWindow, SWIG_POINTER_EXCEPTION | 0);
1920 if (SWIG_arg_fail(1)) SWIG_fail;
1921 if (obj1) {
1922 SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_wxGLContext, SWIG_POINTER_EXCEPTION | 0);
1923 if (SWIG_arg_fail(2)) SWIG_fail;
1924 }
1925 if (obj2) {
1926 {
1927 arg3 = (int)(SWIG_As_int(obj2));
1928 if (SWIG_arg_fail(3)) SWIG_fail;
1929 }
1930 }
1931 if (obj3) {
1932 {
1933 arg4 = &temp4;
1934 if ( ! wxPoint_helper(obj3, &arg4)) SWIG_fail;
1935 }
1936 }
1937 if (obj4) {
1938 {
1939 arg5 = &temp5;
1940 if ( ! wxSize_helper(obj4, &arg5)) SWIG_fail;
1941 }
1942 }
1943 if (obj5) {
1944 {
1945 arg6 = (long)(SWIG_As_long(obj5));
1946 if (SWIG_arg_fail(6)) SWIG_fail;
1947 }
1948 }
1949 if (obj6) {
1950 {
1951 arg7 = wxString_in_helper(obj6);
1952 if (arg7 == NULL) SWIG_fail;
1953 temp7 = true;
1954 }
1955 }
1956 if (obj7) {
1957 {
1958 int i;
1959 if (PySequence_Check(obj7)) {
1960 int size = PyObject_Length(obj7);
1961 temp8 = new int[size+1]; // (int*)malloc((size + 1) * sizeof(int));
1962 for (i = 0; i < size; i++) {
1963 temp8[i] = PyInt_AsLong(PySequence_GetItem(obj7, i));
1964 }
1965 temp8[size] = 0;
1966 arg8 = temp8;
1967 }
1968 }
1969 }
1970 if (obj8) {
1971 {
1972 SWIG_Python_ConvertPtr(obj8, (void **)&arg9, SWIGTYPE_p_wxPalette, SWIG_POINTER_EXCEPTION | 0);
1973 if (SWIG_arg_fail(9)) SWIG_fail;
1974 if (arg9 == NULL) {
1975 SWIG_null_ref("wxPalette");
1976 }
1977 if (SWIG_arg_fail(9)) SWIG_fail;
1978 }
1979 }
1980 {
1981 if (!wxPyCheckForApp()) SWIG_fail;
1982 PyThreadState* __tstate = wxPyBeginAllowThreads();
1983 result = (wxGLCanvas *)new wxGLCanvas(arg1,(wxGLContext const *)arg2,arg3,(wxPoint const &)*arg4,(wxSize const &)*arg5,arg6,(wxString const &)*arg7,arg8,(wxPalette const &)*arg9);
1984
1985 wxPyEndAllowThreads(__tstate);
1986 if (PyErr_Occurred()) SWIG_fail;
1987 }
1988 resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_wxGLCanvas, 1);
1989 {
1990 if (temp7)
1991 delete arg7;
1992 }
1993 {
1994 delete [] arg8;
1995 }
1996 return resultobj;
1997 fail:
1998 {
1999 if (temp7)
2000 delete arg7;
2001 }
2002 {
2003 delete [] arg8;
2004 }
2005 return NULL;
2006 }
2007
2008
2009 static PyObject *_wrap_GLCanvas_SetCurrent(PyObject *, PyObject *args, PyObject *kwargs) {
2010 PyObject *resultobj;
2011 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2012 PyObject * obj0 = 0 ;
2013 char *kwnames[] = {
2014 (char *) "self", NULL
2015 };
2016
2017 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLCanvas_SetCurrent",kwnames,&obj0)) goto fail;
2018 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2019 if (SWIG_arg_fail(1)) SWIG_fail;
2020 {
2021 PyThreadState* __tstate = wxPyBeginAllowThreads();
2022 (arg1)->SetCurrent();
2023
2024 wxPyEndAllowThreads(__tstate);
2025 if (PyErr_Occurred()) SWIG_fail;
2026 }
2027 Py_INCREF(Py_None); resultobj = Py_None;
2028 return resultobj;
2029 fail:
2030 return NULL;
2031 }
2032
2033
2034 static PyObject *_wrap_GLCanvas_SetColour(PyObject *, PyObject *args, PyObject *kwargs) {
2035 PyObject *resultobj;
2036 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2037 wxString *arg2 = 0 ;
2038 bool temp2 = false ;
2039 PyObject * obj0 = 0 ;
2040 PyObject * obj1 = 0 ;
2041 char *kwnames[] = {
2042 (char *) "self",(char *) "colour", NULL
2043 };
2044
2045 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:GLCanvas_SetColour",kwnames,&obj0,&obj1)) goto fail;
2046 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2047 if (SWIG_arg_fail(1)) SWIG_fail;
2048 {
2049 arg2 = wxString_in_helper(obj1);
2050 if (arg2 == NULL) SWIG_fail;
2051 temp2 = true;
2052 }
2053 {
2054 PyThreadState* __tstate = wxPyBeginAllowThreads();
2055 (arg1)->SetColour((wxString const &)*arg2);
2056
2057 wxPyEndAllowThreads(__tstate);
2058 if (PyErr_Occurred()) SWIG_fail;
2059 }
2060 Py_INCREF(Py_None); resultobj = Py_None;
2061 {
2062 if (temp2)
2063 delete arg2;
2064 }
2065 return resultobj;
2066 fail:
2067 {
2068 if (temp2)
2069 delete arg2;
2070 }
2071 return NULL;
2072 }
2073
2074
2075 static PyObject *_wrap_GLCanvas_SwapBuffers(PyObject *, PyObject *args, PyObject *kwargs) {
2076 PyObject *resultobj;
2077 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2078 PyObject * obj0 = 0 ;
2079 char *kwnames[] = {
2080 (char *) "self", NULL
2081 };
2082
2083 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLCanvas_SwapBuffers",kwnames,&obj0)) goto fail;
2084 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2085 if (SWIG_arg_fail(1)) SWIG_fail;
2086 {
2087 PyThreadState* __tstate = wxPyBeginAllowThreads();
2088 (arg1)->SwapBuffers();
2089
2090 wxPyEndAllowThreads(__tstate);
2091 if (PyErr_Occurred()) SWIG_fail;
2092 }
2093 Py_INCREF(Py_None); resultobj = Py_None;
2094 return resultobj;
2095 fail:
2096 return NULL;
2097 }
2098
2099
2100 static PyObject *_wrap_GLCanvas_GetContext(PyObject *, PyObject *args, PyObject *kwargs) {
2101 PyObject *resultobj;
2102 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2103 wxGLContext *result;
2104 PyObject * obj0 = 0 ;
2105 char *kwnames[] = {
2106 (char *) "self", NULL
2107 };
2108
2109 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLCanvas_GetContext",kwnames,&obj0)) goto fail;
2110 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2111 if (SWIG_arg_fail(1)) SWIG_fail;
2112 {
2113 PyThreadState* __tstate = wxPyBeginAllowThreads();
2114 result = (wxGLContext *)(arg1)->GetContext();
2115
2116 wxPyEndAllowThreads(__tstate);
2117 if (PyErr_Occurred()) SWIG_fail;
2118 }
2119 resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_wxGLContext, 0);
2120 return resultobj;
2121 fail:
2122 return NULL;
2123 }
2124
2125
2126 static PyObject *_wrap_GLCanvas_SetupPixelFormat(PyObject *, PyObject *args, PyObject *kwargs) {
2127 PyObject *resultobj;
2128 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2129 int *arg2 = (int *) NULL ;
2130 int *temp2 ;
2131 PyObject * obj0 = 0 ;
2132 PyObject * obj1 = 0 ;
2133 char *kwnames[] = {
2134 (char *) "self",(char *) "attribList", NULL
2135 };
2136
2137 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:GLCanvas_SetupPixelFormat",kwnames,&obj0,&obj1)) goto fail;
2138 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2139 if (SWIG_arg_fail(1)) SWIG_fail;
2140 if (obj1) {
2141 {
2142 int i;
2143 if (PySequence_Check(obj1)) {
2144 int size = PyObject_Length(obj1);
2145 temp2 = new int[size+1]; // (int*)malloc((size + 1) * sizeof(int));
2146 for (i = 0; i < size; i++) {
2147 temp2[i] = PyInt_AsLong(PySequence_GetItem(obj1, i));
2148 }
2149 temp2[size] = 0;
2150 arg2 = temp2;
2151 }
2152 }
2153 }
2154 {
2155 PyThreadState* __tstate = wxPyBeginAllowThreads();
2156 (arg1)->SetupPixelFormat(arg2);
2157
2158 wxPyEndAllowThreads(__tstate);
2159 if (PyErr_Occurred()) SWIG_fail;
2160 }
2161 Py_INCREF(Py_None); resultobj = Py_None;
2162 {
2163 delete [] arg2;
2164 }
2165 return resultobj;
2166 fail:
2167 {
2168 delete [] arg2;
2169 }
2170 return NULL;
2171 }
2172
2173
2174 static PyObject *_wrap_GLCanvas_SetupPalette(PyObject *, PyObject *args, PyObject *kwargs) {
2175 PyObject *resultobj;
2176 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2177 wxPalette *arg2 = 0 ;
2178 PyObject * obj0 = 0 ;
2179 PyObject * obj1 = 0 ;
2180 char *kwnames[] = {
2181 (char *) "self",(char *) "palette", NULL
2182 };
2183
2184 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:GLCanvas_SetupPalette",kwnames,&obj0,&obj1)) goto fail;
2185 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2186 if (SWIG_arg_fail(1)) SWIG_fail;
2187 {
2188 SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_wxPalette, SWIG_POINTER_EXCEPTION | 0);
2189 if (SWIG_arg_fail(2)) SWIG_fail;
2190 if (arg2 == NULL) {
2191 SWIG_null_ref("wxPalette");
2192 }
2193 if (SWIG_arg_fail(2)) SWIG_fail;
2194 }
2195 {
2196 PyThreadState* __tstate = wxPyBeginAllowThreads();
2197 (arg1)->SetupPalette((wxPalette const &)*arg2);
2198
2199 wxPyEndAllowThreads(__tstate);
2200 if (PyErr_Occurred()) SWIG_fail;
2201 }
2202 Py_INCREF(Py_None); resultobj = Py_None;
2203 return resultobj;
2204 fail:
2205 return NULL;
2206 }
2207
2208
2209 static PyObject *_wrap_GLCanvas_CreateDefaultPalette(PyObject *, PyObject *args, PyObject *kwargs) {
2210 PyObject *resultobj;
2211 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2212 wxPalette result;
2213 PyObject * obj0 = 0 ;
2214 char *kwnames[] = {
2215 (char *) "self", NULL
2216 };
2217
2218 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLCanvas_CreateDefaultPalette",kwnames,&obj0)) goto fail;
2219 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2220 if (SWIG_arg_fail(1)) SWIG_fail;
2221 {
2222 PyThreadState* __tstate = wxPyBeginAllowThreads();
2223 result = (arg1)->CreateDefaultPalette();
2224
2225 wxPyEndAllowThreads(__tstate);
2226 if (PyErr_Occurred()) SWIG_fail;
2227 }
2228 {
2229 wxPalette * resultptr;
2230 resultptr = new wxPalette((wxPalette &)(result));
2231 resultobj = SWIG_NewPointerObj((void *)(resultptr), SWIGTYPE_p_wxPalette, 1);
2232 }
2233 return resultobj;
2234 fail:
2235 return NULL;
2236 }
2237
2238
2239 static PyObject *_wrap_GLCanvas_GetPalette(PyObject *, PyObject *args, PyObject *kwargs) {
2240 PyObject *resultobj;
2241 wxGLCanvas *arg1 = (wxGLCanvas *) 0 ;
2242 wxPalette *result;
2243 PyObject * obj0 = 0 ;
2244 char *kwnames[] = {
2245 (char *) "self", NULL
2246 };
2247
2248 if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:GLCanvas_GetPalette",kwnames,&obj0)) goto fail;
2249 SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_wxGLCanvas, SWIG_POINTER_EXCEPTION | 0);
2250 if (SWIG_arg_fail(1)) SWIG_fail;
2251 {
2252 PyThreadState* __tstate = wxPyBeginAllowThreads();
2253 result = (wxPalette *)(arg1)->GetPalette();
2254
2255 wxPyEndAllowThreads(__tstate);
2256 if (PyErr_Occurred()) SWIG_fail;
2257 }
2258 resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_wxPalette, 0);
2259 return resultobj;
2260 fail:
2261 return NULL;
2262 }
2263
2264
2265 static PyObject * GLCanvas_swigregister(PyObject *, PyObject *args) {
2266 PyObject *obj;
2267 if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
2268 SWIG_TypeClientData(SWIGTYPE_p_wxGLCanvas, obj);
2269 Py_INCREF(obj);
2270 return Py_BuildValue((char *)"");
2271 }
2272 static PyMethodDef SwigMethods[] = {
2273 { (char *)"new_GLContext", (PyCFunction) _wrap_new_GLContext, METH_VARARGS | METH_KEYWORDS, NULL},
2274 { (char *)"delete_GLContext", (PyCFunction) _wrap_delete_GLContext, METH_VARARGS | METH_KEYWORDS, NULL},
2275 { (char *)"GLContext_SetCurrent", (PyCFunction) _wrap_GLContext_SetCurrent, METH_VARARGS | METH_KEYWORDS, NULL},
2276 { (char *)"GLContext_SetColour", (PyCFunction) _wrap_GLContext_SetColour, METH_VARARGS | METH_KEYWORDS, NULL},
2277 { (char *)"GLContext_SwapBuffers", (PyCFunction) _wrap_GLContext_SwapBuffers, METH_VARARGS | METH_KEYWORDS, NULL},
2278 { (char *)"GLContext_GetWindow", (PyCFunction) _wrap_GLContext_GetWindow, METH_VARARGS | METH_KEYWORDS, NULL},
2279 { (char *)"GLContext_swigregister", GLContext_swigregister, METH_VARARGS, NULL},
2280 { (char *)"new_GLCanvas", (PyCFunction) _wrap_new_GLCanvas, METH_VARARGS | METH_KEYWORDS, NULL},
2281 { (char *)"new_GLCanvasWithContext", (PyCFunction) _wrap_new_GLCanvasWithContext, METH_VARARGS | METH_KEYWORDS, NULL},
2282 { (char *)"GLCanvas_SetCurrent", (PyCFunction) _wrap_GLCanvas_SetCurrent, METH_VARARGS | METH_KEYWORDS, NULL},
2283 { (char *)"GLCanvas_SetColour", (PyCFunction) _wrap_GLCanvas_SetColour, METH_VARARGS | METH_KEYWORDS, NULL},
2284 { (char *)"GLCanvas_SwapBuffers", (PyCFunction) _wrap_GLCanvas_SwapBuffers, METH_VARARGS | METH_KEYWORDS, NULL},
2285 { (char *)"GLCanvas_GetContext", (PyCFunction) _wrap_GLCanvas_GetContext, METH_VARARGS | METH_KEYWORDS, NULL},
2286 { (char *)"GLCanvas_SetupPixelFormat", (PyCFunction) _wrap_GLCanvas_SetupPixelFormat, METH_VARARGS | METH_KEYWORDS, NULL},
2287 { (char *)"GLCanvas_SetupPalette", (PyCFunction) _wrap_GLCanvas_SetupPalette, METH_VARARGS | METH_KEYWORDS, NULL},
2288 { (char *)"GLCanvas_CreateDefaultPalette", (PyCFunction) _wrap_GLCanvas_CreateDefaultPalette, METH_VARARGS | METH_KEYWORDS, NULL},
2289 { (char *)"GLCanvas_GetPalette", (PyCFunction) _wrap_GLCanvas_GetPalette, METH_VARARGS | METH_KEYWORDS, NULL},
2290 { (char *)"GLCanvas_swigregister", GLCanvas_swigregister, METH_VARARGS, NULL},
2291 { NULL, NULL, 0, NULL }
2292 };
2293
2294
2295 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
2296
2297 static void *_p_wxLayoutConstraintsTo_p_wxObject(void *x) {
2298 return (void *)((wxObject *) ((wxLayoutConstraints *) x));
2299 }
2300 static void *_p_wxGBSizerItemTo_p_wxObject(void *x) {
2301 return (void *)((wxObject *) (wxSizerItem *) ((wxGBSizerItem *) x));
2302 }
2303 static void *_p_wxSizerItemTo_p_wxObject(void *x) {
2304 return (void *)((wxObject *) ((wxSizerItem *) x));
2305 }
2306 static void *_p_wxScrollEventTo_p_wxObject(void *x) {
2307 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxScrollEvent *) x));
2308 }
2309 static void *_p_wxIndividualLayoutConstraintTo_p_wxObject(void *x) {
2310 return (void *)((wxObject *) ((wxIndividualLayoutConstraint *) x));
2311 }
2312 static void *_p_wxStaticBoxSizerTo_p_wxObject(void *x) {
2313 return (void *)((wxObject *) (wxSizer *)(wxBoxSizer *) ((wxStaticBoxSizer *) x));
2314 }
2315 static void *_p_wxBoxSizerTo_p_wxObject(void *x) {
2316 return (void *)((wxObject *) (wxSizer *) ((wxBoxSizer *) x));
2317 }
2318 static void *_p_wxSizerTo_p_wxObject(void *x) {
2319 return (void *)((wxObject *) ((wxSizer *) x));
2320 }
2321 static void *_p_wxGridBagSizerTo_p_wxObject(void *x) {
2322 return (void *)((wxObject *) (wxSizer *)(wxGridSizer *)(wxFlexGridSizer *) ((wxGridBagSizer *) x));
2323 }
2324 static void *_p_wxUpdateUIEventTo_p_wxObject(void *x) {
2325 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxUpdateUIEvent *) x));
2326 }
2327 static void *_p_wxEventTo_p_wxObject(void *x) {
2328 return (void *)((wxObject *) ((wxEvent *) x));
2329 }
2330 static void *_p_wxFlexGridSizerTo_p_wxObject(void *x) {
2331 return (void *)((wxObject *) (wxSizer *)(wxGridSizer *) ((wxFlexGridSizer *) x));
2332 }
2333 static void *_p_wxGridSizerTo_p_wxObject(void *x) {
2334 return (void *)((wxObject *) (wxSizer *) ((wxGridSizer *) x));
2335 }
2336 static void *_p_wxInitDialogEventTo_p_wxObject(void *x) {
2337 return (void *)((wxObject *) (wxEvent *) ((wxInitDialogEvent *) x));
2338 }
2339 static void *_p_wxPaintEventTo_p_wxObject(void *x) {
2340 return (void *)((wxObject *) (wxEvent *) ((wxPaintEvent *) x));
2341 }
2342 static void *_p_wxNcPaintEventTo_p_wxObject(void *x) {
2343 return (void *)((wxObject *) (wxEvent *) ((wxNcPaintEvent *) x));
2344 }
2345 static void *_p_wxPaletteChangedEventTo_p_wxObject(void *x) {
2346 return (void *)((wxObject *) (wxEvent *) ((wxPaletteChangedEvent *) x));
2347 }
2348 static void *_p_wxDisplayChangedEventTo_p_wxObject(void *x) {
2349 return (void *)((wxObject *) (wxEvent *) ((wxDisplayChangedEvent *) x));
2350 }
2351 static void *_p_wxMouseCaptureChangedEventTo_p_wxObject(void *x) {
2352 return (void *)((wxObject *) (wxEvent *) ((wxMouseCaptureChangedEvent *) x));
2353 }
2354 static void *_p_wxSysColourChangedEventTo_p_wxObject(void *x) {
2355 return (void *)((wxObject *) (wxEvent *) ((wxSysColourChangedEvent *) x));
2356 }
2357 static void *_p_wxControlTo_p_wxObject(void *x) {
2358 return (void *)((wxObject *) (wxEvtHandler *)(wxWindow *) ((wxControl *) x));
2359 }
2360 static void *_p_wxSetCursorEventTo_p_wxObject(void *x) {
2361 return (void *)((wxObject *) (wxEvent *) ((wxSetCursorEvent *) x));
2362 }
2363 static void *_p_wxFSFileTo_p_wxObject(void *x) {
2364 return (void *)((wxObject *) ((wxFSFile *) x));
2365 }
2366 static void *_p_wxPySizerTo_p_wxObject(void *x) {
2367 return (void *)((wxObject *) (wxSizer *) ((wxPySizer *) x));
2368 }
2369 static void *_p_wxPyEventTo_p_wxObject(void *x) {
2370 return (void *)((wxObject *) (wxEvent *) ((wxPyEvent *) x));
2371 }
2372 static void *_p_wxNotifyEventTo_p_wxObject(void *x) {
2373 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxNotifyEvent *) x));
2374 }
2375 static void *_p_wxGLContextTo_p_wxObject(void *x) {
2376 return (void *)((wxObject *) ((wxGLContext *) x));
2377 }
2378 static void *_p_wxShowEventTo_p_wxObject(void *x) {
2379 return (void *)((wxObject *) (wxEvent *) ((wxShowEvent *) x));
2380 }
2381 static void *_p_wxMenuItemTo_p_wxObject(void *x) {
2382 return (void *)((wxObject *) ((wxMenuItem *) x));
2383 }
2384 static void *_p_wxDateEventTo_p_wxObject(void *x) {
2385 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxDateEvent *) x));
2386 }
2387 static void *_p_wxIdleEventTo_p_wxObject(void *x) {
2388 return (void *)((wxObject *) (wxEvent *) ((wxIdleEvent *) x));
2389 }
2390 static void *_p_wxWindowCreateEventTo_p_wxObject(void *x) {
2391 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxWindowCreateEvent *) x));
2392 }
2393 static void *_p_wxQueryNewPaletteEventTo_p_wxObject(void *x) {
2394 return (void *)((wxObject *) (wxEvent *) ((wxQueryNewPaletteEvent *) x));
2395 }
2396 static void *_p_wxMaximizeEventTo_p_wxObject(void *x) {
2397 return (void *)((wxObject *) (wxEvent *) ((wxMaximizeEvent *) x));
2398 }
2399 static void *_p_wxIconizeEventTo_p_wxObject(void *x) {
2400 return (void *)((wxObject *) (wxEvent *) ((wxIconizeEvent *) x));
2401 }
2402 static void *_p_wxSizeEventTo_p_wxObject(void *x) {
2403 return (void *)((wxObject *) (wxEvent *) ((wxSizeEvent *) x));
2404 }
2405 static void *_p_wxMoveEventTo_p_wxObject(void *x) {
2406 return (void *)((wxObject *) (wxEvent *) ((wxMoveEvent *) x));
2407 }
2408 static void *_p_wxActivateEventTo_p_wxObject(void *x) {
2409 return (void *)((wxObject *) (wxEvent *) ((wxActivateEvent *) x));
2410 }
2411 static void *_p_wxXPMHandlerTo_p_wxObject(void *x) {
2412 return (void *)((wxObject *) (wxImageHandler *) ((wxXPMHandler *) x));
2413 }
2414 static void *_p_wxPNMHandlerTo_p_wxObject(void *x) {
2415 return (void *)((wxObject *) (wxImageHandler *) ((wxPNMHandler *) x));
2416 }
2417 static void *_p_wxJPEGHandlerTo_p_wxObject(void *x) {
2418 return (void *)((wxObject *) (wxImageHandler *) ((wxJPEGHandler *) x));
2419 }
2420 static void *_p_wxPCXHandlerTo_p_wxObject(void *x) {
2421 return (void *)((wxObject *) (wxImageHandler *) ((wxPCXHandler *) x));
2422 }
2423 static void *_p_wxGIFHandlerTo_p_wxObject(void *x) {
2424 return (void *)((wxObject *) (wxImageHandler *) ((wxGIFHandler *) x));
2425 }
2426 static void *_p_wxPNGHandlerTo_p_wxObject(void *x) {
2427 return (void *)((wxObject *) (wxImageHandler *) ((wxPNGHandler *) x));
2428 }
2429 static void *_p_wxANIHandlerTo_p_wxObject(void *x) {
2430 return (void *)((wxObject *) (wxImageHandler *)(wxBMPHandler *)(wxICOHandler *)(wxCURHandler *) ((wxANIHandler *) x));
2431 }
2432 static void *_p_wxCURHandlerTo_p_wxObject(void *x) {
2433 return (void *)((wxObject *) (wxImageHandler *)(wxBMPHandler *)(wxICOHandler *) ((wxCURHandler *) x));
2434 }
2435 static void *_p_wxICOHandlerTo_p_wxObject(void *x) {
2436 return (void *)((wxObject *) (wxImageHandler *)(wxBMPHandler *) ((wxICOHandler *) x));
2437 }
2438 static void *_p_wxBMPHandlerTo_p_wxObject(void *x) {
2439 return (void *)((wxObject *) (wxImageHandler *) ((wxBMPHandler *) x));
2440 }
2441 static void *_p_wxImageHandlerTo_p_wxObject(void *x) {
2442 return (void *)((wxObject *) ((wxImageHandler *) x));
2443 }
2444 static void *_p_wxTIFFHandlerTo_p_wxObject(void *x) {
2445 return (void *)((wxObject *) (wxImageHandler *) ((wxTIFFHandler *) x));
2446 }
2447 static void *_p_wxEvtHandlerTo_p_wxObject(void *x) {
2448 return (void *)((wxObject *) ((wxEvtHandler *) x));
2449 }
2450 static void *_p_wxGLCanvasTo_p_wxObject(void *x) {
2451 return (void *)((wxObject *) (wxEvtHandler *)(wxWindow *) ((wxGLCanvas *) x));
2452 }
2453 static void *_p_wxStdDialogButtonSizerTo_p_wxObject(void *x) {
2454 return (void *)((wxObject *) (wxSizer *)(wxBoxSizer *) ((wxStdDialogButtonSizer *) x));
2455 }
2456 static void *_p_wxAcceleratorTableTo_p_wxObject(void *x) {
2457 return (void *)((wxObject *) ((wxAcceleratorTable *) x));
2458 }
2459 static void *_p_wxImageTo_p_wxObject(void *x) {
2460 return (void *)((wxObject *) ((wxImage *) x));
2461 }
2462 static void *_p_wxScrollWinEventTo_p_wxObject(void *x) {
2463 return (void *)((wxObject *) (wxEvent *) ((wxScrollWinEvent *) x));
2464 }
2465 static void *_p_wxWindowDestroyEventTo_p_wxObject(void *x) {
2466 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxWindowDestroyEvent *) x));
2467 }
2468 static void *_p_wxNavigationKeyEventTo_p_wxObject(void *x) {
2469 return (void *)((wxObject *) (wxEvent *) ((wxNavigationKeyEvent *) x));
2470 }
2471 static void *_p_wxKeyEventTo_p_wxObject(void *x) {
2472 return (void *)((wxObject *) (wxEvent *) ((wxKeyEvent *) x));
2473 }
2474 static void *_p_wxWindowTo_p_wxObject(void *x) {
2475 return (void *)((wxObject *) (wxEvtHandler *) ((wxWindow *) x));
2476 }
2477 static void *_p_wxMenuTo_p_wxObject(void *x) {
2478 return (void *)((wxObject *) (wxEvtHandler *) ((wxMenu *) x));
2479 }
2480 static void *_p_wxMenuBarTo_p_wxObject(void *x) {
2481 return (void *)((wxObject *) (wxEvtHandler *)(wxWindow *) ((wxMenuBar *) x));
2482 }
2483 static void *_p_wxFileSystemTo_p_wxObject(void *x) {
2484 return (void *)((wxObject *) ((wxFileSystem *) x));
2485 }
2486 static void *_p_wxContextMenuEventTo_p_wxObject(void *x) {
2487 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxContextMenuEvent *) x));
2488 }
2489 static void *_p_wxMenuEventTo_p_wxObject(void *x) {
2490 return (void *)((wxObject *) (wxEvent *) ((wxMenuEvent *) x));
2491 }
2492 static void *_p_wxPyAppTo_p_wxObject(void *x) {
2493 return (void *)((wxObject *) (wxEvtHandler *) ((wxPyApp *) x));
2494 }
2495 static void *_p_wxCloseEventTo_p_wxObject(void *x) {
2496 return (void *)((wxObject *) (wxEvent *) ((wxCloseEvent *) x));
2497 }
2498 static void *_p_wxMouseEventTo_p_wxObject(void *x) {
2499 return (void *)((wxObject *) (wxEvent *) ((wxMouseEvent *) x));
2500 }
2501 static void *_p_wxEraseEventTo_p_wxObject(void *x) {
2502 return (void *)((wxObject *) (wxEvent *) ((wxEraseEvent *) x));
2503 }
2504 static void *_p_wxPyCommandEventTo_p_wxObject(void *x) {
2505 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxPyCommandEvent *) x));
2506 }
2507 static void *_p_wxCommandEventTo_p_wxObject(void *x) {
2508 return (void *)((wxObject *) (wxEvent *) ((wxCommandEvent *) x));
2509 }
2510 static void *_p_wxDropFilesEventTo_p_wxObject(void *x) {
2511 return (void *)((wxObject *) (wxEvent *) ((wxDropFilesEvent *) x));
2512 }
2513 static void *_p_wxFocusEventTo_p_wxObject(void *x) {
2514 return (void *)((wxObject *) (wxEvent *) ((wxFocusEvent *) x));
2515 }
2516 static void *_p_wxChildFocusEventTo_p_wxObject(void *x) {
2517 return (void *)((wxObject *) (wxEvent *)(wxCommandEvent *) ((wxChildFocusEvent *) x));
2518 }
2519 static void *_p_wxControlWithItemsTo_p_wxObject(void *x) {
2520 return (void *)((wxObject *) (wxEvtHandler *)(wxWindow *)(wxControl *) ((wxControlWithItems *) x));
2521 }
2522 static void *_p_wxPyValidatorTo_p_wxObject(void *x) {
2523 return (void *)((wxObject *) (wxEvtHandler *)(wxValidator *) ((wxPyValidator *) x));
2524 }
2525 static void *_p_wxValidatorTo_p_wxObject(void *x) {
2526 return (void *)((wxObject *) (wxEvtHandler *) ((wxValidator *) x));
2527 }
2528 static void *_p_wxControlTo_p_wxWindow(void *x) {
2529 return (void *)((wxWindow *) ((wxControl *) x));
2530 }
2531 static void *_p_wxControlWithItemsTo_p_wxWindow(void *x) {
2532 return (void *)((wxWindow *) (wxControl *) ((wxControlWithItems *) x));
2533 }
2534 static void *_p_wxMenuBarTo_p_wxWindow(void *x) {
2535 return (void *)((wxWindow *) ((wxMenuBar *) x));
2536 }
2537 static void *_p_wxGLCanvasTo_p_wxWindow(void *x) {
2538 return (void *)((wxWindow *) ((wxGLCanvas *) x));
2539 }
2540 static void *_p_wxControlTo_p_wxEvtHandler(void *x) {
2541 return (void *)((wxEvtHandler *) (wxWindow *) ((wxControl *) x));
2542 }
2543 static void *_p_wxWindowTo_p_wxEvtHandler(void *x) {
2544 return (void *)((wxEvtHandler *) ((wxWindow *) x));
2545 }
2546 static void *_p_wxControlWithItemsTo_p_wxEvtHandler(void *x) {
2547 return (void *)((wxEvtHandler *) (wxWindow *)(wxControl *) ((wxControlWithItems *) x));
2548 }
2549 static void *_p_wxPyAppTo_p_wxEvtHandler(void *x) {
2550 return (void *)((wxEvtHandler *) ((wxPyApp *) x));
2551 }
2552 static void *_p_wxValidatorTo_p_wxEvtHandler(void *x) {
2553 return (void *)((wxEvtHandler *) ((wxValidator *) x));
2554 }
2555 static void *_p_wxPyValidatorTo_p_wxEvtHandler(void *x) {
2556 return (void *)((wxEvtHandler *) (wxValidator *) ((wxPyValidator *) x));
2557 }
2558 static void *_p_wxMenuBarTo_p_wxEvtHandler(void *x) {
2559 return (void *)((wxEvtHandler *) (wxWindow *) ((wxMenuBar *) x));
2560 }
2561 static void *_p_wxGLCanvasTo_p_wxEvtHandler(void *x) {
2562 return (void *)((wxEvtHandler *) (wxWindow *) ((wxGLCanvas *) x));
2563 }
2564 static void *_p_wxMenuTo_p_wxEvtHandler(void *x) {
2565 return (void *)((wxEvtHandler *) ((wxMenu *) x));
2566 }
2567 static swig_type_info _swigt__p_wxGLCanvas[] = {{"_p_wxGLCanvas", 0, "wxGLCanvas *", 0, 0, 0, 0},{"_p_wxGLCanvas", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2568 static swig_type_info _swigt__p_wxObject[] = {{"_p_wxObject", 0, "wxObject *", 0, 0, 0, 0},{"_p_wxLayoutConstraints", _p_wxLayoutConstraintsTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxGBSizerItem", _p_wxGBSizerItemTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxSizerItem", _p_wxSizerItemTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxScrollEvent", _p_wxScrollEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxIndividualLayoutConstraint", _p_wxIndividualLayoutConstraintTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxStaticBoxSizer", _p_wxStaticBoxSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxBoxSizer", _p_wxBoxSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxSizer", _p_wxSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxGridBagSizer", _p_wxGridBagSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxUpdateUIEvent", _p_wxUpdateUIEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMenu", _p_wxMenuTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxEvent", _p_wxEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxGridSizer", _p_wxGridSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxFlexGridSizer", _p_wxFlexGridSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxInitDialogEvent", _p_wxInitDialogEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPaintEvent", _p_wxPaintEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxNcPaintEvent", _p_wxNcPaintEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPaletteChangedEvent", _p_wxPaletteChangedEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxDisplayChangedEvent", _p_wxDisplayChangedEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMouseCaptureChangedEvent", _p_wxMouseCaptureChangedEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxSysColourChangedEvent", _p_wxSysColourChangedEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxControl", _p_wxControlTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxSetCursorEvent", _p_wxSetCursorEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxFSFile", _p_wxFSFileTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPySizer", _p_wxPySizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPyEvent", _p_wxPyEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxNotifyEvent", _p_wxNotifyEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxGLContext", _p_wxGLContextTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxShowEvent", _p_wxShowEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMenuItem", _p_wxMenuItemTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxQueryNewPaletteEvent", _p_wxQueryNewPaletteEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxWindowCreateEvent", _p_wxWindowCreateEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxIdleEvent", _p_wxIdleEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxDateEvent", _p_wxDateEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMaximizeEvent", _p_wxMaximizeEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxIconizeEvent", _p_wxIconizeEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxActivateEvent", _p_wxActivateEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMoveEvent", _p_wxMoveEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxSizeEvent", _p_wxSizeEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxXPMHandler", _p_wxXPMHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPNMHandler", _p_wxPNMHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxJPEGHandler", _p_wxJPEGHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPCXHandler", _p_wxPCXHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxGIFHandler", _p_wxGIFHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPNGHandler", _p_wxPNGHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxANIHandler", _p_wxANIHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxCURHandler", _p_wxCURHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxICOHandler", _p_wxICOHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxBMPHandler", _p_wxBMPHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxImageHandler", _p_wxImageHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxTIFFHandler", _p_wxTIFFHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxEvtHandler", _p_wxEvtHandlerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxGLCanvas", _p_wxGLCanvasTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxStdDialogButtonSizer", _p_wxStdDialogButtonSizerTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxAcceleratorTable", _p_wxAcceleratorTableTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxImage", _p_wxImageTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxScrollWinEvent", _p_wxScrollWinEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxObject", 0, 0, 0, 0, 0, 0},{"_p_wxWindowDestroyEvent", _p_wxWindowDestroyEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxNavigationKeyEvent", _p_wxNavigationKeyEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxKeyEvent", _p_wxKeyEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxWindow", _p_wxWindowTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMenuBar", _p_wxMenuBarTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxFileSystem", _p_wxFileSystemTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxContextMenuEvent", _p_wxContextMenuEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMenuEvent", _p_wxMenuEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPyApp", _p_wxPyAppTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxCloseEvent", _p_wxCloseEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxMouseEvent", _p_wxMouseEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxEraseEvent", _p_wxEraseEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxCommandEvent", _p_wxCommandEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPyCommandEvent", _p_wxPyCommandEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxFocusEvent", _p_wxFocusEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxDropFilesEvent", _p_wxDropFilesEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxChildFocusEvent", _p_wxChildFocusEventTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxControlWithItems", _p_wxControlWithItemsTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxPyValidator", _p_wxPyValidatorTo_p_wxObject, 0, 0, 0, 0, 0},{"_p_wxValidator", _p_wxValidatorTo_p_wxObject, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2569 static swig_type_info _swigt__p_unsigned_char[] = {{"_p_unsigned_char", 0, "unsigned char *|byte *", 0, 0, 0, 0},{"_p_unsigned_char", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2570 static swig_type_info _swigt__p_wxGLContext[] = {{"_p_wxGLContext", 0, "wxGLContext *", 0, 0, 0, 0},{"_p_wxGLContext", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2571 static swig_type_info _swigt__p_wxWindow[] = {{"_p_wxWindow", 0, "wxWindow *", 0, 0, 0, 0},{"_p_wxControl", _p_wxControlTo_p_wxWindow, 0, 0, 0, 0, 0},{"_p_wxWindow", 0, 0, 0, 0, 0, 0},{"_p_wxControlWithItems", _p_wxControlWithItemsTo_p_wxWindow, 0, 0, 0, 0, 0},{"_p_wxMenuBar", _p_wxMenuBarTo_p_wxWindow, 0, 0, 0, 0, 0},{"_p_wxGLCanvas", _p_wxGLCanvasTo_p_wxWindow, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2572 static swig_type_info _swigt__p_unsigned_long[] = {{"_p_unsigned_long", 0, "unsigned long *|wxUIntPtr *", 0, 0, 0, 0},{"_p_unsigned_long", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2573 static swig_type_info _swigt__p_form_ops_t[] = {{"_p_form_ops_t", 0, "enum form_ops_t *|form_ops_t *", 0, 0, 0, 0},{"_p_form_ops_t", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2574 static swig_type_info _swigt__p_unsigned_int[] = {{"_p_unsigned_int", 0, "unsigned int *|time_t *", 0, 0, 0, 0},{"_p_unsigned_int", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2575 static swig_type_info _swigt__unsigned_int[] = {{"_unsigned_int", 0, "unsigned int|std::size_t", 0, 0, 0, 0},{"_unsigned_int", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2576 static swig_type_info _swigt__p_wxDuplexMode[] = {{"_p_wxDuplexMode", 0, "enum wxDuplexMode *|wxDuplexMode *", 0, 0, 0, 0},{"_p_wxDuplexMode", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2577 static swig_type_info _swigt__p_char[] = {{"_p_char", 0, "char *", 0, 0, 0, 0},{"_p_char", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2578 static swig_type_info _swigt__p_wxEvtHandler[] = {{"_p_wxEvtHandler", 0, "wxEvtHandler *", 0, 0, 0, 0},{"_p_wxControl", _p_wxControlTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxWindow", _p_wxWindowTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxControlWithItems", _p_wxControlWithItemsTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxEvtHandler", 0, 0, 0, 0, 0, 0},{"_p_wxPyApp", _p_wxPyAppTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxMenuBar", _p_wxMenuBarTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxGLCanvas", _p_wxGLCanvasTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxValidator", _p_wxValidatorTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxPyValidator", _p_wxPyValidatorTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{"_p_wxMenu", _p_wxMenuTo_p_wxEvtHandler, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2579 static swig_type_info _swigt__p_wxPalette[] = {{"_p_wxPalette", 0, "wxPalette *", 0, 0, 0, 0},{"_p_wxPalette", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2580 static swig_type_info _swigt__std__ptrdiff_t[] = {{"_std__ptrdiff_t", 0, "std::ptrdiff_t", 0, 0, 0, 0},{"_std__ptrdiff_t", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2581 static swig_type_info _swigt__ptrdiff_t[] = {{"_ptrdiff_t", 0, "ptrdiff_t", 0, 0, 0, 0},{"_ptrdiff_t", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2582 static swig_type_info _swigt__p_wxPaperSize[] = {{"_p_wxPaperSize", 0, "enum wxPaperSize *|wxPaperSize *", 0, 0, 0, 0},{"_p_wxPaperSize", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2583 static swig_type_info _swigt__p_int[] = {{"_p_int", 0, "int *", 0, 0, 0, 0},{"_p_int", 0, 0, 0, 0, 0, 0},{0, 0, 0, 0, 0, 0, 0}};
2584
2585 static swig_type_info *swig_types_initial[] = {
2586 _swigt__p_wxGLCanvas,
2587 _swigt__p_wxObject,
2588 _swigt__p_unsigned_char,
2589 _swigt__p_wxGLContext,
2590 _swigt__p_wxWindow,
2591 _swigt__p_unsigned_long,
2592 _swigt__p_form_ops_t,
2593 _swigt__p_unsigned_int,
2594 _swigt__unsigned_int,
2595 _swigt__p_wxDuplexMode,
2596 _swigt__p_char,
2597 _swigt__p_wxEvtHandler,
2598 _swigt__p_wxPalette,
2599 _swigt__std__ptrdiff_t,
2600 _swigt__ptrdiff_t,
2601 _swigt__p_wxPaperSize,
2602 _swigt__p_int,
2603 0
2604 };
2605
2606
2607 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */
2608
2609 static swig_const_info swig_const_table[] = {
2610 {0, 0, 0, 0.0, 0, 0}};
2611
2612 #ifdef __cplusplus
2613 }
2614 #endif
2615
2616
2617 #ifdef __cplusplus
2618 extern "C" {
2619 #endif
2620
2621 /* Python-specific SWIG API */
2622 #define SWIG_newvarlink() SWIG_Python_newvarlink()
2623 #define SWIG_addvarlink(p, name, get_attr, set_attr) SWIG_Python_addvarlink(p, name, get_attr, set_attr)
2624 #define SWIG_InstallConstants(d, constants) SWIG_Python_InstallConstants(d, constants)
2625
2626 /* -----------------------------------------------------------------------------
2627 * global variable support code.
2628 * ----------------------------------------------------------------------------- */
2629
2630 typedef struct swig_globalvar {
2631 char *name; /* Name of global variable */
2632 PyObject *(*get_attr)(); /* Return the current value */
2633 int (*set_attr)(PyObject *); /* Set the value */
2634 struct swig_globalvar *next;
2635 } swig_globalvar;
2636
2637 typedef struct swig_varlinkobject {
2638 PyObject_HEAD
2639 swig_globalvar *vars;
2640 } swig_varlinkobject;
2641
2642 static PyObject *
2643 swig_varlink_repr(swig_varlinkobject *v) {
2644 v = v;
2645 return PyString_FromString("<Swig global variables>");
2646 }
2647
2648 static int
2649 swig_varlink_print(swig_varlinkobject *v, FILE *fp, int flags) {
2650 swig_globalvar *var;
2651 flags = flags;
2652 fprintf(fp,"Swig global variables { ");
2653 for (var = v->vars; var; var=var->next) {
2654 fprintf(fp,"%s", var->name);
2655 if (var->next) fprintf(fp,", ");
2656 }
2657 fprintf(fp," }\n");
2658 return 0;
2659 }
2660
2661 static PyObject *
2662 swig_varlink_getattr(swig_varlinkobject *v, char *n) {
2663 swig_globalvar *var = v->vars;
2664 while (var) {
2665 if (strcmp(var->name,n) == 0) {
2666 return (*var->get_attr)();
2667 }
2668 var = var->next;
2669 }
2670 PyErr_SetString(PyExc_NameError,"Unknown C global variable");
2671 return NULL;
2672 }
2673
2674 static int
2675 swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
2676 swig_globalvar *var = v->vars;
2677 while (var) {
2678 if (strcmp(var->name,n) == 0) {
2679 return (*var->set_attr)(p);
2680 }
2681 var = var->next;
2682 }
2683 PyErr_SetString(PyExc_NameError,"Unknown C global variable");
2684 return 1;
2685 }
2686
2687 static PyTypeObject varlinktype = {
2688 PyObject_HEAD_INIT(0)
2689 0, /* Number of items in variable part (ob_size) */
2690 (char *)"swigvarlink", /* Type name (tp_name) */
2691 sizeof(swig_varlinkobject), /* Basic size (tp_basicsize) */
2692 0, /* Itemsize (tp_itemsize) */
2693 0, /* Deallocator (tp_dealloc) */
2694 (printfunc) swig_varlink_print, /* Print (tp_print) */
2695 (getattrfunc) swig_varlink_getattr, /* get attr (tp_getattr) */
2696 (setattrfunc) swig_varlink_setattr, /* Set attr (tp_setattr) */
2697 0, /* tp_compare */
2698 (reprfunc) swig_varlink_repr, /* tp_repr */
2699 0, /* tp_as_number */
2700 0, /* tp_as_sequence */
2701 0, /* tp_as_mapping */
2702 0, /* tp_hash */
2703 0, /* tp_call */
2704 0, /* tp_str */
2705 0, /* tp_getattro */
2706 0, /* tp_setattro */
2707 0, /* tp_as_buffer */
2708 0, /* tp_flags */
2709 0, /* tp_doc */
2710 #if PY_VERSION_HEX >= 0x02000000
2711 0, /* tp_traverse */
2712 0, /* tp_clear */
2713 #endif
2714 #if PY_VERSION_HEX >= 0x02010000
2715 0, /* tp_richcompare */
2716 0, /* tp_weaklistoffset */
2717 #endif
2718 #if PY_VERSION_HEX >= 0x02020000
2719 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
2720 #endif
2721 #if PY_VERSION_HEX >= 0x02030000
2722 0, /* tp_del */
2723 #endif
2724 #ifdef COUNT_ALLOCS
2725 0,0,0,0 /* tp_alloc -> tp_next */
2726 #endif
2727 };
2728
2729 /* Create a variable linking object for use later */
2730 static PyObject *
2731 SWIG_Python_newvarlink(void) {
2732 swig_varlinkobject *result = 0;
2733 result = PyMem_NEW(swig_varlinkobject,1);
2734 varlinktype.ob_type = &PyType_Type; /* Patch varlinktype into a PyType */
2735 result->ob_type = &varlinktype;
2736 result->vars = 0;
2737 result->ob_refcnt = 0;
2738 Py_XINCREF((PyObject *) result);
2739 return ((PyObject*) result);
2740 }
2741
2742 static void
2743 SWIG_Python_addvarlink(PyObject *p, char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
2744 swig_varlinkobject *v;
2745 swig_globalvar *gv;
2746 v= (swig_varlinkobject *) p;
2747 gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
2748 gv->name = (char *) malloc(strlen(name)+1);
2749 strcpy(gv->name,name);
2750 gv->get_attr = get_attr;
2751 gv->set_attr = set_attr;
2752 gv->next = v->vars;
2753 v->vars = gv;
2754 }
2755
2756 /* -----------------------------------------------------------------------------
2757 * constants/methods manipulation
2758 * ----------------------------------------------------------------------------- */
2759
2760 /* Install Constants */
2761 static void
2762 SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]) {
2763 PyObject *obj = 0;
2764 size_t i;
2765 for (i = 0; constants[i].type; i++) {
2766 switch(constants[i].type) {
2767 case SWIG_PY_INT:
2768 obj = PyInt_FromLong(constants[i].lvalue);
2769 break;
2770 case SWIG_PY_FLOAT:
2771 obj = PyFloat_FromDouble(constants[i].dvalue);
2772 break;
2773 case SWIG_PY_STRING:
2774 if (constants[i].pvalue) {
2775 obj = PyString_FromString((char *) constants[i].pvalue);
2776 } else {
2777 Py_INCREF(Py_None);
2778 obj = Py_None;
2779 }
2780 break;
2781 case SWIG_PY_POINTER:
2782 obj = SWIG_NewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
2783 break;
2784 case SWIG_PY_BINARY:
2785 obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
2786 break;
2787 default:
2788 obj = 0;
2789 break;
2790 }
2791 if (obj) {
2792 PyDict_SetItemString(d,constants[i].name,obj);
2793 Py_DECREF(obj);
2794 }
2795 }
2796 }
2797
2798 /* -----------------------------------------------------------------------------*/
2799 /* Fix SwigMethods to carry the callback ptrs when needed */
2800 /* -----------------------------------------------------------------------------*/
2801
2802 static void
2803 SWIG_Python_FixMethods(PyMethodDef *methods,
2804 swig_const_info *const_table,
2805 swig_type_info **types,
2806 swig_type_info **types_initial) {
2807 size_t i;
2808 for (i = 0; methods[i].ml_name; ++i) {
2809 char *c = methods[i].ml_doc;
2810 if (c && (c = strstr(c, "swig_ptr: "))) {
2811 int j;
2812 swig_const_info *ci = 0;
2813 char *name = c + 10;
2814 for (j = 0; const_table[j].type; j++) {
2815 if (strncmp(const_table[j].name, name,
2816 strlen(const_table[j].name)) == 0) {
2817 ci = &(const_table[j]);
2818 break;
2819 }
2820 }
2821 if (ci) {
2822 size_t shift = (ci->ptype) - types;
2823 swig_type_info *ty = types_initial[shift];
2824 size_t ldoc = (c - methods[i].ml_doc);
2825 size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
2826 char *ndoc = (char*)malloc(ldoc + lptr + 10);
2827 char *buff = ndoc;
2828 void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue: (void *)(ci->lvalue);
2829 strncpy(buff, methods[i].ml_doc, ldoc);
2830 buff += ldoc;
2831 strncpy(buff, "swig_ptr: ", 10);
2832 buff += 10;
2833 SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
2834 methods[i].ml_doc = ndoc;
2835 }
2836 }
2837 }
2838 }
2839
2840 /* -----------------------------------------------------------------------------*
2841 * Initialize type list
2842 * -----------------------------------------------------------------------------*/
2843
2844 #if PY_MAJOR_VERSION < 2
2845 /* PyModule_AddObject function was introduced in Python 2.0. The following function
2846 is copied out of Python/modsupport.c in python version 2.3.4 */
2847 static int
2848 PyModule_AddObject(PyObject *m, char *name, PyObject *o)
2849 {
2850 PyObject *dict;
2851 if (!PyModule_Check(m)) {
2852 PyErr_SetString(PyExc_TypeError,
2853 "PyModule_AddObject() needs module as first arg");
2854 return -1;
2855 }
2856 if (!o) {
2857 PyErr_SetString(PyExc_TypeError,
2858 "PyModule_AddObject() needs non-NULL value");
2859 return -1;
2860 }
2861
2862 dict = PyModule_GetDict(m);
2863 if (dict == NULL) {
2864 /* Internal error -- modules must have a dict! */
2865 PyErr_Format(PyExc_SystemError, "module '%s' has no __dict__",
2866 PyModule_GetName(m));
2867 return -1;
2868 }
2869 if (PyDict_SetItemString(dict, name, o))
2870 return -1;
2871 Py_DECREF(o);
2872 return 0;
2873 }
2874 #endif
2875
2876 static swig_type_info **
2877 SWIG_Python_SetTypeListHandle(swig_type_info **type_list_handle) {
2878 static PyMethodDef swig_empty_runtime_method_table[] = {
2879 {
2880 NULL, NULL, 0, NULL
2881 }
2882 };/* Sentinel */
2883
2884 PyObject *module = Py_InitModule((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION,
2885 swig_empty_runtime_method_table);
2886 PyObject *pointer = PyCObject_FromVoidPtr((void *) type_list_handle, NULL);
2887 if (pointer && module) {
2888 PyModule_AddObject(module, (char*)"type_pointer" SWIG_TYPE_TABLE_NAME, pointer);
2889 }
2890 return type_list_handle;
2891 }
2892
2893 static swig_type_info **
2894 SWIG_Python_LookupTypePointer(swig_type_info **type_list_handle) {
2895 swig_type_info **type_pointer;
2896
2897 /* first check if module already created */
2898 type_pointer = SWIG_Python_GetTypeListHandle();
2899 if (type_pointer) {
2900 return type_pointer;
2901 } else {
2902 /* create a new module and variable */
2903 return SWIG_Python_SetTypeListHandle(type_list_handle);
2904 }
2905 }
2906
2907 #ifdef __cplusplus
2908 }
2909 #endif
2910
2911 /* -----------------------------------------------------------------------------*
2912 * Partial Init method
2913 * -----------------------------------------------------------------------------*/
2914
2915 #ifdef SWIG_LINK_RUNTIME
2916 #ifdef __cplusplus
2917 extern "C"
2918 #endif
2919 SWIGEXPORT(void *) SWIG_ReturnGlobalTypeList(void *);
2920 #endif
2921
2922 #ifdef __cplusplus
2923 extern "C"
2924 #endif
2925 SWIGEXPORT(void) SWIG_init(void) {
2926 static PyObject *SWIG_globals = 0;
2927 static int typeinit = 0;
2928 PyObject *m, *d;
2929 int i;
2930 if (!SWIG_globals) SWIG_globals = SWIG_newvarlink();
2931
2932 /* Fix SwigMethods to carry the callback ptrs when needed */
2933 SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_types_initial);
2934
2935 m = Py_InitModule((char *) SWIG_name, SwigMethods);
2936 d = PyModule_GetDict(m);
2937
2938 if (!typeinit) {
2939 #ifdef SWIG_LINK_RUNTIME
2940 swig_type_list_handle = (swig_type_info **) SWIG_ReturnGlobalTypeList(swig_type_list_handle);
2941 #else
2942 # ifndef SWIG_STATIC_RUNTIME
2943 swig_type_list_handle = SWIG_Python_LookupTypePointer(swig_type_list_handle);
2944 # endif
2945 #endif
2946 for (i = 0; swig_types_initial[i]; i++) {
2947 swig_types[i] = SWIG_TypeRegister(swig_types_initial[i]);
2948 }
2949 typeinit = 1;
2950 }
2951 SWIG_InstallConstants(d,swig_const_table);
2952
2953 PyDict_SetItemString(d,(char*)"cvar", SWIG_globals);
2954 SWIG_addvarlink(SWIG_globals,(char*)"GLCanvasNameStr",_wrap_GLCanvasNameStr_get, _wrap_GLCanvasNameStr_set);
2955 {
2956 PyDict_SetItemString(d,"WX_GL_RGBA", SWIG_From_int((int)(WX_GL_RGBA)));
2957 }
2958 {
2959 PyDict_SetItemString(d,"WX_GL_BUFFER_SIZE", SWIG_From_int((int)(WX_GL_BUFFER_SIZE)));
2960 }
2961 {
2962 PyDict_SetItemString(d,"WX_GL_LEVEL", SWIG_From_int((int)(WX_GL_LEVEL)));
2963 }
2964 {
2965 PyDict_SetItemString(d,"WX_GL_DOUBLEBUFFER", SWIG_From_int((int)(WX_GL_DOUBLEBUFFER)));
2966 }
2967 {
2968 PyDict_SetItemString(d,"WX_GL_STEREO", SWIG_From_int((int)(WX_GL_STEREO)));
2969 }
2970 {
2971 PyDict_SetItemString(d,"WX_GL_AUX_BUFFERS", SWIG_From_int((int)(WX_GL_AUX_BUFFERS)));
2972 }
2973 {
2974 PyDict_SetItemString(d,"WX_GL_MIN_RED", SWIG_From_int((int)(WX_GL_MIN_RED)));
2975 }
2976 {
2977 PyDict_SetItemString(d,"WX_GL_MIN_GREEN", SWIG_From_int((int)(WX_GL_MIN_GREEN)));
2978 }
2979 {
2980 PyDict_SetItemString(d,"WX_GL_MIN_BLUE", SWIG_From_int((int)(WX_GL_MIN_BLUE)));
2981 }
2982 {
2983 PyDict_SetItemString(d,"WX_GL_MIN_ALPHA", SWIG_From_int((int)(WX_GL_MIN_ALPHA)));
2984 }
2985 {
2986 PyDict_SetItemString(d,"WX_GL_DEPTH_SIZE", SWIG_From_int((int)(WX_GL_DEPTH_SIZE)));
2987 }
2988 {
2989 PyDict_SetItemString(d,"WX_GL_STENCIL_SIZE", SWIG_From_int((int)(WX_GL_STENCIL_SIZE)));
2990 }
2991 {
2992 PyDict_SetItemString(d,"WX_GL_MIN_ACCUM_RED", SWIG_From_int((int)(WX_GL_MIN_ACCUM_RED)));
2993 }
2994 {
2995 PyDict_SetItemString(d,"WX_GL_MIN_ACCUM_GREEN", SWIG_From_int((int)(WX_GL_MIN_ACCUM_GREEN)));
2996 }
2997 {
2998 PyDict_SetItemString(d,"WX_GL_MIN_ACCUM_BLUE", SWIG_From_int((int)(WX_GL_MIN_ACCUM_BLUE)));
2999 }
3000 {
3001 PyDict_SetItemString(d,"WX_GL_MIN_ACCUM_ALPHA", SWIG_From_int((int)(WX_GL_MIN_ACCUM_ALPHA)));
3002 }
3003
3004
3005
3006 }
3007