PLplot  5.13.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
plplotluacLUA_wrap.c
Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * This file was automatically generated by SWIG (http://www.swig.org).
3  * Version 2.0.12
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 SWIGLUA
12 #define SWIG_LUA_TARGET SWIG_LUA_FLAVOR_LUA
13 #define SWIG_LUA_MODULE_GLOBAL
14 
15 /* -----------------------------------------------------------------------------
16  * This section contains generic SWIG labels for method/variable
17  * declarations/attributes, and other compiler dependent labels.
18  * ----------------------------------------------------------------------------- */
19 
20 /* template workaround for compilers that cannot correctly implement the C++ standard */
21 #ifndef SWIGTEMPLATEDISAMBIGUATOR
22 # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
23 # define SWIGTEMPLATEDISAMBIGUATOR template
24 # elif defined(__HP_aCC)
25 /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
26 /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
27 # define SWIGTEMPLATEDISAMBIGUATOR template
28 # else
29 # define SWIGTEMPLATEDISAMBIGUATOR
30 # endif
31 #endif
32 
33 /* inline attribute */
34 #ifndef SWIGINLINE
35 # if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
36 # define SWIGINLINE inline
37 # else
38 # define SWIGINLINE
39 # endif
40 #endif
41 
42 /* attribute recognised by some compilers to avoid 'unused' warnings */
43 #ifndef SWIGUNUSED
44 # if defined(__GNUC__)
45 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
46 # define SWIGUNUSED __attribute__ ((__unused__))
47 # else
48 # define SWIGUNUSED
49 # endif
50 # elif defined(__ICC)
51 # define SWIGUNUSED __attribute__ ((__unused__))
52 # else
53 # define SWIGUNUSED
54 # endif
55 #endif
56 
57 #ifndef SWIG_MSC_UNSUPPRESS_4505
58 # if defined(_MSC_VER)
59 # pragma warning(disable : 4505) /* unreferenced local function has been removed */
60 # endif
61 #endif
62 
63 #ifndef SWIGUNUSEDPARM
64 # ifdef __cplusplus
65 # define SWIGUNUSEDPARM(p)
66 # else
67 # define SWIGUNUSEDPARM(p) p SWIGUNUSED
68 # endif
69 #endif
70 
71 /* internal SWIG method */
72 #ifndef SWIGINTERN
73 # define SWIGINTERN static SWIGUNUSED
74 #endif
75 
76 /* internal inline SWIG method */
77 #ifndef SWIGINTERNINLINE
78 # define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
79 #endif
80 
81 /* exporting methods */
82 #if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
83 # ifndef GCC_HASCLASSVISIBILITY
84 # define GCC_HASCLASSVISIBILITY
85 # endif
86 #endif
87 
88 #ifndef SWIGEXPORT
89 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
90 # if defined(STATIC_LINKED)
91 # define SWIGEXPORT
92 # else
93 # define SWIGEXPORT __declspec(dllexport)
94 # endif
95 # else
96 # if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
97 # define SWIGEXPORT __attribute__ ((visibility("default")))
98 # else
99 # define SWIGEXPORT
100 # endif
101 # endif
102 #endif
103 
104 /* calling conventions for Windows */
105 #ifndef SWIGSTDCALL
106 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
107 # define SWIGSTDCALL __stdcall
108 # else
109 # define SWIGSTDCALL
110 # endif
111 #endif
112 
113 /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
114 #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
115 # define _CRT_SECURE_NO_DEPRECATE
116 #endif
117 
118 /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
119 #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
120 # define _SCL_SECURE_NO_DEPRECATE
121 #endif
122 
123 
124 /* -----------------------------------------------------------------------------
125  * swigrun.swg
126  *
127  * This file contains generic C API SWIG runtime support for pointer
128  * type checking.
129  * ----------------------------------------------------------------------------- */
130 
131 /* This should only be incremented when either the layout of swig_type_info changes,
132  or for whatever reason, the runtime changes incompatibly */
133 #define SWIG_RUNTIME_VERSION "4"
134 
135 /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
136 #ifdef SWIG_TYPE_TABLE
137 # define SWIG_QUOTE_STRING(x) #x
138 # define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
139 # define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
140 #else
141 # define SWIG_TYPE_TABLE_NAME
142 #endif
143 
144 /*
145  You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
146  creating a static or dynamic library from the SWIG runtime code.
147  In 99.9% of the cases, SWIG just needs to declare them as 'static'.
148 
149  But only do this if strictly necessary, ie, if you have problems
150  with your compiler or suchlike.
151 */
152 
153 #ifndef SWIGRUNTIME
154 # define SWIGRUNTIME SWIGINTERN
155 #endif
156 
157 #ifndef SWIGRUNTIMEINLINE
158 # define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
159 #endif
160 
161 /* Generic buffer size */
162 #ifndef SWIG_BUFFER_SIZE
163 # define SWIG_BUFFER_SIZE 1024
164 #endif
165 
166 /* Flags for pointer conversions */
167 #define SWIG_POINTER_DISOWN 0x1
168 #define SWIG_CAST_NEW_MEMORY 0x2
169 
170 /* Flags for new pointer objects */
171 #define SWIG_POINTER_OWN 0x1
172 
173 
174 /*
175  Flags/methods for returning states.
176 
177  The SWIG conversion methods, as ConvertPtr, return an integer
178  that tells if the conversion was successful or not. And if not,
179  an error code can be returned (see swigerrors.swg for the codes).
180 
181  Use the following macros/flags to set or process the returning
182  states.
183 
184  In old versions of SWIG, code such as the following was usually written:
185 
186  if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
187  // success code
188  } else {
189  //fail code
190  }
191 
192  Now you can be more explicit:
193 
194  int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
195  if (SWIG_IsOK(res)) {
196  // success code
197  } else {
198  // fail code
199  }
200 
201  which is the same really, but now you can also do
202 
203  Type *ptr;
204  int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
205  if (SWIG_IsOK(res)) {
206  // success code
207  if (SWIG_IsNewObj(res) {
208  ...
209  delete *ptr;
210  } else {
211  ...
212  }
213  } else {
214  // fail code
215  }
216 
217  I.e., now SWIG_ConvertPtr can return new objects and you can
218  identify the case and take care of the deallocation. Of course that
219  also requires SWIG_ConvertPtr to return new result values, such as
220 
221  int SWIG_ConvertPtr(obj, ptr,...) {
222  if (<obj is ok>) {
223  if (<need new object>) {
224  *ptr = <ptr to new allocated object>;
225  return SWIG_NEWOBJ;
226  } else {
227  *ptr = <ptr to old object>;
228  return SWIG_OLDOBJ;
229  }
230  } else {
231  return SWIG_BADOBJ;
232  }
233  }
234 
235  Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
236  more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
237  SWIG errors code.
238 
239  Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
240  allows to return the 'cast rank', for example, if you have this
241 
242  int food(double)
243  int fooi(int);
244 
245  and you call
246 
247  food(1) // cast rank '1' (1 -> 1.0)
248  fooi(1) // cast rank '0'
249 
250  just use the SWIG_AddCast()/SWIG_CheckState()
251 */
252 
253 #define SWIG_OK (0)
254 #define SWIG_ERROR (-1)
255 #define SWIG_IsOK(r) (r >= 0)
256 #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
257 
258 /* The CastRankLimit says how many bits are used for the cast rank */
259 #define SWIG_CASTRANKLIMIT (1 << 8)
260 /* The NewMask denotes the object was created (using new/malloc) */
261 #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1)
262 /* The TmpMask is for in/out typemaps that use temporal objects */
263 #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1)
264 /* Simple returning values */
265 #define SWIG_BADOBJ (SWIG_ERROR)
266 #define SWIG_OLDOBJ (SWIG_OK)
267 #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK)
268 #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK)
269 /* Check, add and del mask methods */
270 #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
271 #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
272 #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
273 #define SWIG_AddTmpMask(r) (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
274 #define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
275 #define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
276 
277 /* Cast-Rank Mode */
278 #if defined(SWIG_CASTRANK_MODE)
279 # ifndef SWIG_TypeRank
280 # define SWIG_TypeRank unsigned long
281 # endif
282 # ifndef SWIG_MAXCASTRANK /* Default cast allowed */
283 # define SWIG_MAXCASTRANK (2)
284 # endif
285 # define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
286 # define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
287 SWIGINTERNINLINE int SWIG_AddCast(int r) {
288  return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
289 }
291  return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
292 }
293 #else /* no cast-rank mode */
294 # define SWIG_AddCast(r) (r)
295 # define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
296 #endif
297 
298 
299 #include <string.h>
300 
301 #ifdef __cplusplus
302 extern "C" {
303 #endif
304 
305 typedef void *(*swig_converter_func)(void *, int *);
306 typedef struct swig_type_info *(*swig_dycast_func)(void **);
307 
308 /* Structure to store information on one type */
309 typedef struct swig_type_info {
310  const char *name; /* mangled name of this type */
311  const char *str; /* human readable name of this type */
312  swig_dycast_func dcast; /* dynamic cast function down a hierarchy */
313  struct swig_cast_info *cast; /* linked list of types that can cast into this type */
314  void *clientdata; /* language specific type data */
315  int owndata; /* flag if the structure owns the clientdata */
317 
318 /* Structure to store a type and conversion function used for casting */
319 typedef struct swig_cast_info {
320  swig_type_info *type; /* pointer to type that is equivalent to this type */
321  swig_converter_func converter; /* function to cast the void pointers */
322  struct swig_cast_info *next; /* pointer to next cast in linked list */
323  struct swig_cast_info *prev; /* pointer to the previous cast */
325 
326 /* Structure used to store module information
327  * Each module generates one structure like this, and the runtime collects
328  * all of these structures and stores them in a circularly linked list.*/
329 typedef struct swig_module_info {
330  swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */
331  size_t size; /* Number of types in this module */
332  struct swig_module_info *next; /* Pointer to next element in circularly linked list */
333  swig_type_info **type_initial; /* Array of initially generated type structures */
334  swig_cast_info **cast_initial; /* Array of initially generated casting structures */
335  void *clientdata; /* Language specific module data */
337 
338 /*
339  Compare two type names skipping the space characters, therefore
340  "char*" == "char *" and "Class<int>" == "Class<int >", etc.
341 
342  Return 0 when the two name types are equivalent, as in
343  strncmp, but skipping ' '.
344 */
345 SWIGRUNTIME int
346 SWIG_TypeNameComp(const char *f1, const char *l1,
347  const char *f2, const char *l2) {
348  for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
349  while ((*f1 == ' ') && (f1 != l1)) ++f1;
350  while ((*f2 == ' ') && (f2 != l2)) ++f2;
351  if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
352  }
353  return (int)((l1 - f1) - (l2 - f2));
354 }
355 
356 /*
357  Check type equivalence in a name list like <name1>|<name2>|...
358  Return 0 if equal, -1 if nb < tb, 1 if nb > tb
359 */
360 SWIGRUNTIME int
361 SWIG_TypeCmp(const char *nb, const char *tb) {
362  int equiv = 1;
363  const char* te = tb + strlen(tb);
364  const char* ne = nb;
365  while (equiv != 0 && *ne) {
366  for (nb = ne; *ne; ++ne) {
367  if (*ne == '|') break;
368  }
369  equiv = SWIG_TypeNameComp(nb, ne, tb, te);
370  if (*ne) ++ne;
371  }
372  return equiv;
373 }
374 
375 /*
376  Check type equivalence in a name list like <name1>|<name2>|...
377  Return 0 if not equal, 1 if equal
378 */
379 SWIGRUNTIME int
380 SWIG_TypeEquiv(const char *nb, const char *tb) {
381  return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
382 }
383 
384 /*
385  Check the typename
386 */
388 SWIG_TypeCheck(const char *c, swig_type_info *ty) {
389  if (ty) {
390  swig_cast_info *iter = ty->cast;
391  while (iter) {
392  if (strcmp(iter->type->name, c) == 0) {
393  if (iter == ty->cast)
394  return iter;
395  /* Move iter to the top of the linked list */
396  iter->prev->next = iter->next;
397  if (iter->next)
398  iter->next->prev = iter->prev;
399  iter->next = ty->cast;
400  iter->prev = 0;
401  if (ty->cast) ty->cast->prev = iter;
402  ty->cast = iter;
403  return iter;
404  }
405  iter = iter->next;
406  }
407  }
408  return 0;
409 }
410 
411 /*
412  Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
413 */
416  if (ty) {
417  swig_cast_info *iter = ty->cast;
418  while (iter) {
419  if (iter->type == from) {
420  if (iter == ty->cast)
421  return iter;
422  /* Move iter to the top of the linked list */
423  iter->prev->next = iter->next;
424  if (iter->next)
425  iter->next->prev = iter->prev;
426  iter->next = ty->cast;
427  iter->prev = 0;
428  if (ty->cast) ty->cast->prev = iter;
429  ty->cast = iter;
430  return iter;
431  }
432  iter = iter->next;
433  }
434  }
435  return 0;
436 }
437 
438 /*
439  Cast a pointer up an inheritance hierarchy
440 */
441 SWIGRUNTIMEINLINE void *
442 SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
443  return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
444 }
445 
446 /*
447  Dynamic pointer casting. Down an inheritance hierarchy
448 */
451  swig_type_info *lastty = ty;
452  if (!ty || !ty->dcast) return ty;
453  while (ty && (ty->dcast)) {
454  ty = (*ty->dcast)(ptr);
455  if (ty) lastty = ty;
456  }
457  return lastty;
458 }
459 
460 /*
461  Return the name associated with this type
462 */
463 SWIGRUNTIMEINLINE const char *
465  return ty->name;
466 }
467 
468 /*
469  Return the pretty name associated with this type,
470  that is an unmangled type name in a form presentable to the user.
471 */
472 SWIGRUNTIME const char *
474  /* The "str" field contains the equivalent pretty names of the
475  type, separated by vertical-bar characters. We choose
476  to print the last name, as it is often (?) the most
477  specific. */
478  if (!type) return NULL;
479  if (type->str != NULL) {
480  const char *last_name = type->str;
481  const char *s;
482  for (s = type->str; *s; s++)
483  if (*s == '|') last_name = s+1;
484  return last_name;
485  }
486  else
487  return type->name;
488 }
489 
490 /*
491  Set the clientdata field for a type
492 */
493 SWIGRUNTIME void
495  swig_cast_info *cast = ti->cast;
496  /* if (ti->clientdata == clientdata) return; */
497  ti->clientdata = clientdata;
498 
499  while (cast) {
500  if (!cast->converter) {
501  swig_type_info *tc = cast->type;
502  if (!tc->clientdata) {
503  SWIG_TypeClientData(tc, clientdata);
504  }
505  }
506  cast = cast->next;
507  }
508 }
509 SWIGRUNTIME void
511  SWIG_TypeClientData(ti, clientdata);
512  ti->owndata = 1;
513 }
514 
515 /*
516  Search for a swig_type_info structure only by mangled name
517  Search is a O(log #types)
518 
519  We start searching at module start, and finish searching when start == end.
520  Note: if start == end at the beginning of the function, we go all the way around
521  the circular list.
522 */
525  swig_module_info *end,
526  const char *name) {
527  swig_module_info *iter = start;
528  do {
529  if (iter->size) {
530  register size_t l = 0;
531  register size_t r = iter->size - 1;
532  do {
533  /* since l+r >= 0, we can (>> 1) instead (/ 2) */
534  register size_t i = (l + r) >> 1;
535  const char *iname = iter->types[i]->name;
536  if (iname) {
537  register int compare = strcmp(name, iname);
538  if (compare == 0) {
539  return iter->types[i];
540  } else if (compare < 0) {
541  if (i) {
542  r = i - 1;
543  } else {
544  break;
545  }
546  } else if (compare > 0) {
547  l = i + 1;
548  }
549  } else {
550  break; /* should never happen */
551  }
552  } while (l <= r);
553  }
554  iter = iter->next;
555  } while (iter != end);
556  return 0;
557 }
558 
559 /*
560  Search for a swig_type_info structure for either a mangled name or a human readable name.
561  It first searches the mangled names of the types, which is a O(log #types)
562  If a type is not found it then searches the human readable names, which is O(#types).
563 
564  We start searching at module start, and finish searching when start == end.
565  Note: if start == end at the beginning of the function, we go all the way around
566  the circular list.
567 */
570  swig_module_info *end,
571  const char *name) {
572  /* STEP 1: Search the name field using binary search */
573  swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
574  if (ret) {
575  return ret;
576  } else {
577  /* STEP 2: If the type hasn't been found, do a complete search
578  of the str field (the human readable name) */
579  swig_module_info *iter = start;
580  do {
581  register size_t i = 0;
582  for (; i < iter->size; ++i) {
583  if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
584  return iter->types[i];
585  }
586  iter = iter->next;
587  } while (iter != end);
588  }
589 
590  /* neither found a match */
591  return 0;
592 }
593 
594 /*
595  Pack binary data into a string
596 */
597 SWIGRUNTIME char *
598 SWIG_PackData(char *c, void *ptr, size_t sz) {
599  static const char hex[17] = "0123456789abcdef";
600  register const unsigned char *u = (unsigned char *) ptr;
601  register const unsigned char *eu = u + sz;
602  for (; u != eu; ++u) {
603  register unsigned char uu = *u;
604  *(c++) = hex[(uu & 0xf0) >> 4];
605  *(c++) = hex[uu & 0xf];
606  }
607  return c;
608 }
609 
610 /*
611  Unpack binary data from a string
612 */
613 SWIGRUNTIME const char *
614 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
615  register unsigned char *u = (unsigned char *) ptr;
616  register const unsigned char *eu = u + sz;
617  for (; u != eu; ++u) {
618  register char d = *(c++);
619  register unsigned char uu;
620  if ((d >= '0') && (d <= '9'))
621  uu = ((d - '0') << 4);
622  else if ((d >= 'a') && (d <= 'f'))
623  uu = ((d - ('a'-10)) << 4);
624  else
625  return (char *) 0;
626  d = *(c++);
627  if ((d >= '0') && (d <= '9'))
628  uu |= (d - '0');
629  else if ((d >= 'a') && (d <= 'f'))
630  uu |= (d - ('a'-10));
631  else
632  return (char *) 0;
633  *u = uu;
634  }
635  return c;
636 }
637 
638 /*
639  Pack 'void *' into a string buffer.
640 */
641 SWIGRUNTIME char *
642 SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
643  char *r = buff;
644  if ((2*sizeof(void *) + 2) > bsz) return 0;
645  *(r++) = '_';
646  r = SWIG_PackData(r,&ptr,sizeof(void *));
647  if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
648  strcpy(r,name);
649  return buff;
650 }
651 
652 SWIGRUNTIME const char *
653 SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
654  if (*c != '_') {
655  if (strcmp(c,"NULL") == 0) {
656  *ptr = (void *) 0;
657  return name;
658  } else {
659  return 0;
660  }
661  }
662  return SWIG_UnpackData(++c,ptr,sizeof(void *));
663 }
664 
665 SWIGRUNTIME char *
666 SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
667  char *r = buff;
668  size_t lname = (name ? strlen(name) : 0);
669  if ((2*sz + 2 + lname) > bsz) return 0;
670  *(r++) = '_';
671  r = SWIG_PackData(r,ptr,sz);
672  if (lname) {
673  strncpy(r,name,lname+1);
674  } else {
675  *r = 0;
676  }
677  return buff;
678 }
679 
680 SWIGRUNTIME const char *
681 SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
682  if (*c != '_') {
683  if (strcmp(c,"NULL") == 0) {
684  memset(ptr,0,sz);
685  return name;
686  } else {
687  return 0;
688  }
689  }
690  return SWIG_UnpackData(++c,ptr,sz);
691 }
692 
693 #ifdef __cplusplus
694 }
695 #endif
696 
697 /* -----------------------------------------------------------------------------
698  * luarun.swg
699  *
700  * This file contains the runtime support for Lua modules
701  * and includes code for managing global variables and pointer
702  * type checking.
703  * ----------------------------------------------------------------------------- */
704 
705 #ifdef __cplusplus
706 extern "C" {
707 #endif
708 
709 #include "lua.h"
710 #include "lauxlib.h"
711 #include <stdlib.h> /* for malloc */
712 #include <assert.h> /* for a few sanity tests */
713 
714 /* -----------------------------------------------------------------------------
715  * Lua flavors
716  * ----------------------------------------------------------------------------- */
717 
718 #define SWIG_LUA_FLAVOR_LUA 1
719 #define SWIG_LUA_FLAVOR_ELUA 2
720 #define SWIG_LUA_FLAVOR_ELUAC 3
721 
722 #if !defined(SWIG_LUA_TARGET)
723 # error SWIG_LUA_TARGET not defined
724 #endif
725 
726 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
727 # define SWIG_LUA_CONSTTAB_INT(B, C) LSTRKEY(B), LNUMVAL(C)
728 # define SWIG_LUA_CONSTTAB_FLOAT(B, C) LSTRKEY(B), LNUMVAL(C)
729 # define SWIG_LUA_CONSTTAB_STRING(B, C) LSTRKEY(B), LSTRVAL(C)
730 # define SWIG_LUA_CONSTTAB_CHAR(B, C) LSTRKEY(B), LNUMVAL(C)
731 #else /* SWIG_LUA_FLAVOR_LUA */
732 # define SWIG_LUA_CONSTTAB_INT(B, C) SWIG_LUA_INT, (char *)B, (long)C, 0, 0, 0
733 # define SWIG_LUA_CONSTTAB_FLOAT(B, C) SWIG_LUA_FLOAT, (char *)B, 0, (double)C, 0, 0
734 # define SWIG_LUA_CONSTTAB_STRING(B, C) SWIG_LUA_STRING, (char *)B, 0, 0, (void *)C, 0
735 # define SWIG_LUA_CONSTTAB_CHAR(B, C) SWIG_LUA_CHAR, (char *)B, (long)C, 0, 0, 0
736 #endif
737 
738 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
739 # define LRO_STRVAL(v) {{.p = (char *) v}, LUA_TSTRING}
740 # define LSTRVAL LRO_STRVAL
741 #endif
742 
743 /* -----------------------------------------------------------------------------
744  * compatibility defines
745  * ----------------------------------------------------------------------------- */
746 
747 /* History of Lua C API length functions: In Lua 5.0 (and before?)
748  there was "lua_strlen". In Lua 5.1, this was renamed "lua_objlen",
749  but a compatibility define of "lua_strlen" was added. In Lua 5.2,
750  this function was again renamed, to "lua_rawlen" (to emphasize that
751  it doesn't call the "__len" metamethod), and the compatibility
752  define of lua_strlen was removed. All SWIG uses have been updated
753  to "lua_rawlen", and we add our own defines of that here for older
754  versions of Lua. */
755 #if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 501
756 # define lua_rawlen lua_strlen
757 #elif LUA_VERSION_NUM == 501
758 # define lua_rawlen lua_objlen
759 #endif
760 
761 
762 /* lua_pushglobaltable is the recommended "future-proof" way to get
763  the global table for Lua 5.2 and later. Here we define
764  lua_pushglobaltable ourselves for Lua versions before 5.2. */
765 #if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 502
766 # define lua_pushglobaltable(L) lua_pushvalue(L, LUA_GLOBALSINDEX)
767 #endif
768 
769 
770 /* --------------------------------------------------------------------------
771  * Helper functions for error handling
772  * -------------------------------------------------------------------------- */
773 
774 /* Push the string STR on the Lua stack, like lua_pushstring, but
775  prefixed with the the location of the innermost Lua call-point
776  (as formated by luaL_where). */
777 SWIGRUNTIME void
778 SWIG_Lua_pusherrstring (lua_State *L, const char *str)
779 {
780  luaL_where (L, 1);
781  lua_pushstring (L, str);
782  lua_concat (L, 2);
783 }
784 
785 /* Push a formatted string generated from FMT and following args on
786  the Lua stack, like lua_pushfstring, but prefixed with the the
787  location of the innermost Lua call-point (as formated by luaL_where). */
788 SWIGRUNTIME void
789 SWIG_Lua_pushferrstring (lua_State *L, const char *fmt, ...)
790 {
791  va_list argp;
792  va_start(argp, fmt);
793  luaL_where(L, 1);
794  lua_pushvfstring(L, fmt, argp);
795  va_end(argp);
796  lua_concat(L, 2);
797 }
798 
799 
800 /* -----------------------------------------------------------------------------
801  * global swig types
802  * ----------------------------------------------------------------------------- */
803 /* Constant table */
804 #define SWIG_LUA_INT 1
805 #define SWIG_LUA_FLOAT 2
806 #define SWIG_LUA_STRING 3
807 #define SWIG_LUA_POINTER 4
808 #define SWIG_LUA_BINARY 5
809 #define SWIG_LUA_CHAR 6
810 
811 /* Structure for variable linking table */
812 typedef struct {
813  const char *name;
814  lua_CFunction get;
815  lua_CFunction set;
817 
818 /* Constant information structure */
819 typedef struct {
820  int type;
821  char *name;
822  long lvalue;
823  double dvalue;
824  void *pvalue;
827 
828 typedef struct {
829  const char *name;
830  lua_CFunction method;
832 
833 typedef struct {
834  const char *name;
835  lua_CFunction getmethod;
836  lua_CFunction setmethod;
838 
839 // Can be used to create namespaces. Currently used to
840 // wrap class static methods/variables/constants
841 typedef struct {
842  const char *name;
847 
848 typedef struct swig_lua_class {
849  const char *name;
851  lua_CFunction constructor;
852  void (*destructor)(void *);
857  const char **base_names;
859 
860 /* this is the struct for wrapping all pointers in SwigLua
861 */
862 typedef struct {
864  int own; /* 1 if owned & must be destroyed */
865  void *ptr;
867 
868 /* this is the struct for wrapping arbitrary packed binary data
869 (currently it is only used for member function pointers)
870 the data ordering is similar to swig_lua_userdata, but it is currently not possible
871 to tell the two structures apart within SWIG, other than by looking at the type
872 */
873 typedef struct {
875  int own; /* 1 if owned & must be destroyed */
876  char data[1]; /* arbitary amount of data */
878 
879 /* Common SWIG API */
880 #define SWIG_NewPointerObj(L, ptr, type, owner) SWIG_Lua_NewPointerObj(L, (void *)ptr, type, owner)
881 #define SWIG_ConvertPtr(L,idx, ptr, type, flags) SWIG_Lua_ConvertPtr(L,idx,ptr,type,flags)
882 #define SWIG_MustGetPtr(L,idx, type,flags, argnum,fnname) SWIG_Lua_MustGetPtr(L,idx, type,flags, argnum,fnname)
883 /* for C++ member pointers, ie, member methods */
884 #define SWIG_ConvertMember(L, idx, ptr, sz, ty) SWIG_Lua_ConvertPacked(L, idx, ptr, sz, ty)
885 #define SWIG_NewMemberObj(L, ptr, sz, type) SWIG_Lua_NewPackedObj(L, ptr, sz, type)
886 
887 /* Runtime API */
888 #define SWIG_GetModule(clientdata) SWIG_Lua_GetModule((lua_State*)(clientdata))
889 #define SWIG_SetModule(clientdata, pointer) SWIG_Lua_SetModule((lua_State*) (clientdata), pointer)
890 #define SWIG_MODULE_CLIENTDATA_TYPE lua_State*
891 
892 /* Contract support */
893 #define SWIG_contract_assert(expr, msg) \
894  if (!(expr)) { SWIG_Lua_pusherrstring(L, (char *) msg); goto fail; } else
895 
896 
897 /* helper #defines */
898 #define SWIG_fail {goto fail;}
899 #define SWIG_fail_arg(func_name,argnum,type) \
900  {SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'",\
901  func_name,argnum,type,SWIG_Lua_typename(L,argnum));\
902  goto fail;}
903 #define SWIG_fail_ptr(func_name,argnum,type) \
904  SWIG_fail_arg(func_name,argnum,(type && type->str)?type->str:"void*")
905 #define SWIG_check_num_args(func_name,a,b) \
906  if (lua_gettop(L)<a || lua_gettop(L)>b) \
907  {SWIG_Lua_pushferrstring(L,"Error in %s expected %d..%d args, got %d",func_name,a,b,lua_gettop(L));\
908  goto fail;}
909 
910 
911 #define SWIG_Lua_get_table(L,n) \
912  (lua_pushstring(L, n), lua_rawget(L,-2))
913 
914 #define SWIG_Lua_add_function(L,n,f) \
915  (lua_pushstring(L, n), \
916  lua_pushcfunction(L, f), \
917  lua_rawset(L,-3))
918 
919 /* special helper for allowing 'nil' for usertypes */
920 #define SWIG_isptrtype(L,I) (lua_isuserdata(L,I) || lua_isnil(L,I))
921 
922 #ifdef __cplusplus
923 /* Special helper for member function pointers
924 it gets the address, casts it, then dereferences it */
925 //#define SWIG_mem_fn_as_voidptr(a) (*((char**)&(a)))
926 #endif
927 
928 /* storing/access of swig_module_info */
930 SWIG_Lua_GetModule(lua_State* L) {
931  swig_module_info *ret = 0;
932  lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
933  lua_rawget(L,LUA_REGISTRYINDEX);
934  if (lua_islightuserdata(L,-1))
935  ret=(swig_module_info*)lua_touserdata(L,-1);
936  lua_pop(L,1); /* tidy */
937  return ret;
938 }
939 
940 SWIGRUNTIME void
941 SWIG_Lua_SetModule(lua_State* L, swig_module_info *module) {
942  /* add this all into the Lua registry: */
943  lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
944  lua_pushlightuserdata(L,(void*)module);
945  lua_rawset(L,LUA_REGISTRYINDEX);
946 }
947 
948 /* -----------------------------------------------------------------------------
949  * global variable support code: modules
950  * ----------------------------------------------------------------------------- */
951 
952 /* this function is called when trying to set an immutable.
953 default action is to print an error.
954 This can removed with a compile flag SWIGLUA_IGNORE_SET_IMMUTABLE */
956 {
957 /* there should be 1 param passed in: the new value */
958 #ifndef SWIGLUA_IGNORE_SET_IMMUTABLE
959  lua_pop(L,1); /* remove it */
960  luaL_error(L,"This variable is immutable");
961 #endif
962  return 0; /* should not return anything */
963 }
964 
965 /* the module.get method used for getting linked data */
967 {
968 /* there should be 2 params passed in
969  (1) table (not the meta table)
970  (2) string name of the attribute
971  printf("SWIG_Lua_module_get %p(%s) '%s'\n",
972  lua_topointer(L,1),lua_typename(L,lua_type(L,1)),
973  lua_tostring(L,2));
974 */
975  /* get the metatable */
976 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
977  assert(lua_isrotable(L,1)); /* just in case */
978 #else
979  assert(lua_istable(L,1)); /* default Lua action */
980 #endif
981  lua_getmetatable(L,1); /* get the metatable */
982 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
983  assert(lua_isrotable(L,-1)); /* just in case */
984 #else
985  assert(lua_istable(L,-1));
986 #endif
987  SWIG_Lua_get_table(L,".get"); /* get the .get table */
988  lua_remove(L,3); /* remove metatable */
989 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
990  if (lua_isrotable(L,-1))
991 #else
992  if (lua_istable(L,-1))
993 #endif
994  {
995  /* look for the key in the .get table */
996  lua_pushvalue(L,2); /* key */
997  lua_rawget(L,-2);
998  lua_remove(L,3); /* remove .get */
999  if (lua_iscfunction(L,-1))
1000  { /* found it so call the fn & return its value */
1001  lua_call(L,0,1);
1002  return 1;
1003  }
1004  lua_pop(L,1); /* remove the top */
1005  }
1006  lua_pop(L,1); /* remove the .get */
1007  lua_pushnil(L); /* return a nil */
1008  return 1;
1009 }
1010 
1011 /* the module.set method used for setting linked data */
1013 {
1014 /* there should be 3 params passed in
1015  (1) table (not the meta table)
1016  (2) string name of the attribute
1017  (3) any for the new value
1018 */
1019  /* get the metatable */
1020 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
1021  assert(lua_isrotable(L,1)); /* just in case */
1022 #else
1023  assert(lua_istable(L,1)); /* default Lua action */
1024 #endif
1025  lua_getmetatable(L,1); /* get the metatable */
1026 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
1027  assert(lua_isrotable(L,-1)); /* just in case */
1028 #else
1029  assert(lua_istable(L,-1));
1030 #endif
1031  SWIG_Lua_get_table(L,".set"); /* get the .set table */
1032  lua_remove(L,4); /* remove metatable */
1033 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
1034  if (lua_isrotable(L,-1))
1035 #else
1036  if (lua_istable(L,-1))
1037 #endif
1038  {
1039  /* look for the key in the .set table */
1040  lua_pushvalue(L,2); /* key */
1041  lua_rawget(L,-2);
1042  lua_remove(L,4); /* remove .set */
1043  if (lua_iscfunction(L,-1))
1044  { /* found it so call the fn & return its value */
1045  lua_pushvalue(L,3); /* value */
1046  lua_call(L,1,0);
1047  return 0;
1048  }
1049 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA)
1050  else {
1051  return 0; // Exits stoically if an invalid key is initialized.
1052  }
1053 #endif
1054  }
1055  lua_settop(L,3); /* reset back to start */
1056  /* we now have the table, key & new value, so just set directly */
1057  lua_rawset(L,1); /* add direct */
1058  return 0;
1059 }
1060 
1061 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
1062 /* registering a module in lua. Pushes the module table on the stack. */
1063 SWIGINTERN void SWIG_Lua_module_begin(lua_State* L,const char* name)
1064 {
1065  assert(lua_istable(L,-1)); /* just in case */
1066  lua_pushstring(L,name);
1067  lua_newtable(L); /* the table */
1068  /* add meta table */
1069  lua_newtable(L); /* the meta table */
1072  lua_pushstring(L,".get");
1073  lua_newtable(L); /* the .get table */
1074  lua_rawset(L,-3); /* add .get into metatable */
1075  lua_pushstring(L,".set");
1076  lua_newtable(L); /* the .set table */
1077  lua_rawset(L,-3); /* add .set into metatable */
1078  lua_setmetatable(L,-2); /* sets meta table in module */
1079 #ifdef SWIG_LUA_MODULE_GLOBAL
1080  /* If requested, install the module directly into the global namespace. */
1081  lua_rawset(L,-3); /* add module into parent */
1082  SWIG_Lua_get_table(L,name); /* get the table back out */
1083 #else
1084  /* Do not install the module table as global name. The stack top has
1085  the module table with the name below. We pop the top and replace
1086  the name with it. */
1087  lua_replace(L,-2);
1088 #endif
1089 }
1090 
1091 /* ending the register */
1093 {
1094  lua_pop(L,1); /* tidy stack (remove module) */
1095 }
1096 
1097 /* adding a linked variable to the module */
1098 SWIGINTERN void SWIG_Lua_module_add_variable(lua_State* L,const char* name,lua_CFunction getFn,lua_CFunction setFn)
1099 {
1100  assert(lua_istable(L,-1)); /* just in case */
1101  lua_getmetatable(L,-1); /* get the metatable */
1102  assert(lua_istable(L,-1)); /* just in case */
1103  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1104  assert(lua_istable(L,-1)); /* should be a table: */
1105  SWIG_Lua_add_function(L,name,getFn);
1106  lua_pop(L,1); /* tidy stack (remove table) */
1107  if (setFn) /* if there is a set fn */
1108  {
1109  SWIG_Lua_get_table(L,".set"); /* find the .set table */
1110  assert(lua_istable(L,-1)); /* should be a table: */
1111  SWIG_Lua_add_function(L,name,setFn);
1112  lua_pop(L,1); /* tidy stack (remove table) */
1113  }
1114  lua_pop(L,1); /* tidy stack (remove meta) */
1115 }
1116 #endif
1117 
1118 /* adding a function module */
1119 SWIGINTERN void SWIG_Lua_module_add_function(lua_State* L,const char* name,lua_CFunction fn)
1120 {
1121  SWIG_Lua_add_function(L,name,fn);
1122 }
1123 
1124 /* -----------------------------------------------------------------------------
1125  * global variable support code: namespaces
1126  * ----------------------------------------------------------------------------- */
1127 
1129 {
1130 /* there should be 2 params passed in
1131  (1) table (not the meta table)
1132  (2) string name of the attribute
1133 */
1134  assert(lua_istable(L,-2)); /* just in case */
1135  lua_getmetatable(L,-2);
1136  assert(lua_istable(L,-1));
1137  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1138  assert(lua_istable(L,-1));
1139  /* look for the key in the .get table */
1140  lua_pushvalue(L,2); /* key */
1141  lua_rawget(L,-2);
1142  lua_remove(L,-2); /* stack tidy, remove .get table */
1143  if (lua_iscfunction(L,-1))
1144  { /* found it so call the fn & return its value */
1145  lua_call(L,0,1); /* 1 value in (userdata),1 out (result) */
1146  lua_remove(L,-2); /* stack tidy, remove metatable */
1147  return 1;
1148  }
1149  lua_pop(L,1); /* remove whatever was there */
1150  /* ok, so try the .fn table */
1151  SWIG_Lua_get_table(L,".fn"); /* find the .get table */
1152  assert(lua_istable(L,-1)); /* just in case */
1153  lua_pushvalue(L,2); /* key */
1154  lua_rawget(L,-2); /* look for the fn */
1155  lua_remove(L,-2); /* stack tidy, remove .fn table */
1156  if (lua_isfunction(L,-1)) /* note: whether it's a C function or lua function */
1157  { /* found it so return the fn & let lua call it */
1158  lua_remove(L,-2); /* stack tidy, remove metatable */
1159  return 1;
1160  }
1161  lua_pop(L,1); /* remove whatever was there */
1162  return 0;
1163 }
1164 
1166 {
1167 /* there should be 3 params passed in
1168  (1) table (not the meta table)
1169  (2) string name of the attribute
1170  (3) any for the new value
1171 */
1172 
1173  assert(lua_istable(L,1));
1174  lua_getmetatable(L,1); /* get the meta table */
1175  assert(lua_istable(L,-1));
1176 
1177  SWIG_Lua_get_table(L,".set"); /* find the .set table */
1178  if (lua_istable(L,-1))
1179  {
1180  /* look for the key in the .set table */
1181  lua_pushvalue(L,2); /* key */
1182  lua_rawget(L,-2);
1183  if (lua_iscfunction(L,-1))
1184  { /* found it so call the fn & return its value */
1185  lua_pushvalue(L,3); /* value */
1186  lua_call(L,1,0);
1187  return 0;
1188  }
1189  lua_pop(L,1); /* remove the value */
1190  }
1191  lua_pop(L,1); /* remove the value .set table */
1192  return 0;
1193 }
1194 
1195 SWIGINTERN void SWIG_Lua_InstallConstants(lua_State* L, swig_lua_const_info constants[]); // forward declaration
1196 SWIGINTERN void SWIG_Lua_add_class_variable(lua_State* L,const char* name,lua_CFunction getFn,lua_CFunction setFn); // forward declaration
1197 
1198 /* helper function - register namespace methods and attributes into namespace */
1200 {
1201  int i = 0;
1202  assert(lua_istable(L,-1));
1203  /* There must be table at the top of the stack */
1205 
1206  lua_getmetatable(L,-1);
1207 
1208  /* add fns */
1209  for(i=0;ns->ns_attributes[i].name;i++){
1211  }
1212 
1213  /* add methods to the metatable */
1214  SWIG_Lua_get_table(L,".fn"); /* find the .fn table */
1215  assert(lua_istable(L,-1)); /* just in case */
1216  for(i=0;ns->ns_methods[i].name;i++){
1218  }
1219  lua_pop(L,1);
1220 
1221  /* clear stack - remove metatble */
1222  lua_pop(L,1);
1223  return 0;
1224 }
1225 
1226 /* helper function. creates namespace table and add it to module table */
1228 {
1229  assert(lua_istable(L,-1)); /* just in case. This is supposed to be module table */
1230  lua_checkstack(L,5);
1231  lua_pushstring(L, ns->name);
1232  lua_newtable(L); /* namespace itself */
1233  lua_newtable(L); /* metatable for namespace */
1234 
1235  /* add a table called ".get" */
1236  lua_pushstring(L,".get");
1237  lua_newtable(L);
1238  lua_rawset(L,-3);
1239  /* add a table called ".set" */
1240  lua_pushstring(L,".set");
1241  lua_newtable(L);
1242  lua_rawset(L,-3);
1243  /* add a table called ".fn" */
1244  lua_pushstring(L,".fn");
1245  lua_newtable(L);
1246  lua_rawset(L,-3);
1247 
1248  /* add accessor fns for using the .get,.set&.fn */
1251 
1252  lua_setmetatable(L,-2); /* set metatable */
1253  lua_rawset(L,-3); /* add namespace to module table */
1254  return 0;
1255 }
1256 /* -----------------------------------------------------------------------------
1257  * global variable support code: classes
1258  * ----------------------------------------------------------------------------- */
1259 
1260 /* the class.get method, performs the lookup of class attributes */
1262 {
1263 /* there should be 2 params passed in
1264  (1) userdata (not the meta table)
1265  (2) string name of the attribute
1266 */
1267  assert(lua_isuserdata(L,-2)); /* just in case */
1268  lua_getmetatable(L,-2); /* get the meta table */
1269  assert(lua_istable(L,-1)); /* just in case */
1270  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1271  assert(lua_istable(L,-1)); /* just in case */
1272  /* look for the key in the .get table */
1273  lua_pushvalue(L,2); /* key */
1274  lua_rawget(L,-2);
1275  lua_remove(L,-2); /* stack tidy, remove .get table */
1276  if (lua_iscfunction(L,-1))
1277  { /* found it so call the fn & return its value */
1278  lua_pushvalue(L,1); /* the userdata */
1279  lua_call(L,1,1); /* 1 value in (userdata),1 out (result) */
1280  lua_remove(L,-2); /* stack tidy, remove metatable */
1281  return 1;
1282  }
1283  lua_pop(L,1); /* remove whatever was there */
1284  /* ok, so try the .fn table */
1285  SWIG_Lua_get_table(L,".fn"); /* find the .get table */
1286  assert(lua_istable(L,-1)); /* just in case */
1287  lua_pushvalue(L,2); /* key */
1288  lua_rawget(L,-2); /* look for the fn */
1289  lua_remove(L,-2); /* stack tidy, remove .fn table */
1290  if (lua_isfunction(L,-1)) /* note: if its a C function or lua function */
1291  { /* found it so return the fn & let lua call it */
1292  lua_remove(L,-2); /* stack tidy, remove metatable */
1293  return 1;
1294  }
1295  lua_pop(L,1); /* remove whatever was there */
1296  /* NEW: looks for the __getitem() fn
1297  this is a user provided get fn */
1298  SWIG_Lua_get_table(L,"__getitem"); /* find the __getitem fn */
1299  if (lua_iscfunction(L,-1)) /* if its there */
1300  { /* found it so call the fn & return its value */
1301  lua_pushvalue(L,1); /* the userdata */
1302  lua_pushvalue(L,2); /* the parameter */
1303  lua_call(L,2,1); /* 2 value in (userdata),1 out (result) */
1304  lua_remove(L,-2); /* stack tidy, remove metatable */
1305  return 1;
1306  }
1307  return 0; /* sorry not known */
1308 }
1309 
1310 /* the class.set method, performs the lookup of class attributes */
1312 {
1313 /* there should be 3 params passed in
1314  (1) table (not the meta table)
1315  (2) string name of the attribute
1316  (3) any for the new value
1317 printf("SWIG_Lua_class_set %p(%s) '%s' %p(%s)\n",
1318  lua_topointer(L,1),lua_typename(L,lua_type(L,1)),
1319  lua_tostring(L,2),
1320  lua_topointer(L,3),lua_typename(L,lua_type(L,3)));*/
1321 
1322  assert(lua_isuserdata(L,1)); /* just in case */
1323  lua_getmetatable(L,1); /* get the meta table */
1324  assert(lua_istable(L,-1)); /* just in case */
1325 
1326  SWIG_Lua_get_table(L,".set"); /* find the .set table */
1327  if (lua_istable(L,-1))
1328  {
1329  /* look for the key in the .set table */
1330  lua_pushvalue(L,2); /* key */
1331  lua_rawget(L,-2);
1332  if (lua_iscfunction(L,-1))
1333  { /* found it so call the fn & return its value */
1334  lua_pushvalue(L,1); /* userdata */
1335  lua_pushvalue(L,3); /* value */
1336  lua_call(L,2,0);
1337  return 0;
1338  }
1339  lua_pop(L,1); /* remove the value */
1340  }
1341  lua_pop(L,1); /* remove the value .set table */
1342  /* NEW: looks for the __setitem() fn
1343  this is a user provided set fn */
1344  SWIG_Lua_get_table(L,"__setitem"); /* find the fn */
1345  if (lua_iscfunction(L,-1)) /* if its there */
1346  { /* found it so call the fn & return its value */
1347  lua_pushvalue(L,1); /* the userdata */
1348  lua_pushvalue(L,2); /* the parameter */
1349  lua_pushvalue(L,3); /* the value */
1350  lua_call(L,3,0); /* 3 values in ,0 out */
1351  lua_remove(L,-2); /* stack tidy, remove metatable */
1352  return 1;
1353  }
1354  return 0;
1355 }
1356 
1357 /* the class.destruct method called by the interpreter */
1359 {
1360 /* there should be 1 params passed in
1361  (1) userdata (not the meta table) */
1362  swig_lua_userdata* usr;
1363  swig_lua_class* clss;
1364  assert(lua_isuserdata(L,-1)); /* just in case */
1365  usr=(swig_lua_userdata*)lua_touserdata(L,-1); /* get it */
1366  /* if must be destroyed & has a destructor */
1367  if (usr->own) /* if must be destroyed */
1368  {
1369  clss=(swig_lua_class*)usr->type->clientdata; /* get the class */
1370  if (clss && clss->destructor) /* there is a destroy fn */
1371  {
1372  clss->destructor(usr->ptr); /* bye bye */
1373  }
1374  }
1375  return 0;
1376 }
1377 
1378 /* the class.__tostring method called by the interpreter and print */
1380 {
1381 /* there should be 1 param passed in
1382  (1) userdata (not the metatable) */
1383  assert(lua_isuserdata(L,1)); /* just in case */
1384  unsigned long userData = (unsigned long)lua_touserdata(L,1); /* get the userdata address for later */
1385  lua_getmetatable(L,1); /* get the meta table */
1386  assert(lua_istable(L,-1)); /* just in case */
1387 
1388  lua_getfield(L, -1, ".type");
1389  const char* className = lua_tostring(L, -1);
1390 
1391  char output[256];
1392  sprintf(output, "<%s userdata: %lX>", className, userData);
1393 
1394  lua_pushstring(L, (const char*)output);
1395  return 1;
1396 }
1397 
1398 /* to manually disown some userdata */
1400 {
1401 /* there should be 1 params passed in
1402  (1) userdata (not the meta table) */
1403  swig_lua_userdata* usr;
1404  assert(lua_isuserdata(L,-1)); /* just in case */
1405  usr=(swig_lua_userdata*)lua_touserdata(L,-1); /* get it */
1406 
1407  usr->own = 0; /* clear our ownership */
1408  return 0;
1409 }
1410 
1411 /* Constructor proxy. Used when class name entry in module is not class constructor,
1412 but special table instead. */
1414 {
1415  /* unlimited number of parameters
1416  First one is our proxy table and we should remove it
1417  Other we should pass to real constructor
1418  */
1419  assert(lua_istable(L,1));
1420  lua_pushstring(L,".constructor");
1421  lua_rawget(L,1);
1422  assert(!lua_isnil(L,-1));
1423  lua_replace(L,1); /* replace our table with real constructor */
1424  lua_call(L,lua_gettop(L)-1,1);
1425  return 1;
1426 }
1427 
1428 /* gets the swig class registry (or creates it) */
1430 {
1431  /* add this all into the swig registry: */
1432  lua_pushstring(L,"SWIG");
1433  lua_rawget(L,LUA_REGISTRYINDEX); /* get the registry */
1434  if (!lua_istable(L,-1)) /* not there */
1435  { /* must be first time, so add it */
1436  lua_pop(L,1); /* remove the result */
1437  lua_pushstring(L,"SWIG");
1438  lua_newtable(L);
1439  lua_rawset(L,LUA_REGISTRYINDEX);
1440  /* then get it */
1441  lua_pushstring(L,"SWIG");
1442  lua_rawget(L,LUA_REGISTRYINDEX);
1443  }
1444 }
1445 
1446 /* helper fn to get the classes metatable from the register */
1447 SWIGINTERN void SWIG_Lua_get_class_metatable(lua_State* L,const char* cname)
1448 {
1449  SWIG_Lua_get_class_registry(L); /* get the registry */
1450  lua_pushstring(L,cname); /* get the name */
1451  lua_rawget(L,-2); /* get it */
1452  lua_remove(L,-2); /* tidy up (remove registry) */
1453 }
1454 
1455 /* helper add a variable to a registered class */
1456 SWIGINTERN void SWIG_Lua_add_class_variable(lua_State* L,const char* name,lua_CFunction getFn,lua_CFunction setFn)
1457 {
1458  assert(lua_istable(L,-1)); /* just in case */
1459  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1460  assert(lua_istable(L,-1)); /* just in case */
1461  SWIG_Lua_add_function(L,name,getFn);
1462  lua_pop(L,1); /* tidy stack (remove table) */
1463  if (setFn)
1464  {
1465  SWIG_Lua_get_table(L,".set"); /* find the .set table */
1466  assert(lua_istable(L,-1)); /* just in case */
1467  SWIG_Lua_add_function(L,name,setFn);
1468  lua_pop(L,1); /* tidy stack (remove table) */
1469  }
1470 }
1471 
1472 /* helper to recursively add class static details (static attributes, operations and constants) */
1474 {
1475  int i = 0;
1476  /* The class namespace table must be on the top of the stack */
1477  assert(lua_istable(L,-1));
1478  /* call all the base classes first: we can then override these later: */
1479  for(i=0;clss->bases[i];i++)
1480  {
1482  }
1483 
1485 }
1486 
1487 /* helper to recursively add class details (attributes & operations) */
1489 {
1490  int i;
1491  /* call all the base classes first: we can then override these later: */
1492  for(i=0;clss->bases[i];i++)
1493  {
1494  SWIG_Lua_add_class_details(L,clss->bases[i]);
1495  }
1496  /* add fns */
1497  for(i=0;clss->attributes[i].name;i++){
1499  }
1500  /* add methods to the metatable */
1501  SWIG_Lua_get_table(L,".fn"); /* find the .fn table */
1502  assert(lua_istable(L,-1)); /* just in case */
1503  for(i=0;clss->methods[i].name;i++){
1504  SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].method);
1505  }
1506  lua_pop(L,1); /* tidy stack (remove table) */
1507  /* add operator overloads
1508  these look ANY method which start with "__" and assume they
1509  are operator overloads & add them to the metatable
1510  (this might mess up is someone defines a method __gc (the destructor)*/
1511  for(i=0;clss->methods[i].name;i++){
1512  if (clss->methods[i].name[0]=='_' && clss->methods[i].name[1]=='_'){
1513  SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].method);
1514  }
1515  }
1516 }
1517 
1518 /* set up the base classes pointers.
1519 Each class structure has a list of pointers to the base class structures.
1520 This function fills them.
1521 It cannot be done at compile time, as this will not work with hireachies
1522 spread over more than one swig file.
1523 Therefore it must be done at runtime, querying the SWIG type system.
1524 */
1526 {
1527  int i=0;
1528  swig_module_info* module=SWIG_GetModule(L);
1529  for(i=0;clss->base_names[i];i++)
1530  {
1531  if (clss->bases[i]==0) /* not found yet */
1532  {
1533  /* lookup and cache the base class */
1534  swig_type_info *info = SWIG_TypeQueryModule(module,module,clss->base_names[i]);
1535  if (info) clss->bases[i] = (swig_lua_class *) info->clientdata;
1536  }
1537  }
1538 }
1539 
1540 /* Register class static methods,attributes etc as well as constructor proxy */
1542 {
1543  lua_checkstack(L,5); /* just in case */
1544  assert(lua_istable(L,-1)); /* just in case */
1545  assert(strcmp(clss->name, clss->cls_static.name) == 0); /* in class those 2 must be equal */
1546 
1548 
1549  SWIG_Lua_get_table(L,clss->name); // Get namespace table back
1550  assert(lua_istable(L,-1)); /* just in case */
1551 
1552  /* add its constructor to module with the name of the class
1553  so you can do MyClass(...) as well as new_MyClass(...)
1554  BUT only if a constructor is defined
1555  (this overcomes the problem of pure virtual classes without constructors)*/
1556  if (clss->constructor)
1557  {
1558  SWIG_Lua_add_function(L,".constructor", clss->constructor);
1559  lua_getmetatable(L,-1);
1560  assert(lua_istable(L,-1)); /* just in case */
1562  lua_pop(L,1);
1563  }
1564 
1565  assert(lua_istable(L,-1)); /* just in case */
1567 
1568  /* clear stack */
1569  lua_pop(L,1);
1570 }
1571 
1572 /* performs the entire class registration process */
1574 {
1576 
1577  SWIG_Lua_get_class_registry(L); /* get the registry */
1578  lua_pushstring(L,clss->name); /* get the name */
1579  lua_newtable(L); /* create the metatable */
1580  /* add string of class name called ".type" */
1581  lua_pushstring(L,".type");
1582  lua_pushstring(L,clss->name);
1583  lua_rawset(L,-3);
1584  /* add a table called ".get" */
1585  lua_pushstring(L,".get");
1586  lua_newtable(L);
1587  lua_rawset(L,-3);
1588  /* add a table called ".set" */
1589  lua_pushstring(L,".set");
1590  lua_newtable(L);
1591  lua_rawset(L,-3);
1592  /* add a table called ".fn" */
1593  lua_pushstring(L,".fn");
1594  lua_newtable(L);
1595  /* add manual disown method */
1597  lua_rawset(L,-3);
1598  /* add accessor fns for using the .get,.set&.fn */
1600  SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_class_set);
1602  /* add tostring method for better output */
1604  /* add it */
1605  lua_rawset(L,-3); /* metatable into registry */
1606  lua_pop(L,1); /* tidy stack (remove registry) */
1607 
1609  SWIG_Lua_add_class_details(L,clss); /* recursive adding of details (atts & ops) */
1610  lua_pop(L,1); /* tidy stack (remove class metatable) */
1611 }
1612 
1613 /* -----------------------------------------------------------------------------
1614  * Class/structure conversion fns
1615  * ----------------------------------------------------------------------------- */
1616 
1617 /* helper to add metatable to new lua object */
1619 {
1620  if (type->clientdata) /* there is clientdata: so add the metatable */
1621  {
1623  if (lua_istable(L,-1))
1624  {
1625  lua_setmetatable(L,-2);
1626  }
1627  else
1628  {
1629  lua_pop(L,1);
1630  }
1631  }
1632 }
1633 
1634 /* pushes a new object into the lua stack */
1635 SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State* L,void* ptr,swig_type_info *type, int own)
1636 {
1637  swig_lua_userdata* usr;
1638  if (!ptr){
1639  lua_pushnil(L);
1640  return;
1641  }
1642  usr=(swig_lua_userdata*)lua_newuserdata(L,sizeof(swig_lua_userdata)); /* get data */
1643  usr->ptr=ptr; /* set the ptr */
1644  usr->type=type;
1645  usr->own=own;
1646 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
1647  _SWIG_Lua_AddMetatable(L,type); /* add metatable */
1648 #endif
1649 }
1650 
1651 /* takes a object from the lua stack & converts it into an object of the correct type
1652  (if possible) */
1653 SWIGRUNTIME int SWIG_Lua_ConvertPtr(lua_State* L,int index,void** ptr,swig_type_info *type,int flags)
1654 {
1655  swig_lua_userdata* usr;
1656  swig_cast_info *cast;
1657  if (lua_isnil(L,index)){*ptr=0; return SWIG_OK;} /* special case: lua nil => NULL pointer */
1658  usr=(swig_lua_userdata*)lua_touserdata(L,index); /* get data */
1659  if (usr)
1660  {
1661  if (flags & SWIG_POINTER_DISOWN) /* must disown the object */
1662  {
1663  usr->own=0;
1664  }
1665  if (!type) /* special cast void*, no casting fn */
1666  {
1667  *ptr=usr->ptr;
1668  return SWIG_OK; /* ok */
1669  }
1670  cast=SWIG_TypeCheckStruct(usr->type,type); /* performs normal type checking */
1671  if (cast)
1672  {
1673  int newmemory = 0;
1674  *ptr=SWIG_TypeCast(cast,usr->ptr,&newmemory);
1675  assert(!newmemory); /* newmemory handling not yet implemented */
1676  return SWIG_OK; /* ok */
1677  }
1678  }
1679  return SWIG_ERROR; /* error */
1680 }
1681 
1682 SWIGRUNTIME void* SWIG_Lua_MustGetPtr(lua_State* L,int index,swig_type_info *type,int flags,
1683  int argnum,const char* func_name){
1684  void* result;
1685  if (!SWIG_IsOK(SWIG_ConvertPtr(L,index,&result,type,flags))){
1686  luaL_error (L,"Error in %s, expected a %s at argument number %d\n",
1687  func_name,(type && type->str)?type->str:"void*",argnum);
1688  }
1689  return result;
1690 }
1691 
1692 /* pushes a packed userdata. user for member fn pointers only */
1693 SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State* L,void* ptr,size_t size,swig_type_info *type)
1694 {
1695  swig_lua_rawdata* raw;
1696  assert(ptr); /* not acceptable to pass in a NULL value */
1697  raw=(swig_lua_rawdata*)lua_newuserdata(L,sizeof(swig_lua_rawdata)-1+size); /* alloc data */
1698  raw->type=type;
1699  raw->own=0;
1700  memcpy(raw->data,ptr,size); /* copy the data */
1701  _SWIG_Lua_AddMetatable(L,type); /* add metatable */
1702 }
1703 
1704 /* converts a packed userdata. user for member fn pointers only */
1705 SWIGRUNTIME int SWIG_Lua_ConvertPacked(lua_State* L,int index,void* ptr,size_t size,swig_type_info *type)
1706 {
1707  swig_lua_rawdata* raw;
1708  raw=(swig_lua_rawdata*)lua_touserdata(L,index); /* get data */
1709  if (!raw) return SWIG_ERROR; /* error */
1710  if (type==0 || type==raw->type) /* void* or identical type */
1711  {
1712  memcpy(ptr,raw->data,size); /* copy it */
1713  return SWIG_OK; /* ok */
1714  }
1715  return SWIG_ERROR; /* error */
1716 }
1717 
1718 /* a function to get the typestring of a piece of data */
1719 SWIGRUNTIME const char *SWIG_Lua_typename(lua_State *L, int tp)
1720 {
1721  swig_lua_userdata* usr;
1722  if (lua_isuserdata(L,tp))
1723  {
1724  usr=(swig_lua_userdata*)lua_touserdata(L,tp); /* get data */
1725  if (usr && usr->type && usr->type->str)
1726  return usr->type->str;
1727  return "userdata (unknown type)";
1728  }
1729  return lua_typename(L,lua_type(L,tp));
1730 }
1731 
1732 /* lua callable function to get the userdata's type */
1733 SWIGRUNTIME int SWIG_Lua_type(lua_State* L)
1734 {
1735  lua_pushstring(L,SWIG_Lua_typename(L,1));
1736  return 1;
1737 }
1738 
1739 /* lua callable function to compare userdata's value
1740 the issue is that two userdata may point to the same thing
1741 but to lua, they are different objects */
1742 SWIGRUNTIME int SWIG_Lua_equal(lua_State* L)
1743 {
1744  int result;
1745  swig_lua_userdata *usr1,*usr2;
1746  if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2)) /* just in case */
1747  return 0; /* nil reply */
1748  usr1=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */
1749  usr2=(swig_lua_userdata*)lua_touserdata(L,2); /* get data */
1750  /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/
1751  result=(usr1->ptr==usr2->ptr);
1752  lua_pushboolean(L,result);
1753  return 1;
1754 }
1755 
1756 /* -----------------------------------------------------------------------------
1757  * global variable support code: class/struct typemap functions
1758  * ----------------------------------------------------------------------------- */
1759 
1760 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
1761 /* Install Constants */
1762 SWIGINTERN void
1764  int i;
1765  for (i = 0; constants[i].type; i++) {
1766  switch(constants[i].type) {
1767  case SWIG_LUA_INT:
1768  lua_pushstring(L,constants[i].name);
1769  lua_pushnumber(L,(lua_Number)constants[i].lvalue);
1770  lua_rawset(L,-3);
1771  break;
1772  case SWIG_LUA_FLOAT:
1773  lua_pushstring(L,constants[i].name);
1774  lua_pushnumber(L,(lua_Number)constants[i].dvalue);
1775  lua_rawset(L,-3);
1776  break;
1777  case SWIG_LUA_CHAR:
1778  lua_pushstring(L,constants[i].name);
1779  lua_pushfstring(L,"%c",(char)constants[i].lvalue);
1780  lua_rawset(L,-3);
1781  break;
1782  case SWIG_LUA_STRING:
1783  lua_pushstring(L,constants[i].name);
1784  lua_pushstring(L,(char *) constants[i].pvalue);
1785  lua_rawset(L,-3);
1786  break;
1787  case SWIG_LUA_POINTER:
1788  lua_pushstring(L,constants[i].name);
1789  SWIG_NewPointerObj(L,constants[i].pvalue, *(constants[i]).ptype,0);
1790  lua_rawset(L,-3);
1791  break;
1792  case SWIG_LUA_BINARY:
1793  lua_pushstring(L,constants[i].name);
1794  SWIG_NewMemberObj(L,constants[i].pvalue,constants[i].lvalue,*(constants[i]).ptype);
1795  lua_rawset(L,-3);
1796  break;
1797  default:
1798  break;
1799  }
1800  }
1801 }
1802 #endif
1803 
1804 /* -----------------------------------------------------------------------------
1805  * executing lua code from within the wrapper
1806  * ----------------------------------------------------------------------------- */
1807 
1808 #ifndef SWIG_DOSTRING_FAIL /* Allows redefining of error function */
1809 #define SWIG_DOSTRING_FAIL(S) fprintf(stderr,"%s\n",S)
1810 #endif
1811 /* Executes a C string in Lua which is a really simple way of calling lua from C
1812 Unfortunately lua keeps changing its APIs, so we need a conditional compile
1813 In lua 5.0.X its lua_dostring()
1814 In lua 5.1.X its luaL_dostring()
1815 */
1816 SWIGINTERN int
1817 SWIG_Lua_dostring(lua_State *L, const char* str) {
1818  int ok,top;
1819  if (str==0 || str[0]==0) return 0; /* nothing to do */
1820  top=lua_gettop(L); /* save stack */
1821 #if (defined(LUA_VERSION_NUM) && (LUA_VERSION_NUM>=501))
1822  ok=luaL_dostring(L,str); /* looks like this is lua 5.1.X or later, good */
1823 #else
1824  ok=lua_dostring(L,str); /* might be lua 5.0.x, using lua_dostring */
1825 #endif
1826  if (ok!=0) {
1827  SWIG_DOSTRING_FAIL(lua_tostring(L,-1));
1828  }
1829  lua_settop(L,top); /* restore the stack */
1830  return ok;
1831 }
1832 
1833 #ifdef __cplusplus
1834 }
1835 #endif
1836 
1837 /* ------------------------------ end luarun.swg ------------------------------ */
1838 
1839 
1840 /* -------- TYPES TABLE (BEGIN) -------- */
1841 
1842 #define SWIGTYPE_p_PLGraphicsIn swig_types[0]
1843 #define SWIGTYPE_p_char swig_types[1]
1844 #define SWIGTYPE_p_double swig_types[2]
1845 #define SWIGTYPE_p_f_double_double__int swig_types[3]
1846 #define SWIGTYPE_p_f_double_double_p_double_p_double_p_void__void swig_types[4]
1847 #define SWIGTYPE_p_f_int_double_p_char_int_p_void__void swig_types[5]
1848 #define SWIGTYPE_p_f_int_p_double_p_double__void swig_types[6]
1849 #define SWIGTYPE_p_f_int_p_q_const__double_p_q_const__double__void swig_types[7]
1850 #define SWIGTYPE_p_int swig_types[8]
1851 #define SWIGTYPE_p_p_char swig_types[9]
1852 #define SWIGTYPE_p_p_double swig_types[10]
1853 #define SWIGTYPE_p_unsigned_int swig_types[11]
1855 static swig_module_info swig_module = {swig_types, 12, 0, 0, 0, 0};
1856 #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
1857 #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
1858 
1859 /* -------- TYPES TABLE (END) -------- */
1860 
1861 #define SWIG_name "plplotluac"
1862 #define SWIG_init luaopen_plplotluac
1863 #define SWIG_init_user luaopen_plplotluac_user
1864 
1865 #define SWIG_LUACODE luaopen_plplotluac_luacode
1866 
1867 #include "plplotP.h"
1868 
1869 
1870 #define LUA_ALLOC_ARRAY( TYPE, LEN ) (TYPE *) malloc( LEN * sizeof ( TYPE ) )
1871 #define LUA_FREE_ARRAY( PTR ) if ( PTR ) { free( PTR ); PTR = NULL;}
1872 
1873 // super macro to declare array typemap helper fns
1874  SWIGINTERN int SWIG_itable_size( lua_State* L, int index );
1875 #define LUA_DECLARE_TYPEMAP_ARR_FN( NAME, TYPE ) \
1876  SWIGINTERN int LUA_read_ ## NAME ## _num_array( lua_State * L, int index, TYPE * array, int size ){ \
1877  int i; \
1878  for ( i = 0; i < size; i++ ) { \
1879  lua_rawgeti( L, index, i + 1 ); \
1880  if ( lua_isnumber( L, -1 ) ) { \
1881  array[i] = (TYPE) lua_tonumber( L, -1 ); \
1882  } else { \
1883  lua_pop( L, 1 ); \
1884  return 0; \
1885  } \
1886  lua_pop( L, 1 ); \
1887  } \
1888  return 1; \
1889  } \
1890  SWIGINTERN TYPE* LUA_get_ ## NAME ## _num_array_var( lua_State * L, int index, int* size ) \
1891  { \
1892  TYPE *array; \
1893  if ( !lua_istable( L, index ) ) { \
1894  lua_pushstring( L, "expected a table" ); \
1895  return 0; \
1896  } \
1897  *size = SWIG_itable_size( L, index ); \
1898  if ( *size < 1 ) { \
1899  array = LUA_ALLOC_ARRAY( TYPE, 1 ); \
1900  array[0] = (TYPE) 0; \
1901  return array; \
1902  } \
1903  array = LUA_ALLOC_ARRAY( TYPE, *size ); \
1904  if ( !LUA_read_ ## NAME ## _num_array( L, index, array, *size ) ) { \
1905  lua_pushstring( L, "table must contain numbers" ); \
1906  LUA_FREE_ARRAY( array ); \
1907  return 0; \
1908  } \
1909  return array; \
1910  }
1911 
1912  LUA_DECLARE_TYPEMAP_ARR_FN( double, double );
1913  LUA_DECLARE_TYPEMAP_ARR_FN( int, int );
1914 
1915 
1916  static PLINT Alen = 0;
1917  static PLINT Xlen = 0, Ylen = 0;
1918 
1919 
1920 #ifdef __cplusplus /* generic alloc/dealloc fns*/
1921 #define SWIG_ALLOC_ARRAY(TYPE,LEN) new TYPE[LEN]
1922 #define SWIG_FREE_ARRAY(PTR) delete[] PTR
1923 #else
1924 #define SWIG_ALLOC_ARRAY(TYPE,LEN) (TYPE *)malloc(LEN*sizeof(TYPE))
1925 #define SWIG_FREE_ARRAY(PTR) free(PTR)
1926 #endif
1927 /* counting the size of arrays:*/
1928 SWIGINTERN int SWIG_itable_size(lua_State* L, int index)
1929 {
1930  int n=0;
1931  while(1){
1932  lua_rawgeti(L,index,n+1);
1933  if (lua_isnil(L,-1))break;
1934  ++n;
1935  lua_pop(L,1);
1936  }
1937  lua_pop(L,1);
1938  return n;
1939 }
1940 
1941 SWIGINTERN int SWIG_table_size(lua_State* L, int index)
1942 {
1943  int n=0;
1944  lua_pushnil(L); /* first key*/
1945  while (lua_next(L, index) != 0) {
1946  ++n;
1947  lua_pop(L, 1); /* removes `value'; keeps `key' for next iteration*/
1948  }
1949  return n;
1950 }
1951 
1952 /* super macro to declare array typemap helper fns */
1953 #define SWIG_DECLARE_TYPEMAP_ARR_FN(NAME,TYPE)\
1954  SWIGINTERN int SWIG_read_##NAME##_num_array(lua_State* L,int index,TYPE *array,int size){\
1955  int i;\
1956  for (i = 0; i < size; i++) {\
1957  lua_rawgeti(L,index,i+1);\
1958  if (lua_isnumber(L,-1)){\
1959  array[i] = (TYPE)lua_tonumber(L,-1);\
1960  } else {\
1961  lua_pop(L,1);\
1962  return 0;\
1963  }\
1964  lua_pop(L,1);\
1965  }\
1966  return 1;\
1967  }\
1968  SWIGINTERN TYPE* SWIG_get_##NAME##_num_array_fixed(lua_State* L, int index, int size){\
1969  TYPE *array;\
1970  if (!lua_istable(L,index) || SWIG_itable_size(L,index) != size) {\
1971  SWIG_Lua_pushferrstring(L,"expected a table of size %d",size);\
1972  return 0;\
1973  }\
1974  array=SWIG_ALLOC_ARRAY(TYPE,size);\
1975  if (!SWIG_read_##NAME##_num_array(L,index,array,size)){\
1976  SWIG_Lua_pusherrstring(L,"table must contain numbers");\
1977  SWIG_FREE_ARRAY(array);\
1978  return 0;\
1979  }\
1980  return array;\
1981  }\
1982  SWIGINTERN TYPE* SWIG_get_##NAME##_num_array_var(lua_State* L, int index, int* size)\
1983  {\
1984  TYPE *array;\
1985  if (!lua_istable(L,index)) {\
1986  SWIG_Lua_pusherrstring(L,"expected a table");\
1987  return 0;\
1988  }\
1989  *size=SWIG_itable_size(L,index);\
1990  if (*size<1){\
1991  SWIG_Lua_pusherrstring(L,"table appears to be empty");\
1992  return 0;\
1993  }\
1994  array=SWIG_ALLOC_ARRAY(TYPE,*size);\
1995  if (!SWIG_read_##NAME##_num_array(L,index,array,*size)){\
1996  SWIG_Lua_pusherrstring(L,"table must contain numbers");\
1997  SWIG_FREE_ARRAY(array);\
1998  return 0;\
1999  }\
2000  return array;\
2001  }\
2002  SWIGINTERN void SWIG_write_##NAME##_num_array(lua_State* L,TYPE *array,int size){\
2003  int i;\
2004  lua_newtable(L);\
2005  for (i = 0; i < size; i++){\
2006  lua_pushnumber(L,(lua_Number)array[i]);\
2007  lua_rawseti(L,-2,i+1);/* -1 is the number, -2 is the table*/ \
2008  }\
2009  }
2010 
2011 SWIG_DECLARE_TYPEMAP_ARR_FN(schar,signed char);
2012 SWIG_DECLARE_TYPEMAP_ARR_FN(uchar,unsigned char);
2014 SWIG_DECLARE_TYPEMAP_ARR_FN(uint,unsigned int);
2015 SWIG_DECLARE_TYPEMAP_ARR_FN(short,short);
2016 SWIG_DECLARE_TYPEMAP_ARR_FN(ushort,unsigned short);
2017 SWIG_DECLARE_TYPEMAP_ARR_FN(long,long);
2018 SWIG_DECLARE_TYPEMAP_ARR_FN(ulong,unsigned long);
2019 SWIG_DECLARE_TYPEMAP_ARR_FN(float,float);
2020 SWIG_DECLARE_TYPEMAP_ARR_FN(double,double);
2021 
2022 SWIGINTERN int SWIG_read_ptr_array(lua_State* L,int index,void **array,int size,swig_type_info *type){
2023  int i;
2024  for (i = 0; i < size; i++) {
2025  lua_rawgeti(L,index,i+1);
2026  if (!lua_isuserdata(L,-1) || SWIG_ConvertPtr(L,-1,&array[i],type,0)==-1){
2027  lua_pop(L,1);
2028  return 0;
2029  }
2030  lua_pop(L,1);
2031  }
2032  return 1;
2033 }
2034 SWIGINTERN void** SWIG_get_ptr_array_fixed(lua_State* L, int index, int size,swig_type_info *type){
2035  void **array;
2036  if (!lua_istable(L,index) || SWIG_itable_size(L,index) != size) {
2037  SWIG_Lua_pushferrstring(L,"expected a table of size %d",size);
2038  return 0;
2039  }
2040  array=SWIG_ALLOC_ARRAY(void*,size);
2041  if (!SWIG_read_ptr_array(L,index,array,size,type)){
2042  SWIG_Lua_pushferrstring(L,"table must contain pointers of type %s",type->name);
2043  SWIG_FREE_ARRAY(array);
2044  return 0;
2045  }
2046  return array;
2047 }
2048 SWIGINTERN void** SWIG_get_ptr_array_var(lua_State* L, int index, int* size,swig_type_info *type){
2049  void **array;
2050  if (!lua_istable(L,index)) {
2051  SWIG_Lua_pusherrstring(L,"expected a table");
2052  return 0;
2053  }
2054  *size=SWIG_itable_size(L,index);
2055  if (*size<1){
2056  SWIG_Lua_pusherrstring(L,"table appears to be empty");
2057  return 0;
2058  }
2059  array=SWIG_ALLOC_ARRAY(void*,*size);
2060  if (!SWIG_read_ptr_array(L,index,array,*size,type)){
2061  SWIG_Lua_pushferrstring(L,"table must contain pointers of type %s",type->name);
2062  SWIG_FREE_ARRAY(array);
2063  return 0;
2064  }
2065  return array;
2066 }
2067 SWIGINTERN void SWIG_write_ptr_array(lua_State* L,void **array,int size,swig_type_info *type,int own){
2068  int i;
2069  lua_newtable(L);
2070  for (i = 0; i < size; i++){
2071  SWIG_NewPointerObj(L,array[i],type,own);
2072  lua_rawseti(L,-2,i+1);/* -1 is the number, -2 is the table*/
2073  }
2074 }
2075 
2076 
2077  PLFLT** read_double_Matrix( lua_State* L, int index, int* nx, int *ny );
2078 
2079  PLFLT** read_double_Matrix( lua_State* L, int index, int* nx, int *ny )
2080  {
2081  int i, j;
2082  PLFLT** matrix;
2083 
2084  *nx = 0;
2085  *ny = 0;
2086 
2087  if ( !lua_istable( L, index ) )
2088  {
2089  lua_pushstring( L, "expected a table" );
2090  return NULL;
2091  }
2092  *nx = SWIG_itable_size( L, index );
2093  if ( *nx < 1 )
2094  {
2095  lua_pushstring( L, "table appears to be empty" );
2096  return NULL;
2097  }
2098  matrix = LUA_ALLOC_ARRAY( PLFLT *, *nx );
2099  for ( i = 0; i < *nx; i++ )
2100  matrix[i] = NULL;
2101 
2102  lua_rawgeti( L, index, 1 );
2103  if ( !lua_istable( L, -1 ) )
2104  {
2105  lua_pop( L, 1 );
2106  lua_pushstring( L, "expected a table" );
2107  LUA_FREE_ARRAY( matrix );
2108  return NULL;
2109  }
2110  *ny = SWIG_itable_size( L, -1 );
2111  if ( *ny < 1 )
2112  {
2113  lua_pushstring( L, "table appears to be empty" );
2114  LUA_FREE_ARRAY( matrix );
2115  return NULL;
2116  }
2117  lua_pop( L, 1 );
2118 
2119  for ( i = 0; i < *nx; i++ )
2120  {
2121  lua_rawgeti( L, index, i + 1 );
2122  if ( !lua_istable( L, -1 ) )
2123  {
2124  lua_pop( L, 1 );
2125  lua_pushstring( L, "expected a table" );
2126  for ( j = 0; j < *ny; j++ )
2127  LUA_FREE_ARRAY( matrix[j] );
2128  LUA_FREE_ARRAY( matrix );
2129  return NULL;
2130  }
2131  if ( *ny != SWIG_itable_size( L, -1 ) )
2132  {
2133  lua_pop( L, 1 );
2134  lua_pushstring( L, "inconsistent table sizes" );
2135  for ( j = 0; j < i; j++ )
2136  LUA_FREE_ARRAY( matrix[j] );
2137  LUA_FREE_ARRAY( matrix );
2138  return NULL;
2139  }
2140  matrix[i] = LUA_ALLOC_ARRAY( PLFLT, *ny );
2141  for ( j = 0; j < *ny; j++ )
2142  {
2143  lua_rawgeti( L, -1, j + 1 );
2144  if ( lua_isnumber( L, -1 ) )
2145  {
2146  matrix[i][j] = (PLFLT) lua_tonumber( L, -1 );
2147  }
2148  else
2149  {
2150  lua_pop( L, 1 );
2151  lua_pushstring( L, "table must contain numbers" );
2152  for ( j = 0; j < i + 1; j++ )
2153  LUA_FREE_ARRAY( matrix[j] );
2154  LUA_FREE_ARRAY( matrix );
2155  return NULL;
2156  }
2157  lua_pop( L, 1 );
2158  }
2159  lua_pop( L, 1 );
2160  }
2161 
2162  return matrix;
2163  }
2164 
2165 
2166  void mapform( PLINT n, PLFLT* x, PLFLT* y );
2167 
2168  static lua_State* myL = NULL;
2169  static char mapform_funcstr[255];
2170 
2171  void mapform( PLINT n, PLFLT* x, PLFLT* y )
2172  {
2173  PLFLT *xtemp, *ytemp;
2174  int len, i;
2175 
2176  // check Lua state
2177  if ( myL == NULL )
2178  {
2179  fprintf( stderr, "Lua state is not set!" );
2180  return;
2181  }
2182 
2183  // push functions and arguments
2184  lua_getglobal( myL, mapform_funcstr ); // function to be called
2185  lua_pushnumber( myL, n ); // push 1st argument
2186  SWIG_write_double_num_array( myL, x, n ); // push 2nd argument
2187  SWIG_write_double_num_array( myL, y, n ); // push 3rd argument
2188 
2189  // do the call (3 arguments, 2 result)
2190  if ( lua_pcall( myL, 3, 2, 0 ) != 0 )
2191  fprintf( stderr, "error running function `%s':%s",
2192  mapform_funcstr, lua_tostring( myL, -1 ) );
2193 
2194  // retrieve results
2195  if ( !lua_istable( myL, -2 ) )
2196  {
2197  fprintf( stderr, "function `%s' must return a table as 1st result", mapform_funcstr );
2198  return;
2199  }
2200  if ( !lua_istable( myL, -1 ) )
2201  {
2202  fprintf( stderr, "function `%s' must return a table as 2nd result", mapform_funcstr );
2203  return;
2204  }
2205  xtemp = (PLFLT *) LUA_get_double_num_array_var( myL, -2, &len );
2206  if ( !xtemp || len != n )
2207  {
2208  fprintf( stderr, "function `%s' must return a table of length%d", mapform_funcstr, n );
2209  return;
2210  }
2211  for ( i = 0; i < n; i++ )
2212  x[i] = xtemp[i];
2213  LUA_FREE_ARRAY( xtemp );
2214 
2215  ytemp = (PLFLT *) LUA_get_double_num_array_var( myL, -1, &len );
2216  if ( !ytemp || len != n )
2217  {
2218  fprintf( stderr, "function `%s' must return a table of length%d", mapform_funcstr, n );
2219  return;
2220  }
2221  for ( i = 0; i < n; i++ )
2222  y[i] = ytemp[i];
2223  LUA_FREE_ARRAY( ytemp );
2224 
2225  lua_pop( myL, 2 ); // pop returned values
2226 
2227  return;
2228  }
2229 
2230 
2231  typedef PLINT ( *defined_func )( PLFLT, PLFLT );
2232  typedef void ( *fill_func )( PLINT, const PLFLT*, const PLFLT* );
2233  typedef void ( *pltr_func )( PLFLT, PLFLT, PLFLT *, PLFLT*, PLPointer );
2234  typedef void ( *ct_func )( PLFLT, PLFLT, PLFLT *, PLFLT*, PLPointer );
2235  typedef void ( *mapform_func )( PLINT, PLFLT *, PLFLT* );
2237  typedef void ( *label_func )( PLINT, PLFLT, char*, PLINT, PLPointer );
2238 
2239 // Function prototypes
2240  void mypltr( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * pltr_data );
2241  void myct( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * pltr_data );
2242  void mylabel( PLINT axis, PLFLT value, char* label, PLINT length, PLPointer data );
2243 
2244  static char mypltr_funcstr[255];
2245 
2246 // This is the callback that gets handed to the C code.
2247 // It, in turn, calls the Lua callback
2248  void mypltr( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * PL_UNUSED( pltr_data ) )
2249  {
2250  *tx = 0;
2251  *ty = 0;
2252 
2253  // check Lua state
2254  if ( myL == NULL )
2255  {
2256  fprintf( stderr, "Lua state is not set!" );
2257  return;
2258  }
2259 
2260  // push functions and arguments
2261  lua_getglobal( myL, mypltr_funcstr ); // function to be called
2262  lua_pushnumber( myL, x ); // push 1st argument
2263  lua_pushnumber( myL, y ); // push 2nd argument
2264 
2265  // do the call (2 arguments, 2 result)
2266  if ( lua_pcall( myL, 2, 2, 0 ) != 0 )
2267  fprintf( stderr, "error running function `%s':%s",
2268  mypltr_funcstr, lua_tostring( myL, -1 ) );
2269 
2270  // retrieve results
2271  if ( !lua_isnumber( myL, -2 ) )
2272  {
2273  fprintf( stderr, "function `%s' must return a number as 1st result", mypltr_funcstr );
2274  return;
2275  }
2276  if ( !lua_isnumber( myL, -1 ) )
2277  {
2278  fprintf( stderr, "function `%s' must return a number as 2nd result", mypltr_funcstr );
2279  return;
2280  }
2281  *tx = lua_tonumber( myL, -2 );
2282  *ty = lua_tonumber( myL, -1 );
2283  lua_pop( myL, 2 ); // pop returned values
2284 
2285  return;
2286  }
2287 
2288  static char myct_funcstr[255];
2289 
2290 // This is the callback that gets handed to the C code.
2291 // It, in turn, calls the Lua callback
2292  void myct( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * PL_UNUSED( pltr_data ) )
2293  {
2294  *tx = 0;
2295  *ty = 0;
2296 
2297  // check Lua state
2298  if ( myL == NULL )
2299  {
2300  fprintf( stderr, "Lua state is not set!" );
2301  return;
2302  }
2303 
2304  // push functions and arguments
2305  lua_getglobal( myL, myct_funcstr ); // function to be called
2306  lua_pushnumber( myL, x ); // push 1st argument
2307  lua_pushnumber( myL, y ); // push 2nd argument
2308 
2309  // do the call (2 arguments, 2 result)
2310  if ( lua_pcall( myL, 2, 2, 0 ) != 0 )
2311  fprintf( stderr, "error running function `%s':%s",
2312  myct_funcstr, lua_tostring( myL, -1 ) );
2313 
2314  // retrieve results
2315  if ( !lua_isnumber( myL, -2 ) )
2316  {
2317  fprintf( stderr, "function `%s' must return a number as 1st result", myct_funcstr );
2318  return;
2319  }
2320  if ( !lua_isnumber( myL, -1 ) )
2321  {
2322  fprintf( stderr, "function `%s' must return a number as 2nd result", myct_funcstr );
2323  return;
2324  }
2325  *tx = lua_tonumber( myL, -2 );
2326  *ty = lua_tonumber( myL, -1 );
2327  lua_pop( myL, 2 ); // pop returned values
2328 
2329  return;
2330  }
2331 
2332  static char mylabel_funcstr[255];
2333 
2334  void mylabel( PLINT axis, PLFLT value, char* label, PLINT length, PLPointer PL_UNUSED( data ) )
2335  {
2336  // check Lua state
2337  if ( myL == NULL )
2338  {
2339  fprintf( stderr, "Lua state is not set!" );
2340  return;
2341  }
2342 
2343  // push functions and arguments
2344  lua_getglobal( myL, mylabel_funcstr ); // function to be called
2345  lua_pushnumber( myL, axis ); // push 1st argument
2346  lua_pushnumber( myL, value ); // push 1st argument
2347 
2348  // do the call (2 arguments, 1 result)
2349  if ( lua_pcall( myL, 2, 1, 0 ) != 0 )
2350  fprintf( stderr, "error running function `%s':%s",
2351  mylabel_funcstr, lua_tostring( myL, -1 ) );
2352 
2353  // retrieve results
2354  if ( !lua_isstring( myL, -1 ) )
2355  {
2356  fprintf( stderr, "function `%s' must return a string as result", mylabel_funcstr );
2357  return;
2358  }
2359  strncpy( label, lua_tostring( myL, -1 ), length );
2360 
2361  lua_pop( myL, 1 ); // pop returned values
2362 
2363  return;
2364  }
2365 
2366 
2367 SWIGINTERN int SWIG_lua_isnilstring(lua_State *L, int idx) {
2368  int ret = lua_isstring(L, idx);
2369  if (!ret)
2370  ret = lua_isnil(L, idx);
2371  return ret;
2372 }
2373 
2374 #ifdef __cplusplus
2375 extern "C" {
2376 #endif
2377 static int _wrap_PLGraphicsIn_type_set(lua_State* L) {
2378  int SWIG_arg = 0;
2379  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2380  int arg2 ;
2381 
2382  SWIG_check_num_args("PLGraphicsIn::type",2,2)
2383  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::type",1,"PLGraphicsIn *");
2384  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::type",2,"int");
2385 
2386  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2387  SWIG_fail_ptr("PLGraphicsIn_type_set",1,SWIGTYPE_p_PLGraphicsIn);
2388  }
2389 
2390  arg2 = (int)lua_tonumber(L, 2);
2391  if (arg1) (arg1)->type = arg2;
2392 
2393  return SWIG_arg;
2394 
2395  if(0) SWIG_fail;
2396 
2397 fail:
2398  lua_error(L);
2399  return SWIG_arg;
2400 }
2401 
2402 
2403 static int _wrap_PLGraphicsIn_type_get(lua_State* L) {
2404  int SWIG_arg = 0;
2405  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2406  int result;
2407 
2408  SWIG_check_num_args("PLGraphicsIn::type",1,1)
2409  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::type",1,"PLGraphicsIn *");
2410 
2411  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2412  SWIG_fail_ptr("PLGraphicsIn_type_get",1,SWIGTYPE_p_PLGraphicsIn);
2413  }
2414 
2415  result = (int) ((arg1)->type);
2416  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2417  return SWIG_arg;
2418 
2419  if(0) SWIG_fail;
2420 
2421 fail:
2422  lua_error(L);
2423  return SWIG_arg;
2424 }
2425 
2426 
2427 static int _wrap_PLGraphicsIn_state_set(lua_State* L) {
2428  int SWIG_arg = 0;
2429  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2430  unsigned int arg2 ;
2431 
2432  SWIG_check_num_args("PLGraphicsIn::state",2,2)
2433  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::state",1,"PLGraphicsIn *");
2434  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::state",2,"unsigned int");
2435 
2436  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2437  SWIG_fail_ptr("PLGraphicsIn_state_set",1,SWIGTYPE_p_PLGraphicsIn);
2438  }
2439 
2440  SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")
2441  arg2 = (unsigned int)lua_tonumber(L, 2);
2442  if (arg1) (arg1)->state = arg2;
2443 
2444  return SWIG_arg;
2445 
2446  if(0) SWIG_fail;
2447 
2448 fail:
2449  lua_error(L);
2450  return SWIG_arg;
2451 }
2452 
2453 
2454 static int _wrap_PLGraphicsIn_state_get(lua_State* L) {
2455  int SWIG_arg = 0;
2456  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2457  unsigned int result;
2458 
2459  SWIG_check_num_args("PLGraphicsIn::state",1,1)
2460  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::state",1,"PLGraphicsIn *");
2461 
2462  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2463  SWIG_fail_ptr("PLGraphicsIn_state_get",1,SWIGTYPE_p_PLGraphicsIn);
2464  }
2465 
2466  result = (unsigned int) ((arg1)->state);
2467  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2468  return SWIG_arg;
2469 
2470  if(0) SWIG_fail;
2471 
2472 fail:
2473  lua_error(L);
2474  return SWIG_arg;
2475 }
2476 
2477 
2478 static int _wrap_PLGraphicsIn_keysym_set(lua_State* L) {
2479  int SWIG_arg = 0;
2480  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2481  unsigned int arg2 ;
2482 
2483  SWIG_check_num_args("PLGraphicsIn::keysym",2,2)
2484  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::keysym",1,"PLGraphicsIn *");
2485  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::keysym",2,"unsigned int");
2486 
2487  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2488  SWIG_fail_ptr("PLGraphicsIn_keysym_set",1,SWIGTYPE_p_PLGraphicsIn);
2489  }
2490 
2491  SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")
2492  arg2 = (unsigned int)lua_tonumber(L, 2);
2493  if (arg1) (arg1)->keysym = arg2;
2494 
2495  return SWIG_arg;
2496 
2497  if(0) SWIG_fail;
2498 
2499 fail:
2500  lua_error(L);
2501  return SWIG_arg;
2502 }
2503 
2504 
2505 static int _wrap_PLGraphicsIn_keysym_get(lua_State* L) {
2506  int SWIG_arg = 0;
2507  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2508  unsigned int result;
2509 
2510  SWIG_check_num_args("PLGraphicsIn::keysym",1,1)
2511  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::keysym",1,"PLGraphicsIn *");
2512 
2513  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2514  SWIG_fail_ptr("PLGraphicsIn_keysym_get",1,SWIGTYPE_p_PLGraphicsIn);
2515  }
2516 
2517  result = (unsigned int) ((arg1)->keysym);
2518  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2519  return SWIG_arg;
2520 
2521  if(0) SWIG_fail;
2522 
2523 fail:
2524  lua_error(L);
2525  return SWIG_arg;
2526 }
2527 
2528 
2529 static int _wrap_PLGraphicsIn_button_set(lua_State* L) {
2530  int SWIG_arg = 0;
2531  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2532  unsigned int arg2 ;
2533 
2534  SWIG_check_num_args("PLGraphicsIn::button",2,2)
2535  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::button",1,"PLGraphicsIn *");
2536  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::button",2,"unsigned int");
2537 
2538  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2539  SWIG_fail_ptr("PLGraphicsIn_button_set",1,SWIGTYPE_p_PLGraphicsIn);
2540  }
2541 
2542  SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")
2543  arg2 = (unsigned int)lua_tonumber(L, 2);
2544  if (arg1) (arg1)->button = arg2;
2545 
2546  return SWIG_arg;
2547 
2548  if(0) SWIG_fail;
2549 
2550 fail:
2551  lua_error(L);
2552  return SWIG_arg;
2553 }
2554 
2555 
2556 static int _wrap_PLGraphicsIn_button_get(lua_State* L) {
2557  int SWIG_arg = 0;
2558  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2559  unsigned int result;
2560 
2561  SWIG_check_num_args("PLGraphicsIn::button",1,1)
2562  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::button",1,"PLGraphicsIn *");
2563 
2564  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2565  SWIG_fail_ptr("PLGraphicsIn_button_get",1,SWIGTYPE_p_PLGraphicsIn);
2566  }
2567 
2568  result = (unsigned int) ((arg1)->button);
2569  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2570  return SWIG_arg;
2571 
2572  if(0) SWIG_fail;
2573 
2574 fail:
2575  lua_error(L);
2576  return SWIG_arg;
2577 }
2578 
2579 
2580 static int _wrap_PLGraphicsIn_subwindow_set(lua_State* L) {
2581  int SWIG_arg = 0;
2582  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2583  PLINT arg2 ;
2584 
2585  SWIG_check_num_args("PLGraphicsIn::subwindow",2,2)
2586  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::subwindow",1,"PLGraphicsIn *");
2587  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::subwindow",2,"PLINT");
2588 
2589  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2590  SWIG_fail_ptr("PLGraphicsIn_subwindow_set",1,SWIGTYPE_p_PLGraphicsIn);
2591  }
2592 
2593  arg2 = (PLINT)lua_tonumber(L, 2);
2594  if (arg1) (arg1)->subwindow = arg2;
2595 
2596  return SWIG_arg;
2597 
2598  if(0) SWIG_fail;
2599 
2600 fail:
2601  lua_error(L);
2602  return SWIG_arg;
2603 }
2604 
2605 
2606 static int _wrap_PLGraphicsIn_subwindow_get(lua_State* L) {
2607  int SWIG_arg = 0;
2608  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2609  PLINT result;
2610 
2611  SWIG_check_num_args("PLGraphicsIn::subwindow",1,1)
2612  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::subwindow",1,"PLGraphicsIn *");
2613 
2614  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2615  SWIG_fail_ptr("PLGraphicsIn_subwindow_get",1,SWIGTYPE_p_PLGraphicsIn);
2616  }
2617 
2618  result = (PLINT) ((arg1)->subwindow);
2619  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2620  return SWIG_arg;
2621 
2622  if(0) SWIG_fail;
2623 
2624 fail:
2625  lua_error(L);
2626  return SWIG_arg;
2627 }
2628 
2629 
2630 static int _wrap_PLGraphicsIn_string_set(lua_State* L) {
2631  int SWIG_arg = 0;
2632  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2633  char *arg2 ;
2634 
2635  SWIG_check_num_args("PLGraphicsIn::string",2,2)
2636  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::string",1,"PLGraphicsIn *");
2637  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("PLGraphicsIn::string",2,"char [16]");
2638 
2639  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2640  SWIG_fail_ptr("PLGraphicsIn_string_set",1,SWIGTYPE_p_PLGraphicsIn);
2641  }
2642 
2643  arg2 = (char *)lua_tostring(L, 2);
2644  {
2645  if(arg2) {
2646  strncpy((char*)arg1->string, (const char *)arg2, 16-1);
2647  arg1->string[16-1] = 0;
2648  } else {
2649  arg1->string[0] = 0;
2650  }
2651  }
2652 
2653  return SWIG_arg;
2654 
2655  if(0) SWIG_fail;
2656 
2657 fail:
2658  lua_error(L);
2659  return SWIG_arg;
2660 }
2661 
2662 
2663 static int _wrap_PLGraphicsIn_string_get(lua_State* L) {
2664  int SWIG_arg = 0;
2665  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2666  char *result = 0 ;
2667 
2668  SWIG_check_num_args("PLGraphicsIn::string",1,1)
2669  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::string",1,"PLGraphicsIn *");
2670 
2671  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2672  SWIG_fail_ptr("PLGraphicsIn_string_get",1,SWIGTYPE_p_PLGraphicsIn);
2673  }
2674 
2675  result = (char *)(char *) ((arg1)->string);
2676  lua_pushstring(L,(const char *)result); SWIG_arg++;
2677  return SWIG_arg;
2678 
2679  if(0) SWIG_fail;
2680 
2681 fail:
2682  lua_error(L);
2683  return SWIG_arg;
2684 }
2685 
2686 
2687 static int _wrap_PLGraphicsIn_pX_set(lua_State* L) {
2688  int SWIG_arg = 0;
2689  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2690  int arg2 ;
2691 
2692  SWIG_check_num_args("PLGraphicsIn::pX",2,2)
2693  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pX",1,"PLGraphicsIn *");
2694  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::pX",2,"int");
2695 
2696  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2697  SWIG_fail_ptr("PLGraphicsIn_pX_set",1,SWIGTYPE_p_PLGraphicsIn);
2698  }
2699 
2700  arg2 = (int)lua_tonumber(L, 2);
2701  if (arg1) (arg1)->pX = arg2;
2702 
2703  return SWIG_arg;
2704 
2705  if(0) SWIG_fail;
2706 
2707 fail:
2708  lua_error(L);
2709  return SWIG_arg;
2710 }
2711 
2712 
2713 static int _wrap_PLGraphicsIn_pX_get(lua_State* L) {
2714  int SWIG_arg = 0;
2715  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2716  int result;
2717 
2718  SWIG_check_num_args("PLGraphicsIn::pX",1,1)
2719  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pX",1,"PLGraphicsIn *");
2720 
2721  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2722  SWIG_fail_ptr("PLGraphicsIn_pX_get",1,SWIGTYPE_p_PLGraphicsIn);
2723  }
2724 
2725  result = (int) ((arg1)->pX);
2726  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2727  return SWIG_arg;
2728 
2729  if(0) SWIG_fail;
2730 
2731 fail:
2732  lua_error(L);
2733  return SWIG_arg;
2734 }
2735 
2736 
2737 static int _wrap_PLGraphicsIn_pY_set(lua_State* L) {
2738  int SWIG_arg = 0;
2739  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2740  int arg2 ;
2741 
2742  SWIG_check_num_args("PLGraphicsIn::pY",2,2)
2743  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pY",1,"PLGraphicsIn *");
2744  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::pY",2,"int");
2745 
2746  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2747  SWIG_fail_ptr("PLGraphicsIn_pY_set",1,SWIGTYPE_p_PLGraphicsIn);
2748  }
2749 
2750  arg2 = (int)lua_tonumber(L, 2);
2751  if (arg1) (arg1)->pY = arg2;
2752 
2753  return SWIG_arg;
2754 
2755  if(0) SWIG_fail;
2756 
2757 fail:
2758  lua_error(L);
2759  return SWIG_arg;
2760 }
2761 
2762 
2763 static int _wrap_PLGraphicsIn_pY_get(lua_State* L) {
2764  int SWIG_arg = 0;
2765  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2766  int result;
2767 
2768  SWIG_check_num_args("PLGraphicsIn::pY",1,1)
2769  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pY",1,"PLGraphicsIn *");
2770 
2771  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2772  SWIG_fail_ptr("PLGraphicsIn_pY_get",1,SWIGTYPE_p_PLGraphicsIn);
2773  }
2774 
2775  result = (int) ((arg1)->pY);
2776  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2777  return SWIG_arg;
2778 
2779  if(0) SWIG_fail;
2780 
2781 fail:
2782  lua_error(L);
2783  return SWIG_arg;
2784 }
2785 
2786 
2787 static int _wrap_PLGraphicsIn_dX_set(lua_State* L) {
2788  int SWIG_arg = 0;
2789  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2790  PLFLT arg2 ;
2791 
2792  SWIG_check_num_args("PLGraphicsIn::dX",2,2)
2793  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dX",1,"PLGraphicsIn *");
2794  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::dX",2,"PLFLT");
2795 
2796  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2797  SWIG_fail_ptr("PLGraphicsIn_dX_set",1,SWIGTYPE_p_PLGraphicsIn);
2798  }
2799 
2800  arg2 = (PLFLT)lua_tonumber(L, 2);
2801  if (arg1) (arg1)->dX = arg2;
2802 
2803  return SWIG_arg;
2804 
2805  if(0) SWIG_fail;
2806 
2807 fail:
2808  lua_error(L);
2809  return SWIG_arg;
2810 }
2811 
2812 
2813 static int _wrap_PLGraphicsIn_dX_get(lua_State* L) {
2814  int SWIG_arg = 0;
2815  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2816  PLFLT result;
2817 
2818  SWIG_check_num_args("PLGraphicsIn::dX",1,1)
2819  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dX",1,"PLGraphicsIn *");
2820 
2821  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2822  SWIG_fail_ptr("PLGraphicsIn_dX_get",1,SWIGTYPE_p_PLGraphicsIn);
2823  }
2824 
2825  result = (PLFLT) ((arg1)->dX);
2826  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2827  return SWIG_arg;
2828 
2829  if(0) SWIG_fail;
2830 
2831 fail:
2832  lua_error(L);
2833  return SWIG_arg;
2834 }
2835 
2836 
2837 static int _wrap_PLGraphicsIn_dY_set(lua_State* L) {
2838  int SWIG_arg = 0;
2839  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2840  PLFLT arg2 ;
2841 
2842  SWIG_check_num_args("PLGraphicsIn::dY",2,2)
2843  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dY",1,"PLGraphicsIn *");
2844  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::dY",2,"PLFLT");
2845 
2846  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2847  SWIG_fail_ptr("PLGraphicsIn_dY_set",1,SWIGTYPE_p_PLGraphicsIn);
2848  }
2849 
2850  arg2 = (PLFLT)lua_tonumber(L, 2);
2851  if (arg1) (arg1)->dY = arg2;
2852 
2853  return SWIG_arg;
2854 
2855  if(0) SWIG_fail;
2856 
2857 fail:
2858  lua_error(L);
2859  return SWIG_arg;
2860 }
2861 
2862 
2863 static int _wrap_PLGraphicsIn_dY_get(lua_State* L) {
2864  int SWIG_arg = 0;
2865  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2866  PLFLT result;
2867 
2868  SWIG_check_num_args("PLGraphicsIn::dY",1,1)
2869  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dY",1,"PLGraphicsIn *");
2870 
2871  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2872  SWIG_fail_ptr("PLGraphicsIn_dY_get",1,SWIGTYPE_p_PLGraphicsIn);
2873  }
2874 
2875  result = (PLFLT) ((arg1)->dY);
2876  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2877  return SWIG_arg;
2878 
2879  if(0) SWIG_fail;
2880 
2881 fail:
2882  lua_error(L);
2883  return SWIG_arg;
2884 }
2885 
2886 
2887 static int _wrap_PLGraphicsIn_wX_set(lua_State* L) {
2888  int SWIG_arg = 0;
2889  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2890  PLFLT arg2 ;
2891 
2892  SWIG_check_num_args("PLGraphicsIn::wX",2,2)
2893  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wX",1,"PLGraphicsIn *");
2894  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::wX",2,"PLFLT");
2895 
2896  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2897  SWIG_fail_ptr("PLGraphicsIn_wX_set",1,SWIGTYPE_p_PLGraphicsIn);
2898  }
2899 
2900  arg2 = (PLFLT)lua_tonumber(L, 2);
2901  if (arg1) (arg1)->wX = arg2;
2902 
2903  return SWIG_arg;
2904 
2905  if(0) SWIG_fail;
2906 
2907 fail:
2908  lua_error(L);
2909  return SWIG_arg;
2910 }
2911 
2912 
2913 static int _wrap_PLGraphicsIn_wX_get(lua_State* L) {
2914  int SWIG_arg = 0;
2915  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2916  PLFLT result;
2917 
2918  SWIG_check_num_args("PLGraphicsIn::wX",1,1)
2919  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wX",1,"PLGraphicsIn *");
2920 
2921  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2922  SWIG_fail_ptr("PLGraphicsIn_wX_get",1,SWIGTYPE_p_PLGraphicsIn);
2923  }
2924 
2925  result = (PLFLT) ((arg1)->wX);
2926  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2927  return SWIG_arg;
2928 
2929  if(0) SWIG_fail;
2930 
2931 fail:
2932  lua_error(L);
2933  return SWIG_arg;
2934 }
2935 
2936 
2937 static int _wrap_PLGraphicsIn_wY_set(lua_State* L) {
2938  int SWIG_arg = 0;
2939  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2940  PLFLT arg2 ;
2941 
2942  SWIG_check_num_args("PLGraphicsIn::wY",2,2)
2943  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wY",1,"PLGraphicsIn *");
2944  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::wY",2,"PLFLT");
2945 
2946  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2947  SWIG_fail_ptr("PLGraphicsIn_wY_set",1,SWIGTYPE_p_PLGraphicsIn);
2948  }
2949 
2950  arg2 = (PLFLT)lua_tonumber(L, 2);
2951  if (arg1) (arg1)->wY = arg2;
2952 
2953  return SWIG_arg;
2954 
2955  if(0) SWIG_fail;
2956 
2957 fail:
2958  lua_error(L);
2959  return SWIG_arg;
2960 }
2961 
2962 
2963 static int _wrap_PLGraphicsIn_wY_get(lua_State* L) {
2964  int SWIG_arg = 0;
2965  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
2966  PLFLT result;
2967 
2968  SWIG_check_num_args("PLGraphicsIn::wY",1,1)
2969  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wY",1,"PLGraphicsIn *");
2970 
2971  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
2972  SWIG_fail_ptr("PLGraphicsIn_wY_get",1,SWIGTYPE_p_PLGraphicsIn);
2973  }
2974 
2975  result = (PLFLT) ((arg1)->wY);
2976  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
2977  return SWIG_arg;
2978 
2979  if(0) SWIG_fail;
2980 
2981 fail:
2982  lua_error(L);
2983  return SWIG_arg;
2984 }
2985 
2986 
2987 static int _wrap_new_PLGraphicsIn(lua_State* L) {
2988  int SWIG_arg = 0;
2989  PLGraphicsIn *result = 0 ;
2990 
2991  SWIG_check_num_args("PLGraphicsIn::PLGraphicsIn",0,0)
2992  result = (PLGraphicsIn *)calloc(1, sizeof(PLGraphicsIn));
2993  SWIG_NewPointerObj(L,result,SWIGTYPE_p_PLGraphicsIn,1); SWIG_arg++;
2994  return SWIG_arg;
2995 
2996  if(0) SWIG_fail;
2997 
2998 fail:
2999  lua_error(L);
3000  return SWIG_arg;
3001 }
3002 
3003 
3004 static void swig_delete_PLGraphicsIn(void *obj) {
3005 PLGraphicsIn *arg1 = (PLGraphicsIn *) obj;
3006 free((char *) arg1);
3007 }
3009  {0,0}
3010 };
3024  {0,0,0}
3025 };
3027  {0,0,0}
3028 };
3030  {0,0}
3031 };
3033  {0,0,0,0,0,0}
3034 };
3036 static const char *swig_PLGraphicsIn_base_names[] = {0};
3038 
3039 static int _wrap_setcontlabelformat(lua_State* L) {
3040  int SWIG_arg = 0;
3041  PLINT arg1 ;
3042  PLINT arg2 ;
3043 
3044  SWIG_check_num_args("pl_setcontlabelformat",2,2)
3045  if(!lua_isnumber(L,1)) SWIG_fail_arg("pl_setcontlabelformat",1,"PLINT");
3046  if(!lua_isnumber(L,2)) SWIG_fail_arg("pl_setcontlabelformat",2,"PLINT");
3047  arg1 = (PLINT)lua_tonumber(L, 1);
3048  arg2 = (PLINT)lua_tonumber(L, 2);
3049  pl_setcontlabelformat(arg1,arg2);
3050 
3051  return SWIG_arg;
3052 
3053  if(0) SWIG_fail;
3054 
3055 fail:
3056  lua_error(L);
3057  return SWIG_arg;
3058 }
3059 
3060 
3061 static int _wrap_setcontlabelparam(lua_State* L) {
3062  int SWIG_arg = 0;
3063  PLFLT arg1 ;
3064  PLFLT arg2 ;
3065  PLFLT arg3 ;
3066  PLINT arg4 ;
3067 
3068  SWIG_check_num_args("pl_setcontlabelparam",4,4)
3069  if(!lua_isnumber(L,1)) SWIG_fail_arg("pl_setcontlabelparam",1,"PLFLT");
3070  if(!lua_isnumber(L,2)) SWIG_fail_arg("pl_setcontlabelparam",2,"PLFLT");
3071  if(!lua_isnumber(L,3)) SWIG_fail_arg("pl_setcontlabelparam",3,"PLFLT");
3072  if(!lua_isnumber(L,4)) SWIG_fail_arg("pl_setcontlabelparam",4,"PLINT");
3073  arg1 = (PLFLT)lua_tonumber(L, 1);
3074  arg2 = (PLFLT)lua_tonumber(L, 2);
3075  arg3 = (PLFLT)lua_tonumber(L, 3);
3076  arg4 = (PLINT)lua_tonumber(L, 4);
3077  pl_setcontlabelparam(arg1,arg2,arg3,arg4);
3078 
3079  return SWIG_arg;
3080 
3081  if(0) SWIG_fail;
3082 
3083 fail:
3084  lua_error(L);
3085  return SWIG_arg;
3086 }
3087 
3088 
3089 static int _wrap_adv(lua_State* L) {
3090  int SWIG_arg = 0;
3091  PLINT arg1 ;
3092 
3093  SWIG_check_num_args("pladv",1,1)
3094  if(!lua_isnumber(L,1)) SWIG_fail_arg("pladv",1,"PLINT");
3095  arg1 = (PLINT)lua_tonumber(L, 1);
3096  pladv(arg1);
3097 
3098  return SWIG_arg;
3099 
3100  if(0) SWIG_fail;
3101 
3102 fail:
3103  lua_error(L);
3104  return SWIG_arg;
3105 }
3106 
3107 
3108 static int _wrap_arc(lua_State* L) {
3109  int SWIG_arg = 0;
3110  PLFLT arg1 ;
3111  PLFLT arg2 ;
3112  PLFLT arg3 ;
3113  PLFLT arg4 ;
3114  PLFLT arg5 ;
3115  PLFLT arg6 ;
3116  PLFLT arg7 ;
3117  PLBOOL arg8 ;
3118 
3119  SWIG_check_num_args("plarc",8,8)
3120  if(!lua_isnumber(L,1)) SWIG_fail_arg("plarc",1,"PLFLT");
3121  if(!lua_isnumber(L,2)) SWIG_fail_arg("plarc",2,"PLFLT");
3122  if(!lua_isnumber(L,3)) SWIG_fail_arg("plarc",3,"PLFLT");
3123  if(!lua_isnumber(L,4)) SWIG_fail_arg("plarc",4,"PLFLT");
3124  if(!lua_isnumber(L,5)) SWIG_fail_arg("plarc",5,"PLFLT");
3125  if(!lua_isnumber(L,6)) SWIG_fail_arg("plarc",6,"PLFLT");
3126  if(!lua_isnumber(L,7)) SWIG_fail_arg("plarc",7,"PLFLT");
3127  if(!lua_isnumber(L,8)) SWIG_fail_arg("plarc",8,"PLBOOL");
3128  arg1 = (PLFLT)lua_tonumber(L, 1);
3129  arg2 = (PLFLT)lua_tonumber(L, 2);
3130  arg3 = (PLFLT)lua_tonumber(L, 3);
3131  arg4 = (PLFLT)lua_tonumber(L, 4);
3132  arg5 = (PLFLT)lua_tonumber(L, 5);
3133  arg6 = (PLFLT)lua_tonumber(L, 6);
3134  arg7 = (PLFLT)lua_tonumber(L, 7);
3135  arg8 = (PLBOOL)lua_tonumber(L, 8);
3136  plarc(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
3137 
3138  return SWIG_arg;
3139 
3140  if(0) SWIG_fail;
3141 
3142 fail:
3143  lua_error(L);
3144  return SWIG_arg;
3145 }
3146 
3147 
3148 static int _wrap_axes(lua_State* L) {
3149  int SWIG_arg = 0;
3150  PLFLT arg1 ;
3151  PLFLT arg2 ;
3152  char *arg3 = (char *) 0 ;
3153  PLFLT arg4 ;
3154  PLINT arg5 ;
3155  char *arg6 = (char *) 0 ;
3156  PLFLT arg7 ;
3157  PLINT arg8 ;
3158 
3159  SWIG_check_num_args("plaxes",8,8)
3160  if(!lua_isnumber(L,1)) SWIG_fail_arg("plaxes",1,"PLFLT");
3161  if(!lua_isnumber(L,2)) SWIG_fail_arg("plaxes",2,"PLFLT");
3162  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("plaxes",3,"char const *");
3163  if(!lua_isnumber(L,4)) SWIG_fail_arg("plaxes",4,"PLFLT");
3164  if(!lua_isnumber(L,5)) SWIG_fail_arg("plaxes",5,"PLINT");
3165  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plaxes",6,"char const *");
3166  if(!lua_isnumber(L,7)) SWIG_fail_arg("plaxes",7,"PLFLT");
3167  if(!lua_isnumber(L,8)) SWIG_fail_arg("plaxes",8,"PLINT");
3168  arg1 = (PLFLT)lua_tonumber(L, 1);
3169  arg2 = (PLFLT)lua_tonumber(L, 2);
3170  arg3 = (char *)lua_tostring(L, 3);
3171  arg4 = (PLFLT)lua_tonumber(L, 4);
3172  arg5 = (PLINT)lua_tonumber(L, 5);
3173  arg6 = (char *)lua_tostring(L, 6);
3174  arg7 = (PLFLT)lua_tonumber(L, 7);
3175  arg8 = (PLINT)lua_tonumber(L, 8);
3176  plaxes(arg1,arg2,(char const *)arg3,arg4,arg5,(char const *)arg6,arg7,arg8);
3177 
3178  return SWIG_arg;
3179 
3180  if(0) SWIG_fail;
3181 
3182 fail:
3183  lua_error(L);
3184  return SWIG_arg;
3185 }
3186 
3187 
3188 static int _wrap_bin(lua_State* L) {
3189  int SWIG_arg = 0;
3190  PLINT arg1 ;
3191  PLFLT *arg2 = (PLFLT *) 0 ;
3192  PLFLT *arg3 = (PLFLT *) 0 ;
3193  PLINT arg4 ;
3194  int temp3 ;
3195 
3196  SWIG_check_num_args("plbin",3,3)
3197  if(!lua_isnumber(L,3)) SWIG_fail_arg("plbin",3,"PLINT");
3198  {
3199  int temp;
3200  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
3201  if ( !arg2 )
3202  SWIG_fail;
3203  arg1 = Alen = temp;
3204  }
3205  {
3206  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
3207  if ( !arg3 )
3208  SWIG_fail;
3209  if ( temp3 != Alen )
3210  {
3211  lua_pushfstring( L, "Tables must be of same length." );
3212  SWIG_fail;
3213  }
3214  }
3215  arg4 = (PLINT)lua_tonumber(L, 3);
3216  plbin(arg1,(double const *)arg2,(double const *)arg3,arg4);
3217 
3218  {
3219  LUA_FREE_ARRAY( arg2 );
3220  }
3221  {
3222  LUA_FREE_ARRAY( arg3 );
3223  }
3224  return SWIG_arg;
3225 
3226  if(0) SWIG_fail;
3227 
3228 fail:
3229  {
3230  LUA_FREE_ARRAY( arg2 );
3231  }
3232  {
3233  LUA_FREE_ARRAY( arg3 );
3234  }
3235  lua_error(L);
3236  return SWIG_arg;
3237 }
3238 
3239 
3240 static int _wrap_btime(lua_State* L) {
3241  int SWIG_arg = 0;
3242  PLINT *arg1 = (PLINT *) 0 ;
3243  PLINT *arg2 = (PLINT *) 0 ;
3244  PLINT *arg3 = (PLINT *) 0 ;
3245  PLINT *arg4 = (PLINT *) 0 ;
3246  PLINT *arg5 = (PLINT *) 0 ;
3247  PLFLT *arg6 = (PLFLT *) 0 ;
3248  PLFLT arg7 ;
3249  PLINT temp1 ;
3250  PLINT temp2 ;
3251  PLINT temp3 ;
3252  PLINT temp4 ;
3253  PLINT temp5 ;
3254  PLFLT temp6 ;
3255 
3256  arg1 = &temp1;
3257  arg2 = &temp2;
3258  arg3 = &temp3;
3259  arg4 = &temp4;
3260  arg5 = &temp5;
3261  arg6 = &temp6;
3262  SWIG_check_num_args("plbtime",1,1)
3263  if(!lua_isnumber(L,1)) SWIG_fail_arg("plbtime",1,"PLFLT");
3264  arg7 = (PLFLT)lua_tonumber(L, 1);
3265  plbtime(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
3266 
3267  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
3268  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
3269  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
3270  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
3271  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
3272  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
3273  return SWIG_arg;
3274 
3275  if(0) SWIG_fail;
3276 
3277 fail:
3278  lua_error(L);
3279  return SWIG_arg;
3280 }
3281 
3282 
3283 static int _wrap_bop(lua_State* L) {
3284  int SWIG_arg = 0;
3285 
3286  SWIG_check_num_args("plbop",0,0)
3287  plbop();
3288 
3289  return SWIG_arg;
3290 
3291  if(0) SWIG_fail;
3292 
3293 fail:
3294  lua_error(L);
3295  return SWIG_arg;
3296 }
3297 
3298 
3299 static int _wrap_box(lua_State* L) {
3300  int SWIG_arg = 0;
3301  char *arg1 = (char *) 0 ;
3302  PLFLT arg2 ;
3303  PLINT arg3 ;
3304  char *arg4 = (char *) 0 ;
3305  PLFLT arg5 ;
3306  PLINT arg6 ;
3307 
3308  SWIG_check_num_args("plbox",6,6)
3309  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plbox",1,"char const *");
3310  if(!lua_isnumber(L,2)) SWIG_fail_arg("plbox",2,"PLFLT");
3311  if(!lua_isnumber(L,3)) SWIG_fail_arg("plbox",3,"PLINT");
3312  if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("plbox",4,"char const *");
3313  if(!lua_isnumber(L,5)) SWIG_fail_arg("plbox",5,"PLFLT");
3314  if(!lua_isnumber(L,6)) SWIG_fail_arg("plbox",6,"PLINT");
3315  arg1 = (char *)lua_tostring(L, 1);
3316  arg2 = (PLFLT)lua_tonumber(L, 2);
3317  arg3 = (PLINT)lua_tonumber(L, 3);
3318  arg4 = (char *)lua_tostring(L, 4);
3319  arg5 = (PLFLT)lua_tonumber(L, 5);
3320  arg6 = (PLINT)lua_tonumber(L, 6);
3321  plbox((char const *)arg1,arg2,arg3,(char const *)arg4,arg5,arg6);
3322 
3323  return SWIG_arg;
3324 
3325  if(0) SWIG_fail;
3326 
3327 fail:
3328  lua_error(L);
3329  return SWIG_arg;
3330 }
3331 
3332 
3333 static int _wrap_box3(lua_State* L) {
3334  int SWIG_arg = 0;
3335  char *arg1 = (char *) 0 ;
3336  char *arg2 = (char *) 0 ;
3337  PLFLT arg3 ;
3338  PLINT arg4 ;
3339  char *arg5 = (char *) 0 ;
3340  char *arg6 = (char *) 0 ;
3341  PLFLT arg7 ;
3342  PLINT arg8 ;
3343  char *arg9 = (char *) 0 ;
3344  char *arg10 = (char *) 0 ;
3345  PLFLT arg11 ;
3346  PLINT arg12 ;
3347 
3348  SWIG_check_num_args("plbox3",12,12)
3349  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plbox3",1,"char const *");
3350  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plbox3",2,"char const *");
3351  if(!lua_isnumber(L,3)) SWIG_fail_arg("plbox3",3,"PLFLT");
3352  if(!lua_isnumber(L,4)) SWIG_fail_arg("plbox3",4,"PLINT");
3353  if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("plbox3",5,"char const *");
3354  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plbox3",6,"char const *");
3355  if(!lua_isnumber(L,7)) SWIG_fail_arg("plbox3",7,"PLFLT");
3356  if(!lua_isnumber(L,8)) SWIG_fail_arg("plbox3",8,"PLINT");
3357  if(!SWIG_lua_isnilstring(L,9)) SWIG_fail_arg("plbox3",9,"char const *");
3358  if(!SWIG_lua_isnilstring(L,10)) SWIG_fail_arg("plbox3",10,"char const *");
3359  if(!lua_isnumber(L,11)) SWIG_fail_arg("plbox3",11,"PLFLT");
3360  if(!lua_isnumber(L,12)) SWIG_fail_arg("plbox3",12,"PLINT");
3361  arg1 = (char *)lua_tostring(L, 1);
3362  arg2 = (char *)lua_tostring(L, 2);
3363  arg3 = (PLFLT)lua_tonumber(L, 3);
3364  arg4 = (PLINT)lua_tonumber(L, 4);
3365  arg5 = (char *)lua_tostring(L, 5);
3366  arg6 = (char *)lua_tostring(L, 6);
3367  arg7 = (PLFLT)lua_tonumber(L, 7);
3368  arg8 = (PLINT)lua_tonumber(L, 8);
3369  arg9 = (char *)lua_tostring(L, 9);
3370  arg10 = (char *)lua_tostring(L, 10);
3371  arg11 = (PLFLT)lua_tonumber(L, 11);
3372  arg12 = (PLINT)lua_tonumber(L, 12);
3373  plbox3((char const *)arg1,(char const *)arg2,arg3,arg4,(char const *)arg5,(char const *)arg6,arg7,arg8,(char const *)arg9,(char const *)arg10,arg11,arg12);
3374 
3375  return SWIG_arg;
3376 
3377  if(0) SWIG_fail;
3378 
3379 fail:
3380  lua_error(L);
3381  return SWIG_arg;
3382 }
3383 
3384 
3385 static int _wrap_calc_world(lua_State* L) {
3386  int SWIG_arg = 0;
3387  PLFLT arg1 ;
3388  PLFLT arg2 ;
3389  PLFLT *arg3 = (PLFLT *) 0 ;
3390  PLFLT *arg4 = (PLFLT *) 0 ;
3391  PLINT *arg5 = (PLINT *) 0 ;
3392  PLFLT temp3 ;
3393  PLFLT temp4 ;
3394  PLINT temp5 ;
3395 
3396  arg3 = &temp3;
3397  arg4 = &temp4;
3398  arg5 = &temp5;
3399  SWIG_check_num_args("plcalc_world",2,2)
3400  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcalc_world",1,"PLFLT");
3401  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcalc_world",2,"PLFLT");
3402  arg1 = (PLFLT)lua_tonumber(L, 1);
3403  arg2 = (PLFLT)lua_tonumber(L, 2);
3404  plcalc_world(arg1,arg2,arg3,arg4,arg5);
3405 
3406  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
3407  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
3408  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
3409  return SWIG_arg;
3410 
3411  if(0) SWIG_fail;
3412 
3413 fail:
3414  lua_error(L);
3415  return SWIG_arg;
3416 }
3417 
3418 
3419 static int _wrap_clear(lua_State* L) {
3420  int SWIG_arg = 0;
3421 
3422  SWIG_check_num_args("plclear",0,0)
3423  plclear();
3424 
3425  return SWIG_arg;
3426 
3427  if(0) SWIG_fail;
3428 
3429 fail:
3430  lua_error(L);
3431  return SWIG_arg;
3432 }
3433 
3434 
3435 static int _wrap_col0(lua_State* L) {
3436  int SWIG_arg = 0;
3437  PLINT arg1 ;
3438 
3439  SWIG_check_num_args("plcol0",1,1)
3440  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcol0",1,"PLINT");
3441  arg1 = (PLINT)lua_tonumber(L, 1);
3442  plcol0(arg1);
3443 
3444  return SWIG_arg;
3445 
3446  if(0) SWIG_fail;
3447 
3448 fail:
3449  lua_error(L);
3450  return SWIG_arg;
3451 }
3452 
3453 
3454 static int _wrap_col1(lua_State* L) {
3455  int SWIG_arg = 0;
3456  PLFLT arg1 ;
3457 
3458  SWIG_check_num_args("plcol1",1,1)
3459  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcol1",1,"PLFLT");
3460  arg1 = (PLFLT)lua_tonumber(L, 1);
3461  plcol1(arg1);
3462 
3463  return SWIG_arg;
3464 
3465  if(0) SWIG_fail;
3466 
3467 fail:
3468  lua_error(L);
3469  return SWIG_arg;
3470 }
3471 
3472 
3473 static int _wrap_configtime(lua_State* L) {
3474  int SWIG_arg = 0;
3475  PLFLT arg1 ;
3476  PLFLT arg2 ;
3477  PLFLT arg3 ;
3478  PLINT arg4 ;
3479  PLBOOL arg5 ;
3480  PLINT arg6 ;
3481  PLINT arg7 ;
3482  PLINT arg8 ;
3483  PLINT arg9 ;
3484  PLINT arg10 ;
3485  PLFLT arg11 ;
3486 
3487  SWIG_check_num_args("plconfigtime",11,11)
3488  if(!lua_isnumber(L,1)) SWIG_fail_arg("plconfigtime",1,"PLFLT");
3489  if(!lua_isnumber(L,2)) SWIG_fail_arg("plconfigtime",2,"PLFLT");
3490  if(!lua_isnumber(L,3)) SWIG_fail_arg("plconfigtime",3,"PLFLT");
3491  if(!lua_isnumber(L,4)) SWIG_fail_arg("plconfigtime",4,"PLINT");
3492  if(!lua_isnumber(L,5)) SWIG_fail_arg("plconfigtime",5,"PLBOOL");
3493  if(!lua_isnumber(L,6)) SWIG_fail_arg("plconfigtime",6,"PLINT");
3494  if(!lua_isnumber(L,7)) SWIG_fail_arg("plconfigtime",7,"PLINT");
3495  if(!lua_isnumber(L,8)) SWIG_fail_arg("plconfigtime",8,"PLINT");
3496  if(!lua_isnumber(L,9)) SWIG_fail_arg("plconfigtime",9,"PLINT");
3497  if(!lua_isnumber(L,10)) SWIG_fail_arg("plconfigtime",10,"PLINT");
3498  if(!lua_isnumber(L,11)) SWIG_fail_arg("plconfigtime",11,"PLFLT");
3499  arg1 = (PLFLT)lua_tonumber(L, 1);
3500  arg2 = (PLFLT)lua_tonumber(L, 2);
3501  arg3 = (PLFLT)lua_tonumber(L, 3);
3502  arg4 = (PLINT)lua_tonumber(L, 4);
3503  arg5 = (PLBOOL)lua_tonumber(L, 5);
3504  arg6 = (PLINT)lua_tonumber(L, 6);
3505  arg7 = (PLINT)lua_tonumber(L, 7);
3506  arg8 = (PLINT)lua_tonumber(L, 8);
3507  arg9 = (PLINT)lua_tonumber(L, 9);
3508  arg10 = (PLINT)lua_tonumber(L, 10);
3509  arg11 = (PLFLT)lua_tonumber(L, 11);
3510  plconfigtime(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11);
3511 
3512  return SWIG_arg;
3513 
3514  if(0) SWIG_fail;
3515 
3516 fail:
3517  lua_error(L);
3518  return SWIG_arg;
3519 }
3520 
3521 
3522 static int _wrap_cont(lua_State* L) {
3523  int SWIG_arg = 0;
3524  PLFLT **arg1 = (PLFLT **) 0 ;
3525  PLINT arg2 ;
3526  PLINT arg3 ;
3527  PLINT arg4 ;
3528  PLINT arg5 ;
3529  PLINT arg6 ;
3530  PLINT arg7 ;
3531  PLFLT *arg8 = (PLFLT *) 0 ;
3532  PLINT arg9 ;
3533  pltr_func arg10 = (pltr_func) 0 ;
3534  PLPointer arg11 = (PLPointer) 0 ;
3535  int ii1 ;
3536  PLcGrid cgrid111 ;
3537  PLcGrid2 cgrid211 ;
3538 
3539  {
3540  cgrid111.xg = cgrid111.yg = cgrid111.zg = NULL;
3541  cgrid111.nx = cgrid111.ny = cgrid111.nz = 0;
3542  cgrid211.xg = cgrid211.yg = cgrid211.zg = NULL;
3543  cgrid211.nx = cgrid211.ny = 0;
3544  }
3545  {
3546  arg10 = NULL;
3547  }
3548  {
3549  arg11 = NULL;
3550  }
3551  SWIG_check_num_args("plcont",6,8)
3552  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcont",2,"PLINT");
3553  if(!lua_isnumber(L,3)) SWIG_fail_arg("plcont",3,"PLINT");
3554  if(!lua_isnumber(L,4)) SWIG_fail_arg("plcont",4,"PLINT");
3555  if(!lua_isnumber(L,5)) SWIG_fail_arg("plcont",5,"PLINT");
3556  {
3557  int jj;
3558 
3559  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
3560  if ( !arg1 )
3561  SWIG_fail;
3562  Xlen = arg2 = ii1;
3563  Ylen = arg3 = jj;
3564  }
3565  arg4 = (PLINT)lua_tonumber(L, 2);
3566  arg5 = (PLINT)lua_tonumber(L, 3);
3567  arg6 = (PLINT)lua_tonumber(L, 4);
3568  arg7 = (PLINT)lua_tonumber(L, 5);
3569  {
3570  int temp;
3571  arg8 = (PLFLT *) LUA_get_double_num_array_var( L, 6, &temp );
3572  if ( !arg8 )
3573  SWIG_fail;
3574  arg9 = Alen = temp;
3575  }
3576  if(lua_gettop(L)>=7){
3577  {
3578  arg10 = NULL;
3579  mypltr_funcstr[0] = '\0';
3580 
3581  if ( lua_isstring( L, 7 ) )
3582  {
3583  const char* funcstr = lua_tostring( L, 7 );
3584  if ( strcmp( "pltr0", funcstr ) == 0 )
3585  {
3586  arg10 = pltr0;
3587  }
3588  else if ( strcmp( "pltr1", funcstr ) == 0 )
3589  {
3590  arg10 = pltr1;
3591  }
3592  else if ( strcmp( "pltr2", funcstr ) == 0 )
3593  {
3594  arg10 = pltr2;
3595  }
3596  else
3597  {
3598  arg10 = mypltr;
3599  strncpy( mypltr_funcstr, funcstr, 255 );
3600  myL = L;
3601  }
3602  }
3603  else
3604  SWIG_fail_arg( "cont", 10, "pltr_func" );
3605  }
3606  }
3607  if(lua_gettop(L)>=8){
3608  {
3609  int nx, ny;
3610  int gridmode = 0;
3611 
3612  lua_pushstring( L, "xg" );
3613  lua_gettable( L, 8 );
3614  if ( !lua_istable( L, -1 ) )
3615  {
3616  lua_pop( L, 1 ); // pop "xg"
3617  lua_pushstring( L, "expected a table xg" );
3618  SWIG_fail;
3619  }
3620  lua_rawgeti( L, -1, 1 );
3621  if ( lua_istable( L, -1 ) )
3622  gridmode = 2; // two dimensional array
3623  else if ( lua_isnumber( L, -1 ) )
3624  gridmode = 1; // one dimensional array
3625  else
3626  {
3627  lua_pop( L, 1 ); // pop "1"
3628  lua_pop( L, 1 ); // pop "xg"
3629  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
3630  SWIG_fail;
3631  }
3632  lua_pop( L, 1 ); // pop test element
3633  if ( gridmode == 1 )
3634  {
3635  cgrid111.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
3636  if ( !cgrid111.xg )
3637  {
3638  lua_pop( L, 1 ); // pop "xg"
3639  SWIG_fail;
3640  }
3641  if ( nx != Xlen )
3642  {
3643  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
3644  SWIG_fail;
3645  }
3646  cgrid111.nx = nx;
3647  }
3648  else
3649  {
3650  cgrid211.xg = read_double_Matrix( L, -1, &nx, &ny );
3651  if ( !cgrid211.xg )
3652  {
3653  lua_pop( L, 1 ); // pop "xg"
3654  SWIG_fail;
3655  }
3656  if ( ( nx != Xlen ) || ( ny != Ylen ) )
3657  {
3658  lua_pop( L, 1 ); // pop "xg"
3659  lua_pushfstring( L, "Vectors must match matrix." );
3660  SWIG_fail;
3661  }
3662  cgrid211.nx = nx;
3663  cgrid211.ny = ny;
3664  }
3665  lua_pop( L, 1 ); // pop "xg"
3666 
3667  lua_pushstring( L, "yg" );
3668  lua_gettable( L, 8 );
3669  if ( !lua_istable( L, -1 ) )
3670  {
3671  lua_pop( L, 1 );
3672  lua_pushstring( L, "expected a table yg" );
3673  SWIG_fail;
3674  }
3675  lua_rawgeti( L, -1, 1 );
3676  if ( gridmode == 2 )
3677  {
3678  if ( !lua_istable( L, -1 ) )
3679  {
3680  lua_pop( L, 1 ); // pop "1"
3681  lua_pop( L, 1 ); // pop "yg"
3682  lua_pushstring( L, "expected a two dimensional array/table in yg" );
3683  SWIG_fail;
3684  }
3685  }
3686  else
3687  {
3688  if ( !lua_isnumber( L, -1 ) )
3689  {
3690  lua_pop( L, 1 ); // pop "1"
3691  lua_pop( L, 1 ); // pop "yg"
3692  lua_pushstring( L, "expected a one dimensional array/table in yg" );
3693  SWIG_fail;
3694  }
3695  }
3696  lua_pop( L, 1 ); // pop "1"
3697  if ( gridmode == 1 )
3698  {
3699  cgrid111.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
3700  if ( !cgrid111.yg )
3701  {
3702  lua_pop( L, 1 ); // pop "yg"
3703  SWIG_fail;
3704  }
3705  if ( ny != Ylen )
3706  {
3707  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
3708  SWIG_fail;
3709  }
3710  cgrid111.ny = ny;
3711  }
3712  else
3713  {
3714  cgrid211.yg = read_double_Matrix( L, -1, &nx, &ny );
3715  if ( !cgrid211.yg )
3716  {
3717  lua_pop( L, 1 ); // pop "xg"
3718  SWIG_fail;
3719  }
3720  if ( ( nx != Xlen ) || ( ny != Ylen ) )
3721  {
3722  lua_pop( L, 1 ); // pop "xg"
3723  lua_pushfstring( L, "Vectors must match matrix." );
3724  SWIG_fail;
3725  }
3726  // cgrid211.nx/ny already set
3727  }
3728  lua_pop( L, 1 ); // pop "yg"
3729 
3730  if ( gridmode == 1 )
3731  arg11 = &cgrid111;
3732  else if ( gridmode == 2 )
3733  arg11 = &cgrid211;
3734  }
3735  }
3736  plcont((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,(double const *)arg8,arg9,arg10,arg11);
3737 
3738  {
3739  int i;
3740 
3741  if ( arg1 )
3742  {
3743  for ( i = 0; i < ii1; i++ )
3744  LUA_FREE_ARRAY( arg1[i] );
3745  LUA_FREE_ARRAY( arg1 );
3746  }
3747  }
3748  {
3749  LUA_FREE_ARRAY( arg8 );
3750  }
3751  {
3752  mypltr_funcstr[0] = '\0';
3753  }
3754  {
3755  int i;
3756 
3757  LUA_FREE_ARRAY( cgrid111.xg );
3758  LUA_FREE_ARRAY( cgrid111.yg );
3759 
3760  if ( cgrid211.xg )
3761  {
3762  for ( i = 0; i < Xlen; i++ )
3763  LUA_FREE_ARRAY( cgrid211.xg[i] );
3764  LUA_FREE_ARRAY( cgrid211.xg );
3765  }
3766  if ( cgrid211.yg )
3767  {
3768  for ( i = 0; i < Xlen; i++ )
3769  LUA_FREE_ARRAY( cgrid211.yg[i] );
3770  LUA_FREE_ARRAY( cgrid211.yg );
3771  }
3772  }
3773  return SWIG_arg;
3774 
3775  if(0) SWIG_fail;
3776 
3777 fail:
3778  {
3779  int i;
3780 
3781  if ( arg1 )
3782  {
3783  for ( i = 0; i < ii1; i++ )
3784  LUA_FREE_ARRAY( arg1[i] );
3785  LUA_FREE_ARRAY( arg1 );
3786  }
3787  }
3788  {
3789  LUA_FREE_ARRAY( arg8 );
3790  }
3791  {
3792  mypltr_funcstr[0] = '\0';
3793  }
3794  {
3795  int i;
3796 
3797  LUA_FREE_ARRAY( cgrid111.xg );
3798  LUA_FREE_ARRAY( cgrid111.yg );
3799 
3800  if ( cgrid211.xg )
3801  {
3802  for ( i = 0; i < Xlen; i++ )
3803  LUA_FREE_ARRAY( cgrid211.xg[i] );
3804  LUA_FREE_ARRAY( cgrid211.xg );
3805  }
3806  if ( cgrid211.yg )
3807  {
3808  for ( i = 0; i < Xlen; i++ )
3809  LUA_FREE_ARRAY( cgrid211.yg[i] );
3810  LUA_FREE_ARRAY( cgrid211.yg );
3811  }
3812  }
3813  lua_error(L);
3814  return SWIG_arg;
3815 }
3816 
3817 
3818 static int _wrap_ctime(lua_State* L) {
3819  int SWIG_arg = 0;
3820  PLINT arg1 ;
3821  PLINT arg2 ;
3822  PLINT arg3 ;
3823  PLINT arg4 ;
3824  PLINT arg5 ;
3825  PLFLT arg6 ;
3826  PLFLT *arg7 = (PLFLT *) 0 ;
3827  PLFLT temp7 ;
3828 
3829  arg7 = &temp7;
3830  SWIG_check_num_args("plctime",6,6)
3831  if(!lua_isnumber(L,1)) SWIG_fail_arg("plctime",1,"PLINT");
3832  if(!lua_isnumber(L,2)) SWIG_fail_arg("plctime",2,"PLINT");
3833  if(!lua_isnumber(L,3)) SWIG_fail_arg("plctime",3,"PLINT");
3834  if(!lua_isnumber(L,4)) SWIG_fail_arg("plctime",4,"PLINT");
3835  if(!lua_isnumber(L,5)) SWIG_fail_arg("plctime",5,"PLINT");
3836  if(!lua_isnumber(L,6)) SWIG_fail_arg("plctime",6,"PLFLT");
3837  arg1 = (PLINT)lua_tonumber(L, 1);
3838  arg2 = (PLINT)lua_tonumber(L, 2);
3839  arg3 = (PLINT)lua_tonumber(L, 3);
3840  arg4 = (PLINT)lua_tonumber(L, 4);
3841  arg5 = (PLINT)lua_tonumber(L, 5);
3842  arg6 = (PLFLT)lua_tonumber(L, 6);
3843  plctime(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
3844 
3845  lua_pushnumber(L, (lua_Number) *arg7); SWIG_arg++;
3846  return SWIG_arg;
3847 
3848  if(0) SWIG_fail;
3849 
3850 fail:
3851  lua_error(L);
3852  return SWIG_arg;
3853 }
3854 
3855 
3856 static int _wrap_cpstrm(lua_State* L) {
3857  int SWIG_arg = 0;
3858  PLINT arg1 ;
3859  PLBOOL arg2 ;
3860 
3861  SWIG_check_num_args("plcpstrm",2,2)
3862  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcpstrm",1,"PLINT");
3863  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcpstrm",2,"PLBOOL");
3864  arg1 = (PLINT)lua_tonumber(L, 1);
3865  arg2 = (PLBOOL)lua_tonumber(L, 2);
3866  plcpstrm(arg1,arg2);
3867 
3868  return SWIG_arg;
3869 
3870  if(0) SWIG_fail;
3871 
3872 fail:
3873  lua_error(L);
3874  return SWIG_arg;
3875 }
3876 
3877 
3878 static int _wrap_plend(lua_State* L) {
3879  int SWIG_arg = 0;
3880 
3881  SWIG_check_num_args("plend",0,0)
3882  plend();
3883 
3884  return SWIG_arg;
3885 
3886  if(0) SWIG_fail;
3887 
3888 fail:
3889  lua_error(L);
3890  return SWIG_arg;
3891 }
3892 
3893 
3894 static int _wrap_plend1(lua_State* L) {
3895  int SWIG_arg = 0;
3896 
3897  SWIG_check_num_args("plend1",0,0)
3898  plend1();
3899 
3900  return SWIG_arg;
3901 
3902  if(0) SWIG_fail;
3903 
3904 fail:
3905  lua_error(L);
3906  return SWIG_arg;
3907 }
3908 
3909 
3910 static int _wrap_env(lua_State* L) {
3911  int SWIG_arg = 0;
3912  PLFLT arg1 ;
3913  PLFLT arg2 ;
3914  PLFLT arg3 ;
3915  PLFLT arg4 ;
3916  PLINT arg5 ;
3917  PLINT arg6 ;
3918 
3919  SWIG_check_num_args("plenv",6,6)
3920  if(!lua_isnumber(L,1)) SWIG_fail_arg("plenv",1,"PLFLT");
3921  if(!lua_isnumber(L,2)) SWIG_fail_arg("plenv",2,"PLFLT");
3922  if(!lua_isnumber(L,3)) SWIG_fail_arg("plenv",3,"PLFLT");
3923  if(!lua_isnumber(L,4)) SWIG_fail_arg("plenv",4,"PLFLT");
3924  if(!lua_isnumber(L,5)) SWIG_fail_arg("plenv",5,"PLINT");
3925  if(!lua_isnumber(L,6)) SWIG_fail_arg("plenv",6,"PLINT");
3926  arg1 = (PLFLT)lua_tonumber(L, 1);
3927  arg2 = (PLFLT)lua_tonumber(L, 2);
3928  arg3 = (PLFLT)lua_tonumber(L, 3);
3929  arg4 = (PLFLT)lua_tonumber(L, 4);
3930  arg5 = (PLINT)lua_tonumber(L, 5);
3931  arg6 = (PLINT)lua_tonumber(L, 6);
3932  plenv(arg1,arg2,arg3,arg4,arg5,arg6);
3933 
3934  return SWIG_arg;
3935 
3936  if(0) SWIG_fail;
3937 
3938 fail:
3939  lua_error(L);
3940  return SWIG_arg;
3941 }
3942 
3943 
3944 static int _wrap_env0(lua_State* L) {
3945  int SWIG_arg = 0;
3946  PLFLT arg1 ;
3947  PLFLT arg2 ;
3948  PLFLT arg3 ;
3949  PLFLT arg4 ;
3950  PLINT arg5 ;
3951  PLINT arg6 ;
3952 
3953  SWIG_check_num_args("plenv0",6,6)
3954  if(!lua_isnumber(L,1)) SWIG_fail_arg("plenv0",1,"PLFLT");
3955  if(!lua_isnumber(L,2)) SWIG_fail_arg("plenv0",2,"PLFLT");
3956  if(!lua_isnumber(L,3)) SWIG_fail_arg("plenv0",3,"PLFLT");
3957  if(!lua_isnumber(L,4)) SWIG_fail_arg("plenv0",4,"PLFLT");
3958  if(!lua_isnumber(L,5)) SWIG_fail_arg("plenv0",5,"PLINT");
3959  if(!lua_isnumber(L,6)) SWIG_fail_arg("plenv0",6,"PLINT");
3960  arg1 = (PLFLT)lua_tonumber(L, 1);
3961  arg2 = (PLFLT)lua_tonumber(L, 2);
3962  arg3 = (PLFLT)lua_tonumber(L, 3);
3963  arg4 = (PLFLT)lua_tonumber(L, 4);
3964  arg5 = (PLINT)lua_tonumber(L, 5);
3965  arg6 = (PLINT)lua_tonumber(L, 6);
3966  plenv0(arg1,arg2,arg3,arg4,arg5,arg6);
3967 
3968  return SWIG_arg;
3969 
3970  if(0) SWIG_fail;
3971 
3972 fail:
3973  lua_error(L);
3974  return SWIG_arg;
3975 }
3976 
3977 
3978 static int _wrap_eop(lua_State* L) {
3979  int SWIG_arg = 0;
3980 
3981  SWIG_check_num_args("pleop",0,0)
3982  pleop();
3983 
3984  return SWIG_arg;
3985 
3986  if(0) SWIG_fail;
3987 
3988 fail:
3989  lua_error(L);
3990  return SWIG_arg;
3991 }
3992 
3993 
3994 static int _wrap_errx(lua_State* L) {
3995  int SWIG_arg = 0;
3996  PLINT arg1 ;
3997  PLFLT *arg2 = (PLFLT *) 0 ;
3998  PLFLT *arg3 = (PLFLT *) 0 ;
3999  PLFLT *arg4 = (PLFLT *) 0 ;
4000  int temp3 ;
4001  int temp4 ;
4002 
4003  SWIG_check_num_args("plerrx",3,3)
4004  {
4005  int temp;
4006  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4007  if ( !arg2 )
4008  SWIG_fail;
4009  arg1 = Alen = temp;
4010  }
4011  {
4012  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4013  if ( !arg3 )
4014  SWIG_fail;
4015  if ( temp3 != Alen )
4016  {
4017  lua_pushfstring( L, "Tables must be of same length." );
4018  SWIG_fail;
4019  }
4020  }
4021  {
4022  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
4023  if ( !arg4 )
4024  SWIG_fail;
4025  if ( temp4 != Alen )
4026  {
4027  lua_pushfstring( L, "Tables must be of same length." );
4028  SWIG_fail;
4029  }
4030  }
4031  plerrx(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
4032 
4033  {
4034  LUA_FREE_ARRAY( arg2 );
4035  }
4036  {
4037  LUA_FREE_ARRAY( arg3 );
4038  }
4039  {
4040  LUA_FREE_ARRAY( arg4 );
4041  }
4042  return SWIG_arg;
4043 
4044  if(0) SWIG_fail;
4045 
4046 fail:
4047  {
4048  LUA_FREE_ARRAY( arg2 );
4049  }
4050  {
4051  LUA_FREE_ARRAY( arg3 );
4052  }
4053  {
4054  LUA_FREE_ARRAY( arg4 );
4055  }
4056  lua_error(L);
4057  return SWIG_arg;
4058 }
4059 
4060 
4061 static int _wrap_erry(lua_State* L) {
4062  int SWIG_arg = 0;
4063  PLINT arg1 ;
4064  PLFLT *arg2 = (PLFLT *) 0 ;
4065  PLFLT *arg3 = (PLFLT *) 0 ;
4066  PLFLT *arg4 = (PLFLT *) 0 ;
4067  int temp3 ;
4068  int temp4 ;
4069 
4070  SWIG_check_num_args("plerry",3,3)
4071  {
4072  int temp;
4073  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4074  if ( !arg2 )
4075  SWIG_fail;
4076  arg1 = Alen = temp;
4077  }
4078  {
4079  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4080  if ( !arg3 )
4081  SWIG_fail;
4082  if ( temp3 != Alen )
4083  {
4084  lua_pushfstring( L, "Tables must be of same length." );
4085  SWIG_fail;
4086  }
4087  }
4088  {
4089  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
4090  if ( !arg4 )
4091  SWIG_fail;
4092  if ( temp4 != Alen )
4093  {
4094  lua_pushfstring( L, "Tables must be of same length." );
4095  SWIG_fail;
4096  }
4097  }
4098  plerry(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
4099 
4100  {
4101  LUA_FREE_ARRAY( arg2 );
4102  }
4103  {
4104  LUA_FREE_ARRAY( arg3 );
4105  }
4106  {
4107  LUA_FREE_ARRAY( arg4 );
4108  }
4109  return SWIG_arg;
4110 
4111  if(0) SWIG_fail;
4112 
4113 fail:
4114  {
4115  LUA_FREE_ARRAY( arg2 );
4116  }
4117  {
4118  LUA_FREE_ARRAY( arg3 );
4119  }
4120  {
4121  LUA_FREE_ARRAY( arg4 );
4122  }
4123  lua_error(L);
4124  return SWIG_arg;
4125 }
4126 
4127 
4128 static int _wrap_famadv(lua_State* L) {
4129  int SWIG_arg = 0;
4130 
4131  SWIG_check_num_args("plfamadv",0,0)
4132  plfamadv();
4133 
4134  return SWIG_arg;
4135 
4136  if(0) SWIG_fail;
4137 
4138 fail:
4139  lua_error(L);
4140  return SWIG_arg;
4141 }
4142 
4143 
4144 static int _wrap_fill(lua_State* L) {
4145  int SWIG_arg = 0;
4146  PLINT arg1 ;
4147  PLFLT *arg2 = (PLFLT *) 0 ;
4148  PLFLT *arg3 = (PLFLT *) 0 ;
4149  int temp3 ;
4150 
4151  SWIG_check_num_args("plfill",2,2)
4152  {
4153  int temp;
4154  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4155  if ( !arg2 )
4156  SWIG_fail;
4157  arg1 = Alen = temp;
4158  }
4159  {
4160  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4161  if ( !arg3 )
4162  SWIG_fail;
4163  if ( temp3 != Alen )
4164  {
4165  lua_pushfstring( L, "Tables must be of same length." );
4166  SWIG_fail;
4167  }
4168  }
4169  plfill(arg1,(double const *)arg2,(double const *)arg3);
4170 
4171  {
4172  LUA_FREE_ARRAY( arg2 );
4173  }
4174  {
4175  LUA_FREE_ARRAY( arg3 );
4176  }
4177  return SWIG_arg;
4178 
4179  if(0) SWIG_fail;
4180 
4181 fail:
4182  {
4183  LUA_FREE_ARRAY( arg2 );
4184  }
4185  {
4186  LUA_FREE_ARRAY( arg3 );
4187  }
4188  lua_error(L);
4189  return SWIG_arg;
4190 }
4191 
4192 
4193 static int _wrap_fill3(lua_State* L) {
4194  int SWIG_arg = 0;
4195  PLINT arg1 ;
4196  PLFLT *arg2 = (PLFLT *) 0 ;
4197  PLFLT *arg3 = (PLFLT *) 0 ;
4198  PLFLT *arg4 = (PLFLT *) 0 ;
4199  int temp3 ;
4200  int temp4 ;
4201 
4202  SWIG_check_num_args("plfill3",3,3)
4203  {
4204  int temp;
4205  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4206  if ( !arg2 )
4207  SWIG_fail;
4208  arg1 = Alen = temp;
4209  }
4210  {
4211  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4212  if ( !arg3 )
4213  SWIG_fail;
4214  if ( temp3 != Alen )
4215  {
4216  lua_pushfstring( L, "Tables must be of same length." );
4217  SWIG_fail;
4218  }
4219  }
4220  {
4221  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
4222  if ( !arg4 )
4223  SWIG_fail;
4224  if ( temp4 != Alen )
4225  {
4226  lua_pushfstring( L, "Tables must be of same length." );
4227  SWIG_fail;
4228  }
4229  }
4230  plfill3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
4231 
4232  {
4233  LUA_FREE_ARRAY( arg2 );
4234  }
4235  {
4236  LUA_FREE_ARRAY( arg3 );
4237  }
4238  {
4239  LUA_FREE_ARRAY( arg4 );
4240  }
4241  return SWIG_arg;
4242 
4243  if(0) SWIG_fail;
4244 
4245 fail:
4246  {
4247  LUA_FREE_ARRAY( arg2 );
4248  }
4249  {
4250  LUA_FREE_ARRAY( arg3 );
4251  }
4252  {
4253  LUA_FREE_ARRAY( arg4 );
4254  }
4255  lua_error(L);
4256  return SWIG_arg;
4257 }
4258 
4259 
4260 static int _wrap_gradient(lua_State* L) {
4261  int SWIG_arg = 0;
4262  PLINT arg1 ;
4263  PLFLT *arg2 = (PLFLT *) 0 ;
4264  PLFLT *arg3 = (PLFLT *) 0 ;
4265  PLFLT arg4 ;
4266  int temp3 ;
4267 
4268  SWIG_check_num_args("plgradient",3,3)
4269  if(!lua_isnumber(L,3)) SWIG_fail_arg("plgradient",3,"PLFLT");
4270  {
4271  int temp;
4272  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4273  if ( !arg2 )
4274  SWIG_fail;
4275  arg1 = Alen = temp;
4276  }
4277  {
4278  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4279  if ( !arg3 )
4280  SWIG_fail;
4281  if ( temp3 != Alen )
4282  {
4283  lua_pushfstring( L, "Tables must be of same length." );
4284  SWIG_fail;
4285  }
4286  }
4287  arg4 = (PLFLT)lua_tonumber(L, 3);
4288  plgradient(arg1,(double const *)arg2,(double const *)arg3,arg4);
4289 
4290  {
4291  LUA_FREE_ARRAY( arg2 );
4292  }
4293  {
4294  LUA_FREE_ARRAY( arg3 );
4295  }
4296  return SWIG_arg;
4297 
4298  if(0) SWIG_fail;
4299 
4300 fail:
4301  {
4302  LUA_FREE_ARRAY( arg2 );
4303  }
4304  {
4305  LUA_FREE_ARRAY( arg3 );
4306  }
4307  lua_error(L);
4308  return SWIG_arg;
4309 }
4310 
4311 
4312 static int _wrap_flush(lua_State* L) {
4313  int SWIG_arg = 0;
4314 
4315  SWIG_check_num_args("plflush",0,0)
4316  plflush();
4317 
4318  return SWIG_arg;
4319 
4320  if(0) SWIG_fail;
4321 
4322 fail:
4323  lua_error(L);
4324  return SWIG_arg;
4325 }
4326 
4327 
4328 static int _wrap_font(lua_State* L) {
4329  int SWIG_arg = 0;
4330  PLINT arg1 ;
4331 
4332  SWIG_check_num_args("plfont",1,1)
4333  if(!lua_isnumber(L,1)) SWIG_fail_arg("plfont",1,"PLINT");
4334  arg1 = (PLINT)lua_tonumber(L, 1);
4335  plfont(arg1);
4336 
4337  return SWIG_arg;
4338 
4339  if(0) SWIG_fail;
4340 
4341 fail:
4342  lua_error(L);
4343  return SWIG_arg;
4344 }
4345 
4346 
4347 static int _wrap_fontld(lua_State* L) {
4348  int SWIG_arg = 0;
4349  PLINT arg1 ;
4350 
4351  SWIG_check_num_args("plfontld",1,1)
4352  if(!lua_isnumber(L,1)) SWIG_fail_arg("plfontld",1,"PLINT");
4353  arg1 = (PLINT)lua_tonumber(L, 1);
4354  plfontld(arg1);
4355 
4356  return SWIG_arg;
4357 
4358  if(0) SWIG_fail;
4359 
4360 fail:
4361  lua_error(L);
4362  return SWIG_arg;
4363 }
4364 
4365 
4366 static int _wrap_gchr(lua_State* L) {
4367  int SWIG_arg = 0;
4368  PLFLT *arg1 = (PLFLT *) 0 ;
4369  PLFLT *arg2 = (PLFLT *) 0 ;
4370  PLFLT temp1 ;
4371  PLFLT temp2 ;
4372 
4373  arg1 = &temp1;
4374  arg2 = &temp2;
4375  SWIG_check_num_args("plgchr",0,0)
4376  plgchr(arg1,arg2);
4377 
4378  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4379  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4380  return SWIG_arg;
4381 
4382  if(0) SWIG_fail;
4383 
4384 fail:
4385  lua_error(L);
4386  return SWIG_arg;
4387 }
4388 
4389 
4390 static int _wrap_gcol0(lua_State* L) {
4391  int SWIG_arg = 0;
4392  PLINT arg1 ;
4393  PLINT *arg2 = (PLINT *) 0 ;
4394  PLINT *arg3 = (PLINT *) 0 ;
4395  PLINT *arg4 = (PLINT *) 0 ;
4396  PLINT temp2 ;
4397  PLINT temp3 ;
4398  PLINT temp4 ;
4399 
4400  arg2 = &temp2;
4401  arg3 = &temp3;
4402  arg4 = &temp4;
4403  SWIG_check_num_args("plgcol0",1,1)
4404  if(!lua_isnumber(L,1)) SWIG_fail_arg("plgcol0",1,"PLINT");
4405  arg1 = (PLINT)lua_tonumber(L, 1);
4406  plgcol0(arg1,arg2,arg3,arg4);
4407 
4408  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4409  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4410  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4411  return SWIG_arg;
4412 
4413  if(0) SWIG_fail;
4414 
4415 fail:
4416  lua_error(L);
4417  return SWIG_arg;
4418 }
4419 
4420 
4421 static int _wrap_gcol0a(lua_State* L) {
4422  int SWIG_arg = 0;
4423  PLINT arg1 ;
4424  PLINT *arg2 = (PLINT *) 0 ;
4425  PLINT *arg3 = (PLINT *) 0 ;
4426  PLINT *arg4 = (PLINT *) 0 ;
4427  PLFLT *arg5 = (PLFLT *) 0 ;
4428  PLINT temp2 ;
4429  PLINT temp3 ;
4430  PLINT temp4 ;
4431  PLFLT temp5 ;
4432 
4433  arg2 = &temp2;
4434  arg3 = &temp3;
4435  arg4 = &temp4;
4436  arg5 = &temp5;
4437  SWIG_check_num_args("plgcol0a",1,1)
4438  if(!lua_isnumber(L,1)) SWIG_fail_arg("plgcol0a",1,"PLINT");
4439  arg1 = (PLINT)lua_tonumber(L, 1);
4440  plgcol0a(arg1,arg2,arg3,arg4,arg5);
4441 
4442  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4443  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4444  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4445  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
4446  return SWIG_arg;
4447 
4448  if(0) SWIG_fail;
4449 
4450 fail:
4451  lua_error(L);
4452  return SWIG_arg;
4453 }
4454 
4455 
4456 static int _wrap_gcolbg(lua_State* L) {
4457  int SWIG_arg = 0;
4458  PLINT *arg1 = (PLINT *) 0 ;
4459  PLINT *arg2 = (PLINT *) 0 ;
4460  PLINT *arg3 = (PLINT *) 0 ;
4461  PLINT temp1 ;
4462  PLINT temp2 ;
4463  PLINT temp3 ;
4464 
4465  arg1 = &temp1;
4466  arg2 = &temp2;
4467  arg3 = &temp3;
4468  SWIG_check_num_args("plgcolbg",0,0)
4469  plgcolbg(arg1,arg2,arg3);
4470 
4471  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4472  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4473  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4474  return SWIG_arg;
4475 
4476  if(0) SWIG_fail;
4477 
4478 fail:
4479  lua_error(L);
4480  return SWIG_arg;
4481 }
4482 
4483 
4484 static int _wrap_gcolbga(lua_State* L) {
4485  int SWIG_arg = 0;
4486  PLINT *arg1 = (PLINT *) 0 ;
4487  PLINT *arg2 = (PLINT *) 0 ;
4488  PLINT *arg3 = (PLINT *) 0 ;
4489  PLFLT *arg4 = (PLFLT *) 0 ;
4490  PLINT temp1 ;
4491  PLINT temp2 ;
4492  PLINT temp3 ;
4493  PLFLT temp4 ;
4494 
4495  arg1 = &temp1;
4496  arg2 = &temp2;
4497  arg3 = &temp3;
4498  arg4 = &temp4;
4499  SWIG_check_num_args("plgcolbga",0,0)
4500  plgcolbga(arg1,arg2,arg3,arg4);
4501 
4502  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4503  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4504  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4505  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4506  return SWIG_arg;
4507 
4508  if(0) SWIG_fail;
4509 
4510 fail:
4511  lua_error(L);
4512  return SWIG_arg;
4513 }
4514 
4515 
4516 static int _wrap_gcompression(lua_State* L) {
4517  int SWIG_arg = 0;
4518  PLINT *arg1 = (PLINT *) 0 ;
4519  PLINT temp1 ;
4520 
4521  arg1 = &temp1;
4522  SWIG_check_num_args("plgcompression",0,0)
4523  plgcompression(arg1);
4524 
4525  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4526  return SWIG_arg;
4527 
4528  if(0) SWIG_fail;
4529 
4530 fail:
4531  lua_error(L);
4532  return SWIG_arg;
4533 }
4534 
4535 
4536 static int _wrap_gdev(lua_State* L) {
4537  int SWIG_arg = 0;
4538  char *arg1 = (char *) 0 ;
4539  char buff1[1000] ;
4540 
4541  {
4542  arg1 = buff1;
4543  }
4544  SWIG_check_num_args("plgdev",0,0)
4545  plgdev(arg1);
4546 
4547  {
4548  lua_pushstring( L, arg1 );
4549  SWIG_arg++;
4550  }
4551  return SWIG_arg;
4552 
4553  if(0) SWIG_fail;
4554 
4555 fail:
4556  lua_error(L);
4557  return SWIG_arg;
4558 }
4559 
4560 
4561 static int _wrap_gdidev(lua_State* L) {
4562  int SWIG_arg = 0;
4563  PLFLT *arg1 = (PLFLT *) 0 ;
4564  PLFLT *arg2 = (PLFLT *) 0 ;
4565  PLFLT *arg3 = (PLFLT *) 0 ;
4566  PLFLT *arg4 = (PLFLT *) 0 ;
4567  PLFLT temp1 ;
4568  PLFLT temp2 ;
4569  PLFLT temp3 ;
4570  PLFLT temp4 ;
4571 
4572  arg1 = &temp1;
4573  arg2 = &temp2;
4574  arg3 = &temp3;
4575  arg4 = &temp4;
4576  SWIG_check_num_args("plgdidev",0,0)
4577  plgdidev(arg1,arg2,arg3,arg4);
4578 
4579  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4580  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4581  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4582  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4583  return SWIG_arg;
4584 
4585  if(0) SWIG_fail;
4586 
4587 fail:
4588  lua_error(L);
4589  return SWIG_arg;
4590 }
4591 
4592 
4593 static int _wrap_gdiori(lua_State* L) {
4594  int SWIG_arg = 0;
4595  PLFLT *arg1 = (PLFLT *) 0 ;
4596  PLFLT temp1 ;
4597 
4598  arg1 = &temp1;
4599  SWIG_check_num_args("plgdiori",0,0)
4600  plgdiori(arg1);
4601 
4602  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4603  return SWIG_arg;
4604 
4605  if(0) SWIG_fail;
4606 
4607 fail:
4608  lua_error(L);
4609  return SWIG_arg;
4610 }
4611 
4612 
4613 static int _wrap_gdiplt(lua_State* L) {
4614  int SWIG_arg = 0;
4615  PLFLT *arg1 = (PLFLT *) 0 ;
4616  PLFLT *arg2 = (PLFLT *) 0 ;
4617  PLFLT *arg3 = (PLFLT *) 0 ;
4618  PLFLT *arg4 = (PLFLT *) 0 ;
4619  PLFLT temp1 ;
4620  PLFLT temp2 ;
4621  PLFLT temp3 ;
4622  PLFLT temp4 ;
4623 
4624  arg1 = &temp1;
4625  arg2 = &temp2;
4626  arg3 = &temp3;
4627  arg4 = &temp4;
4628  SWIG_check_num_args("plgdiplt",0,0)
4629  plgdiplt(arg1,arg2,arg3,arg4);
4630 
4631  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4632  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4633  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4634  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4635  return SWIG_arg;
4636 
4637  if(0) SWIG_fail;
4638 
4639 fail:
4640  lua_error(L);
4641  return SWIG_arg;
4642 }
4643 
4644 
4645 static int _wrap_gfam(lua_State* L) {
4646  int SWIG_arg = 0;
4647  PLINT *arg1 = (PLINT *) 0 ;
4648  PLINT *arg2 = (PLINT *) 0 ;
4649  PLINT *arg3 = (PLINT *) 0 ;
4650  PLINT temp1 ;
4651  PLINT temp2 ;
4652  PLINT temp3 ;
4653 
4654  arg1 = &temp1;
4655  arg2 = &temp2;
4656  arg3 = &temp3;
4657  SWIG_check_num_args("plgfam",0,0)
4658  plgfam(arg1,arg2,arg3);
4659 
4660  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4661  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4662  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4663  return SWIG_arg;
4664 
4665  if(0) SWIG_fail;
4666 
4667 fail:
4668  lua_error(L);
4669  return SWIG_arg;
4670 }
4671 
4672 
4673 static int _wrap_gfci(lua_State* L) {
4674  int SWIG_arg = 0;
4675  PLUNICODE *arg1 = (PLUNICODE *) 0 ;
4676  PLUNICODE temp1 ;
4677 
4678  arg1 = &temp1;
4679  SWIG_check_num_args("plgfci",0,0)
4680  plgfci(arg1);
4681 
4682  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4683  return SWIG_arg;
4684 
4685  if(0) SWIG_fail;
4686 
4687 fail:
4688  lua_error(L);
4689  return SWIG_arg;
4690 }
4691 
4692 
4693 static int _wrap_gfnam(lua_State* L) {
4694  int SWIG_arg = 0;
4695  char *arg1 = (char *) 0 ;
4696  char buff1[1000] ;
4697 
4698  {
4699  arg1 = buff1;
4700  }
4701  SWIG_check_num_args("plgfnam",0,0)
4702  plgfnam(arg1);
4703 
4704  {
4705  lua_pushstring( L, arg1 );
4706  SWIG_arg++;
4707  }
4708  return SWIG_arg;
4709 
4710  if(0) SWIG_fail;
4711 
4712 fail:
4713  lua_error(L);
4714  return SWIG_arg;
4715 }
4716 
4717 
4718 static int _wrap_gfont(lua_State* L) {
4719  int SWIG_arg = 0;
4720  PLINT *arg1 = (PLINT *) 0 ;
4721  PLINT *arg2 = (PLINT *) 0 ;
4722  PLINT *arg3 = (PLINT *) 0 ;
4723  PLINT temp1 ;
4724  PLINT temp2 ;
4725  PLINT temp3 ;
4726 
4727  arg1 = &temp1;
4728  arg2 = &temp2;
4729  arg3 = &temp3;
4730  SWIG_check_num_args("plgfont",0,0)
4731  plgfont(arg1,arg2,arg3);
4732 
4733  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4734  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4735  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4736  return SWIG_arg;
4737 
4738  if(0) SWIG_fail;
4739 
4740 fail:
4741  lua_error(L);
4742  return SWIG_arg;
4743 }
4744 
4745 
4746 static int _wrap_glevel(lua_State* L) {
4747  int SWIG_arg = 0;
4748  PLINT *arg1 = (PLINT *) 0 ;
4749  PLINT temp1 ;
4750 
4751  arg1 = &temp1;
4752  SWIG_check_num_args("plglevel",0,0)
4753  plglevel(arg1);
4754 
4755  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4756  return SWIG_arg;
4757 
4758  if(0) SWIG_fail;
4759 
4760 fail:
4761  lua_error(L);
4762  return SWIG_arg;
4763 }
4764 
4765 
4766 static int _wrap_gpage(lua_State* L) {
4767  int SWIG_arg = 0;
4768  PLFLT *arg1 = (PLFLT *) 0 ;
4769  PLFLT *arg2 = (PLFLT *) 0 ;
4770  PLINT *arg3 = (PLINT *) 0 ;
4771  PLINT *arg4 = (PLINT *) 0 ;
4772  PLINT *arg5 = (PLINT *) 0 ;
4773  PLINT *arg6 = (PLINT *) 0 ;
4774  PLFLT temp1 ;
4775  PLFLT temp2 ;
4776  PLINT temp3 ;
4777  PLINT temp4 ;
4778  PLINT temp5 ;
4779  PLINT temp6 ;
4780 
4781  arg1 = &temp1;
4782  arg2 = &temp2;
4783  arg3 = &temp3;
4784  arg4 = &temp4;
4785  arg5 = &temp5;
4786  arg6 = &temp6;
4787  SWIG_check_num_args("plgpage",0,0)
4788  plgpage(arg1,arg2,arg3,arg4,arg5,arg6);
4789 
4790  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4791  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4792  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4793  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4794  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
4795  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
4796  return SWIG_arg;
4797 
4798  if(0) SWIG_fail;
4799 
4800 fail:
4801  lua_error(L);
4802  return SWIG_arg;
4803 }
4804 
4805 
4806 static int _wrap_gra(lua_State* L) {
4807  int SWIG_arg = 0;
4808 
4809  SWIG_check_num_args("plgra",0,0)
4810  plgra();
4811 
4812  return SWIG_arg;
4813 
4814  if(0) SWIG_fail;
4815 
4816 fail:
4817  lua_error(L);
4818  return SWIG_arg;
4819 }
4820 
4821 
4822 static int _wrap_griddata(lua_State* L) {
4823  int SWIG_arg = 0;
4824  PLFLT *arg1 = (PLFLT *) 0 ;
4825  PLFLT *arg2 = (PLFLT *) 0 ;
4826  PLFLT *arg3 = (PLFLT *) 0 ;
4827  PLINT arg4 ;
4828  PLFLT *arg5 = (PLFLT *) 0 ;
4829  PLINT arg6 ;
4830  PLFLT *arg7 = (PLFLT *) 0 ;
4831  PLINT arg8 ;
4832  PLFLT **arg9 = (PLFLT **) 0 ;
4833  PLINT arg10 ;
4834  PLFLT arg11 ;
4835  int temp2 ;
4836 
4837  SWIG_check_num_args("plgriddata",7,7)
4838  if(!lua_isnumber(L,6)) SWIG_fail_arg("plgriddata",6,"PLINT");
4839  if(!lua_isnumber(L,7)) SWIG_fail_arg("plgriddata",7,"PLFLT");
4840  {
4841  int temp;
4842  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4843  if ( !arg1 )
4844  SWIG_fail;
4845  Alen = temp;
4846  }
4847  {
4848  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp2 );
4849  if ( !arg2 )
4850  SWIG_fail;
4851  if ( temp2 != Alen )
4852  {
4853  lua_pushfstring( L, "Tables must be of same length." );
4854  SWIG_fail;
4855  }
4856  }
4857  {
4858  int temp;
4859  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp );
4860  if ( !arg3 )
4861  SWIG_fail;
4862  if ( temp != Alen )
4863  {
4864  lua_pushfstring( L, "Tables must be of same length." );
4865  SWIG_fail;
4866  }
4867  arg4 = temp;
4868  }
4869  {
4870  int temp;
4871  arg5 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp );
4872  if ( !arg5 )
4873  SWIG_fail;
4874  arg6 = Xlen = temp;
4875  }
4876  {
4877  int temp, i;
4878 
4879  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
4880  if ( !arg7 )
4881  SWIG_fail;
4882  arg8 = Ylen = temp;
4883 
4884  arg9 = LUA_ALLOC_ARRAY( PLFLT *, Xlen );
4885  if ( !arg9 )
4886  SWIG_fail;
4887  for ( i = 0; i < Xlen; i++ )
4888  arg9[i] = NULL;
4889 
4890  for ( i = 0; i < Xlen; i++ )
4891  {
4892  arg9[i] = LUA_ALLOC_ARRAY( PLFLT, Ylen );
4893  if ( !arg9[i] )
4894  SWIG_fail;
4895  }
4896  }
4897  arg10 = (PLINT)lua_tonumber(L, 6);
4898  arg11 = (PLFLT)lua_tonumber(L, 7);
4899  plgriddata((double const *)arg1,(double const *)arg2,(double const *)arg3,arg4,(double const *)arg5,arg6,(double const *)arg7,arg8,arg9,arg10,arg11);
4900 
4901  {
4902  int i;
4903 
4904  if ( arg9 )
4905  {
4906  lua_newtable( L );
4907  for ( i = 0; i < Xlen; i++ )
4908  {
4909  SWIG_write_double_num_array( L, arg9[i], Ylen );
4910  lua_rawseti( L, -2, i + 1 ); // -1 is the inner table, -2 is the outer table
4911  }
4912  SWIG_arg++;
4913  }
4914  }
4915  {
4916  LUA_FREE_ARRAY( arg1 );
4917  }
4918  {
4919  LUA_FREE_ARRAY( arg2 );
4920  }
4921  {
4922  LUA_FREE_ARRAY( arg3 );
4923  }
4924  {
4925  LUA_FREE_ARRAY( arg5 );
4926  }
4927  {
4928  int i;
4929 
4930  LUA_FREE_ARRAY( arg7 );
4931 
4932  if ( arg9 )
4933  {
4934  for ( i = 0; i < Xlen; i++ )
4935  LUA_FREE_ARRAY( arg9[i] );
4936  LUA_FREE_ARRAY( arg9 );
4937  }
4938  }
4939  return SWIG_arg;
4940 
4941  if(0) SWIG_fail;
4942 
4943 fail:
4944  {
4945  LUA_FREE_ARRAY( arg1 );
4946  }
4947  {
4948  LUA_FREE_ARRAY( arg2 );
4949  }
4950  {
4951  LUA_FREE_ARRAY( arg3 );
4952  }
4953  {
4954  LUA_FREE_ARRAY( arg5 );
4955  }
4956  {
4957  int i;
4958 
4959  LUA_FREE_ARRAY( arg7 );
4960 
4961  if ( arg9 )
4962  {
4963  for ( i = 0; i < Xlen; i++ )
4964  LUA_FREE_ARRAY( arg9[i] );
4965  LUA_FREE_ARRAY( arg9 );
4966  }
4967  }
4968  lua_error(L);
4969  return SWIG_arg;
4970 }
4971 
4972 
4973 static int _wrap_gspa(lua_State* L) {
4974  int SWIG_arg = 0;
4975  PLFLT *arg1 = (PLFLT *) 0 ;
4976  PLFLT *arg2 = (PLFLT *) 0 ;
4977  PLFLT *arg3 = (PLFLT *) 0 ;
4978  PLFLT *arg4 = (PLFLT *) 0 ;
4979  PLFLT temp1 ;
4980  PLFLT temp2 ;
4981  PLFLT temp3 ;
4982  PLFLT temp4 ;
4983 
4984  arg1 = &temp1;
4985  arg2 = &temp2;
4986  arg3 = &temp3;
4987  arg4 = &temp4;
4988  SWIG_check_num_args("plgspa",0,0)
4989  plgspa(arg1,arg2,arg3,arg4);
4990 
4991  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4992  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4993  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4994  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4995  return SWIG_arg;
4996 
4997  if(0) SWIG_fail;
4998 
4999 fail:
5000  lua_error(L);
5001  return SWIG_arg;
5002 }
5003 
5004 
5005 static int _wrap_gstrm(lua_State* L) {
5006  int SWIG_arg = 0;
5007  PLINT *arg1 = (PLINT *) 0 ;
5008  PLINT temp1 ;
5009 
5010  arg1 = &temp1;
5011  SWIG_check_num_args("plgstrm",0,0)
5012  plgstrm(arg1);
5013 
5014  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5015  return SWIG_arg;
5016 
5017  if(0) SWIG_fail;
5018 
5019 fail:
5020  lua_error(L);
5021  return SWIG_arg;
5022 }
5023 
5024 
5025 static int _wrap_gver(lua_State* L) {
5026  int SWIG_arg = 0;
5027  char *arg1 = (char *) 0 ;
5028  char buff1[1000] ;
5029 
5030  {
5031  arg1 = buff1;
5032  }
5033  SWIG_check_num_args("plgver",0,0)
5034  plgver(arg1);
5035 
5036  {
5037  lua_pushstring( L, arg1 );
5038  SWIG_arg++;
5039  }
5040  return SWIG_arg;
5041 
5042  if(0) SWIG_fail;
5043 
5044 fail:
5045  lua_error(L);
5046  return SWIG_arg;
5047 }
5048 
5049 
5050 static int _wrap_gvpd(lua_State* L) {
5051  int SWIG_arg = 0;
5052  PLFLT *arg1 = (PLFLT *) 0 ;
5053  PLFLT *arg2 = (PLFLT *) 0 ;
5054  PLFLT *arg3 = (PLFLT *) 0 ;
5055  PLFLT *arg4 = (PLFLT *) 0 ;
5056  PLFLT temp1 ;
5057  PLFLT temp2 ;
5058  PLFLT temp3 ;
5059  PLFLT temp4 ;
5060 
5061  arg1 = &temp1;
5062  arg2 = &temp2;
5063  arg3 = &temp3;
5064  arg4 = &temp4;
5065  SWIG_check_num_args("plgvpd",0,0)
5066  plgvpd(arg1,arg2,arg3,arg4);
5067 
5068  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5069  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5070  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5071  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5072  return SWIG_arg;
5073 
5074  if(0) SWIG_fail;
5075 
5076 fail:
5077  lua_error(L);
5078  return SWIG_arg;
5079 }
5080 
5081 
5082 static int _wrap_gvpw(lua_State* L) {
5083  int SWIG_arg = 0;
5084  PLFLT *arg1 = (PLFLT *) 0 ;
5085  PLFLT *arg2 = (PLFLT *) 0 ;
5086  PLFLT *arg3 = (PLFLT *) 0 ;
5087  PLFLT *arg4 = (PLFLT *) 0 ;
5088  PLFLT temp1 ;
5089  PLFLT temp2 ;
5090  PLFLT temp3 ;
5091  PLFLT temp4 ;
5092 
5093  arg1 = &temp1;
5094  arg2 = &temp2;
5095  arg3 = &temp3;
5096  arg4 = &temp4;
5097  SWIG_check_num_args("plgvpw",0,0)
5098  plgvpw(arg1,arg2,arg3,arg4);
5099 
5100  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5101  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5102  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5103  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5104  return SWIG_arg;
5105 
5106  if(0) SWIG_fail;
5107 
5108 fail:
5109  lua_error(L);
5110  return SWIG_arg;
5111 }
5112 
5113 
5114 static int _wrap_gxax(lua_State* L) {
5115  int SWIG_arg = 0;
5116  PLINT *arg1 = (PLINT *) 0 ;
5117  PLINT *arg2 = (PLINT *) 0 ;
5118  PLINT temp1 ;
5119  PLINT temp2 ;
5120 
5121  arg1 = &temp1;
5122  arg2 = &temp2;
5123  SWIG_check_num_args("plgxax",0,0)
5124  plgxax(arg1,arg2);
5125 
5126  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5127  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5128  return SWIG_arg;
5129 
5130  if(0) SWIG_fail;
5131 
5132 fail:
5133  lua_error(L);
5134  return SWIG_arg;
5135 }
5136 
5137 
5138 static int _wrap_gyax(lua_State* L) {
5139  int SWIG_arg = 0;
5140  PLINT *arg1 = (PLINT *) 0 ;
5141  PLINT *arg2 = (PLINT *) 0 ;
5142  PLINT temp1 ;
5143  PLINT temp2 ;
5144 
5145  arg1 = &temp1;
5146  arg2 = &temp2;
5147  SWIG_check_num_args("plgyax",0,0)
5148  plgyax(arg1,arg2);
5149 
5150  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5151  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5152  return SWIG_arg;
5153 
5154  if(0) SWIG_fail;
5155 
5156 fail:
5157  lua_error(L);
5158  return SWIG_arg;
5159 }
5160 
5161 
5162 static int _wrap_gzax(lua_State* L) {
5163  int SWIG_arg = 0;
5164  PLINT *arg1 = (PLINT *) 0 ;
5165  PLINT *arg2 = (PLINT *) 0 ;
5166  PLINT temp1 ;
5167  PLINT temp2 ;
5168 
5169  arg1 = &temp1;
5170  arg2 = &temp2;
5171  SWIG_check_num_args("plgzax",0,0)
5172  plgzax(arg1,arg2);
5173 
5174  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5175  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5176  return SWIG_arg;
5177 
5178  if(0) SWIG_fail;
5179 
5180 fail:
5181  lua_error(L);
5182  return SWIG_arg;
5183 }
5184 
5185 
5186 static int _wrap_hist(lua_State* L) {
5187  int SWIG_arg = 0;
5188  PLINT arg1 ;
5189  PLFLT *arg2 = (PLFLT *) 0 ;
5190  PLFLT arg3 ;
5191  PLFLT arg4 ;
5192  PLINT arg5 ;
5193  PLINT arg6 ;
5194 
5195  SWIG_check_num_args("plhist",5,5)
5196  if(!lua_isnumber(L,2)) SWIG_fail_arg("plhist",2,"PLFLT");
5197  if(!lua_isnumber(L,3)) SWIG_fail_arg("plhist",3,"PLFLT");
5198  if(!lua_isnumber(L,4)) SWIG_fail_arg("plhist",4,"PLINT");
5199  if(!lua_isnumber(L,5)) SWIG_fail_arg("plhist",5,"PLINT");
5200  {
5201  int temp;
5202  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
5203  if ( !arg2 )
5204  SWIG_fail;
5205  arg1 = Alen = temp;
5206  }
5207  arg3 = (PLFLT)lua_tonumber(L, 2);
5208  arg4 = (PLFLT)lua_tonumber(L, 3);
5209  arg5 = (PLINT)lua_tonumber(L, 4);
5210  arg6 = (PLINT)lua_tonumber(L, 5);
5211  plhist(arg1,(double const *)arg2,arg3,arg4,arg5,arg6);
5212 
5213  {
5214  LUA_FREE_ARRAY( arg2 );
5215  }
5216  return SWIG_arg;
5217 
5218  if(0) SWIG_fail;
5219 
5220 fail:
5221  {
5222  LUA_FREE_ARRAY( arg2 );
5223  }
5224  lua_error(L);
5225  return SWIG_arg;
5226 }
5227 
5228 
5229 static int _wrap_hlsrgb(lua_State* L) {
5230  int SWIG_arg = 0;
5231  PLFLT arg1 ;
5232  PLFLT arg2 ;
5233  PLFLT arg3 ;
5234  PLFLT *arg4 = (PLFLT *) 0 ;
5235  PLFLT *arg5 = (PLFLT *) 0 ;
5236  PLFLT *arg6 = (PLFLT *) 0 ;
5237  PLFLT temp4 ;
5238  PLFLT temp5 ;
5239  PLFLT temp6 ;
5240 
5241  arg4 = &temp4;
5242  arg5 = &temp5;
5243  arg6 = &temp6;
5244  SWIG_check_num_args("plhlsrgb",3,3)
5245  if(!lua_isnumber(L,1)) SWIG_fail_arg("plhlsrgb",1,"PLFLT");
5246  if(!lua_isnumber(L,2)) SWIG_fail_arg("plhlsrgb",2,"PLFLT");
5247  if(!lua_isnumber(L,3)) SWIG_fail_arg("plhlsrgb",3,"PLFLT");
5248  arg1 = (PLFLT)lua_tonumber(L, 1);
5249  arg2 = (PLFLT)lua_tonumber(L, 2);
5250  arg3 = (PLFLT)lua_tonumber(L, 3);
5251  plhlsrgb(arg1,arg2,arg3,arg4,arg5,arg6);
5252 
5253  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5254  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
5255  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
5256  return SWIG_arg;
5257 
5258  if(0) SWIG_fail;
5259 
5260 fail:
5261  lua_error(L);
5262  return SWIG_arg;
5263 }
5264 
5265 
5266 static int _wrap_init(lua_State* L) {
5267  int SWIG_arg = 0;
5268 
5269  SWIG_check_num_args("plinit",0,0)
5270  plinit();
5271 
5272  return SWIG_arg;
5273 
5274  if(0) SWIG_fail;
5275 
5276 fail:
5277  lua_error(L);
5278  return SWIG_arg;
5279 }
5280 
5281 
5282 static int _wrap_join(lua_State* L) {
5283  int SWIG_arg = 0;
5284  PLFLT arg1 ;
5285  PLFLT arg2 ;
5286  PLFLT arg3 ;
5287  PLFLT arg4 ;
5288 
5289  SWIG_check_num_args("pljoin",4,4)
5290  if(!lua_isnumber(L,1)) SWIG_fail_arg("pljoin",1,"PLFLT");
5291  if(!lua_isnumber(L,2)) SWIG_fail_arg("pljoin",2,"PLFLT");
5292  if(!lua_isnumber(L,3)) SWIG_fail_arg("pljoin",3,"PLFLT");
5293  if(!lua_isnumber(L,4)) SWIG_fail_arg("pljoin",4,"PLFLT");
5294  arg1 = (PLFLT)lua_tonumber(L, 1);
5295  arg2 = (PLFLT)lua_tonumber(L, 2);
5296  arg3 = (PLFLT)lua_tonumber(L, 3);
5297  arg4 = (PLFLT)lua_tonumber(L, 4);
5298  pljoin(arg1,arg2,arg3,arg4);
5299 
5300  return SWIG_arg;
5301 
5302  if(0) SWIG_fail;
5303 
5304 fail:
5305  lua_error(L);
5306  return SWIG_arg;
5307 }
5308 
5309 
5310 static int _wrap_lab(lua_State* L) {
5311  int SWIG_arg = 0;
5312  char *arg1 = (char *) 0 ;
5313  char *arg2 = (char *) 0 ;
5314  char *arg3 = (char *) 0 ;
5315 
5316  SWIG_check_num_args("pllab",3,3)
5317  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("pllab",1,"char const *");
5318  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("pllab",2,"char const *");
5319  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("pllab",3,"char const *");
5320  arg1 = (char *)lua_tostring(L, 1);
5321  arg2 = (char *)lua_tostring(L, 2);
5322  arg3 = (char *)lua_tostring(L, 3);
5323  pllab((char const *)arg1,(char const *)arg2,(char const *)arg3);
5324 
5325  return SWIG_arg;
5326 
5327  if(0) SWIG_fail;
5328 
5329 fail:
5330  lua_error(L);
5331  return SWIG_arg;
5332 }
5333 
5334 
5335 static int _wrap_legend(lua_State* L) {
5336  int SWIG_arg = 0;
5337  PLFLT *arg1 = (PLFLT *) 0 ;
5338  PLFLT *arg2 = (PLFLT *) 0 ;
5339  PLINT arg3 ;
5340  PLINT arg4 ;
5341  PLFLT arg5 ;
5342  PLFLT arg6 ;
5343  PLFLT arg7 ;
5344  PLINT arg8 ;
5345  PLINT arg9 ;
5346  PLINT arg10 ;
5347  PLINT arg11 ;
5348  PLINT arg12 ;
5349  PLINT arg13 ;
5350  PLINT *arg14 = (PLINT *) 0 ;
5351  PLFLT arg15 ;
5352  PLFLT arg16 ;
5353  PLFLT arg17 ;
5354  PLFLT arg18 ;
5355  PLINT *arg19 = (PLINT *) 0 ;
5356  char **arg20 = (char **) 0 ;
5357  PLINT *arg21 = (PLINT *) 0 ;
5358  PLINT *arg22 = (PLINT *) 0 ;
5359  PLFLT *arg23 = (PLFLT *) 0 ;
5360  PLFLT *arg24 = (PLFLT *) 0 ;
5361  PLINT *arg25 = (PLINT *) 0 ;
5362  PLINT *arg26 = (PLINT *) 0 ;
5363  PLFLT *arg27 = (PLFLT *) 0 ;
5364  PLINT *arg28 = (PLINT *) 0 ;
5365  PLFLT *arg29 = (PLFLT *) 0 ;
5366  PLINT *arg30 = (PLINT *) 0 ;
5367  char **arg31 = (char **) 0 ;
5368  PLFLT temp1 ;
5369  PLFLT temp2 ;
5370  int temp19 ;
5371  int temp21 ;
5372  int temp22 ;
5373  int temp23 ;
5374  int temp24 ;
5375  int temp25 ;
5376  int temp26 ;
5377  int temp27 ;
5378  int temp28 ;
5379  int temp29 ;
5380  int temp30 ;
5381 
5382  {
5383  arg21 = NULL;
5384  }
5385  {
5386  arg22 = NULL;
5387  }
5388  {
5389  arg23 = NULL;
5390  }
5391  {
5392  arg24 = NULL;
5393  }
5394  {
5395  arg25 = NULL;
5396  }
5397  {
5398  arg26 = NULL;
5399  }
5400  {
5401  arg27 = NULL;
5402  }
5403  {
5404  arg28 = NULL;
5405  }
5406  {
5407  arg29 = NULL;
5408  }
5409  {
5410  arg30 = NULL;
5411  }
5412  arg1 = &temp1;
5413  arg2 = &temp2;
5414  SWIG_check_num_args("pllegend",17,28)
5415  if(!lua_isnumber(L,1)) SWIG_fail_arg("pllegend",1,"PLINT");
5416  if(!lua_isnumber(L,2)) SWIG_fail_arg("pllegend",2,"PLINT");
5417  if(!lua_isnumber(L,3)) SWIG_fail_arg("pllegend",3,"PLFLT");
5418  if(!lua_isnumber(L,4)) SWIG_fail_arg("pllegend",4,"PLFLT");
5419  if(!lua_isnumber(L,5)) SWIG_fail_arg("pllegend",5,"PLFLT");
5420  if(!lua_isnumber(L,6)) SWIG_fail_arg("pllegend",6,"PLINT");
5421  if(!lua_isnumber(L,7)) SWIG_fail_arg("pllegend",7,"PLINT");
5422  if(!lua_isnumber(L,8)) SWIG_fail_arg("pllegend",8,"PLINT");
5423  if(!lua_isnumber(L,9)) SWIG_fail_arg("pllegend",9,"PLINT");
5424  if(!lua_isnumber(L,10)) SWIG_fail_arg("pllegend",10,"PLINT");
5425  if(!lua_isnumber(L,12)) SWIG_fail_arg("pllegend",12,"PLFLT");
5426  if(!lua_isnumber(L,13)) SWIG_fail_arg("pllegend",13,"PLFLT");
5427  if(!lua_isnumber(L,14)) SWIG_fail_arg("pllegend",14,"PLFLT");
5428  if(!lua_isnumber(L,15)) SWIG_fail_arg("pllegend",15,"PLFLT");
5429  if(!lua_istable(L,17)) SWIG_fail_arg("pllegend",17,"char const **");
5430  if(lua_gettop(L)>=28 && !lua_istable(L,28)) SWIG_fail_arg("pllegend",28,"char const **");
5431  arg3 = (PLINT)lua_tonumber(L, 1);
5432  arg4 = (PLINT)lua_tonumber(L, 2);
5433  arg5 = (PLFLT)lua_tonumber(L, 3);
5434  arg6 = (PLFLT)lua_tonumber(L, 4);
5435  arg7 = (PLFLT)lua_tonumber(L, 5);
5436  arg8 = (PLINT)lua_tonumber(L, 6);
5437  arg9 = (PLINT)lua_tonumber(L, 7);
5438  arg10 = (PLINT)lua_tonumber(L, 8);
5439  arg11 = (PLINT)lua_tonumber(L, 9);
5440  arg12 = (PLINT)lua_tonumber(L, 10);
5441  {
5442  arg14 = (PLINT *) LUA_get_int_num_array_var( L, 11, &arg13 );
5443  if ( !arg14 )
5444  SWIG_fail;
5445  Alen = arg13;
5446  }
5447  arg15 = (PLFLT)lua_tonumber(L, 12);
5448  arg16 = (PLFLT)lua_tonumber(L, 13);
5449  arg17 = (PLFLT)lua_tonumber(L, 14);
5450  arg18 = (PLFLT)lua_tonumber(L, 15);
5451  {
5452  arg19 = (PLINT *) LUA_get_int_num_array_var( L, 16, &temp19 );
5453  if ( !arg19 )
5454  SWIG_fail;
5455  if ( temp19 != Alen )
5456  {
5457  lua_pushfstring( L, "Tables must be of same length." );
5458  SWIG_fail;
5459  }
5460  }
5461  {
5462  int i;
5463  arg20 = NULL;
5464 
5465  if ( SWIG_table_size( L, 17 ) != Alen )
5466  {
5467  lua_pushfstring( L, "Tables must be of same length." );
5468  SWIG_fail;
5469  }
5470  arg20 = malloc( sizeof ( char* ) * Alen );
5471  for ( i = 1; i <= Alen; i++ )
5472  {
5473  lua_rawgeti( L, 17, i );
5474  if ( lua_isstring( L, -1 ) )
5475  {
5476  arg20[i - 1] = (char *) lua_tostring( L, -1 );
5477  }
5478  else
5479  {
5480  lua_pop( L, 1 );
5481  lua_pushfstring( L, "Requires a sequence of strings." );
5482  SWIG_fail;
5483  // arg20 array is freed after 'fail:'
5484  }
5485  lua_pop( L, 1 );
5486  }
5487  }
5488  if(lua_gettop(L)>=18){
5489  {
5490  if ( lua_isnil( L, 18 ) )
5491  {
5492  arg21 = NULL;
5493  }
5494  else
5495  {
5496  arg21 = (PLINT *) LUA_get_int_num_array_var( L, 18, &temp21 );
5497  if ( !arg21 )
5498  SWIG_fail;
5499  if ( temp21 != Alen )
5500  {
5501  lua_pushfstring( L, "Tables must be of same length." );
5502  SWIG_fail;
5503  }
5504  }
5505  }
5506  }
5507  if(lua_gettop(L)>=19){
5508  {
5509  if ( lua_isnil( L, 19 ) )
5510  {
5511  arg22 = NULL;
5512  }
5513  else
5514  {
5515  arg22 = (PLINT *) LUA_get_int_num_array_var( L, 19, &temp22 );
5516  if ( !arg22 )
5517  SWIG_fail;
5518  if ( temp22 != Alen )
5519  {
5520  lua_pushfstring( L, "Tables must be of same length." );
5521  SWIG_fail;
5522  }
5523  }
5524  }
5525  }
5526  if(lua_gettop(L)>=20){
5527  {
5528  if ( lua_isnil( L, 20 ) )
5529  {
5530  arg23 = NULL;
5531  }
5532  else
5533  {
5534  arg23 = (PLFLT *) LUA_get_double_num_array_var( L, 20, &temp23 );
5535  if ( !arg23 )
5536  SWIG_fail;
5537  if ( temp23 != Alen )
5538  {
5539  lua_pushfstring( L, "Tables must be of same length." );
5540  SWIG_fail;
5541  }
5542  }
5543  }
5544  }
5545  if(lua_gettop(L)>=21){
5546  {
5547  if ( lua_isnil( L, 21 ) )
5548  {
5549  arg24 = NULL;
5550  }
5551  else
5552  {
5553  arg24 = (PLFLT *) LUA_get_double_num_array_var( L, 21, &temp24 );
5554  if ( !arg24 )
5555  SWIG_fail;
5556  if ( temp24 != Alen )
5557  {
5558  lua_pushfstring( L, "Tables must be of same length." );
5559  SWIG_fail;
5560  }
5561  }
5562  }
5563  }
5564  if(lua_gettop(L)>=22){
5565  {
5566  if ( lua_isnil( L, 22 ) )
5567  {
5568  arg25 = NULL;
5569  }
5570  else
5571  {
5572  arg25 = (PLINT *) LUA_get_int_num_array_var( L, 22, &temp25 );
5573  if ( !arg25 )
5574  SWIG_fail;
5575  if ( temp25 != Alen )
5576  {
5577  lua_pushfstring( L, "Tables must be of same length." );
5578  SWIG_fail;
5579  }
5580  }
5581  }
5582  }
5583  if(lua_gettop(L)>=23){
5584  {
5585  if ( lua_isnil( L, 23 ) )
5586  {
5587  arg26 = NULL;
5588  }
5589  else
5590  {
5591  arg26 = (PLINT *) LUA_get_int_num_array_var( L, 23, &temp26 );
5592  if ( !arg26 )
5593  SWIG_fail;
5594  if ( temp26 != Alen )
5595  {
5596  lua_pushfstring( L, "Tables must be of same length." );
5597  SWIG_fail;
5598  }
5599  }
5600  }
5601  }
5602  if(lua_gettop(L)>=24){
5603  {
5604  if ( lua_isnil( L, 24 ) )
5605  {
5606  arg27 = NULL;
5607  }
5608  else
5609  {
5610  arg27 = (PLFLT *) LUA_get_double_num_array_var( L, 24, &temp27 );
5611  if ( !arg27 )
5612  SWIG_fail;
5613  if ( temp27 != Alen )
5614  {
5615  lua_pushfstring( L, "Tables must be of same length." );
5616  SWIG_fail;
5617  }
5618  }
5619  }
5620  }
5621  if(lua_gettop(L)>=25){
5622  {
5623  if ( lua_isnil( L, 25 ) )
5624  {
5625  arg28 = NULL;
5626  }
5627  else
5628  {
5629  arg28 = (PLINT *) LUA_get_int_num_array_var( L, 25, &temp28 );
5630  if ( !arg28 )
5631  SWIG_fail;
5632  if ( temp28 != Alen )
5633  {
5634  lua_pushfstring( L, "Tables must be of same length." );
5635  SWIG_fail;
5636  }
5637  }
5638  }
5639  }
5640  if(lua_gettop(L)>=26){
5641  {
5642  if ( lua_isnil( L, 26 ) )
5643  {
5644  arg29 = NULL;
5645  }
5646  else
5647  {
5648  arg29 = (PLFLT *) LUA_get_double_num_array_var( L, 26, &temp29 );
5649  if ( !arg29 )
5650  SWIG_fail;
5651  if ( temp29 != Alen )
5652  {
5653  lua_pushfstring( L, "Tables must be of same length." );
5654  SWIG_fail;
5655  }
5656  }
5657  }
5658  }
5659  if(lua_gettop(L)>=27){
5660  {
5661  if ( lua_isnil( L, 27 ) )
5662  {
5663  arg30 = NULL;
5664  }
5665  else
5666  {
5667  arg30 = (PLINT *) LUA_get_int_num_array_var( L, 27, &temp30 );
5668  if ( !arg30 )
5669  SWIG_fail;
5670  if ( temp30 != Alen )
5671  {
5672  lua_pushfstring( L, "Tables must be of same length." );
5673  SWIG_fail;
5674  }
5675  }
5676  }
5677  }
5678  if(lua_gettop(L)>=28){
5679  {
5680  int i;
5681  arg31 = NULL;
5682 
5683  if ( SWIG_table_size( L, 28 ) != Alen )
5684  {
5685  lua_pushfstring( L, "Tables must be of same length." );
5686  SWIG_fail;
5687  }
5688  arg31 = malloc( sizeof ( char* ) * Alen );
5689  for ( i = 1; i <= Alen; i++ )
5690  {
5691  lua_rawgeti( L, 28, i );
5692  if ( lua_isstring( L, -1 ) )
5693  {
5694  arg31[i - 1] = (char *) lua_tostring( L, -1 );
5695  }
5696  else
5697  {
5698  lua_pop( L, 1 );
5699  lua_pushfstring( L, "Requires a sequence of strings." );
5700  SWIG_fail;
5701  // arg31 array is freed after 'fail:'
5702  }
5703  lua_pop( L, 1 );
5704  }
5705  }
5706  }
5707  pllegend(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13,(int const *)arg14,arg15,arg16,arg17,arg18,(int const *)arg19,(char const **)arg20,(int const *)arg21,(int const *)arg22,(double const *)arg23,(double const *)arg24,(int const *)arg25,(int const *)arg26,(double const *)arg27,(int const *)arg28,(double const *)arg29,(int const *)arg30,(char const **)arg31);
5708 
5709  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5710  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5711  {
5712  LUA_FREE_ARRAY( arg14 );
5713  }
5714  {
5715  LUA_FREE_ARRAY( arg19 );
5716  }
5717  {
5718  if ( arg20 )
5719  {
5720  free( arg20 ); arg20 = NULL;
5721  }
5722  }
5723  {
5724  LUA_FREE_ARRAY( arg21 );
5725  }
5726  {
5727  LUA_FREE_ARRAY( arg22 );
5728  }
5729  {
5730  LUA_FREE_ARRAY( arg23 );
5731  }
5732  {
5733  LUA_FREE_ARRAY( arg24 );
5734  }
5735  {
5736  LUA_FREE_ARRAY( arg25 );
5737  }
5738  {
5739  LUA_FREE_ARRAY( arg26 );
5740  }
5741  {
5742  LUA_FREE_ARRAY( arg27 );
5743  }
5744  {
5745  LUA_FREE_ARRAY( arg28 );
5746  }
5747  {
5748  LUA_FREE_ARRAY( arg29 );
5749  }
5750  {
5751  LUA_FREE_ARRAY( arg30 );
5752  }
5753  {
5754  if ( arg31 )
5755  {
5756  free( arg31 ); arg31 = NULL;
5757  }
5758  }
5759  return SWIG_arg;
5760 
5761  if(0) SWIG_fail;
5762 
5763 fail:
5764  {
5765  LUA_FREE_ARRAY( arg14 );
5766  }
5767  {
5768  LUA_FREE_ARRAY( arg19 );
5769  }
5770  {
5771  if ( arg20 )
5772  {
5773  free( arg20 ); arg20 = NULL;
5774  }
5775  }
5776  {
5777  LUA_FREE_ARRAY( arg21 );
5778  }
5779  {
5780  LUA_FREE_ARRAY( arg22 );
5781  }
5782  {
5783  LUA_FREE_ARRAY( arg23 );
5784  }
5785  {
5786  LUA_FREE_ARRAY( arg24 );
5787  }
5788  {
5789  LUA_FREE_ARRAY( arg25 );
5790  }
5791  {
5792  LUA_FREE_ARRAY( arg26 );
5793  }
5794  {
5795  LUA_FREE_ARRAY( arg27 );
5796  }
5797  {
5798  LUA_FREE_ARRAY( arg28 );
5799  }
5800  {
5801  LUA_FREE_ARRAY( arg29 );
5802  }
5803  {
5804  LUA_FREE_ARRAY( arg30 );
5805  }
5806  {
5807  if ( arg31 )
5808  {
5809  free( arg31 ); arg31 = NULL;
5810  }
5811  }
5812  lua_error(L);
5813  return SWIG_arg;
5814 }
5815 
5816 
5817 static int _wrap_colorbar(lua_State* L) {
5818  int SWIG_arg = 0;
5819  PLFLT *arg1 = (PLFLT *) 0 ;
5820  PLFLT *arg2 = (PLFLT *) 0 ;
5821  PLINT arg3 ;
5822  PLINT arg4 ;
5823  PLFLT arg5 ;
5824  PLFLT arg6 ;
5825  PLFLT arg7 ;
5826  PLFLT arg8 ;
5827  PLINT arg9 ;
5828  PLINT arg10 ;
5829  PLINT arg11 ;
5830  PLFLT arg12 ;
5831  PLFLT arg13 ;
5832  PLINT arg14 ;
5833  PLFLT arg15 ;
5834  PLINT arg16 ;
5835  PLINT *arg17 = (PLINT *) 0 ;
5836  char **arg18 = (char **) 0 ;
5837  PLINT arg19 ;
5838  char **arg20 = (char **) 0 ;
5839  PLFLT *arg21 = (PLFLT *) 0 ;
5840  PLINT *arg22 = (PLINT *) 0 ;
5841  PLINT *arg23 = (PLINT *) 0 ;
5842  PLFLT **arg24 = (PLFLT **) 0 ;
5843  PLFLT temp1 ;
5844  PLFLT temp2 ;
5845  int temp21 ;
5846  int temp22 ;
5847  int temp23 ;
5848  int ii24 ;
5849 
5850  arg1 = &temp1;
5851  arg2 = &temp2;
5852  SWIG_check_num_args("plcolorbar",20,20)
5853  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcolorbar",1,"PLINT");
5854  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcolorbar",2,"PLINT");
5855  if(!lua_isnumber(L,3)) SWIG_fail_arg("plcolorbar",3,"PLFLT");
5856  if(!lua_isnumber(L,4)) SWIG_fail_arg("plcolorbar",4,"PLFLT");
5857  if(!lua_isnumber(L,5)) SWIG_fail_arg("plcolorbar",5,"PLFLT");
5858  if(!lua_isnumber(L,6)) SWIG_fail_arg("plcolorbar",6,"PLFLT");
5859  if(!lua_isnumber(L,7)) SWIG_fail_arg("plcolorbar",7,"PLINT");
5860  if(!lua_isnumber(L,8)) SWIG_fail_arg("plcolorbar",8,"PLINT");
5861  if(!lua_isnumber(L,9)) SWIG_fail_arg("plcolorbar",9,"PLINT");
5862  if(!lua_isnumber(L,10)) SWIG_fail_arg("plcolorbar",10,"PLFLT");
5863  if(!lua_isnumber(L,11)) SWIG_fail_arg("plcolorbar",11,"PLFLT");
5864  if(!lua_isnumber(L,12)) SWIG_fail_arg("plcolorbar",12,"PLINT");
5865  if(!lua_isnumber(L,13)) SWIG_fail_arg("plcolorbar",13,"PLFLT");
5866  if(!lua_istable(L,15)) SWIG_fail_arg("plcolorbar",15,"char const **");
5867  arg3 = (PLINT)lua_tonumber(L, 1);
5868  arg4 = (PLINT)lua_tonumber(L, 2);
5869  arg5 = (PLFLT)lua_tonumber(L, 3);
5870  arg6 = (PLFLT)lua_tonumber(L, 4);
5871  arg7 = (PLFLT)lua_tonumber(L, 5);
5872  arg8 = (PLFLT)lua_tonumber(L, 6);
5873  arg9 = (PLINT)lua_tonumber(L, 7);
5874  arg10 = (PLINT)lua_tonumber(L, 8);
5875  arg11 = (PLINT)lua_tonumber(L, 9);
5876  arg12 = (PLFLT)lua_tonumber(L, 10);
5877  arg13 = (PLFLT)lua_tonumber(L, 11);
5878  arg14 = (PLINT)lua_tonumber(L, 12);
5879  arg15 = (PLFLT)lua_tonumber(L, 13);
5880  {
5881  arg17 = (PLINT *) LUA_get_int_num_array_var( L, 14, &arg16 );
5882  if ( !arg17 )
5883  SWIG_fail;
5884  Alen = arg16;
5885  }
5886  {
5887  int i;
5888  arg18 = NULL;
5889 
5890  if ( SWIG_table_size( L, 15 ) != Alen )
5891  {
5892  lua_pushfstring( L, "Tables must be of same length." );
5893  SWIG_fail;
5894  }
5895  arg18 = malloc( sizeof ( char* ) * Alen );
5896  for ( i = 1; i <= Alen; i++ )
5897  {
5898  lua_rawgeti( L, 15, i );
5899  if ( lua_isstring( L, -1 ) )
5900  {
5901  arg18[i - 1] = (char *) lua_tostring( L, -1 );
5902  }
5903  else
5904  {
5905  lua_pop( L, 1 );
5906  lua_pushfstring( L, "Requires a sequence of strings." );
5907  SWIG_fail;
5908  // arg18 array is freed after 'fail:'
5909  }
5910  lua_pop( L, 1 );
5911  }
5912  }
5913  {
5914  int i;
5915  arg19 = SWIG_table_size( L, 16 );
5916  Alen = arg19;
5917 
5918  arg20 = malloc( sizeof ( char* ) * Alen );
5919  for ( i = 1; i <= Alen; i++ )
5920  {
5921  lua_rawgeti( L, 16, i );
5922  if ( lua_isstring( L, -1 ) )
5923  {
5924  arg20[i - 1] = (char *) lua_tostring( L, -1 );
5925  }
5926  else
5927  {
5928  lua_pop( L, 1 );
5929  lua_pushfstring( L, "Requires a sequence of strings." );
5930  SWIG_fail;
5931  }
5932  lua_pop( L, 1 );
5933  }
5934  }
5935  {
5936  arg21 = (PLFLT *) LUA_get_double_num_array_var( L, 17, &temp21 );
5937  if ( !arg21 )
5938  SWIG_fail;
5939  if ( temp21 != Alen )
5940  {
5941  lua_pushfstring( L, "Tables must be of same length." );
5942  SWIG_fail;
5943  }
5944  }
5945  {
5946  arg22 = (PLINT *) LUA_get_int_num_array_var( L, 18, &temp22 );
5947  if ( !arg22 )
5948  SWIG_fail;
5949  if ( temp22 != Alen )
5950  {
5951  lua_pushfstring( L, "Tables must be of same length." );
5952  SWIG_fail;
5953  }
5954  }
5955  {
5956  int i;
5957 
5958  arg23 = (PLINT *) LUA_get_int_num_array_var( L, 19, &temp23 );
5959  if ( !arg23 )
5960  SWIG_fail;
5961  if ( temp23 != Alen )
5962  {
5963  lua_pushfstring( L, "Tables must be of same length." );
5964  SWIG_fail;
5965  }
5966 
5967  Xlen = temp23;
5968  Ylen = -1;
5969  for ( i = 0; i < Xlen; i++ )
5970  if ( arg23[i] > Ylen )
5971  Ylen = arg23[i];
5972  }
5973  {
5974  int jj;
5975 
5976  arg24 = read_double_Matrix( L, 20, &ii24, &jj );
5977  if ( !arg24 )
5978  SWIG_fail;
5979  if ( ( ii24 != Xlen ) || ( jj != Ylen ) )
5980  {
5981  lua_pushfstring( L, "Vectors must match matrix." );
5982  SWIG_fail;
5983  }
5984  }
5985  plcolorbar(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13,arg14,arg15,arg16,(int const *)arg17,(char const **)arg18,arg19,(char const **)arg20,(double const *)arg21,(int const *)arg22,(int const *)arg23,(double const **)arg24);
5986 
5987  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5988  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5989  {
5990  LUA_FREE_ARRAY( arg17 );
5991  }
5992  {
5993  if ( arg18 )
5994  {
5995  free( arg18 ); arg18 = NULL;
5996  }
5997  }
5998  {
5999  if ( arg20 )
6000  {
6001  free( arg20 ); arg20 = NULL;
6002  }
6003  }
6004  {
6005  LUA_FREE_ARRAY( arg21 );
6006  }
6007  {
6008  LUA_FREE_ARRAY( arg22 );
6009  }
6010  {
6011  LUA_FREE_ARRAY( arg23 );
6012  }
6013  {
6014  int i;
6015 
6016  if ( arg24 )
6017  {
6018  for ( i = 0; i < ii24; i++ )
6019  LUA_FREE_ARRAY( arg24[i] );
6020  LUA_FREE_ARRAY( arg24 );
6021  }
6022  }
6023  return SWIG_arg;
6024 
6025  if(0) SWIG_fail;
6026 
6027 fail:
6028  {
6029  LUA_FREE_ARRAY( arg17 );
6030  }
6031  {
6032  if ( arg18 )
6033  {
6034  free( arg18 ); arg18 = NULL;
6035  }
6036  }
6037  {
6038  if ( arg20 )
6039  {
6040  free( arg20 ); arg20 = NULL;
6041  }
6042  }
6043  {
6044  LUA_FREE_ARRAY( arg21 );
6045  }
6046  {
6047  LUA_FREE_ARRAY( arg22 );
6048  }
6049  {
6050  LUA_FREE_ARRAY( arg23 );
6051  }
6052  {
6053  int i;
6054 
6055  if ( arg24 )
6056  {
6057  for ( i = 0; i < ii24; i++ )
6058  LUA_FREE_ARRAY( arg24[i] );
6059  LUA_FREE_ARRAY( arg24 );
6060  }
6061  }
6062  lua_error(L);
6063  return SWIG_arg;
6064 }
6065 
6066 
6067 static int _wrap_lightsource(lua_State* L) {
6068  int SWIG_arg = 0;
6069  PLFLT arg1 ;
6070  PLFLT arg2 ;
6071  PLFLT arg3 ;
6072 
6073  SWIG_check_num_args("pllightsource",3,3)
6074  if(!lua_isnumber(L,1)) SWIG_fail_arg("pllightsource",1,"PLFLT");
6075  if(!lua_isnumber(L,2)) SWIG_fail_arg("pllightsource",2,"PLFLT");
6076  if(!lua_isnumber(L,3)) SWIG_fail_arg("pllightsource",3,"PLFLT");
6077  arg1 = (PLFLT)lua_tonumber(L, 1);
6078  arg2 = (PLFLT)lua_tonumber(L, 2);
6079  arg3 = (PLFLT)lua_tonumber(L, 3);
6080  pllightsource(arg1,arg2,arg3);
6081 
6082  return SWIG_arg;
6083 
6084  if(0) SWIG_fail;
6085 
6086 fail:
6087  lua_error(L);
6088  return SWIG_arg;
6089 }
6090 
6091 
6092 static int _wrap_line(lua_State* L) {
6093  int SWIG_arg = 0;
6094  PLINT arg1 ;
6095  PLFLT *arg2 = (PLFLT *) 0 ;
6096  PLFLT *arg3 = (PLFLT *) 0 ;
6097  int temp3 ;
6098 
6099  SWIG_check_num_args("plline",2,2)
6100  {
6101  int temp;
6102  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6103  if ( !arg2 )
6104  SWIG_fail;
6105  arg1 = Alen = temp;
6106  }
6107  {
6108  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
6109  if ( !arg3 )
6110  SWIG_fail;
6111  if ( temp3 != Alen )
6112  {
6113  lua_pushfstring( L, "Tables must be of same length." );
6114  SWIG_fail;
6115  }
6116  }
6117  plline(arg1,(double const *)arg2,(double const *)arg3);
6118 
6119  {
6120  LUA_FREE_ARRAY( arg2 );
6121  }
6122  {
6123  LUA_FREE_ARRAY( arg3 );
6124  }
6125  return SWIG_arg;
6126 
6127  if(0) SWIG_fail;
6128 
6129 fail:
6130  {
6131  LUA_FREE_ARRAY( arg2 );
6132  }
6133  {
6134  LUA_FREE_ARRAY( arg3 );
6135  }
6136  lua_error(L);
6137  return SWIG_arg;
6138 }
6139 
6140 
6141 static int _wrap_line3(lua_State* L) {
6142  int SWIG_arg = 0;
6143  PLINT arg1 ;
6144  PLFLT *arg2 = (PLFLT *) 0 ;
6145  PLFLT *arg3 = (PLFLT *) 0 ;
6146  PLFLT *arg4 = (PLFLT *) 0 ;
6147  int temp3 ;
6148  int temp4 ;
6149 
6150  SWIG_check_num_args("plline3",3,3)
6151  {
6152  int temp;
6153  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6154  if ( !arg2 )
6155  SWIG_fail;
6156  arg1 = Alen = temp;
6157  }
6158  {
6159  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
6160  if ( !arg3 )
6161  SWIG_fail;
6162  if ( temp3 != Alen )
6163  {
6164  lua_pushfstring( L, "Tables must be of same length." );
6165  SWIG_fail;
6166  }
6167  }
6168  {
6169  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
6170  if ( !arg4 )
6171  SWIG_fail;
6172  if ( temp4 != Alen )
6173  {
6174  lua_pushfstring( L, "Tables must be of same length." );
6175  SWIG_fail;
6176  }
6177  }
6178  plline3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
6179 
6180  {
6181  LUA_FREE_ARRAY( arg2 );
6182  }
6183  {
6184  LUA_FREE_ARRAY( arg3 );
6185  }
6186  {
6187  LUA_FREE_ARRAY( arg4 );
6188  }
6189  return SWIG_arg;
6190 
6191  if(0) SWIG_fail;
6192 
6193 fail:
6194  {
6195  LUA_FREE_ARRAY( arg2 );
6196  }
6197  {
6198  LUA_FREE_ARRAY( arg3 );
6199  }
6200  {
6201  LUA_FREE_ARRAY( arg4 );
6202  }
6203  lua_error(L);
6204  return SWIG_arg;
6205 }
6206 
6207 
6208 static int _wrap_lsty(lua_State* L) {
6209  int SWIG_arg = 0;
6210  PLINT arg1 ;
6211 
6212  SWIG_check_num_args("pllsty",1,1)
6213  if(!lua_isnumber(L,1)) SWIG_fail_arg("pllsty",1,"PLINT");
6214  arg1 = (PLINT)lua_tonumber(L, 1);
6215  pllsty(arg1);
6216 
6217  return SWIG_arg;
6218 
6219  if(0) SWIG_fail;
6220 
6221 fail:
6222  lua_error(L);
6223  return SWIG_arg;
6224 }
6225 
6226 
6227 static int _wrap_mesh(lua_State* L) {
6228  int SWIG_arg = 0;
6229  PLFLT *arg1 = (PLFLT *) 0 ;
6230  PLFLT *arg2 = (PLFLT *) 0 ;
6231  PLFLT **arg3 = (PLFLT **) 0 ;
6232  PLINT arg4 ;
6233  PLINT arg5 ;
6234  PLINT arg6 ;
6235  int ii3 ;
6236 
6237  SWIG_check_num_args("plmesh",4,4)
6238  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmesh",4,"PLINT");
6239  {
6240  int temp;
6241  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6242  if ( !arg1 )
6243  SWIG_fail;
6244  Xlen = temp;
6245  }
6246  {
6247  int temp;
6248  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6249  if ( !arg2 )
6250  SWIG_fail;
6251  Ylen = temp;
6252  }
6253  {
6254  int jj;
6255 
6256  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6257  if ( !arg3 )
6258  SWIG_fail;
6259  arg4 = ii3;
6260  arg5 = jj;
6261  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6262  {
6263  lua_pushfstring( L, "Vectors must match matrix." );
6264  SWIG_fail;
6265  }
6266  }
6267  arg6 = (PLINT)lua_tonumber(L, 4);
6268  plmesh((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6);
6269 
6270  {
6271  LUA_FREE_ARRAY( arg1 );
6272  }
6273  {
6274  LUA_FREE_ARRAY( arg2 );
6275  }
6276  {
6277  int i;
6278 
6279  if ( arg3 )
6280  {
6281  for ( i = 0; i < ii3; i++ )
6282  LUA_FREE_ARRAY( arg3[i] );
6283  LUA_FREE_ARRAY( arg3 );
6284  }
6285  }
6286  return SWIG_arg;
6287 
6288  if(0) SWIG_fail;
6289 
6290 fail:
6291  {
6292  LUA_FREE_ARRAY( arg1 );
6293  }
6294  {
6295  LUA_FREE_ARRAY( arg2 );
6296  }
6297  {
6298  int i;
6299 
6300  if ( arg3 )
6301  {
6302  for ( i = 0; i < ii3; i++ )
6303  LUA_FREE_ARRAY( arg3[i] );
6304  LUA_FREE_ARRAY( arg3 );
6305  }
6306  }
6307  lua_error(L);
6308  return SWIG_arg;
6309 }
6310 
6311 
6312 static int _wrap_meshc(lua_State* L) {
6313  int SWIG_arg = 0;
6314  PLFLT *arg1 = (PLFLT *) 0 ;
6315  PLFLT *arg2 = (PLFLT *) 0 ;
6316  PLFLT **arg3 = (PLFLT **) 0 ;
6317  PLINT arg4 ;
6318  PLINT arg5 ;
6319  PLINT arg6 ;
6320  PLFLT *arg7 = (PLFLT *) 0 ;
6321  PLINT arg8 ;
6322  int ii3 ;
6323 
6324  SWIG_check_num_args("plmeshc",5,5)
6325  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmeshc",4,"PLINT");
6326  {
6327  int temp;
6328  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6329  if ( !arg1 )
6330  SWIG_fail;
6331  Xlen = temp;
6332  }
6333  {
6334  int temp;
6335  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6336  if ( !arg2 )
6337  SWIG_fail;
6338  Ylen = temp;
6339  }
6340  {
6341  int jj;
6342 
6343  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6344  if ( !arg3 )
6345  SWIG_fail;
6346  arg4 = ii3;
6347  arg5 = jj;
6348  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6349  {
6350  lua_pushfstring( L, "Vectors must match matrix." );
6351  SWIG_fail;
6352  }
6353  }
6354  arg6 = (PLINT)lua_tonumber(L, 4);
6355  {
6356  int temp;
6357  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
6358  if ( !arg7 )
6359  SWIG_fail;
6360  arg8 = Alen = temp;
6361  }
6362  plmeshc((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8);
6363 
6364  {
6365  LUA_FREE_ARRAY( arg1 );
6366  }
6367  {
6368  LUA_FREE_ARRAY( arg2 );
6369  }
6370  {
6371  int i;
6372 
6373  if ( arg3 )
6374  {
6375  for ( i = 0; i < ii3; i++ )
6376  LUA_FREE_ARRAY( arg3[i] );
6377  LUA_FREE_ARRAY( arg3 );
6378  }
6379  }
6380  {
6381  LUA_FREE_ARRAY( arg7 );
6382  }
6383  return SWIG_arg;
6384 
6385  if(0) SWIG_fail;
6386 
6387 fail:
6388  {
6389  LUA_FREE_ARRAY( arg1 );
6390  }
6391  {
6392  LUA_FREE_ARRAY( arg2 );
6393  }
6394  {
6395  int i;
6396 
6397  if ( arg3 )
6398  {
6399  for ( i = 0; i < ii3; i++ )
6400  LUA_FREE_ARRAY( arg3[i] );
6401  LUA_FREE_ARRAY( arg3 );
6402  }
6403  }
6404  {
6405  LUA_FREE_ARRAY( arg7 );
6406  }
6407  lua_error(L);
6408  return SWIG_arg;
6409 }
6410 
6411 
6412 static int _wrap_mkstrm(lua_State* L) {
6413  int SWIG_arg = 0;
6414  PLINT *arg1 = (PLINT *) 0 ;
6415  PLINT temp1 ;
6416 
6417  arg1 = &temp1;
6418  SWIG_check_num_args("plmkstrm",0,0)
6419  plmkstrm(arg1);
6420 
6421  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
6422  return SWIG_arg;
6423 
6424  if(0) SWIG_fail;
6425 
6426 fail:
6427  lua_error(L);
6428  return SWIG_arg;
6429 }
6430 
6431 
6432 static int _wrap_mtex(lua_State* L) {
6433  int SWIG_arg = 0;
6434  char *arg1 = (char *) 0 ;
6435  PLFLT arg2 ;
6436  PLFLT arg3 ;
6437  PLFLT arg4 ;
6438  char *arg5 = (char *) 0 ;
6439 
6440  SWIG_check_num_args("plmtex",5,5)
6441  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plmtex",1,"char const *");
6442  if(!lua_isnumber(L,2)) SWIG_fail_arg("plmtex",2,"PLFLT");
6443  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmtex",3,"PLFLT");
6444  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmtex",4,"PLFLT");
6445  if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("plmtex",5,"char const *");
6446  arg1 = (char *)lua_tostring(L, 1);
6447  arg2 = (PLFLT)lua_tonumber(L, 2);
6448  arg3 = (PLFLT)lua_tonumber(L, 3);
6449  arg4 = (PLFLT)lua_tonumber(L, 4);
6450  arg5 = (char *)lua_tostring(L, 5);
6451  plmtex((char const *)arg1,arg2,arg3,arg4,(char const *)arg5);
6452 
6453  return SWIG_arg;
6454 
6455  if(0) SWIG_fail;
6456 
6457 fail:
6458  lua_error(L);
6459  return SWIG_arg;
6460 }
6461 
6462 
6463 static int _wrap_mtex3(lua_State* L) {
6464  int SWIG_arg = 0;
6465  char *arg1 = (char *) 0 ;
6466  PLFLT arg2 ;
6467  PLFLT arg3 ;
6468  PLFLT arg4 ;
6469  char *arg5 = (char *) 0 ;
6470 
6471  SWIG_check_num_args("plmtex3",5,5)
6472  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plmtex3",1,"char const *");
6473  if(!lua_isnumber(L,2)) SWIG_fail_arg("plmtex3",2,"PLFLT");
6474  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmtex3",3,"PLFLT");
6475  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmtex3",4,"PLFLT");
6476  if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("plmtex3",5,"char const *");
6477  arg1 = (char *)lua_tostring(L, 1);
6478  arg2 = (PLFLT)lua_tonumber(L, 2);
6479  arg3 = (PLFLT)lua_tonumber(L, 3);
6480  arg4 = (PLFLT)lua_tonumber(L, 4);
6481  arg5 = (char *)lua_tostring(L, 5);
6482  plmtex3((char const *)arg1,arg2,arg3,arg4,(char const *)arg5);
6483 
6484  return SWIG_arg;
6485 
6486  if(0) SWIG_fail;
6487 
6488 fail:
6489  lua_error(L);
6490  return SWIG_arg;
6491 }
6492 
6493 
6494 static int _wrap_plot3d(lua_State* L) {
6495  int SWIG_arg = 0;
6496  PLFLT *arg1 = (PLFLT *) 0 ;
6497  PLFLT *arg2 = (PLFLT *) 0 ;
6498  PLFLT **arg3 = (PLFLT **) 0 ;
6499  PLINT arg4 ;
6500  PLINT arg5 ;
6501  PLINT arg6 ;
6502  PLBOOL arg7 ;
6503  int ii3 ;
6504 
6505  SWIG_check_num_args("plot3d",5,5)
6506  if(!lua_isnumber(L,4)) SWIG_fail_arg("plot3d",4,"PLINT");
6507  if(!lua_isnumber(L,5)) SWIG_fail_arg("plot3d",5,"PLBOOL");
6508  {
6509  int temp;
6510  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6511  if ( !arg1 )
6512  SWIG_fail;
6513  Xlen = temp;
6514  }
6515  {
6516  int temp;
6517  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6518  if ( !arg2 )
6519  SWIG_fail;
6520  Ylen = temp;
6521  }
6522  {
6523  int jj;
6524 
6525  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6526  if ( !arg3 )
6527  SWIG_fail;
6528  arg4 = ii3;
6529  arg5 = jj;
6530  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6531  {
6532  lua_pushfstring( L, "Vectors must match matrix." );
6533  SWIG_fail;
6534  }
6535  }
6536  arg6 = (PLINT)lua_tonumber(L, 4);
6537  arg7 = (PLBOOL)lua_tonumber(L, 5);
6538  plot3d((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,arg7);
6539 
6540  {
6541  LUA_FREE_ARRAY( arg1 );
6542  }
6543  {
6544  LUA_FREE_ARRAY( arg2 );
6545  }
6546  {
6547  int i;
6548 
6549  if ( arg3 )
6550  {
6551  for ( i = 0; i < ii3; i++ )
6552  LUA_FREE_ARRAY( arg3[i] );
6553  LUA_FREE_ARRAY( arg3 );
6554  }
6555  }
6556  return SWIG_arg;
6557 
6558  if(0) SWIG_fail;
6559 
6560 fail:
6561  {
6562  LUA_FREE_ARRAY( arg1 );
6563  }
6564  {
6565  LUA_FREE_ARRAY( arg2 );
6566  }
6567  {
6568  int i;
6569 
6570  if ( arg3 )
6571  {
6572  for ( i = 0; i < ii3; i++ )
6573  LUA_FREE_ARRAY( arg3[i] );
6574  LUA_FREE_ARRAY( arg3 );
6575  }
6576  }
6577  lua_error(L);
6578  return SWIG_arg;
6579 }
6580 
6581 
6582 static int _wrap_plot3dc(lua_State* L) {
6583  int SWIG_arg = 0;
6584  PLFLT *arg1 = (PLFLT *) 0 ;
6585  PLFLT *arg2 = (PLFLT *) 0 ;
6586  PLFLT **arg3 = (PLFLT **) 0 ;
6587  PLINT arg4 ;
6588  PLINT arg5 ;
6589  PLINT arg6 ;
6590  PLFLT *arg7 = (PLFLT *) 0 ;
6591  PLINT arg8 ;
6592  int ii3 ;
6593 
6594  SWIG_check_num_args("plot3dc",5,5)
6595  if(!lua_isnumber(L,4)) SWIG_fail_arg("plot3dc",4,"PLINT");
6596  {
6597  int temp;
6598  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6599  if ( !arg1 )
6600  SWIG_fail;
6601  Xlen = temp;
6602  }
6603  {
6604  int temp;
6605  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6606  if ( !arg2 )
6607  SWIG_fail;
6608  Ylen = temp;
6609  }
6610  {
6611  int jj;
6612 
6613  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6614  if ( !arg3 )
6615  SWIG_fail;
6616  arg4 = ii3;
6617  arg5 = jj;
6618  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6619  {
6620  lua_pushfstring( L, "Vectors must match matrix." );
6621  SWIG_fail;
6622  }
6623  }
6624  arg6 = (PLINT)lua_tonumber(L, 4);
6625  {
6626  int temp;
6627  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
6628  if ( !arg7 )
6629  SWIG_fail;
6630  arg8 = Alen = temp;
6631  }
6632  plot3dc((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8);
6633 
6634  {
6635  LUA_FREE_ARRAY( arg1 );
6636  }
6637  {
6638  LUA_FREE_ARRAY( arg2 );
6639  }
6640  {
6641  int i;
6642 
6643  if ( arg3 )
6644  {
6645  for ( i = 0; i < ii3; i++ )
6646  LUA_FREE_ARRAY( arg3[i] );
6647  LUA_FREE_ARRAY( arg3 );
6648  }
6649  }
6650  {
6651  LUA_FREE_ARRAY( arg7 );
6652  }
6653  return SWIG_arg;
6654 
6655  if(0) SWIG_fail;
6656 
6657 fail:
6658  {
6659  LUA_FREE_ARRAY( arg1 );
6660  }
6661  {
6662  LUA_FREE_ARRAY( arg2 );
6663  }
6664  {
6665  int i;
6666 
6667  if ( arg3 )
6668  {
6669  for ( i = 0; i < ii3; i++ )
6670  LUA_FREE_ARRAY( arg3[i] );
6671  LUA_FREE_ARRAY( arg3 );
6672  }
6673  }
6674  {
6675  LUA_FREE_ARRAY( arg7 );
6676  }
6677  lua_error(L);
6678  return SWIG_arg;
6679 }
6680 
6681 
6682 static int _wrap_plot3dcl(lua_State* L) {
6683  int SWIG_arg = 0;
6684  PLFLT *arg1 = (PLFLT *) 0 ;
6685  PLFLT *arg2 = (PLFLT *) 0 ;
6686  PLFLT **arg3 = (PLFLT **) 0 ;
6687  PLINT arg4 ;
6688  PLINT arg5 ;
6689  PLINT arg6 ;
6690  PLFLT *arg7 = (PLFLT *) 0 ;
6691  PLINT arg8 ;
6692  PLINT arg9 ;
6693  PLINT arg10 ;
6694  PLINT *arg11 = (PLINT *) 0 ;
6695  PLINT *arg12 = (PLINT *) 0 ;
6696  int ii3 ;
6697  int temp12 ;
6698 
6699  SWIG_check_num_args("plot3dcl",8,8)
6700  if(!lua_isnumber(L,4)) SWIG_fail_arg("plot3dcl",4,"PLINT");
6701  if(!lua_isnumber(L,6)) SWIG_fail_arg("plot3dcl",6,"PLINT");
6702  {
6703  int temp;
6704  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6705  if ( !arg1 )
6706  SWIG_fail;
6707  Xlen = temp;
6708  }
6709  {
6710  int temp;
6711  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6712  if ( !arg2 )
6713  SWIG_fail;
6714  Ylen = temp;
6715  }
6716  {
6717  int jj;
6718 
6719  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6720  if ( !arg3 )
6721  SWIG_fail;
6722  arg4 = ii3;
6723  arg5 = jj;
6724  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6725  {
6726  lua_pushfstring( L, "Vectors must match matrix." );
6727  SWIG_fail;
6728  }
6729  }
6730  arg6 = (PLINT)lua_tonumber(L, 4);
6731  {
6732  int temp;
6733  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
6734  if ( !arg7 )
6735  SWIG_fail;
6736  arg8 = Alen = temp;
6737  }
6738  arg9 = (PLINT)lua_tonumber(L, 6);
6739  {
6740  arg11 = (PLINT *) LUA_get_int_num_array_var( L, 7, &arg10 );
6741  if ( !arg11 )
6742  SWIG_fail;
6743  Alen = arg10;
6744  }
6745  {
6746  arg12 = (PLINT *) LUA_get_int_num_array_var( L, 8, &temp12 );
6747  if ( !arg12 )
6748  SWIG_fail;
6749  if ( temp12 != Alen )
6750  {
6751  lua_pushfstring( L, "Tables must be of same length." );
6752  SWIG_fail;
6753  }
6754  }
6755  plot3dcl((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8,arg9,arg10,(int const *)arg11,(int const *)arg12);
6756 
6757  {
6758  LUA_FREE_ARRAY( arg1 );
6759  }
6760  {
6761  LUA_FREE_ARRAY( arg2 );
6762  }
6763  {
6764  int i;
6765 
6766  if ( arg3 )
6767  {
6768  for ( i = 0; i < ii3; i++ )
6769  LUA_FREE_ARRAY( arg3[i] );
6770  LUA_FREE_ARRAY( arg3 );
6771  }
6772  }
6773  {
6774  LUA_FREE_ARRAY( arg7 );
6775  }
6776  {
6777  LUA_FREE_ARRAY( arg11 );
6778  }
6779  {
6780  LUA_FREE_ARRAY( arg12 );
6781  }
6782  return SWIG_arg;
6783 
6784  if(0) SWIG_fail;
6785 
6786 fail:
6787  {
6788  LUA_FREE_ARRAY( arg1 );
6789  }
6790  {
6791  LUA_FREE_ARRAY( arg2 );
6792  }
6793  {
6794  int i;
6795 
6796  if ( arg3 )
6797  {
6798  for ( i = 0; i < ii3; i++ )
6799  LUA_FREE_ARRAY( arg3[i] );
6800  LUA_FREE_ARRAY( arg3 );
6801  }
6802  }
6803  {
6804  LUA_FREE_ARRAY( arg7 );
6805  }
6806  {
6807  LUA_FREE_ARRAY( arg11 );
6808  }
6809  {
6810  LUA_FREE_ARRAY( arg12 );
6811  }
6812  lua_error(L);
6813  return SWIG_arg;
6814 }
6815 
6816 
6817 static int _wrap_surf3d(lua_State* L) {
6818  int SWIG_arg = 0;
6819  PLFLT *arg1 = (PLFLT *) 0 ;
6820  PLFLT *arg2 = (PLFLT *) 0 ;
6821  PLFLT **arg3 = (PLFLT **) 0 ;
6822  PLINT arg4 ;
6823  PLINT arg5 ;
6824  PLINT arg6 ;
6825  PLFLT *arg7 = (PLFLT *) 0 ;
6826  PLINT arg8 ;
6827  int ii3 ;
6828 
6829  SWIG_check_num_args("plsurf3d",5,5)
6830  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsurf3d",4,"PLINT");
6831  {
6832  int temp;
6833  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6834  if ( !arg1 )
6835  SWIG_fail;
6836  Xlen = temp;
6837  }
6838  {
6839  int temp;
6840  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6841  if ( !arg2 )
6842  SWIG_fail;
6843  Ylen = temp;
6844  }
6845  {
6846  int jj;
6847 
6848  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6849  if ( !arg3 )
6850  SWIG_fail;
6851  arg4 = ii3;
6852  arg5 = jj;
6853  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6854  {
6855  lua_pushfstring( L, "Vectors must match matrix." );
6856  SWIG_fail;
6857  }
6858  }
6859  arg6 = (PLINT)lua_tonumber(L, 4);
6860  {
6861  int temp;
6862  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
6863  if ( !arg7 )
6864  SWIG_fail;
6865  arg8 = Alen = temp;
6866  }
6867  plsurf3d((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8);
6868 
6869  {
6870  LUA_FREE_ARRAY( arg1 );
6871  }
6872  {
6873  LUA_FREE_ARRAY( arg2 );
6874  }
6875  {
6876  int i;
6877 
6878  if ( arg3 )
6879  {
6880  for ( i = 0; i < ii3; i++ )
6881  LUA_FREE_ARRAY( arg3[i] );
6882  LUA_FREE_ARRAY( arg3 );
6883  }
6884  }
6885  {
6886  LUA_FREE_ARRAY( arg7 );
6887  }
6888  return SWIG_arg;
6889 
6890  if(0) SWIG_fail;
6891 
6892 fail:
6893  {
6894  LUA_FREE_ARRAY( arg1 );
6895  }
6896  {
6897  LUA_FREE_ARRAY( arg2 );
6898  }
6899  {
6900  int i;
6901 
6902  if ( arg3 )
6903  {
6904  for ( i = 0; i < ii3; i++ )
6905  LUA_FREE_ARRAY( arg3[i] );
6906  LUA_FREE_ARRAY( arg3 );
6907  }
6908  }
6909  {
6910  LUA_FREE_ARRAY( arg7 );
6911  }
6912  lua_error(L);
6913  return SWIG_arg;
6914 }
6915 
6916 
6917 static int _wrap_surf3dl(lua_State* L) {
6918  int SWIG_arg = 0;
6919  PLFLT *arg1 = (PLFLT *) 0 ;
6920  PLFLT *arg2 = (PLFLT *) 0 ;
6921  PLFLT **arg3 = (PLFLT **) 0 ;
6922  PLINT arg4 ;
6923  PLINT arg5 ;
6924  PLINT arg6 ;
6925  PLFLT *arg7 = (PLFLT *) 0 ;
6926  PLINT arg8 ;
6927  PLINT arg9 ;
6928  PLINT arg10 ;
6929  PLINT *arg11 = (PLINT *) 0 ;
6930  PLINT *arg12 = (PLINT *) 0 ;
6931  int ii3 ;
6932  int temp12 ;
6933 
6934  SWIG_check_num_args("plsurf3dl",8,8)
6935  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsurf3dl",4,"PLINT");
6936  if(!lua_isnumber(L,6)) SWIG_fail_arg("plsurf3dl",6,"PLINT");
6937  {
6938  int temp;
6939  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6940  if ( !arg1 )
6941  SWIG_fail;
6942  Xlen = temp;
6943  }
6944  {
6945  int temp;
6946  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
6947  if ( !arg2 )
6948  SWIG_fail;
6949  Ylen = temp;
6950  }
6951  {
6952  int jj;
6953 
6954  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
6955  if ( !arg3 )
6956  SWIG_fail;
6957  arg4 = ii3;
6958  arg5 = jj;
6959  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
6960  {
6961  lua_pushfstring( L, "Vectors must match matrix." );
6962  SWIG_fail;
6963  }
6964  }
6965  arg6 = (PLINT)lua_tonumber(L, 4);
6966  {
6967  int temp;
6968  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
6969  if ( !arg7 )
6970  SWIG_fail;
6971  arg8 = Alen = temp;
6972  }
6973  arg9 = (PLINT)lua_tonumber(L, 6);
6974  {
6975  arg11 = (PLINT *) LUA_get_int_num_array_var( L, 7, &arg10 );
6976  if ( !arg11 )
6977  SWIG_fail;
6978  Alen = arg10;
6979  }
6980  {
6981  arg12 = (PLINT *) LUA_get_int_num_array_var( L, 8, &temp12 );
6982  if ( !arg12 )
6983  SWIG_fail;
6984  if ( temp12 != Alen )
6985  {
6986  lua_pushfstring( L, "Tables must be of same length." );
6987  SWIG_fail;
6988  }
6989  }
6990  plsurf3dl((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8,arg9,arg10,(int const *)arg11,(int const *)arg12);
6991 
6992  {
6993  LUA_FREE_ARRAY( arg1 );
6994  }
6995  {
6996  LUA_FREE_ARRAY( arg2 );
6997  }
6998  {
6999  int i;
7000 
7001  if ( arg3 )
7002  {
7003  for ( i = 0; i < ii3; i++ )
7004  LUA_FREE_ARRAY( arg3[i] );
7005  LUA_FREE_ARRAY( arg3 );
7006  }
7007  }
7008  {
7009  LUA_FREE_ARRAY( arg7 );
7010  }
7011  {
7012  LUA_FREE_ARRAY( arg11 );
7013  }
7014  {
7015  LUA_FREE_ARRAY( arg12 );
7016  }
7017  return SWIG_arg;
7018 
7019  if(0) SWIG_fail;
7020 
7021 fail:
7022  {
7023  LUA_FREE_ARRAY( arg1 );
7024  }
7025  {
7026  LUA_FREE_ARRAY( arg2 );
7027  }
7028  {
7029  int i;
7030 
7031  if ( arg3 )
7032  {
7033  for ( i = 0; i < ii3; i++ )
7034  LUA_FREE_ARRAY( arg3[i] );
7035  LUA_FREE_ARRAY( arg3 );
7036  }
7037  }
7038  {
7039  LUA_FREE_ARRAY( arg7 );
7040  }
7041  {
7042  LUA_FREE_ARRAY( arg11 );
7043  }
7044  {
7045  LUA_FREE_ARRAY( arg12 );
7046  }
7047  lua_error(L);
7048  return SWIG_arg;
7049 }
7050 
7051 
7052 static int _wrap_parseopts(lua_State* L) {
7053  int SWIG_arg = 0;
7054  int *arg1 = (int *) 0 ;
7055  char **arg2 = (char **) 0 ;
7056  PLINT arg3 ;
7057  PLINT result;
7058 
7059  SWIG_check_num_args("plparseopts",2,2)
7060  if(!lua_istable(L,1)) SWIG_fail_arg("plparseopts",1,"int *");
7061  if(!lua_isnumber(L,2)) SWIG_fail_arg("plparseopts",2,"PLINT");
7062  {
7063  int i, n;
7064 
7065  // from lua 5.1 on there is no element "n" anymore,
7066  // so we need to find out the number of command line
7067  // options manually
7068  for ( i = 1;; i++ )
7069  {
7070  lua_rawgeti( L, 1, i );
7071  if ( lua_isnil( L, -1 ) )
7072  {
7073  // ok, this index doesn't exist anymore, we have i-1
7074  // command line options
7075  lua_pop( L, 1 );
7076  break;
7077  }
7078  }
7079  n = i;
7080  arg1 = &n;
7081 
7082  arg2 = LUA_ALLOC_ARRAY( char*, ( n + 1 ) );
7083 
7084  for ( i = 0; i < n; i++ )
7085  {
7086  lua_rawgeti( L, 1, i );
7087  if ( lua_isstring( L, -1 ) )
7088  {
7089  arg2[i] = (char *) lua_tostring( L, -1 );
7090  }
7091  else
7092  {
7093  lua_pop( L, 1 );
7094  lua_pushfstring( L, "List items must be strings" );
7095  SWIG_fail;
7096  // arg2 array is freed after 'fail:'
7097  }
7098  lua_pop( L, 1 );
7099  }
7100  arg2[n] = NULL;
7101  }
7102  arg3 = (PLINT)lua_tonumber(L, 2);
7103  result = (PLINT)plparseopts(arg1,arg2,arg3);
7104  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
7105  {
7106  LUA_FREE_ARRAY( arg2 );
7107  }
7108  return SWIG_arg;
7109 
7110  if(0) SWIG_fail;
7111 
7112 fail:
7113  {
7114  LUA_FREE_ARRAY( arg2 );
7115  }
7116  lua_error(L);
7117  return SWIG_arg;
7118 }
7119 
7120 
7121 static int _wrap_pat(lua_State* L) {
7122  int SWIG_arg = 0;
7123  PLINT arg1 ;
7124  PLINT *arg2 = (PLINT *) 0 ;
7125  PLINT *arg3 = (PLINT *) 0 ;
7126  int temp3 ;
7127 
7128  SWIG_check_num_args("plpat",2,2)
7129  {
7130  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 1, &arg1 );
7131  if ( !arg2 )
7132  SWIG_fail;
7133  Alen = arg1;
7134  }
7135  {
7136  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp3 );
7137  if ( !arg3 )
7138  SWIG_fail;
7139  if ( temp3 != Alen )
7140  {
7141  lua_pushfstring( L, "Tables must be of same length." );
7142  SWIG_fail;
7143  }
7144  }
7145  plpat(arg1,(int const *)arg2,(int const *)arg3);
7146 
7147  {
7148  LUA_FREE_ARRAY( arg2 );
7149  }
7150  {
7151  LUA_FREE_ARRAY( arg3 );
7152  }
7153  return SWIG_arg;
7154 
7155  if(0) SWIG_fail;
7156 
7157 fail:
7158  {
7159  LUA_FREE_ARRAY( arg2 );
7160  }
7161  {
7162  LUA_FREE_ARRAY( arg3 );
7163  }
7164  lua_error(L);
7165  return SWIG_arg;
7166 }
7167 
7168 
7169 static int _wrap_path(lua_State* L) {
7170  int SWIG_arg = 0;
7171  PLINT arg1 ;
7172  PLFLT arg2 ;
7173  PLFLT arg3 ;
7174  PLFLT arg4 ;
7175  PLFLT arg5 ;
7176 
7177  SWIG_check_num_args("plpath",5,5)
7178  if(!lua_isnumber(L,1)) SWIG_fail_arg("plpath",1,"PLINT");
7179  if(!lua_isnumber(L,2)) SWIG_fail_arg("plpath",2,"PLFLT");
7180  if(!lua_isnumber(L,3)) SWIG_fail_arg("plpath",3,"PLFLT");
7181  if(!lua_isnumber(L,4)) SWIG_fail_arg("plpath",4,"PLFLT");
7182  if(!lua_isnumber(L,5)) SWIG_fail_arg("plpath",5,"PLFLT");
7183  arg1 = (PLINT)lua_tonumber(L, 1);
7184  arg2 = (PLFLT)lua_tonumber(L, 2);
7185  arg3 = (PLFLT)lua_tonumber(L, 3);
7186  arg4 = (PLFLT)lua_tonumber(L, 4);
7187  arg5 = (PLFLT)lua_tonumber(L, 5);
7188  plpath(arg1,arg2,arg3,arg4,arg5);
7189 
7190  return SWIG_arg;
7191 
7192  if(0) SWIG_fail;
7193 
7194 fail:
7195  lua_error(L);
7196  return SWIG_arg;
7197 }
7198 
7199 
7200 static int _wrap_poin(lua_State* L) {
7201  int SWIG_arg = 0;
7202  PLINT arg1 ;
7203  PLFLT *arg2 = (PLFLT *) 0 ;
7204  PLFLT *arg3 = (PLFLT *) 0 ;
7205  PLINT arg4 ;
7206  int temp3 ;
7207 
7208  SWIG_check_num_args("plpoin",3,3)
7209  if(!lua_isnumber(L,3)) SWIG_fail_arg("plpoin",3,"PLINT");
7210  {
7211  int temp;
7212  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7213  if ( !arg2 )
7214  SWIG_fail;
7215  arg1 = Alen = temp;
7216  }
7217  {
7218  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
7219  if ( !arg3 )
7220  SWIG_fail;
7221  if ( temp3 != Alen )
7222  {
7223  lua_pushfstring( L, "Tables must be of same length." );
7224  SWIG_fail;
7225  }
7226  }
7227  arg4 = (PLINT)lua_tonumber(L, 3);
7228  plpoin(arg1,(double const *)arg2,(double const *)arg3,arg4);
7229 
7230  {
7231  LUA_FREE_ARRAY( arg2 );
7232  }
7233  {
7234  LUA_FREE_ARRAY( arg3 );
7235  }
7236  return SWIG_arg;
7237 
7238  if(0) SWIG_fail;
7239 
7240 fail:
7241  {
7242  LUA_FREE_ARRAY( arg2 );
7243  }
7244  {
7245  LUA_FREE_ARRAY( arg3 );
7246  }
7247  lua_error(L);
7248  return SWIG_arg;
7249 }
7250 
7251 
7252 static int _wrap_poin3(lua_State* L) {
7253  int SWIG_arg = 0;
7254  PLINT arg1 ;
7255  PLFLT *arg2 = (PLFLT *) 0 ;
7256  PLFLT *arg3 = (PLFLT *) 0 ;
7257  PLFLT *arg4 = (PLFLT *) 0 ;
7258  PLINT arg5 ;
7259  int temp3 ;
7260  int temp4 ;
7261 
7262  SWIG_check_num_args("plpoin3",4,4)
7263  if(!lua_isnumber(L,4)) SWIG_fail_arg("plpoin3",4,"PLINT");
7264  {
7265  int temp;
7266  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7267  if ( !arg2 )
7268  SWIG_fail;
7269  arg1 = Alen = temp;
7270  }
7271  {
7272  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
7273  if ( !arg3 )
7274  SWIG_fail;
7275  if ( temp3 != Alen )
7276  {
7277  lua_pushfstring( L, "Tables must be of same length." );
7278  SWIG_fail;
7279  }
7280  }
7281  {
7282  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
7283  if ( !arg4 )
7284  SWIG_fail;
7285  if ( temp4 != Alen )
7286  {
7287  lua_pushfstring( L, "Tables must be of same length." );
7288  SWIG_fail;
7289  }
7290  }
7291  arg5 = (PLINT)lua_tonumber(L, 4);
7292  plpoin3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4,arg5);
7293 
7294  {
7295  LUA_FREE_ARRAY( arg2 );
7296  }
7297  {
7298  LUA_FREE_ARRAY( arg3 );
7299  }
7300  {
7301  LUA_FREE_ARRAY( arg4 );
7302  }
7303  return SWIG_arg;
7304 
7305  if(0) SWIG_fail;
7306 
7307 fail:
7308  {
7309  LUA_FREE_ARRAY( arg2 );
7310  }
7311  {
7312  LUA_FREE_ARRAY( arg3 );
7313  }
7314  {
7315  LUA_FREE_ARRAY( arg4 );
7316  }
7317  lua_error(L);
7318  return SWIG_arg;
7319 }
7320 
7321 
7322 static int _wrap_poly3(lua_State* L) {
7323  int SWIG_arg = 0;
7324  PLINT arg1 ;
7325  PLFLT *arg2 = (PLFLT *) 0 ;
7326  PLFLT *arg3 = (PLFLT *) 0 ;
7327  PLFLT *arg4 = (PLFLT *) 0 ;
7328  PLBOOL *arg5 = (PLBOOL *) 0 ;
7329  PLBOOL arg6 ;
7330  int temp3 ;
7331  int temp4 ;
7332  int temp5 ;
7333 
7334  SWIG_check_num_args("plpoly3",5,5)
7335  if(!lua_isnumber(L,5)) SWIG_fail_arg("plpoly3",5,"PLBOOL");
7336  {
7337  int temp;
7338  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7339  if ( !arg2 )
7340  SWIG_fail;
7341  arg1 = Alen = temp;
7342  }
7343  {
7344  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
7345  if ( !arg3 )
7346  SWIG_fail;
7347  if ( temp3 != Alen )
7348  {
7349  lua_pushfstring( L, "Tables must be of same length." );
7350  SWIG_fail;
7351  }
7352  }
7353  {
7354  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
7355  if ( !arg4 )
7356  SWIG_fail;
7357  if ( temp4 != Alen )
7358  {
7359  lua_pushfstring( L, "Tables must be of same length." );
7360  SWIG_fail;
7361  }
7362  }
7363  {
7364  arg5 = (PLINT *) LUA_get_int_num_array_var( L, 4, &temp5 );
7365  if ( !arg5 )
7366  SWIG_fail;
7367  if ( temp5 < Alen - 1 )
7368  {
7369  lua_pushfstring( L, "Tables must be at least length of others minus 1." );
7370  SWIG_fail;
7371  }
7372  }
7373  arg6 = (PLBOOL)lua_tonumber(L, 5);
7374  plpoly3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4,(int const *)arg5,arg6);
7375 
7376  {
7377  LUA_FREE_ARRAY( arg2 );
7378  }
7379  {
7380  LUA_FREE_ARRAY( arg3 );
7381  }
7382  {
7383  LUA_FREE_ARRAY( arg4 );
7384  }
7385  {
7386  LUA_FREE_ARRAY( arg5 );
7387  }
7388  return SWIG_arg;
7389 
7390  if(0) SWIG_fail;
7391 
7392 fail:
7393  {
7394  LUA_FREE_ARRAY( arg2 );
7395  }
7396  {
7397  LUA_FREE_ARRAY( arg3 );
7398  }
7399  {
7400  LUA_FREE_ARRAY( arg4 );
7401  }
7402  {
7403  LUA_FREE_ARRAY( arg5 );
7404  }
7405  lua_error(L);
7406  return SWIG_arg;
7407 }
7408 
7409 
7410 static int _wrap_prec(lua_State* L) {
7411  int SWIG_arg = 0;
7412  PLINT arg1 ;
7413  PLINT arg2 ;
7414 
7415  SWIG_check_num_args("plprec",2,2)
7416  if(!lua_isnumber(L,1)) SWIG_fail_arg("plprec",1,"PLINT");
7417  if(!lua_isnumber(L,2)) SWIG_fail_arg("plprec",2,"PLINT");
7418  arg1 = (PLINT)lua_tonumber(L, 1);
7419  arg2 = (PLINT)lua_tonumber(L, 2);
7420  plprec(arg1,arg2);
7421 
7422  return SWIG_arg;
7423 
7424  if(0) SWIG_fail;
7425 
7426 fail:
7427  lua_error(L);
7428  return SWIG_arg;
7429 }
7430 
7431 
7432 static int _wrap_psty(lua_State* L) {
7433  int SWIG_arg = 0;
7434  PLINT arg1 ;
7435 
7436  SWIG_check_num_args("plpsty",1,1)
7437  if(!lua_isnumber(L,1)) SWIG_fail_arg("plpsty",1,"PLINT");
7438  arg1 = (PLINT)lua_tonumber(L, 1);
7439  plpsty(arg1);
7440 
7441  return SWIG_arg;
7442 
7443  if(0) SWIG_fail;
7444 
7445 fail:
7446  lua_error(L);
7447  return SWIG_arg;
7448 }
7449 
7450 
7451 static int _wrap_ptex(lua_State* L) {
7452  int SWIG_arg = 0;
7453  PLFLT arg1 ;
7454  PLFLT arg2 ;
7455  PLFLT arg3 ;
7456  PLFLT arg4 ;
7457  PLFLT arg5 ;
7458  char *arg6 = (char *) 0 ;
7459 
7460  SWIG_check_num_args("plptex",6,6)
7461  if(!lua_isnumber(L,1)) SWIG_fail_arg("plptex",1,"PLFLT");
7462  if(!lua_isnumber(L,2)) SWIG_fail_arg("plptex",2,"PLFLT");
7463  if(!lua_isnumber(L,3)) SWIG_fail_arg("plptex",3,"PLFLT");
7464  if(!lua_isnumber(L,4)) SWIG_fail_arg("plptex",4,"PLFLT");
7465  if(!lua_isnumber(L,5)) SWIG_fail_arg("plptex",5,"PLFLT");
7466  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plptex",6,"char const *");
7467  arg1 = (PLFLT)lua_tonumber(L, 1);
7468  arg2 = (PLFLT)lua_tonumber(L, 2);
7469  arg3 = (PLFLT)lua_tonumber(L, 3);
7470  arg4 = (PLFLT)lua_tonumber(L, 4);
7471  arg5 = (PLFLT)lua_tonumber(L, 5);
7472  arg6 = (char *)lua_tostring(L, 6);
7473  plptex(arg1,arg2,arg3,arg4,arg5,(char const *)arg6);
7474 
7475  return SWIG_arg;
7476 
7477  if(0) SWIG_fail;
7478 
7479 fail:
7480  lua_error(L);
7481  return SWIG_arg;
7482 }
7483 
7484 
7485 static int _wrap_ptex3(lua_State* L) {
7486  int SWIG_arg = 0;
7487  PLFLT arg1 ;
7488  PLFLT arg2 ;
7489  PLFLT arg3 ;
7490  PLFLT arg4 ;
7491  PLFLT arg5 ;
7492  PLFLT arg6 ;
7493  PLFLT arg7 ;
7494  PLFLT arg8 ;
7495  PLFLT arg9 ;
7496  PLFLT arg10 ;
7497  char *arg11 = (char *) 0 ;
7498 
7499  SWIG_check_num_args("plptex3",11,11)
7500  if(!lua_isnumber(L,1)) SWIG_fail_arg("plptex3",1,"PLFLT");
7501  if(!lua_isnumber(L,2)) SWIG_fail_arg("plptex3",2,"PLFLT");
7502  if(!lua_isnumber(L,3)) SWIG_fail_arg("plptex3",3,"PLFLT");
7503  if(!lua_isnumber(L,4)) SWIG_fail_arg("plptex3",4,"PLFLT");
7504  if(!lua_isnumber(L,5)) SWIG_fail_arg("plptex3",5,"PLFLT");
7505  if(!lua_isnumber(L,6)) SWIG_fail_arg("plptex3",6,"PLFLT");
7506  if(!lua_isnumber(L,7)) SWIG_fail_arg("plptex3",7,"PLFLT");
7507  if(!lua_isnumber(L,8)) SWIG_fail_arg("plptex3",8,"PLFLT");
7508  if(!lua_isnumber(L,9)) SWIG_fail_arg("plptex3",9,"PLFLT");
7509  if(!lua_isnumber(L,10)) SWIG_fail_arg("plptex3",10,"PLFLT");
7510  if(!SWIG_lua_isnilstring(L,11)) SWIG_fail_arg("plptex3",11,"char const *");
7511  arg1 = (PLFLT)lua_tonumber(L, 1);
7512  arg2 = (PLFLT)lua_tonumber(L, 2);
7513  arg3 = (PLFLT)lua_tonumber(L, 3);
7514  arg4 = (PLFLT)lua_tonumber(L, 4);
7515  arg5 = (PLFLT)lua_tonumber(L, 5);
7516  arg6 = (PLFLT)lua_tonumber(L, 6);
7517  arg7 = (PLFLT)lua_tonumber(L, 7);
7518  arg8 = (PLFLT)lua_tonumber(L, 8);
7519  arg9 = (PLFLT)lua_tonumber(L, 9);
7520  arg10 = (PLFLT)lua_tonumber(L, 10);
7521  arg11 = (char *)lua_tostring(L, 11);
7522  plptex3(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(char const *)arg11);
7523 
7524  return SWIG_arg;
7525 
7526  if(0) SWIG_fail;
7527 
7528 fail:
7529  lua_error(L);
7530  return SWIG_arg;
7531 }
7532 
7533 
7534 static int _wrap_randd(lua_State* L) {
7535  int SWIG_arg = 0;
7536  PLFLT result;
7537 
7538  SWIG_check_num_args("plrandd",0,0)
7539  result = (PLFLT)plrandd();
7540  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
7541  return SWIG_arg;
7542 
7543  if(0) SWIG_fail;
7544 
7545 fail:
7546  lua_error(L);
7547  return SWIG_arg;
7548 }
7549 
7550 
7551 static int _wrap_replot(lua_State* L) {
7552  int SWIG_arg = 0;
7553 
7554  SWIG_check_num_args("plreplot",0,0)
7555  plreplot();
7556 
7557  return SWIG_arg;
7558 
7559  if(0) SWIG_fail;
7560 
7561 fail:
7562  lua_error(L);
7563  return SWIG_arg;
7564 }
7565 
7566 
7567 static int _wrap_rgbhls(lua_State* L) {
7568  int SWIG_arg = 0;
7569  PLFLT arg1 ;
7570  PLFLT arg2 ;
7571  PLFLT arg3 ;
7572  PLFLT *arg4 = (PLFLT *) 0 ;
7573  PLFLT *arg5 = (PLFLT *) 0 ;
7574  PLFLT *arg6 = (PLFLT *) 0 ;
7575  PLFLT temp4 ;
7576  PLFLT temp5 ;
7577  PLFLT temp6 ;
7578 
7579  arg4 = &temp4;
7580  arg5 = &temp5;
7581  arg6 = &temp6;
7582  SWIG_check_num_args("plrgbhls",3,3)
7583  if(!lua_isnumber(L,1)) SWIG_fail_arg("plrgbhls",1,"PLFLT");
7584  if(!lua_isnumber(L,2)) SWIG_fail_arg("plrgbhls",2,"PLFLT");
7585  if(!lua_isnumber(L,3)) SWIG_fail_arg("plrgbhls",3,"PLFLT");
7586  arg1 = (PLFLT)lua_tonumber(L, 1);
7587  arg2 = (PLFLT)lua_tonumber(L, 2);
7588  arg3 = (PLFLT)lua_tonumber(L, 3);
7589  plrgbhls(arg1,arg2,arg3,arg4,arg5,arg6);
7590 
7591  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
7592  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
7593  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
7594  return SWIG_arg;
7595 
7596  if(0) SWIG_fail;
7597 
7598 fail:
7599  lua_error(L);
7600  return SWIG_arg;
7601 }
7602 
7603 
7604 static int _wrap_schr(lua_State* L) {
7605  int SWIG_arg = 0;
7606  PLFLT arg1 ;
7607  PLFLT arg2 ;
7608 
7609  SWIG_check_num_args("plschr",2,2)
7610  if(!lua_isnumber(L,1)) SWIG_fail_arg("plschr",1,"PLFLT");
7611  if(!lua_isnumber(L,2)) SWIG_fail_arg("plschr",2,"PLFLT");
7612  arg1 = (PLFLT)lua_tonumber(L, 1);
7613  arg2 = (PLFLT)lua_tonumber(L, 2);
7614  plschr(arg1,arg2);
7615 
7616  return SWIG_arg;
7617 
7618  if(0) SWIG_fail;
7619 
7620 fail:
7621  lua_error(L);
7622  return SWIG_arg;
7623 }
7624 
7625 
7626 static int _wrap_scmap0(lua_State* L) {
7627  int SWIG_arg = 0;
7628  PLINT *arg1 = (PLINT *) 0 ;
7629  PLINT *arg2 = (PLINT *) 0 ;
7630  PLINT *arg3 = (PLINT *) 0 ;
7631  PLINT arg4 ;
7632  int temp1 ;
7633  int temp2 ;
7634  int temp3 ;
7635 
7636  SWIG_check_num_args("plscmap0",3,3)
7637  {
7638  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
7639  if ( !arg1 )
7640  SWIG_fail;
7641  Alen = temp1;
7642  }
7643  {
7644  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
7645  if ( !arg2 )
7646  SWIG_fail;
7647  if ( temp2 != Alen )
7648  {
7649  lua_pushfstring( L, "Tables must be of same length." );
7650  SWIG_fail;
7651  }
7652  }
7653  {
7654  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
7655  if ( !arg3 )
7656  SWIG_fail;
7657  if ( temp3 != Alen )
7658  {
7659  lua_pushfstring( L, "Tables must be of same length." );
7660  SWIG_fail;
7661  }
7662  arg4 = temp3;
7663  }
7664  plscmap0((int const *)arg1,(int const *)arg2,(int const *)arg3,arg4);
7665 
7666  {
7667  LUA_FREE_ARRAY( arg1 );
7668  }
7669  {
7670  LUA_FREE_ARRAY( arg2 );
7671  }
7672  {
7673  LUA_FREE_ARRAY( arg3 );
7674  }
7675  return SWIG_arg;
7676 
7677  if(0) SWIG_fail;
7678 
7679 fail:
7680  {
7681  LUA_FREE_ARRAY( arg1 );
7682  }
7683  {
7684  LUA_FREE_ARRAY( arg2 );
7685  }
7686  {
7687  LUA_FREE_ARRAY( arg3 );
7688  }
7689  lua_error(L);
7690  return SWIG_arg;
7691 }
7692 
7693 
7694 static int _wrap_scmap0a(lua_State* L) {
7695  int SWIG_arg = 0;
7696  PLINT *arg1 = (PLINT *) 0 ;
7697  PLINT *arg2 = (PLINT *) 0 ;
7698  PLINT *arg3 = (PLINT *) 0 ;
7699  PLFLT *arg4 = (PLFLT *) 0 ;
7700  PLINT arg5 ;
7701  int temp1 ;
7702  int temp2 ;
7703  int temp3 ;
7704 
7705  SWIG_check_num_args("plscmap0a",4,4)
7706  {
7707  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
7708  if ( !arg1 )
7709  SWIG_fail;
7710  Alen = temp1;
7711  }
7712  {
7713  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
7714  if ( !arg2 )
7715  SWIG_fail;
7716  if ( temp2 != Alen )
7717  {
7718  lua_pushfstring( L, "Tables must be of same length." );
7719  SWIG_fail;
7720  }
7721  }
7722  {
7723  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
7724  if ( !arg3 )
7725  SWIG_fail;
7726  if ( temp3 != Alen )
7727  {
7728  lua_pushfstring( L, "Tables must be of same length." );
7729  SWIG_fail;
7730  }
7731  }
7732  {
7733  int temp;
7734  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp );
7735  if ( !arg4 )
7736  SWIG_fail;
7737  if ( temp != Alen )
7738  {
7739  lua_pushfstring( L, "Tables must be of same length." );
7740  SWIG_fail;
7741  }
7742  arg5 = temp;
7743  }
7744  plscmap0a((int const *)arg1,(int const *)arg2,(int const *)arg3,(double const *)arg4,arg5);
7745 
7746  {
7747  LUA_FREE_ARRAY( arg1 );
7748  }
7749  {
7750  LUA_FREE_ARRAY( arg2 );
7751  }
7752  {
7753  LUA_FREE_ARRAY( arg3 );
7754  }
7755  {
7756  LUA_FREE_ARRAY( arg4 );
7757  }
7758  return SWIG_arg;
7759 
7760  if(0) SWIG_fail;
7761 
7762 fail:
7763  {
7764  LUA_FREE_ARRAY( arg1 );
7765  }
7766  {
7767  LUA_FREE_ARRAY( arg2 );
7768  }
7769  {
7770  LUA_FREE_ARRAY( arg3 );
7771  }
7772  {
7773  LUA_FREE_ARRAY( arg4 );
7774  }
7775  lua_error(L);
7776  return SWIG_arg;
7777 }
7778 
7779 
7780 static int _wrap_scmap0n(lua_State* L) {
7781  int SWIG_arg = 0;
7782  PLINT arg1 ;
7783 
7784  SWIG_check_num_args("plscmap0n",1,1)
7785  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap0n",1,"PLINT");
7786  arg1 = (PLINT)lua_tonumber(L, 1);
7787  plscmap0n(arg1);
7788 
7789  return SWIG_arg;
7790 
7791  if(0) SWIG_fail;
7792 
7793 fail:
7794  lua_error(L);
7795  return SWIG_arg;
7796 }
7797 
7798 
7799 static int _wrap_scmap1(lua_State* L) {
7800  int SWIG_arg = 0;
7801  PLINT *arg1 = (PLINT *) 0 ;
7802  PLINT *arg2 = (PLINT *) 0 ;
7803  PLINT *arg3 = (PLINT *) 0 ;
7804  PLINT arg4 ;
7805  int temp1 ;
7806  int temp2 ;
7807  int temp3 ;
7808 
7809  SWIG_check_num_args("plscmap1",3,3)
7810  {
7811  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
7812  if ( !arg1 )
7813  SWIG_fail;
7814  Alen = temp1;
7815  }
7816  {
7817  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
7818  if ( !arg2 )
7819  SWIG_fail;
7820  if ( temp2 != Alen )
7821  {
7822  lua_pushfstring( L, "Tables must be of same length." );
7823  SWIG_fail;
7824  }
7825  }
7826  {
7827  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
7828  if ( !arg3 )
7829  SWIG_fail;
7830  if ( temp3 != Alen )
7831  {
7832  lua_pushfstring( L, "Tables must be of same length." );
7833  SWIG_fail;
7834  }
7835  arg4 = temp3;
7836  }
7837  plscmap1((int const *)arg1,(int const *)arg2,(int const *)arg3,arg4);
7838 
7839  {
7840  LUA_FREE_ARRAY( arg1 );
7841  }
7842  {
7843  LUA_FREE_ARRAY( arg2 );
7844  }
7845  {
7846  LUA_FREE_ARRAY( arg3 );
7847  }
7848  return SWIG_arg;
7849 
7850  if(0) SWIG_fail;
7851 
7852 fail:
7853  {
7854  LUA_FREE_ARRAY( arg1 );
7855  }
7856  {
7857  LUA_FREE_ARRAY( arg2 );
7858  }
7859  {
7860  LUA_FREE_ARRAY( arg3 );
7861  }
7862  lua_error(L);
7863  return SWIG_arg;
7864 }
7865 
7866 
7867 static int _wrap_scmap1a(lua_State* L) {
7868  int SWIG_arg = 0;
7869  PLINT *arg1 = (PLINT *) 0 ;
7870  PLINT *arg2 = (PLINT *) 0 ;
7871  PLINT *arg3 = (PLINT *) 0 ;
7872  PLFLT *arg4 = (PLFLT *) 0 ;
7873  PLINT arg5 ;
7874  int temp1 ;
7875  int temp2 ;
7876  int temp3 ;
7877 
7878  SWIG_check_num_args("plscmap1a",4,4)
7879  {
7880  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
7881  if ( !arg1 )
7882  SWIG_fail;
7883  Alen = temp1;
7884  }
7885  {
7886  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
7887  if ( !arg2 )
7888  SWIG_fail;
7889  if ( temp2 != Alen )
7890  {
7891  lua_pushfstring( L, "Tables must be of same length." );
7892  SWIG_fail;
7893  }
7894  }
7895  {
7896  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
7897  if ( !arg3 )
7898  SWIG_fail;
7899  if ( temp3 != Alen )
7900  {
7901  lua_pushfstring( L, "Tables must be of same length." );
7902  SWIG_fail;
7903  }
7904  }
7905  {
7906  int temp;
7907  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp );
7908  if ( !arg4 )
7909  SWIG_fail;
7910  if ( temp != Alen )
7911  {
7912  lua_pushfstring( L, "Tables must be of same length." );
7913  SWIG_fail;
7914  }
7915  arg5 = temp;
7916  }
7917  plscmap1a((int const *)arg1,(int const *)arg2,(int const *)arg3,(double const *)arg4,arg5);
7918 
7919  {
7920  LUA_FREE_ARRAY( arg1 );
7921  }
7922  {
7923  LUA_FREE_ARRAY( arg2 );
7924  }
7925  {
7926  LUA_FREE_ARRAY( arg3 );
7927  }
7928  {
7929  LUA_FREE_ARRAY( arg4 );
7930  }
7931  return SWIG_arg;
7932 
7933  if(0) SWIG_fail;
7934 
7935 fail:
7936  {
7937  LUA_FREE_ARRAY( arg1 );
7938  }
7939  {
7940  LUA_FREE_ARRAY( arg2 );
7941  }
7942  {
7943  LUA_FREE_ARRAY( arg3 );
7944  }
7945  {
7946  LUA_FREE_ARRAY( arg4 );
7947  }
7948  lua_error(L);
7949  return SWIG_arg;
7950 }
7951 
7952 
7953 static int _wrap_scmap1l(lua_State* L) {
7954  int SWIG_arg = 0;
7955  PLBOOL arg1 ;
7956  PLINT arg2 ;
7957  PLFLT *arg3 = (PLFLT *) 0 ;
7958  PLFLT *arg4 = (PLFLT *) 0 ;
7959  PLFLT *arg5 = (PLFLT *) 0 ;
7960  PLFLT *arg6 = (PLFLT *) 0 ;
7961  PLBOOL *arg7 = (PLBOOL *) 0 ;
7962  int temp4 ;
7963  int temp5 ;
7964  int temp6 ;
7965  int temp7 ;
7966 
7967  {
7968  arg7 = NULL;
7969  }
7970  SWIG_check_num_args("plscmap1l",5,6)
7971  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1l",1,"PLBOOL");
7972  arg1 = (PLBOOL)lua_tonumber(L, 1);
7973  {
7974  int temp;
7975  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7976  if ( !arg3 )
7977  SWIG_fail;
7978  arg2 = Alen = temp;
7979  }
7980  {
7981  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
7982  if ( !arg4 )
7983  SWIG_fail;
7984  if ( temp4 != Alen )
7985  {
7986  lua_pushfstring( L, "Tables must be of same length." );
7987  SWIG_fail;
7988  }
7989  }
7990  {
7991  arg5 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp5 );
7992  if ( !arg5 )
7993  SWIG_fail;
7994  if ( temp5 != Alen )
7995  {
7996  lua_pushfstring( L, "Tables must be of same length." );
7997  SWIG_fail;
7998  }
7999  }
8000  {
8001  arg6 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp6 );
8002  if ( !arg6 )
8003  SWIG_fail;
8004  if ( temp6 != Alen )
8005  {
8006  lua_pushfstring( L, "Tables must be of same length." );
8007  SWIG_fail;
8008  }
8009  }
8010  if(lua_gettop(L)>=6){
8011  {
8012  if ( lua_isnil( L, 6 ) )
8013  {
8014  arg7 = NULL;
8015  }
8016  else
8017  {
8018  arg7 = (PLINT *) LUA_get_int_num_array_var( L, 6, &temp7 );
8019  if ( !arg7 )
8020  SWIG_fail;
8021  if ( temp7 < Alen - 1 )
8022  {
8023  lua_pushfstring( L, "Tables must be at least length of others minus 1." );
8024  SWIG_fail;
8025  }
8026  }
8027  }
8028  }
8029  plscmap1l(arg1,arg2,(double const *)arg3,(double const *)arg4,(double const *)arg5,(double const *)arg6,(int const *)arg7);
8030 
8031  {
8032  LUA_FREE_ARRAY( arg3 );
8033  }
8034  {
8035  LUA_FREE_ARRAY( arg4 );
8036  }
8037  {
8038  LUA_FREE_ARRAY( arg5 );
8039  }
8040  {
8041  LUA_FREE_ARRAY( arg6 );
8042  }
8043  {
8044  LUA_FREE_ARRAY( arg7 );
8045  }
8046  return SWIG_arg;
8047 
8048  if(0) SWIG_fail;
8049 
8050 fail:
8051  {
8052  LUA_FREE_ARRAY( arg3 );
8053  }
8054  {
8055  LUA_FREE_ARRAY( arg4 );
8056  }
8057  {
8058  LUA_FREE_ARRAY( arg5 );
8059  }
8060  {
8061  LUA_FREE_ARRAY( arg6 );
8062  }
8063  {
8064  LUA_FREE_ARRAY( arg7 );
8065  }
8066  lua_error(L);
8067  return SWIG_arg;
8068 }
8069 
8070 
8071 static int _wrap_scmap1la(lua_State* L) {
8072  int SWIG_arg = 0;
8073  PLBOOL arg1 ;
8074  PLINT arg2 ;
8075  PLFLT *arg3 = (PLFLT *) 0 ;
8076  PLFLT *arg4 = (PLFLT *) 0 ;
8077  PLFLT *arg5 = (PLFLT *) 0 ;
8078  PLFLT *arg6 = (PLFLT *) 0 ;
8079  PLFLT *arg7 = (PLFLT *) 0 ;
8080  PLBOOL *arg8 = (PLBOOL *) 0 ;
8081  int temp4 ;
8082  int temp5 ;
8083  int temp6 ;
8084  int temp7 ;
8085  int temp8 ;
8086 
8087  {
8088  arg8 = NULL;
8089  }
8090  SWIG_check_num_args("plscmap1la",6,7)
8091  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1la",1,"PLBOOL");
8092  arg1 = (PLBOOL)lua_tonumber(L, 1);
8093  {
8094  int temp;
8095  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
8096  if ( !arg3 )
8097  SWIG_fail;
8098  arg2 = Alen = temp;
8099  }
8100  {
8101  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
8102  if ( !arg4 )
8103  SWIG_fail;
8104  if ( temp4 != Alen )
8105  {
8106  lua_pushfstring( L, "Tables must be of same length." );
8107  SWIG_fail;
8108  }
8109  }
8110  {
8111  arg5 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp5 );
8112  if ( !arg5 )
8113  SWIG_fail;
8114  if ( temp5 != Alen )
8115  {
8116  lua_pushfstring( L, "Tables must be of same length." );
8117  SWIG_fail;
8118  }
8119  }
8120  {
8121  arg6 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp6 );
8122  if ( !arg6 )
8123  SWIG_fail;
8124  if ( temp6 != Alen )
8125  {
8126  lua_pushfstring( L, "Tables must be of same length." );
8127  SWIG_fail;
8128  }
8129  }
8130  {
8131  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 6, &temp7 );
8132  if ( !arg7 )
8133  SWIG_fail;
8134  if ( temp7 != Alen )
8135  {
8136  lua_pushfstring( L, "Tables must be of same length." );
8137  SWIG_fail;
8138  }
8139  }
8140  if(lua_gettop(L)>=7){
8141  {
8142  if ( lua_isnil( L, 7 ) )
8143  {
8144  arg8 = NULL;
8145  }
8146  else
8147  {
8148  arg8 = (PLINT *) LUA_get_int_num_array_var( L, 7, &temp8 );
8149  if ( !arg8 )
8150  SWIG_fail;
8151  if ( temp8 < Alen - 1 )
8152  {
8153  lua_pushfstring( L, "Tables must be at least length of others minus 1." );
8154  SWIG_fail;
8155  }
8156  }
8157  }
8158  }
8159  plscmap1la(arg1,arg2,(double const *)arg3,(double const *)arg4,(double const *)arg5,(double const *)arg6,(double const *)arg7,(int const *)arg8);
8160 
8161  {
8162  LUA_FREE_ARRAY( arg3 );
8163  }
8164  {
8165  LUA_FREE_ARRAY( arg4 );
8166  }
8167  {
8168  LUA_FREE_ARRAY( arg5 );
8169  }
8170  {
8171  LUA_FREE_ARRAY( arg6 );
8172  }
8173  {
8174  LUA_FREE_ARRAY( arg7 );
8175  }
8176  {
8177  LUA_FREE_ARRAY( arg8 );
8178  }
8179  return SWIG_arg;
8180 
8181  if(0) SWIG_fail;
8182 
8183 fail:
8184  {
8185  LUA_FREE_ARRAY( arg3 );
8186  }
8187  {
8188  LUA_FREE_ARRAY( arg4 );
8189  }
8190  {
8191  LUA_FREE_ARRAY( arg5 );
8192  }
8193  {
8194  LUA_FREE_ARRAY( arg6 );
8195  }
8196  {
8197  LUA_FREE_ARRAY( arg7 );
8198  }
8199  {
8200  LUA_FREE_ARRAY( arg8 );
8201  }
8202  lua_error(L);
8203  return SWIG_arg;
8204 }
8205 
8206 
8207 static int _wrap_scmap1n(lua_State* L) {
8208  int SWIG_arg = 0;
8209  PLINT arg1 ;
8210 
8211  SWIG_check_num_args("plscmap1n",1,1)
8212  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1n",1,"PLINT");
8213  arg1 = (PLINT)lua_tonumber(L, 1);
8214  plscmap1n(arg1);
8215 
8216  return SWIG_arg;
8217 
8218  if(0) SWIG_fail;
8219 
8220 fail:
8221  lua_error(L);
8222  return SWIG_arg;
8223 }
8224 
8225 
8226 static int _wrap_scmap1_range(lua_State* L) {
8227  int SWIG_arg = 0;
8228  PLFLT arg1 ;
8229  PLFLT arg2 ;
8230 
8231  SWIG_check_num_args("plscmap1_range",2,2)
8232  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1_range",1,"PLFLT");
8233  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscmap1_range",2,"PLFLT");
8234  arg1 = (PLFLT)lua_tonumber(L, 1);
8235  arg2 = (PLFLT)lua_tonumber(L, 2);
8236  plscmap1_range(arg1,arg2);
8237 
8238  return SWIG_arg;
8239 
8240  if(0) SWIG_fail;
8241 
8242 fail:
8243  lua_error(L);
8244  return SWIG_arg;
8245 }
8246 
8247 
8248 static int _wrap_gcmap1_range(lua_State* L) {
8249  int SWIG_arg = 0;
8250  PLFLT *arg1 = (PLFLT *) 0 ;
8251  PLFLT *arg2 = (PLFLT *) 0 ;
8252  PLFLT temp1 ;
8253  PLFLT temp2 ;
8254 
8255  arg1 = &temp1;
8256  arg2 = &temp2;
8257  SWIG_check_num_args("plgcmap1_range",0,0)
8258  plgcmap1_range(arg1,arg2);
8259 
8260  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
8261  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
8262  return SWIG_arg;
8263 
8264  if(0) SWIG_fail;
8265 
8266 fail:
8267  lua_error(L);
8268  return SWIG_arg;
8269 }
8270 
8271 
8272 static int _wrap_scol0(lua_State* L) {
8273  int SWIG_arg = 0;
8274  PLINT arg1 ;
8275  PLINT arg2 ;
8276  PLINT arg3 ;
8277  PLINT arg4 ;
8278 
8279  SWIG_check_num_args("plscol0",4,4)
8280  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscol0",1,"PLINT");
8281  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscol0",2,"PLINT");
8282  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscol0",3,"PLINT");
8283  if(!lua_isnumber(L,4)) SWIG_fail_arg("plscol0",4,"PLINT");
8284  arg1 = (PLINT)lua_tonumber(L, 1);
8285  arg2 = (PLINT)lua_tonumber(L, 2);
8286  arg3 = (PLINT)lua_tonumber(L, 3);
8287  arg4 = (PLINT)lua_tonumber(L, 4);
8288  plscol0(arg1,arg2,arg3,arg4);
8289 
8290  return SWIG_arg;
8291 
8292  if(0) SWIG_fail;
8293 
8294 fail:
8295  lua_error(L);
8296  return SWIG_arg;
8297 }
8298 
8299 
8300 static int _wrap_scol0a(lua_State* L) {
8301  int SWIG_arg = 0;
8302  PLINT arg1 ;
8303  PLINT arg2 ;
8304  PLINT arg3 ;
8305  PLINT arg4 ;
8306  PLFLT arg5 ;
8307 
8308  SWIG_check_num_args("plscol0a",5,5)
8309  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscol0a",1,"PLINT");
8310  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscol0a",2,"PLINT");
8311  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscol0a",3,"PLINT");
8312  if(!lua_isnumber(L,4)) SWIG_fail_arg("plscol0a",4,"PLINT");
8313  if(!lua_isnumber(L,5)) SWIG_fail_arg("plscol0a",5,"PLFLT");
8314  arg1 = (PLINT)lua_tonumber(L, 1);
8315  arg2 = (PLINT)lua_tonumber(L, 2);
8316  arg3 = (PLINT)lua_tonumber(L, 3);
8317  arg4 = (PLINT)lua_tonumber(L, 4);
8318  arg5 = (PLFLT)lua_tonumber(L, 5);
8319  plscol0a(arg1,arg2,arg3,arg4,arg5);
8320 
8321  return SWIG_arg;
8322 
8323  if(0) SWIG_fail;
8324 
8325 fail:
8326  lua_error(L);
8327  return SWIG_arg;
8328 }
8329 
8330 
8331 static int _wrap_scolbg(lua_State* L) {
8332  int SWIG_arg = 0;
8333  PLINT arg1 ;
8334  PLINT arg2 ;
8335  PLINT arg3 ;
8336 
8337  SWIG_check_num_args("plscolbg",3,3)
8338  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscolbg",1,"PLINT");
8339  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscolbg",2,"PLINT");
8340  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscolbg",3,"PLINT");
8341  arg1 = (PLINT)lua_tonumber(L, 1);
8342  arg2 = (PLINT)lua_tonumber(L, 2);
8343  arg3 = (PLINT)lua_tonumber(L, 3);
8344  plscolbg(arg1,arg2,arg3);
8345 
8346  return SWIG_arg;
8347 
8348  if(0) SWIG_fail;
8349 
8350 fail:
8351  lua_error(L);
8352  return SWIG_arg;
8353 }
8354 
8355 
8356 static int _wrap_scolbga(lua_State* L) {
8357  int SWIG_arg = 0;
8358  PLINT arg1 ;
8359  PLINT arg2 ;
8360  PLINT arg3 ;
8361  PLFLT arg4 ;
8362 
8363  SWIG_check_num_args("plscolbga",4,4)
8364  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscolbga",1,"PLINT");
8365  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscolbga",2,"PLINT");
8366  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscolbga",3,"PLINT");
8367  if(!lua_isnumber(L,4)) SWIG_fail_arg("plscolbga",4,"PLFLT");
8368  arg1 = (PLINT)lua_tonumber(L, 1);
8369  arg2 = (PLINT)lua_tonumber(L, 2);
8370  arg3 = (PLINT)lua_tonumber(L, 3);
8371  arg4 = (PLFLT)lua_tonumber(L, 4);
8372  plscolbga(arg1,arg2,arg3,arg4);
8373 
8374  return SWIG_arg;
8375 
8376  if(0) SWIG_fail;
8377 
8378 fail:
8379  lua_error(L);
8380  return SWIG_arg;
8381 }
8382 
8383 
8384 static int _wrap_scolor(lua_State* L) {
8385  int SWIG_arg = 0;
8386  PLINT arg1 ;
8387 
8388  SWIG_check_num_args("plscolor",1,1)
8389  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscolor",1,"PLINT");
8390  arg1 = (PLINT)lua_tonumber(L, 1);
8391  plscolor(arg1);
8392 
8393  return SWIG_arg;
8394 
8395  if(0) SWIG_fail;
8396 
8397 fail:
8398  lua_error(L);
8399  return SWIG_arg;
8400 }
8401 
8402 
8403 static int _wrap_scompression(lua_State* L) {
8404  int SWIG_arg = 0;
8405  PLINT arg1 ;
8406 
8407  SWIG_check_num_args("plscompression",1,1)
8408  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscompression",1,"PLINT");
8409  arg1 = (PLINT)lua_tonumber(L, 1);
8410  plscompression(arg1);
8411 
8412  return SWIG_arg;
8413 
8414  if(0) SWIG_fail;
8415 
8416 fail:
8417  lua_error(L);
8418  return SWIG_arg;
8419 }
8420 
8421 
8422 static int _wrap_sdev(lua_State* L) {
8423  int SWIG_arg = 0;
8424  char *arg1 = (char *) 0 ;
8425 
8426  SWIG_check_num_args("plsdev",1,1)
8427  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsdev",1,"char const *");
8428  arg1 = (char *)lua_tostring(L, 1);
8429  plsdev((char const *)arg1);
8430 
8431  return SWIG_arg;
8432 
8433  if(0) SWIG_fail;
8434 
8435 fail:
8436  lua_error(L);
8437  return SWIG_arg;
8438 }
8439 
8440 
8441 static int _wrap_sdidev(lua_State* L) {
8442  int SWIG_arg = 0;
8443  PLFLT arg1 ;
8444  PLFLT arg2 ;
8445  PLFLT arg3 ;
8446  PLFLT arg4 ;
8447 
8448  SWIG_check_num_args("plsdidev",4,4)
8449  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdidev",1,"PLFLT");
8450  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdidev",2,"PLFLT");
8451  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdidev",3,"PLFLT");
8452  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdidev",4,"PLFLT");
8453  arg1 = (PLFLT)lua_tonumber(L, 1);
8454  arg2 = (PLFLT)lua_tonumber(L, 2);
8455  arg3 = (PLFLT)lua_tonumber(L, 3);
8456  arg4 = (PLFLT)lua_tonumber(L, 4);
8457  plsdidev(arg1,arg2,arg3,arg4);
8458 
8459  return SWIG_arg;
8460 
8461  if(0) SWIG_fail;
8462 
8463 fail:
8464  lua_error(L);
8465  return SWIG_arg;
8466 }
8467 
8468 
8469 static int _wrap_sdimap(lua_State* L) {
8470  int SWIG_arg = 0;
8471  PLINT arg1 ;
8472  PLINT arg2 ;
8473  PLINT arg3 ;
8474  PLINT arg4 ;
8475  PLFLT arg5 ;
8476  PLFLT arg6 ;
8477 
8478  SWIG_check_num_args("plsdimap",6,6)
8479  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdimap",1,"PLINT");
8480  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdimap",2,"PLINT");
8481  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdimap",3,"PLINT");
8482  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdimap",4,"PLINT");
8483  if(!lua_isnumber(L,5)) SWIG_fail_arg("plsdimap",5,"PLFLT");
8484  if(!lua_isnumber(L,6)) SWIG_fail_arg("plsdimap",6,"PLFLT");
8485  arg1 = (PLINT)lua_tonumber(L, 1);
8486  arg2 = (PLINT)lua_tonumber(L, 2);
8487  arg3 = (PLINT)lua_tonumber(L, 3);
8488  arg4 = (PLINT)lua_tonumber(L, 4);
8489  arg5 = (PLFLT)lua_tonumber(L, 5);
8490  arg6 = (PLFLT)lua_tonumber(L, 6);
8491  plsdimap(arg1,arg2,arg3,arg4,arg5,arg6);
8492 
8493  return SWIG_arg;
8494 
8495  if(0) SWIG_fail;
8496 
8497 fail:
8498  lua_error(L);
8499  return SWIG_arg;
8500 }
8501 
8502 
8503 static int _wrap_sdiori(lua_State* L) {
8504  int SWIG_arg = 0;
8505  PLFLT arg1 ;
8506 
8507  SWIG_check_num_args("plsdiori",1,1)
8508  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdiori",1,"PLFLT");
8509  arg1 = (PLFLT)lua_tonumber(L, 1);
8510  plsdiori(arg1);
8511 
8512  return SWIG_arg;
8513 
8514  if(0) SWIG_fail;
8515 
8516 fail:
8517  lua_error(L);
8518  return SWIG_arg;
8519 }
8520 
8521 
8522 static int _wrap_sdiplt(lua_State* L) {
8523  int SWIG_arg = 0;
8524  PLFLT arg1 ;
8525  PLFLT arg2 ;
8526  PLFLT arg3 ;
8527  PLFLT arg4 ;
8528 
8529  SWIG_check_num_args("plsdiplt",4,4)
8530  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdiplt",1,"PLFLT");
8531  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdiplt",2,"PLFLT");
8532  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdiplt",3,"PLFLT");
8533  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdiplt",4,"PLFLT");
8534  arg1 = (PLFLT)lua_tonumber(L, 1);
8535  arg2 = (PLFLT)lua_tonumber(L, 2);
8536  arg3 = (PLFLT)lua_tonumber(L, 3);
8537  arg4 = (PLFLT)lua_tonumber(L, 4);
8538  plsdiplt(arg1,arg2,arg3,arg4);
8539 
8540  return SWIG_arg;
8541 
8542  if(0) SWIG_fail;
8543 
8544 fail:
8545  lua_error(L);
8546  return SWIG_arg;
8547 }
8548 
8549 
8550 static int _wrap_sdiplz(lua_State* L) {
8551  int SWIG_arg = 0;
8552  PLFLT arg1 ;
8553  PLFLT arg2 ;
8554  PLFLT arg3 ;
8555  PLFLT arg4 ;
8556 
8557  SWIG_check_num_args("plsdiplz",4,4)
8558  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdiplz",1,"PLFLT");
8559  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdiplz",2,"PLFLT");
8560  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdiplz",3,"PLFLT");
8561  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdiplz",4,"PLFLT");
8562  arg1 = (PLFLT)lua_tonumber(L, 1);
8563  arg2 = (PLFLT)lua_tonumber(L, 2);
8564  arg3 = (PLFLT)lua_tonumber(L, 3);
8565  arg4 = (PLFLT)lua_tonumber(L, 4);
8566  plsdiplz(arg1,arg2,arg3,arg4);
8567 
8568  return SWIG_arg;
8569 
8570  if(0) SWIG_fail;
8571 
8572 fail:
8573  lua_error(L);
8574  return SWIG_arg;
8575 }
8576 
8577 
8578 static int _wrap_seed(lua_State* L) {
8579  int SWIG_arg = 0;
8580  unsigned int arg1 ;
8581 
8582  SWIG_check_num_args("plseed",1,1)
8583  if(!lua_isnumber(L,1)) SWIG_fail_arg("plseed",1,"unsigned int");
8584  SWIG_contract_assert((lua_tonumber(L,1)>=0),"number must not be negative")
8585  arg1 = (unsigned int)lua_tonumber(L, 1);
8586  plseed(arg1);
8587 
8588  return SWIG_arg;
8589 
8590  if(0) SWIG_fail;
8591 
8592 fail:
8593  lua_error(L);
8594  return SWIG_arg;
8595 }
8596 
8597 
8598 static int _wrap_sesc(lua_State* L) {
8599  int SWIG_arg = 0;
8600  char arg1 ;
8601 
8602  SWIG_check_num_args("plsesc",1,1)
8603  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsesc",1,"char");
8604  arg1 = (lua_tostring(L, 1))[0];
8605  plsesc(arg1);
8606 
8607  return SWIG_arg;
8608 
8609  if(0) SWIG_fail;
8610 
8611 fail:
8612  lua_error(L);
8613  return SWIG_arg;
8614 }
8615 
8616 
8617 static int _wrap_setopt(lua_State* L) {
8618  int SWIG_arg = 0;
8619  char *arg1 = (char *) 0 ;
8620  char *arg2 = (char *) 0 ;
8621  PLINT result;
8622 
8623  SWIG_check_num_args("plsetopt",2,2)
8624  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsetopt",1,"char const *");
8625  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plsetopt",2,"char const *");
8626  arg1 = (char *)lua_tostring(L, 1);
8627  arg2 = (char *)lua_tostring(L, 2);
8628  result = (PLINT)plsetopt((char const *)arg1,(char const *)arg2);
8629  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
8630  return SWIG_arg;
8631 
8632  if(0) SWIG_fail;
8633 
8634 fail:
8635  lua_error(L);
8636  return SWIG_arg;
8637 }
8638 
8639 
8640 static int _wrap_sfam(lua_State* L) {
8641  int SWIG_arg = 0;
8642  PLINT arg1 ;
8643  PLINT arg2 ;
8644  PLINT arg3 ;
8645 
8646  SWIG_check_num_args("plsfam",3,3)
8647  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsfam",1,"PLINT");
8648  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsfam",2,"PLINT");
8649  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsfam",3,"PLINT");
8650  arg1 = (PLINT)lua_tonumber(L, 1);
8651  arg2 = (PLINT)lua_tonumber(L, 2);
8652  arg3 = (PLINT)lua_tonumber(L, 3);
8653  plsfam(arg1,arg2,arg3);
8654 
8655  return SWIG_arg;
8656 
8657  if(0) SWIG_fail;
8658 
8659 fail:
8660  lua_error(L);
8661  return SWIG_arg;
8662 }
8663 
8664 
8665 static int _wrap_sfci(lua_State* L) {
8666  int SWIG_arg = 0;
8667  PLUNICODE arg1 ;
8668 
8669  SWIG_check_num_args("plsfci",1,1)
8670  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsfci",1,"PLUNICODE");
8671  SWIG_contract_assert((lua_tonumber(L,1)>=0),"number must not be negative")
8672  arg1 = (PLUNICODE)lua_tonumber(L, 1);
8673  plsfci(arg1);
8674 
8675  return SWIG_arg;
8676 
8677  if(0) SWIG_fail;
8678 
8679 fail:
8680  lua_error(L);
8681  return SWIG_arg;
8682 }
8683 
8684 
8685 static int _wrap_sfnam(lua_State* L) {
8686  int SWIG_arg = 0;
8687  char *arg1 = (char *) 0 ;
8688 
8689  SWIG_check_num_args("plsfnam",1,1)
8690  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsfnam",1,"char const *");
8691  arg1 = (char *)lua_tostring(L, 1);
8692  plsfnam((char const *)arg1);
8693 
8694  return SWIG_arg;
8695 
8696  if(0) SWIG_fail;
8697 
8698 fail:
8699  lua_error(L);
8700  return SWIG_arg;
8701 }
8702 
8703 
8704 static int _wrap_sfont(lua_State* L) {
8705  int SWIG_arg = 0;
8706  PLINT arg1 ;
8707  PLINT arg2 ;
8708  PLINT arg3 ;
8709 
8710  SWIG_check_num_args("plsfont",3,3)
8711  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsfont",1,"PLINT");
8712  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsfont",2,"PLINT");
8713  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsfont",3,"PLINT");
8714  arg1 = (PLINT)lua_tonumber(L, 1);
8715  arg2 = (PLINT)lua_tonumber(L, 2);
8716  arg3 = (PLINT)lua_tonumber(L, 3);
8717  plsfont(arg1,arg2,arg3);
8718 
8719  return SWIG_arg;
8720 
8721  if(0) SWIG_fail;
8722 
8723 fail:
8724  lua_error(L);
8725  return SWIG_arg;
8726 }
8727 
8728 
8729 static int _wrap_shades(lua_State* L) {
8730  int SWIG_arg = 0;
8731  PLFLT **arg1 = (PLFLT **) 0 ;
8732  PLINT arg2 ;
8733  PLINT arg3 ;
8734  defined_func arg4 = (defined_func) 0 ;
8735  PLFLT arg5 ;
8736  PLFLT arg6 ;
8737  PLFLT arg7 ;
8738  PLFLT arg8 ;
8739  PLFLT *arg9 = (PLFLT *) 0 ;
8740  PLINT arg10 ;
8741  PLFLT arg11 ;
8742  PLINT arg12 ;
8743  PLFLT arg13 ;
8744  fill_func arg14 = (fill_func) 0 ;
8745  PLBOOL arg15 ;
8746  pltr_func arg16 = (pltr_func) 0 ;
8747  PLPointer arg17 = (PLPointer) 0 ;
8748  int ii1 ;
8749  PLcGrid cgrid117 ;
8750  PLcGrid2 cgrid217 ;
8751 
8752  {
8753  cgrid117.xg = cgrid117.yg = cgrid117.zg = NULL;
8754  cgrid117.nx = cgrid117.ny = cgrid117.nz = 0;
8755  cgrid217.xg = cgrid217.yg = cgrid217.zg = NULL;
8756  cgrid217.nx = cgrid217.ny = 0;
8757  }
8758  {
8759  arg16 = NULL;
8760  }
8761  {
8762  arg17 = NULL;
8763  }
8764  {
8765  arg4 = NULL;
8766  }
8767  {
8768  arg14 = plfill;
8769  }
8770  SWIG_check_num_args("plshades",10,12)
8771  if(!lua_isnumber(L,2)) SWIG_fail_arg("plshades",2,"PLFLT");
8772  if(!lua_isnumber(L,3)) SWIG_fail_arg("plshades",3,"PLFLT");
8773  if(!lua_isnumber(L,4)) SWIG_fail_arg("plshades",4,"PLFLT");
8774  if(!lua_isnumber(L,5)) SWIG_fail_arg("plshades",5,"PLFLT");
8775  if(!lua_isnumber(L,7)) SWIG_fail_arg("plshades",7,"PLFLT");
8776  if(!lua_isnumber(L,8)) SWIG_fail_arg("plshades",8,"PLINT");
8777  if(!lua_isnumber(L,9)) SWIG_fail_arg("plshades",9,"PLFLT");
8778  if(!lua_isnumber(L,10)) SWIG_fail_arg("plshades",10,"PLBOOL");
8779  {
8780  int jj;
8781 
8782  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
8783  if ( !arg1 )
8784  SWIG_fail;
8785  Xlen = arg2 = ii1;
8786  Ylen = arg3 = jj;
8787  }
8788  arg5 = (PLFLT)lua_tonumber(L, 2);
8789  arg6 = (PLFLT)lua_tonumber(L, 3);
8790  arg7 = (PLFLT)lua_tonumber(L, 4);
8791  arg8 = (PLFLT)lua_tonumber(L, 5);
8792  {
8793  int temp;
8794  arg9 = (PLFLT *) LUA_get_double_num_array_var( L, 6, &temp );
8795  if ( !arg9 )
8796  SWIG_fail;
8797  arg10 = Alen = temp;
8798  }
8799  arg11 = (PLFLT)lua_tonumber(L, 7);
8800  arg12 = (PLINT)lua_tonumber(L, 8);
8801  arg13 = (PLFLT)lua_tonumber(L, 9);
8802  arg15 = (PLBOOL)lua_tonumber(L, 10);
8803  if(lua_gettop(L)>=11){
8804  {
8805  arg16 = NULL;
8806  mypltr_funcstr[0] = '\0';
8807 
8808  if ( lua_isstring( L, 11 ) )
8809  {
8810  const char* funcstr = lua_tostring( L, 11 );
8811  if ( strcmp( "pltr0", funcstr ) == 0 )
8812  {
8813  arg16 = pltr0;
8814  }
8815  else if ( strcmp( "pltr1", funcstr ) == 0 )
8816  {
8817  arg16 = pltr1;
8818  }
8819  else if ( strcmp( "pltr2", funcstr ) == 0 )
8820  {
8821  arg16 = pltr2;
8822  }
8823  else
8824  {
8825  arg16 = mypltr;
8826  strncpy( mypltr_funcstr, funcstr, 255 );
8827  myL = L;
8828  }
8829  }
8830  else
8831  SWIG_fail_arg( "shades", 16, "pltr_func" );
8832  }
8833  }
8834  if(lua_gettop(L)>=12){
8835  {
8836  int nx, ny;
8837  int gridmode = 0;
8838 
8839  lua_pushstring( L, "xg" );
8840  lua_gettable( L, 12 );
8841  if ( !lua_istable( L, -1 ) )
8842  {
8843  lua_pop( L, 1 ); // pop "xg"
8844  lua_pushstring( L, "expected a table xg" );
8845  SWIG_fail;
8846  }
8847  lua_rawgeti( L, -1, 1 );
8848  if ( lua_istable( L, -1 ) )
8849  gridmode = 2; // two dimensional array
8850  else if ( lua_isnumber( L, -1 ) )
8851  gridmode = 1; // one dimensional array
8852  else
8853  {
8854  lua_pop( L, 1 ); // pop "1"
8855  lua_pop( L, 1 ); // pop "xg"
8856  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
8857  SWIG_fail;
8858  }
8859  lua_pop( L, 1 ); // pop test element
8860  if ( gridmode == 1 )
8861  {
8862  cgrid117.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
8863  if ( !cgrid117.xg )
8864  {
8865  lua_pop( L, 1 ); // pop "xg"
8866  SWIG_fail;
8867  }
8868  if ( nx != Xlen )
8869  {
8870  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
8871  SWIG_fail;
8872  }
8873  cgrid117.nx = nx;
8874  }
8875  else
8876  {
8877  cgrid217.xg = read_double_Matrix( L, -1, &nx, &ny );
8878  if ( !cgrid217.xg )
8879  {
8880  lua_pop( L, 1 ); // pop "xg"
8881  SWIG_fail;
8882  }
8883  if ( ( nx != Xlen ) || ( ny != Ylen ) )
8884  {
8885  lua_pop( L, 1 ); // pop "xg"
8886  lua_pushfstring( L, "Vectors must match matrix." );
8887  SWIG_fail;
8888  }
8889  cgrid217.nx = nx;
8890  cgrid217.ny = ny;
8891  }
8892  lua_pop( L, 1 ); // pop "xg"
8893 
8894  lua_pushstring( L, "yg" );
8895  lua_gettable( L, 12 );
8896  if ( !lua_istable( L, -1 ) )
8897  {
8898  lua_pop( L, 1 );
8899  lua_pushstring( L, "expected a table yg" );
8900  SWIG_fail;
8901  }
8902  lua_rawgeti( L, -1, 1 );
8903  if ( gridmode == 2 )
8904  {
8905  if ( !lua_istable( L, -1 ) )
8906  {
8907  lua_pop( L, 1 ); // pop "1"
8908  lua_pop( L, 1 ); // pop "yg"
8909  lua_pushstring( L, "expected a two dimensional array/table in yg" );
8910  SWIG_fail;
8911  }
8912  }
8913  else
8914  {
8915  if ( !lua_isnumber( L, -1 ) )
8916  {
8917  lua_pop( L, 1 ); // pop "1"
8918  lua_pop( L, 1 ); // pop "yg"
8919  lua_pushstring( L, "expected a one dimensional array/table in yg" );
8920  SWIG_fail;
8921  }
8922  }
8923  lua_pop( L, 1 ); // pop "1"
8924  if ( gridmode == 1 )
8925  {
8926  cgrid117.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
8927  if ( !cgrid117.yg )
8928  {
8929  lua_pop( L, 1 ); // pop "yg"
8930  SWIG_fail;
8931  }
8932  if ( ny != Ylen )
8933  {
8934  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
8935  SWIG_fail;
8936  }
8937  cgrid117.ny = ny;
8938  }
8939  else
8940  {
8941  cgrid217.yg = read_double_Matrix( L, -1, &nx, &ny );
8942  if ( !cgrid217.yg )
8943  {
8944  lua_pop( L, 1 ); // pop "xg"
8945  SWIG_fail;
8946  }
8947  if ( ( nx != Xlen ) || ( ny != Ylen ) )
8948  {
8949  lua_pop( L, 1 ); // pop "xg"
8950  lua_pushfstring( L, "Vectors must match matrix." );
8951  SWIG_fail;
8952  }
8953  // cgrid217.nx/ny already set
8954  }
8955  lua_pop( L, 1 ); // pop "yg"
8956 
8957  if ( gridmode == 1 )
8958  arg17 = &cgrid117;
8959  else if ( gridmode == 2 )
8960  arg17 = &cgrid217;
8961  }
8962  }
8963  plshades((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,(double const *)arg9,arg10,arg11,arg12,arg13,arg14,arg15,arg16,arg17);
8964 
8965  {
8966  int i;
8967 
8968  if ( arg1 )
8969  {
8970  for ( i = 0; i < ii1; i++ )
8971  LUA_FREE_ARRAY( arg1[i] );
8972  LUA_FREE_ARRAY( arg1 );
8973  }
8974  }
8975  {
8976  LUA_FREE_ARRAY( arg9 );
8977  }
8978  {
8979  mypltr_funcstr[0] = '\0';
8980  }
8981  {
8982  int i;
8983 
8984  LUA_FREE_ARRAY( cgrid117.xg );
8985  LUA_FREE_ARRAY( cgrid117.yg );
8986 
8987  if ( cgrid217.xg )
8988  {
8989  for ( i = 0; i < Xlen; i++ )
8990  LUA_FREE_ARRAY( cgrid217.xg[i] );
8991  LUA_FREE_ARRAY( cgrid217.xg );
8992  }
8993  if ( cgrid217.yg )
8994  {
8995  for ( i = 0; i < Xlen; i++ )
8996  LUA_FREE_ARRAY( cgrid217.yg[i] );
8997  LUA_FREE_ARRAY( cgrid217.yg );
8998  }
8999  }
9000  return SWIG_arg;
9001 
9002  if(0) SWIG_fail;
9003 
9004 fail:
9005  {
9006  int i;
9007 
9008  if ( arg1 )
9009  {
9010  for ( i = 0; i < ii1; i++ )
9011  LUA_FREE_ARRAY( arg1[i] );
9012  LUA_FREE_ARRAY( arg1 );
9013  }
9014  }
9015  {
9016  LUA_FREE_ARRAY( arg9 );
9017  }
9018  {
9019  mypltr_funcstr[0] = '\0';
9020  }
9021  {
9022  int i;
9023 
9024  LUA_FREE_ARRAY( cgrid117.xg );
9025  LUA_FREE_ARRAY( cgrid117.yg );
9026 
9027  if ( cgrid217.xg )
9028  {
9029  for ( i = 0; i < Xlen; i++ )
9030  LUA_FREE_ARRAY( cgrid217.xg[i] );
9031  LUA_FREE_ARRAY( cgrid217.xg );
9032  }
9033  if ( cgrid217.yg )
9034  {
9035  for ( i = 0; i < Xlen; i++ )
9036  LUA_FREE_ARRAY( cgrid217.yg[i] );
9037  LUA_FREE_ARRAY( cgrid217.yg );
9038  }
9039  }
9040  lua_error(L);
9041  return SWIG_arg;
9042 }
9043 
9044 
9045 static int _wrap_shade(lua_State* L) {
9046  int SWIG_arg = 0;
9047  PLFLT **arg1 = (PLFLT **) 0 ;
9048  PLINT arg2 ;
9049  PLINT arg3 ;
9050  defined_func arg4 = (defined_func) 0 ;
9051  PLFLT arg5 ;
9052  PLFLT arg6 ;
9053  PLFLT arg7 ;
9054  PLFLT arg8 ;
9055  PLFLT arg9 ;
9056  PLFLT arg10 ;
9057  PLINT arg11 ;
9058  PLFLT arg12 ;
9059  PLFLT arg13 ;
9060  PLINT arg14 ;
9061  PLFLT arg15 ;
9062  PLINT arg16 ;
9063  PLFLT arg17 ;
9064  fill_func arg18 = (fill_func) 0 ;
9065  PLBOOL arg19 ;
9066  pltr_func arg20 = (pltr_func) 0 ;
9067  PLPointer arg21 = (PLPointer) 0 ;
9068  int ii1 ;
9069  PLcGrid cgrid121 ;
9070  PLcGrid2 cgrid221 ;
9071 
9072  {
9073  cgrid121.xg = cgrid121.yg = cgrid121.zg = NULL;
9074  cgrid121.nx = cgrid121.ny = cgrid121.nz = 0;
9075  cgrid221.xg = cgrid221.yg = cgrid221.zg = NULL;
9076  cgrid221.nx = cgrid221.ny = 0;
9077  }
9078  {
9079  arg20 = NULL;
9080  }
9081  {
9082  arg21 = NULL;
9083  }
9084  {
9085  arg4 = NULL;
9086  }
9087  {
9088  arg18 = plfill;
9089  }
9090  SWIG_check_num_args("plshade",15,17)
9091  if(!lua_isnumber(L,2)) SWIG_fail_arg("plshade",2,"PLFLT");
9092  if(!lua_isnumber(L,3)) SWIG_fail_arg("plshade",3,"PLFLT");
9093  if(!lua_isnumber(L,4)) SWIG_fail_arg("plshade",4,"PLFLT");
9094  if(!lua_isnumber(L,5)) SWIG_fail_arg("plshade",5,"PLFLT");
9095  if(!lua_isnumber(L,6)) SWIG_fail_arg("plshade",6,"PLFLT");
9096  if(!lua_isnumber(L,7)) SWIG_fail_arg("plshade",7,"PLFLT");
9097  if(!lua_isnumber(L,8)) SWIG_fail_arg("plshade",8,"PLINT");
9098  if(!lua_isnumber(L,9)) SWIG_fail_arg("plshade",9,"PLFLT");
9099  if(!lua_isnumber(L,10)) SWIG_fail_arg("plshade",10,"PLFLT");
9100  if(!lua_isnumber(L,11)) SWIG_fail_arg("plshade",11,"PLINT");
9101  if(!lua_isnumber(L,12)) SWIG_fail_arg("plshade",12,"PLFLT");
9102  if(!lua_isnumber(L,13)) SWIG_fail_arg("plshade",13,"PLINT");
9103  if(!lua_isnumber(L,14)) SWIG_fail_arg("plshade",14,"PLFLT");
9104  if(!lua_isnumber(L,15)) SWIG_fail_arg("plshade",15,"PLBOOL");
9105  {
9106  int jj;
9107 
9108  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
9109  if ( !arg1 )
9110  SWIG_fail;
9111  Xlen = arg2 = ii1;
9112  Ylen = arg3 = jj;
9113  }
9114  arg5 = (PLFLT)lua_tonumber(L, 2);
9115  arg6 = (PLFLT)lua_tonumber(L, 3);
9116  arg7 = (PLFLT)lua_tonumber(L, 4);
9117  arg8 = (PLFLT)lua_tonumber(L, 5);
9118  arg9 = (PLFLT)lua_tonumber(L, 6);
9119  arg10 = (PLFLT)lua_tonumber(L, 7);
9120  arg11 = (PLINT)lua_tonumber(L, 8);
9121  arg12 = (PLFLT)lua_tonumber(L, 9);
9122  arg13 = (PLFLT)lua_tonumber(L, 10);
9123  arg14 = (PLINT)lua_tonumber(L, 11);
9124  arg15 = (PLFLT)lua_tonumber(L, 12);
9125  arg16 = (PLINT)lua_tonumber(L, 13);
9126  arg17 = (PLFLT)lua_tonumber(L, 14);
9127  arg19 = (PLBOOL)lua_tonumber(L, 15);
9128  if(lua_gettop(L)>=16){
9129  {
9130  arg20 = NULL;
9131  mypltr_funcstr[0] = '\0';
9132 
9133  if ( lua_isstring( L, 16 ) )
9134  {
9135  const char* funcstr = lua_tostring( L, 16 );
9136  if ( strcmp( "pltr0", funcstr ) == 0 )
9137  {
9138  arg20 = pltr0;
9139  }
9140  else if ( strcmp( "pltr1", funcstr ) == 0 )
9141  {
9142  arg20 = pltr1;
9143  }
9144  else if ( strcmp( "pltr2", funcstr ) == 0 )
9145  {
9146  arg20 = pltr2;
9147  }
9148  else
9149  {
9150  arg20 = mypltr;
9151  strncpy( mypltr_funcstr, funcstr, 255 );
9152  myL = L;
9153  }
9154  }
9155  else
9156  SWIG_fail_arg( "shade", 20, "pltr_func" );
9157  }
9158  }
9159  if(lua_gettop(L)>=17){
9160  {
9161  int nx, ny;
9162  int gridmode = 0;
9163 
9164  lua_pushstring( L, "xg" );
9165  lua_gettable( L, 17 );
9166  if ( !lua_istable( L, -1 ) )
9167  {
9168  lua_pop( L, 1 ); // pop "xg"
9169  lua_pushstring( L, "expected a table xg" );
9170  SWIG_fail;
9171  }
9172  lua_rawgeti( L, -1, 1 );
9173  if ( lua_istable( L, -1 ) )
9174  gridmode = 2; // two dimensional array
9175  else if ( lua_isnumber( L, -1 ) )
9176  gridmode = 1; // one dimensional array
9177  else
9178  {
9179  lua_pop( L, 1 ); // pop "1"
9180  lua_pop( L, 1 ); // pop "xg"
9181  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
9182  SWIG_fail;
9183  }
9184  lua_pop( L, 1 ); // pop test element
9185  if ( gridmode == 1 )
9186  {
9187  cgrid121.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
9188  if ( !cgrid121.xg )
9189  {
9190  lua_pop( L, 1 ); // pop "xg"
9191  SWIG_fail;
9192  }
9193  if ( nx != Xlen )
9194  {
9195  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
9196  SWIG_fail;
9197  }
9198  cgrid121.nx = nx;
9199  }
9200  else
9201  {
9202  cgrid221.xg = read_double_Matrix( L, -1, &nx, &ny );
9203  if ( !cgrid221.xg )
9204  {
9205  lua_pop( L, 1 ); // pop "xg"
9206  SWIG_fail;
9207  }
9208  if ( ( nx != Xlen ) || ( ny != Ylen ) )
9209  {
9210  lua_pop( L, 1 ); // pop "xg"
9211  lua_pushfstring( L, "Vectors must match matrix." );
9212  SWIG_fail;
9213  }
9214  cgrid221.nx = nx;
9215  cgrid221.ny = ny;
9216  }
9217  lua_pop( L, 1 ); // pop "xg"
9218 
9219  lua_pushstring( L, "yg" );
9220  lua_gettable( L, 17 );
9221  if ( !lua_istable( L, -1 ) )
9222  {
9223  lua_pop( L, 1 );
9224  lua_pushstring( L, "expected a table yg" );
9225  SWIG_fail;
9226  }
9227  lua_rawgeti( L, -1, 1 );
9228  if ( gridmode == 2 )
9229  {
9230  if ( !lua_istable( L, -1 ) )
9231  {
9232  lua_pop( L, 1 ); // pop "1"
9233  lua_pop( L, 1 ); // pop "yg"
9234  lua_pushstring( L, "expected a two dimensional array/table in yg" );
9235  SWIG_fail;
9236  }
9237  }
9238  else
9239  {
9240  if ( !lua_isnumber( L, -1 ) )
9241  {
9242  lua_pop( L, 1 ); // pop "1"
9243  lua_pop( L, 1 ); // pop "yg"
9244  lua_pushstring( L, "expected a one dimensional array/table in yg" );
9245  SWIG_fail;
9246  }
9247  }
9248  lua_pop( L, 1 ); // pop "1"
9249  if ( gridmode == 1 )
9250  {
9251  cgrid121.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
9252  if ( !cgrid121.yg )
9253  {
9254  lua_pop( L, 1 ); // pop "yg"
9255  SWIG_fail;
9256  }
9257  if ( ny != Ylen )
9258  {
9259  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
9260  SWIG_fail;
9261  }
9262  cgrid121.ny = ny;
9263  }
9264  else
9265  {
9266  cgrid221.yg = read_double_Matrix( L, -1, &nx, &ny );
9267  if ( !cgrid221.yg )
9268  {
9269  lua_pop( L, 1 ); // pop "xg"
9270  SWIG_fail;
9271  }
9272  if ( ( nx != Xlen ) || ( ny != Ylen ) )
9273  {
9274  lua_pop( L, 1 ); // pop "xg"
9275  lua_pushfstring( L, "Vectors must match matrix." );
9276  SWIG_fail;
9277  }
9278  // cgrid221.nx/ny already set
9279  }
9280  lua_pop( L, 1 ); // pop "yg"
9281 
9282  if ( gridmode == 1 )
9283  arg21 = &cgrid121;
9284  else if ( gridmode == 2 )
9285  arg21 = &cgrid221;
9286  }
9287  }
9288  plshade((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13,arg14,arg15,arg16,arg17,arg18,arg19,arg20,arg21);
9289 
9290  {
9291  int i;
9292 
9293  if ( arg1 )
9294  {
9295  for ( i = 0; i < ii1; i++ )
9296  LUA_FREE_ARRAY( arg1[i] );
9297  LUA_FREE_ARRAY( arg1 );
9298  }
9299  }
9300  {
9301  mypltr_funcstr[0] = '\0';
9302  }
9303  {
9304  int i;
9305 
9306  LUA_FREE_ARRAY( cgrid121.xg );
9307  LUA_FREE_ARRAY( cgrid121.yg );
9308 
9309  if ( cgrid221.xg )
9310  {
9311  for ( i = 0; i < Xlen; i++ )
9312  LUA_FREE_ARRAY( cgrid221.xg[i] );
9313  LUA_FREE_ARRAY( cgrid221.xg );
9314  }
9315  if ( cgrid221.yg )
9316  {
9317  for ( i = 0; i < Xlen; i++ )
9318  LUA_FREE_ARRAY( cgrid221.yg[i] );
9319  LUA_FREE_ARRAY( cgrid221.yg );
9320  }
9321  }
9322  return SWIG_arg;
9323 
9324  if(0) SWIG_fail;
9325 
9326 fail:
9327  {
9328  int i;
9329 
9330  if ( arg1 )
9331  {
9332  for ( i = 0; i < ii1; i++ )
9333  LUA_FREE_ARRAY( arg1[i] );
9334  LUA_FREE_ARRAY( arg1 );
9335  }
9336  }
9337  {
9338  mypltr_funcstr[0] = '\0';
9339  }
9340  {
9341  int i;
9342 
9343  LUA_FREE_ARRAY( cgrid121.xg );
9344  LUA_FREE_ARRAY( cgrid121.yg );
9345 
9346  if ( cgrid221.xg )
9347  {
9348  for ( i = 0; i < Xlen; i++ )
9349  LUA_FREE_ARRAY( cgrid221.xg[i] );
9350  LUA_FREE_ARRAY( cgrid221.xg );
9351  }
9352  if ( cgrid221.yg )
9353  {
9354  for ( i = 0; i < Xlen; i++ )
9355  LUA_FREE_ARRAY( cgrid221.yg[i] );
9356  LUA_FREE_ARRAY( cgrid221.yg );
9357  }
9358  }
9359  lua_error(L);
9360  return SWIG_arg;
9361 }
9362 
9363 
9364 static int _wrap_slabelfunc(lua_State* L) {
9365  int SWIG_arg = 0;
9366  label_func arg1 = (label_func) 0 ;
9367  PLPointer arg2 = (PLPointer) 0 ;
9368 
9369  {
9370  arg2 = NULL;
9371  }
9372  SWIG_check_num_args("plslabelfunc",1,1)
9373  {
9374  arg1 = NULL;
9375  mylabel_funcstr[0] = '\0';
9376 
9377  if ( lua_isnil( L, 1 ) )
9378  {
9379  arg1 = NULL;
9380  }
9381  else if ( lua_isstring( L, 1 ) )
9382  {
9383  arg1 = mylabel;
9384  strncpy( mylabel_funcstr, lua_tostring( L, 1 ), 255 );
9385  myL = L;
9386  }
9387  else
9388  SWIG_fail_arg( "slabelfunc", 1, "label_func" );
9389  }
9390  plslabelfunc(arg1,arg2);
9391 
9392  {
9393 
9394  }
9395  return SWIG_arg;
9396 
9397  if(0) SWIG_fail;
9398 
9399 fail:
9400  {
9401 
9402  }
9403  lua_error(L);
9404  return SWIG_arg;
9405 }
9406 
9407 
9408 static int _wrap_smaj(lua_State* L) {
9409  int SWIG_arg = 0;
9410  PLFLT arg1 ;
9411  PLFLT arg2 ;
9412 
9413  SWIG_check_num_args("plsmaj",2,2)
9414  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsmaj",1,"PLFLT");
9415  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsmaj",2,"PLFLT");
9416  arg1 = (PLFLT)lua_tonumber(L, 1);
9417  arg2 = (PLFLT)lua_tonumber(L, 2);
9418  plsmaj(arg1,arg2);
9419 
9420  return SWIG_arg;
9421 
9422  if(0) SWIG_fail;
9423 
9424 fail:
9425  lua_error(L);
9426  return SWIG_arg;
9427 }
9428 
9429 
9430 static int _wrap_smin(lua_State* L) {
9431  int SWIG_arg = 0;
9432  PLFLT arg1 ;
9433  PLFLT arg2 ;
9434 
9435  SWIG_check_num_args("plsmin",2,2)
9436  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsmin",1,"PLFLT");
9437  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsmin",2,"PLFLT");
9438  arg1 = (PLFLT)lua_tonumber(L, 1);
9439  arg2 = (PLFLT)lua_tonumber(L, 2);
9440  plsmin(arg1,arg2);
9441 
9442  return SWIG_arg;
9443 
9444  if(0) SWIG_fail;
9445 
9446 fail:
9447  lua_error(L);
9448  return SWIG_arg;
9449 }
9450 
9451 
9452 static int _wrap_sori(lua_State* L) {
9453  int SWIG_arg = 0;
9454  PLINT arg1 ;
9455 
9456  SWIG_check_num_args("plsori",1,1)
9457  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsori",1,"PLINT");
9458  arg1 = (PLINT)lua_tonumber(L, 1);
9459  plsori(arg1);
9460 
9461  return SWIG_arg;
9462 
9463  if(0) SWIG_fail;
9464 
9465 fail:
9466  lua_error(L);
9467  return SWIG_arg;
9468 }
9469 
9470 
9471 static int _wrap_spage(lua_State* L) {
9472  int SWIG_arg = 0;
9473  PLFLT arg1 ;
9474  PLFLT arg2 ;
9475  PLINT arg3 ;
9476  PLINT arg4 ;
9477  PLINT arg5 ;
9478  PLINT arg6 ;
9479 
9480  SWIG_check_num_args("plspage",6,6)
9481  if(!lua_isnumber(L,1)) SWIG_fail_arg("plspage",1,"PLFLT");
9482  if(!lua_isnumber(L,2)) SWIG_fail_arg("plspage",2,"PLFLT");
9483  if(!lua_isnumber(L,3)) SWIG_fail_arg("plspage",3,"PLINT");
9484  if(!lua_isnumber(L,4)) SWIG_fail_arg("plspage",4,"PLINT");
9485  if(!lua_isnumber(L,5)) SWIG_fail_arg("plspage",5,"PLINT");
9486  if(!lua_isnumber(L,6)) SWIG_fail_arg("plspage",6,"PLINT");
9487  arg1 = (PLFLT)lua_tonumber(L, 1);
9488  arg2 = (PLFLT)lua_tonumber(L, 2);
9489  arg3 = (PLINT)lua_tonumber(L, 3);
9490  arg4 = (PLINT)lua_tonumber(L, 4);
9491  arg5 = (PLINT)lua_tonumber(L, 5);
9492  arg6 = (PLINT)lua_tonumber(L, 6);
9493  plspage(arg1,arg2,arg3,arg4,arg5,arg6);
9494 
9495  return SWIG_arg;
9496 
9497  if(0) SWIG_fail;
9498 
9499 fail:
9500  lua_error(L);
9501  return SWIG_arg;
9502 }
9503 
9504 
9505 static int _wrap_spal0(lua_State* L) {
9506  int SWIG_arg = 0;
9507  char *arg1 = (char *) 0 ;
9508 
9509  SWIG_check_num_args("plspal0",1,1)
9510  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plspal0",1,"char const *");
9511  arg1 = (char *)lua_tostring(L, 1);
9512  plspal0((char const *)arg1);
9513 
9514  return SWIG_arg;
9515 
9516  if(0) SWIG_fail;
9517 
9518 fail:
9519  lua_error(L);
9520  return SWIG_arg;
9521 }
9522 
9523 
9524 static int _wrap_spal1(lua_State* L) {
9525  int SWIG_arg = 0;
9526  char *arg1 = (char *) 0 ;
9527  PLBOOL arg2 ;
9528 
9529  SWIG_check_num_args("plspal1",2,2)
9530  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plspal1",1,"char const *");
9531  if(!lua_isnumber(L,2)) SWIG_fail_arg("plspal1",2,"PLBOOL");
9532  arg1 = (char *)lua_tostring(L, 1);
9533  arg2 = (PLBOOL)lua_tonumber(L, 2);
9534  plspal1((char const *)arg1,arg2);
9535 
9536  return SWIG_arg;
9537 
9538  if(0) SWIG_fail;
9539 
9540 fail:
9541  lua_error(L);
9542  return SWIG_arg;
9543 }
9544 
9545 
9546 static int _wrap_spause(lua_State* L) {
9547  int SWIG_arg = 0;
9548  PLBOOL arg1 ;
9549 
9550  SWIG_check_num_args("plspause",1,1)
9551  if(!lua_isnumber(L,1)) SWIG_fail_arg("plspause",1,"PLBOOL");
9552  arg1 = (PLBOOL)lua_tonumber(L, 1);
9553  plspause(arg1);
9554 
9555  return SWIG_arg;
9556 
9557  if(0) SWIG_fail;
9558 
9559 fail:
9560  lua_error(L);
9561  return SWIG_arg;
9562 }
9563 
9564 
9565 static int _wrap_sstrm(lua_State* L) {
9566  int SWIG_arg = 0;
9567  PLINT arg1 ;
9568 
9569  SWIG_check_num_args("plsstrm",1,1)
9570  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsstrm",1,"PLINT");
9571  arg1 = (PLINT)lua_tonumber(L, 1);
9572  plsstrm(arg1);
9573 
9574  return SWIG_arg;
9575 
9576  if(0) SWIG_fail;
9577 
9578 fail:
9579  lua_error(L);
9580  return SWIG_arg;
9581 }
9582 
9583 
9584 static int _wrap_ssub(lua_State* L) {
9585  int SWIG_arg = 0;
9586  PLINT arg1 ;
9587  PLINT arg2 ;
9588 
9589  SWIG_check_num_args("plssub",2,2)
9590  if(!lua_isnumber(L,1)) SWIG_fail_arg("plssub",1,"PLINT");
9591  if(!lua_isnumber(L,2)) SWIG_fail_arg("plssub",2,"PLINT");
9592  arg1 = (PLINT)lua_tonumber(L, 1);
9593  arg2 = (PLINT)lua_tonumber(L, 2);
9594  plssub(arg1,arg2);
9595 
9596  return SWIG_arg;
9597 
9598  if(0) SWIG_fail;
9599 
9600 fail:
9601  lua_error(L);
9602  return SWIG_arg;
9603 }
9604 
9605 
9606 static int _wrap_ssym(lua_State* L) {
9607  int SWIG_arg = 0;
9608  PLFLT arg1 ;
9609  PLFLT arg2 ;
9610 
9611  SWIG_check_num_args("plssym",2,2)
9612  if(!lua_isnumber(L,1)) SWIG_fail_arg("plssym",1,"PLFLT");
9613  if(!lua_isnumber(L,2)) SWIG_fail_arg("plssym",2,"PLFLT");
9614  arg1 = (PLFLT)lua_tonumber(L, 1);
9615  arg2 = (PLFLT)lua_tonumber(L, 2);
9616  plssym(arg1,arg2);
9617 
9618  return SWIG_arg;
9619 
9620  if(0) SWIG_fail;
9621 
9622 fail:
9623  lua_error(L);
9624  return SWIG_arg;
9625 }
9626 
9627 
9628 static int _wrap_star(lua_State* L) {
9629  int SWIG_arg = 0;
9630  PLINT arg1 ;
9631  PLINT arg2 ;
9632 
9633  SWIG_check_num_args("plstar",2,2)
9634  if(!lua_isnumber(L,1)) SWIG_fail_arg("plstar",1,"PLINT");
9635  if(!lua_isnumber(L,2)) SWIG_fail_arg("plstar",2,"PLINT");
9636  arg1 = (PLINT)lua_tonumber(L, 1);
9637  arg2 = (PLINT)lua_tonumber(L, 2);
9638  plstar(arg1,arg2);
9639 
9640  return SWIG_arg;
9641 
9642  if(0) SWIG_fail;
9643 
9644 fail:
9645  lua_error(L);
9646  return SWIG_arg;
9647 }
9648 
9649 
9650 static int _wrap_start(lua_State* L) {
9651  int SWIG_arg = 0;
9652  char *arg1 = (char *) 0 ;
9653  PLINT arg2 ;
9654  PLINT arg3 ;
9655 
9656  SWIG_check_num_args("plstart",3,3)
9657  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plstart",1,"char const *");
9658  if(!lua_isnumber(L,2)) SWIG_fail_arg("plstart",2,"PLINT");
9659  if(!lua_isnumber(L,3)) SWIG_fail_arg("plstart",3,"PLINT");
9660  arg1 = (char *)lua_tostring(L, 1);
9661  arg2 = (PLINT)lua_tonumber(L, 2);
9662  arg3 = (PLINT)lua_tonumber(L, 3);
9663  plstart((char const *)arg1,arg2,arg3);
9664 
9665  return SWIG_arg;
9666 
9667  if(0) SWIG_fail;
9668 
9669 fail:
9670  lua_error(L);
9671  return SWIG_arg;
9672 }
9673 
9674 
9675 static int _wrap_stransform(lua_State* L) {
9676  int SWIG_arg = 0;
9677  ct_func arg1 = (ct_func) 0 ;
9678  PLPointer arg2 = (PLPointer) 0 ;
9679 
9680  {
9681  arg1 = NULL;
9682  myct_funcstr[0] = '\0';
9683  }
9684  {
9685  arg2 = NULL;
9686  }
9687  SWIG_check_num_args("plstransform",0,1)
9688  if(lua_gettop(L)>=1){
9689  {
9690  arg1 = NULL;
9691  myct_funcstr[0] = '\0';
9692 
9693  if ( lua_isstring( L, 1 ) )
9694  {
9695  const char* funcstr = lua_tostring( L, 1 );
9696  arg1 = myct;
9697  strncpy( myct_funcstr, funcstr, 255 );
9698  myL = L;
9699  }
9700  else
9701  SWIG_fail_arg( "stransform", 1, "ct_func" );
9702  }
9703  }
9704  plstransform(arg1,arg2);
9705 
9706  return SWIG_arg;
9707 
9708  if(0) SWIG_fail;
9709 
9710 fail:
9711  lua_error(L);
9712  return SWIG_arg;
9713 }
9714 
9715 
9716 static int _wrap_string(lua_State* L) {
9717  int SWIG_arg = 0;
9718  PLINT arg1 ;
9719  PLFLT *arg2 = (PLFLT *) 0 ;
9720  PLFLT *arg3 = (PLFLT *) 0 ;
9721  char *arg4 = (char *) 0 ;
9722  int temp3 ;
9723 
9724  SWIG_check_num_args("plstring",3,3)
9725  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("plstring",3,"char const *");
9726  {
9727  int temp;
9728  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
9729  if ( !arg2 )
9730  SWIG_fail;
9731  arg1 = Alen = temp;
9732  }
9733  {
9734  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
9735  if ( !arg3 )
9736  SWIG_fail;
9737  if ( temp3 != Alen )
9738  {
9739  lua_pushfstring( L, "Tables must be of same length." );
9740  SWIG_fail;
9741  }
9742  }
9743  arg4 = (char *)lua_tostring(L, 3);
9744  plstring(arg1,(double const *)arg2,(double const *)arg3,(char const *)arg4);
9745 
9746  {
9747  LUA_FREE_ARRAY( arg2 );
9748  }
9749  {
9750  LUA_FREE_ARRAY( arg3 );
9751  }
9752  return SWIG_arg;
9753 
9754  if(0) SWIG_fail;
9755 
9756 fail:
9757  {
9758  LUA_FREE_ARRAY( arg2 );
9759  }
9760  {
9761  LUA_FREE_ARRAY( arg3 );
9762  }
9763  lua_error(L);
9764  return SWIG_arg;
9765 }
9766 
9767 
9768 static int _wrap_string3(lua_State* L) {
9769  int SWIG_arg = 0;
9770  PLINT arg1 ;
9771  PLFLT *arg2 = (PLFLT *) 0 ;
9772  PLFLT *arg3 = (PLFLT *) 0 ;
9773  PLFLT *arg4 = (PLFLT *) 0 ;
9774  char *arg5 = (char *) 0 ;
9775  int temp3 ;
9776  int temp4 ;
9777 
9778  SWIG_check_num_args("plstring3",4,4)
9779  if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("plstring3",4,"char const *");
9780  {
9781  int temp;
9782  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
9783  if ( !arg2 )
9784  SWIG_fail;
9785  arg1 = Alen = temp;
9786  }
9787  {
9788  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
9789  if ( !arg3 )
9790  SWIG_fail;
9791  if ( temp3 != Alen )
9792  {
9793  lua_pushfstring( L, "Tables must be of same length." );
9794  SWIG_fail;
9795  }
9796  }
9797  {
9798  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
9799  if ( !arg4 )
9800  SWIG_fail;
9801  if ( temp4 != Alen )
9802  {
9803  lua_pushfstring( L, "Tables must be of same length." );
9804  SWIG_fail;
9805  }
9806  }
9807  arg5 = (char *)lua_tostring(L, 4);
9808  plstring3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4,(char const *)arg5);
9809 
9810  {
9811  LUA_FREE_ARRAY( arg2 );
9812  }
9813  {
9814  LUA_FREE_ARRAY( arg3 );
9815  }
9816  {
9817  LUA_FREE_ARRAY( arg4 );
9818  }
9819  return SWIG_arg;
9820 
9821  if(0) SWIG_fail;
9822 
9823 fail:
9824  {
9825  LUA_FREE_ARRAY( arg2 );
9826  }
9827  {
9828  LUA_FREE_ARRAY( arg3 );
9829  }
9830  {
9831  LUA_FREE_ARRAY( arg4 );
9832  }
9833  lua_error(L);
9834  return SWIG_arg;
9835 }
9836 
9837 
9838 static int _wrap_stripa(lua_State* L) {
9839  int SWIG_arg = 0;
9840  PLINT arg1 ;
9841  PLINT arg2 ;
9842  PLFLT arg3 ;
9843  PLFLT arg4 ;
9844 
9845  SWIG_check_num_args("plstripa",4,4)
9846  if(!lua_isnumber(L,1)) SWIG_fail_arg("plstripa",1,"PLINT");
9847  if(!lua_isnumber(L,2)) SWIG_fail_arg("plstripa",2,"PLINT");
9848  if(!lua_isnumber(L,3)) SWIG_fail_arg("plstripa",3,"PLFLT");
9849  if(!lua_isnumber(L,4)) SWIG_fail_arg("plstripa",4,"PLFLT");
9850  arg1 = (PLINT)lua_tonumber(L, 1);
9851  arg2 = (PLINT)lua_tonumber(L, 2);
9852  arg3 = (PLFLT)lua_tonumber(L, 3);
9853  arg4 = (PLFLT)lua_tonumber(L, 4);
9854  plstripa(arg1,arg2,arg3,arg4);
9855 
9856  return SWIG_arg;
9857 
9858  if(0) SWIG_fail;
9859 
9860 fail:
9861  lua_error(L);
9862  return SWIG_arg;
9863 }
9864 
9865 
9866 static int _wrap_stripc(lua_State* L) {
9867  int SWIG_arg = 0;
9868  PLINT *arg1 = (PLINT *) 0 ;
9869  char *arg2 = (char *) 0 ;
9870  char *arg3 = (char *) 0 ;
9871  PLFLT arg4 ;
9872  PLFLT arg5 ;
9873  PLFLT arg6 ;
9874  PLFLT arg7 ;
9875  PLFLT arg8 ;
9876  PLFLT arg9 ;
9877  PLFLT arg10 ;
9878  PLBOOL arg11 ;
9879  PLBOOL arg12 ;
9880  PLINT arg13 ;
9881  PLINT arg14 ;
9882  PLINT *arg15 = (PLINT *) 0 ;
9883  PLINT *arg16 = (PLINT *) 0 ;
9884  char **arg17 ;
9885  char *arg18 = (char *) 0 ;
9886  char *arg19 = (char *) 0 ;
9887  char *arg20 = (char *) 0 ;
9888  PLINT temp1 ;
9889  int temp15 ;
9890  int temp16 ;
9891 
9892  {
9893  arg17 = NULL;
9894  }
9895  arg1 = &temp1;
9896  SWIG_check_num_args("plstripc",15,19)
9897  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plstripc",1,"char const *");
9898  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plstripc",2,"char const *");
9899  if(!lua_isnumber(L,3)) SWIG_fail_arg("plstripc",3,"PLFLT");
9900  if(!lua_isnumber(L,4)) SWIG_fail_arg("plstripc",4,"PLFLT");
9901  if(!lua_isnumber(L,5)) SWIG_fail_arg("plstripc",5,"PLFLT");
9902  if(!lua_isnumber(L,6)) SWIG_fail_arg("plstripc",6,"PLFLT");
9903  if(!lua_isnumber(L,7)) SWIG_fail_arg("plstripc",7,"PLFLT");
9904  if(!lua_isnumber(L,8)) SWIG_fail_arg("plstripc",8,"PLFLT");
9905  if(!lua_isnumber(L,9)) SWIG_fail_arg("plstripc",9,"PLFLT");
9906  if(!lua_isnumber(L,10)) SWIG_fail_arg("plstripc",10,"PLBOOL");
9907  if(!lua_isnumber(L,11)) SWIG_fail_arg("plstripc",11,"PLBOOL");
9908  if(!lua_isnumber(L,12)) SWIG_fail_arg("plstripc",12,"PLINT");
9909  if(!lua_isnumber(L,13)) SWIG_fail_arg("plstripc",13,"PLINT");
9910  if(lua_gettop(L)>=16 && !lua_istable(L,16)) SWIG_fail_arg("plstripc",16,"char const *[4]");
9911  if(lua_gettop(L)>=17 && !SWIG_lua_isnilstring(L,17)) SWIG_fail_arg("plstripc",17,"char const *");
9912  if(lua_gettop(L)>=18 && !SWIG_lua_isnilstring(L,18)) SWIG_fail_arg("plstripc",18,"char const *");
9913  if(lua_gettop(L)>=19 && !SWIG_lua_isnilstring(L,19)) SWIG_fail_arg("plstripc",19,"char const *");
9914  arg2 = (char *)lua_tostring(L, 1);
9915  arg3 = (char *)lua_tostring(L, 2);
9916  arg4 = (PLFLT)lua_tonumber(L, 3);
9917  arg5 = (PLFLT)lua_tonumber(L, 4);
9918  arg6 = (PLFLT)lua_tonumber(L, 5);
9919  arg7 = (PLFLT)lua_tonumber(L, 6);
9920  arg8 = (PLFLT)lua_tonumber(L, 7);
9921  arg9 = (PLFLT)lua_tonumber(L, 8);
9922  arg10 = (PLFLT)lua_tonumber(L, 9);
9923  arg11 = (PLBOOL)lua_tonumber(L, 10);
9924  arg12 = (PLBOOL)lua_tonumber(L, 11);
9925  arg13 = (PLINT)lua_tonumber(L, 12);
9926  arg14 = (PLINT)lua_tonumber(L, 13);
9927  {
9928  arg15 = (PLINT *) LUA_get_int_num_array_var( L, 14, &temp15 );
9929  if ( !arg15 )
9930  SWIG_fail;
9931  Alen = temp15;
9932  }
9933  {
9934  arg16 = (PLINT *) LUA_get_int_num_array_var( L, 15, &temp16 );
9935  if ( !arg16 )
9936  SWIG_fail;
9937  if ( temp16 != Alen )
9938  {
9939  lua_pushfstring( L, "Tables must be of same length." );
9940  SWIG_fail;
9941  }
9942  }
9943  if(lua_gettop(L)>=16){
9944  {
9945  int i;
9946  arg17 = NULL;
9947 
9948  if ( SWIG_table_size( L, 16 ) != 4 )
9949  {
9950  lua_pushfstring( L, "Requires a sequence of 4 strings." );
9951  SWIG_fail;
9952  }
9953  if ( Alen != 4 )
9954  {
9955  lua_pushfstring( L, "colline and styline args must be length 4." );
9956  SWIG_fail;
9957  }
9958 
9959  arg17 = malloc( sizeof ( char* ) * 4 );
9960  for ( i = 1; i <= 4; i++ )
9961  {
9962  lua_rawgeti( L, 16, i );
9963  if ( lua_isstring( L, -1 ) )
9964  {
9965  arg17[i - 1] = (char *) lua_tostring( L, -1 );
9966  }
9967  else
9968  {
9969  lua_pop( L, 1 );
9970  lua_pushfstring( L, "Requires a sequence of 4 strings." );
9971  SWIG_fail;
9972  // arg17 array is freed after 'fail:'
9973  }
9974  lua_pop( L, 1 );
9975  }
9976  }
9977  }
9978  if(lua_gettop(L)>=17){
9979  arg18 = (char *)lua_tostring(L, 17);
9980  }
9981  if(lua_gettop(L)>=18){
9982  arg19 = (char *)lua_tostring(L, 18);
9983  }
9984  if(lua_gettop(L)>=19){
9985  arg20 = (char *)lua_tostring(L, 19);
9986  }
9987  plstripc(arg1,(char const *)arg2,(char const *)arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13,arg14,(int const *)arg15,(int const *)arg16,(char const *(*))arg17,(char const *)arg18,(char const *)arg19,(char const *)arg20);
9988 
9989  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
9990  {
9991  LUA_FREE_ARRAY( arg15 );
9992  }
9993  {
9994  LUA_FREE_ARRAY( arg16 );
9995  }
9996  {
9997  if ( arg17 )
9998  {
9999  free( arg17 ); arg17 = NULL;
10000  }
10001  }
10002  return SWIG_arg;
10003 
10004  if(0) SWIG_fail;
10005 
10006 fail:
10007  {
10008  LUA_FREE_ARRAY( arg15 );
10009  }
10010  {
10011  LUA_FREE_ARRAY( arg16 );
10012  }
10013  {
10014  if ( arg17 )
10015  {
10016  free( arg17 ); arg17 = NULL;
10017  }
10018  }
10019  lua_error(L);
10020  return SWIG_arg;
10021 }
10022 
10023 
10024 static int _wrap_stripd(lua_State* L) {
10025  int SWIG_arg = 0;
10026  PLINT arg1 ;
10027 
10028  SWIG_check_num_args("plstripd",1,1)
10029  if(!lua_isnumber(L,1)) SWIG_fail_arg("plstripd",1,"PLINT");
10030  arg1 = (PLINT)lua_tonumber(L, 1);
10031  plstripd(arg1);
10032 
10033  return SWIG_arg;
10034 
10035  if(0) SWIG_fail;
10036 
10037 fail:
10038  lua_error(L);
10039  return SWIG_arg;
10040 }
10041 
10042 
10043 static int _wrap_styl(lua_State* L) {
10044  int SWIG_arg = 0;
10045  PLINT arg1 ;
10046  PLINT *arg2 = (PLINT *) 0 ;
10047  PLINT *arg3 = (PLINT *) 0 ;
10048  int temp3 ;
10049 
10050  SWIG_check_num_args("plstyl",2,2)
10051  {
10052  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 1, &arg1 );
10053  if ( !arg2 )
10054  SWIG_fail;
10055  Alen = arg1;
10056  }
10057  {
10058  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp3 );
10059  if ( !arg3 )
10060  SWIG_fail;
10061  if ( temp3 != Alen )
10062  {
10063  lua_pushfstring( L, "Tables must be of same length." );
10064  SWIG_fail;
10065  }
10066  }
10067  plstyl(arg1,(int const *)arg2,(int const *)arg3);
10068 
10069  {
10070  LUA_FREE_ARRAY( arg2 );
10071  }
10072  {
10073  LUA_FREE_ARRAY( arg3 );
10074  }
10075  return SWIG_arg;
10076 
10077  if(0) SWIG_fail;
10078 
10079 fail:
10080  {
10081  LUA_FREE_ARRAY( arg2 );
10082  }
10083  {
10084  LUA_FREE_ARRAY( arg3 );
10085  }
10086  lua_error(L);
10087  return SWIG_arg;
10088 }
10089 
10090 
10091 static int _wrap_svect(lua_State* L) {
10092  int SWIG_arg = 0;
10093  PLFLT *arg1 = (PLFLT *) 0 ;
10094  PLFLT *arg2 = (PLFLT *) 0 ;
10095  PLINT arg3 ;
10096  PLBOOL arg4 ;
10097 
10098  {
10099  arg2 = NULL; arg3 = 0;
10100  }
10101  {
10102  arg4 = 0;
10103  }
10104  SWIG_check_num_args("plsvect",1,3)
10105  if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("plsvect",3,"PLBOOL");
10106  {
10107  int temp;
10108  if ( lua_isnil( L, 1 ) )
10109  {
10110  arg1 = NULL;
10111  Alen = 0;
10112  }
10113  else
10114  {
10115  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
10116  if ( !arg1 )
10117  SWIG_fail;
10118  Alen = temp;
10119  }
10120  }
10121  if(lua_gettop(L)>=2){
10122  {
10123  int temp = 0;
10124  if ( lua_isnil( L, 2 ) )
10125  {
10126  arg2 = NULL;
10127  }
10128  else
10129  {
10130  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
10131  if ( !arg2 )
10132  SWIG_fail;
10133  if ( temp != Alen )
10134  {
10135  lua_pushfstring( L, "Tables must be of same length." );
10136  SWIG_fail;
10137  }
10138  }
10139  arg3 = temp;
10140  }
10141  }
10142  if(lua_gettop(L)>=3){
10143  arg4 = (PLBOOL)lua_tonumber(L, 3);
10144  }
10145  plsvect((double const *)arg1,(double const *)arg2,arg3,arg4);
10146 
10147  {
10148  LUA_FREE_ARRAY( arg2 );
10149  }
10150  return SWIG_arg;
10151 
10152  if(0) SWIG_fail;
10153 
10154 fail:
10155  {
10156  LUA_FREE_ARRAY( arg2 );
10157  }
10158  lua_error(L);
10159  return SWIG_arg;
10160 }
10161 
10162 
10163 static int _wrap_svpa(lua_State* L) {
10164  int SWIG_arg = 0;
10165  PLFLT arg1 ;
10166  PLFLT arg2 ;
10167  PLFLT arg3 ;
10168  PLFLT arg4 ;
10169 
10170  SWIG_check_num_args("plsvpa",4,4)
10171  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsvpa",1,"PLFLT");
10172  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsvpa",2,"PLFLT");
10173  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsvpa",3,"PLFLT");
10174  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsvpa",4,"PLFLT");
10175  arg1 = (PLFLT)lua_tonumber(L, 1);
10176  arg2 = (PLFLT)lua_tonumber(L, 2);
10177  arg3 = (PLFLT)lua_tonumber(L, 3);
10178  arg4 = (PLFLT)lua_tonumber(L, 4);
10179  plsvpa(arg1,arg2,arg3,arg4);
10180 
10181  return SWIG_arg;
10182 
10183  if(0) SWIG_fail;
10184 
10185 fail:
10186  lua_error(L);
10187  return SWIG_arg;
10188 }
10189 
10190 
10191 static int _wrap_sxax(lua_State* L) {
10192  int SWIG_arg = 0;
10193  PLINT arg1 ;
10194  PLINT arg2 ;
10195 
10196  SWIG_check_num_args("plsxax",2,2)
10197  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsxax",1,"PLINT");
10198  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsxax",2,"PLINT");
10199  arg1 = (PLINT)lua_tonumber(L, 1);
10200  arg2 = (PLINT)lua_tonumber(L, 2);
10201  plsxax(arg1,arg2);
10202 
10203  return SWIG_arg;
10204 
10205  if(0) SWIG_fail;
10206 
10207 fail:
10208  lua_error(L);
10209  return SWIG_arg;
10210 }
10211 
10212 
10213 static int _wrap_syax(lua_State* L) {
10214  int SWIG_arg = 0;
10215  PLINT arg1 ;
10216  PLINT arg2 ;
10217 
10218  SWIG_check_num_args("plsyax",2,2)
10219  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsyax",1,"PLINT");
10220  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsyax",2,"PLINT");
10221  arg1 = (PLINT)lua_tonumber(L, 1);
10222  arg2 = (PLINT)lua_tonumber(L, 2);
10223  plsyax(arg1,arg2);
10224 
10225  return SWIG_arg;
10226 
10227  if(0) SWIG_fail;
10228 
10229 fail:
10230  lua_error(L);
10231  return SWIG_arg;
10232 }
10233 
10234 
10235 static int _wrap_sym(lua_State* L) {
10236  int SWIG_arg = 0;
10237  PLINT arg1 ;
10238  PLFLT *arg2 = (PLFLT *) 0 ;
10239  PLFLT *arg3 = (PLFLT *) 0 ;
10240  PLINT arg4 ;
10241  int temp3 ;
10242 
10243  SWIG_check_num_args("plsym",3,3)
10244  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsym",3,"PLINT");
10245  {
10246  int temp;
10247  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
10248  if ( !arg2 )
10249  SWIG_fail;
10250  arg1 = Alen = temp;
10251  }
10252  {
10253  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
10254  if ( !arg3 )
10255  SWIG_fail;
10256  if ( temp3 != Alen )
10257  {
10258  lua_pushfstring( L, "Tables must be of same length." );
10259  SWIG_fail;
10260  }
10261  }
10262  arg4 = (PLINT)lua_tonumber(L, 3);
10263  plsym(arg1,(double const *)arg2,(double const *)arg3,arg4);
10264 
10265  {
10266  LUA_FREE_ARRAY( arg2 );
10267  }
10268  {
10269  LUA_FREE_ARRAY( arg3 );
10270  }
10271  return SWIG_arg;
10272 
10273  if(0) SWIG_fail;
10274 
10275 fail:
10276  {
10277  LUA_FREE_ARRAY( arg2 );
10278  }
10279  {
10280  LUA_FREE_ARRAY( arg3 );
10281  }
10282  lua_error(L);
10283  return SWIG_arg;
10284 }
10285 
10286 
10287 static int _wrap_szax(lua_State* L) {
10288  int SWIG_arg = 0;
10289  PLINT arg1 ;
10290  PLINT arg2 ;
10291 
10292  SWIG_check_num_args("plszax",2,2)
10293  if(!lua_isnumber(L,1)) SWIG_fail_arg("plszax",1,"PLINT");
10294  if(!lua_isnumber(L,2)) SWIG_fail_arg("plszax",2,"PLINT");
10295  arg1 = (PLINT)lua_tonumber(L, 1);
10296  arg2 = (PLINT)lua_tonumber(L, 2);
10297  plszax(arg1,arg2);
10298 
10299  return SWIG_arg;
10300 
10301  if(0) SWIG_fail;
10302 
10303 fail:
10304  lua_error(L);
10305  return SWIG_arg;
10306 }
10307 
10308 
10309 static int _wrap_text(lua_State* L) {
10310  int SWIG_arg = 0;
10311 
10312  SWIG_check_num_args("pltext",0,0)
10313  pltext();
10314 
10315  return SWIG_arg;
10316 
10317  if(0) SWIG_fail;
10318 
10319 fail:
10320  lua_error(L);
10321  return SWIG_arg;
10322 }
10323 
10324 
10325 static int _wrap_timefmt(lua_State* L) {
10326  int SWIG_arg = 0;
10327  char *arg1 = (char *) 0 ;
10328 
10329  SWIG_check_num_args("pltimefmt",1,1)
10330  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("pltimefmt",1,"char const *");
10331  arg1 = (char *)lua_tostring(L, 1);
10332  pltimefmt((char const *)arg1);
10333 
10334  return SWIG_arg;
10335 
10336  if(0) SWIG_fail;
10337 
10338 fail:
10339  lua_error(L);
10340  return SWIG_arg;
10341 }
10342 
10343 
10344 static int _wrap_vasp(lua_State* L) {
10345  int SWIG_arg = 0;
10346  PLFLT arg1 ;
10347 
10348  SWIG_check_num_args("plvasp",1,1)
10349  if(!lua_isnumber(L,1)) SWIG_fail_arg("plvasp",1,"PLFLT");
10350  arg1 = (PLFLT)lua_tonumber(L, 1);
10351  plvasp(arg1);
10352 
10353  return SWIG_arg;
10354 
10355  if(0) SWIG_fail;
10356 
10357 fail:
10358  lua_error(L);
10359  return SWIG_arg;
10360 }
10361 
10362 
10363 static int _wrap_vect(lua_State* L) {
10364  int SWIG_arg = 0;
10365  PLFLT **arg1 = (PLFLT **) 0 ;
10366  PLFLT **arg2 = (PLFLT **) 0 ;
10367  PLINT arg3 ;
10368  PLINT arg4 ;
10369  PLFLT arg5 ;
10370  pltr_func arg6 = (pltr_func) 0 ;
10371  PLPointer arg7 = (PLPointer) 0 ;
10372  int ii1 ;
10373  int ii2 ;
10374  PLcGrid cgrid17 ;
10375  PLcGrid2 cgrid27 ;
10376 
10377  {
10378  cgrid17.xg = cgrid17.yg = cgrid17.zg = NULL;
10379  cgrid17.nx = cgrid17.ny = cgrid17.nz = 0;
10380  cgrid27.xg = cgrid27.yg = cgrid27.zg = NULL;
10381  cgrid27.nx = cgrid27.ny = 0;
10382  }
10383  {
10384  arg6 = NULL;
10385  }
10386  {
10387  arg7 = NULL;
10388  }
10389  SWIG_check_num_args("plvect",3,5)
10390  if(!lua_isnumber(L,3)) SWIG_fail_arg("plvect",3,"PLFLT");
10391  {
10392  int jj;
10393 
10394  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
10395  if ( !arg1 )
10396  SWIG_fail;
10397  Xlen = ii1;
10398  Ylen = jj;
10399  }
10400  {
10401  int jj;
10402 
10403  arg2 = read_double_Matrix( L, 2, &ii2, &jj );
10404  if ( !arg2 )
10405  SWIG_fail;
10406  arg3 = ii2;
10407  arg4 = jj;
10408  if ( ( arg3 != Xlen ) || ( arg4 != Ylen ) )
10409  {
10410  lua_pushfstring( L, "Vectors must match matrix." );
10411  SWIG_fail;
10412  }
10413  }
10414  arg5 = (PLFLT)lua_tonumber(L, 3);
10415  if(lua_gettop(L)>=4){
10416  {
10417  arg6 = NULL;
10418  mypltr_funcstr[0] = '\0';
10419 
10420  if ( lua_isstring( L, 4 ) )
10421  {
10422  const char* funcstr = lua_tostring( L, 4 );
10423  if ( strcmp( "pltr0", funcstr ) == 0 )
10424  {
10425  arg6 = pltr0;
10426  }
10427  else if ( strcmp( "pltr1", funcstr ) == 0 )
10428  {
10429  arg6 = pltr1;
10430  }
10431  else if ( strcmp( "pltr2", funcstr ) == 0 )
10432  {
10433  arg6 = pltr2;
10434  }
10435  else
10436  {
10437  arg6 = mypltr;
10438  strncpy( mypltr_funcstr, funcstr, 255 );
10439  myL = L;
10440  }
10441  }
10442  else
10443  SWIG_fail_arg( "vect", 6, "pltr_func" );
10444  }
10445  }
10446  if(lua_gettop(L)>=5){
10447  {
10448  int nx, ny;
10449  int gridmode = 0;
10450 
10451  lua_pushstring( L, "xg" );
10452  lua_gettable( L, 5 );
10453  if ( !lua_istable( L, -1 ) )
10454  {
10455  lua_pop( L, 1 ); // pop "xg"
10456  lua_pushstring( L, "expected a table xg" );
10457  SWIG_fail;
10458  }
10459  lua_rawgeti( L, -1, 1 );
10460  if ( lua_istable( L, -1 ) )
10461  gridmode = 2; // two dimensional array
10462  else if ( lua_isnumber( L, -1 ) )
10463  gridmode = 1; // one dimensional array
10464  else
10465  {
10466  lua_pop( L, 1 ); // pop "1"
10467  lua_pop( L, 1 ); // pop "xg"
10468  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
10469  SWIG_fail;
10470  }
10471  lua_pop( L, 1 ); // pop test element
10472  if ( gridmode == 1 )
10473  {
10474  cgrid17.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
10475  if ( !cgrid17.xg )
10476  {
10477  lua_pop( L, 1 ); // pop "xg"
10478  SWIG_fail;
10479  }
10480  if ( nx != Xlen )
10481  {
10482  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
10483  SWIG_fail;
10484  }
10485  cgrid17.nx = nx;
10486  }
10487  else
10488  {
10489  cgrid27.xg = read_double_Matrix( L, -1, &nx, &ny );
10490  if ( !cgrid27.xg )
10491  {
10492  lua_pop( L, 1 ); // pop "xg"
10493  SWIG_fail;
10494  }
10495  if ( ( nx != Xlen ) || ( ny != Ylen ) )
10496  {
10497  lua_pop( L, 1 ); // pop "xg"
10498  lua_pushfstring( L, "Vectors must match matrix." );
10499  SWIG_fail;
10500  }
10501  cgrid27.nx = nx;
10502  cgrid27.ny = ny;
10503  }
10504  lua_pop( L, 1 ); // pop "xg"
10505 
10506  lua_pushstring( L, "yg" );
10507  lua_gettable( L, 5 );
10508  if ( !lua_istable( L, -1 ) )
10509  {
10510  lua_pop( L, 1 );
10511  lua_pushstring( L, "expected a table yg" );
10512  SWIG_fail;
10513  }
10514  lua_rawgeti( L, -1, 1 );
10515  if ( gridmode == 2 )
10516  {
10517  if ( !lua_istable( L, -1 ) )
10518  {
10519  lua_pop( L, 1 ); // pop "1"
10520  lua_pop( L, 1 ); // pop "yg"
10521  lua_pushstring( L, "expected a two dimensional array/table in yg" );
10522  SWIG_fail;
10523  }
10524  }
10525  else
10526  {
10527  if ( !lua_isnumber( L, -1 ) )
10528  {
10529  lua_pop( L, 1 ); // pop "1"
10530  lua_pop( L, 1 ); // pop "yg"
10531  lua_pushstring( L, "expected a one dimensional array/table in yg" );
10532  SWIG_fail;
10533  }
10534  }
10535  lua_pop( L, 1 ); // pop "1"
10536  if ( gridmode == 1 )
10537  {
10538  cgrid17.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
10539  if ( !cgrid17.yg )
10540  {
10541  lua_pop( L, 1 ); // pop "yg"
10542  SWIG_fail;
10543  }
10544  if ( ny != Ylen )
10545  {
10546  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
10547  SWIG_fail;
10548  }
10549  cgrid17.ny = ny;
10550  }
10551  else
10552  {
10553  cgrid27.yg = read_double_Matrix( L, -1, &nx, &ny );
10554  if ( !cgrid27.yg )
10555  {
10556  lua_pop( L, 1 ); // pop "xg"
10557  SWIG_fail;
10558  }
10559  if ( ( nx != Xlen ) || ( ny != Ylen ) )
10560  {
10561  lua_pop( L, 1 ); // pop "xg"
10562  lua_pushfstring( L, "Vectors must match matrix." );
10563  SWIG_fail;
10564  }
10565  // cgrid27.nx/ny already set
10566  }
10567  lua_pop( L, 1 ); // pop "yg"
10568 
10569  if ( gridmode == 1 )
10570  arg7 = &cgrid17;
10571  else if ( gridmode == 2 )
10572  arg7 = &cgrid27;
10573  }
10574  }
10575  plvect((double const **)arg1,(double const **)arg2,arg3,arg4,arg5,arg6,arg7);
10576 
10577  {
10578  int i;
10579 
10580  if ( arg1 )
10581  {
10582  for ( i = 0; i < ii1; i++ )
10583  LUA_FREE_ARRAY( arg1[i] );
10584  LUA_FREE_ARRAY( arg1 );
10585  }
10586  }
10587  {
10588  int i;
10589 
10590  if ( arg2 )
10591  {
10592  for ( i = 0; i < ii2; i++ )
10593  LUA_FREE_ARRAY( arg2[i] );
10594  LUA_FREE_ARRAY( arg2 );
10595  }
10596  }
10597  {
10598  mypltr_funcstr[0] = '\0';
10599  }
10600  {
10601  int i;
10602 
10603  LUA_FREE_ARRAY( cgrid17.xg );
10604  LUA_FREE_ARRAY( cgrid17.yg );
10605 
10606  if ( cgrid27.xg )
10607  {
10608  for ( i = 0; i < Xlen; i++ )
10609  LUA_FREE_ARRAY( cgrid27.xg[i] );
10610  LUA_FREE_ARRAY( cgrid27.xg );
10611  }
10612  if ( cgrid27.yg )
10613  {
10614  for ( i = 0; i < Xlen; i++ )
10615  LUA_FREE_ARRAY( cgrid27.yg[i] );
10616  LUA_FREE_ARRAY( cgrid27.yg );
10617  }
10618  }
10619  return SWIG_arg;
10620 
10621  if(0) SWIG_fail;
10622 
10623 fail:
10624  {
10625  int i;
10626 
10627  if ( arg1 )
10628  {
10629  for ( i = 0; i < ii1; i++ )
10630  LUA_FREE_ARRAY( arg1[i] );
10631  LUA_FREE_ARRAY( arg1 );
10632  }
10633  }
10634  {
10635  int i;
10636 
10637  if ( arg2 )
10638  {
10639  for ( i = 0; i < ii2; i++ )
10640  LUA_FREE_ARRAY( arg2[i] );
10641  LUA_FREE_ARRAY( arg2 );
10642  }
10643  }
10644  {
10645  mypltr_funcstr[0] = '\0';
10646  }
10647  {
10648  int i;
10649 
10650  LUA_FREE_ARRAY( cgrid17.xg );
10651  LUA_FREE_ARRAY( cgrid17.yg );
10652 
10653  if ( cgrid27.xg )
10654  {
10655  for ( i = 0; i < Xlen; i++ )
10656  LUA_FREE_ARRAY( cgrid27.xg[i] );
10657  LUA_FREE_ARRAY( cgrid27.xg );
10658  }
10659  if ( cgrid27.yg )
10660  {
10661  for ( i = 0; i < Xlen; i++ )
10662  LUA_FREE_ARRAY( cgrid27.yg[i] );
10663  LUA_FREE_ARRAY( cgrid27.yg );
10664  }
10665  }
10666  lua_error(L);
10667  return SWIG_arg;
10668 }
10669 
10670 
10671 static int _wrap_vpas(lua_State* L) {
10672  int SWIG_arg = 0;
10673  PLFLT arg1 ;
10674  PLFLT arg2 ;
10675  PLFLT arg3 ;
10676  PLFLT arg4 ;
10677  PLFLT arg5 ;
10678 
10679  SWIG_check_num_args("plvpas",5,5)
10680  if(!lua_isnumber(L,1)) SWIG_fail_arg("plvpas",1,"PLFLT");
10681  if(!lua_isnumber(L,2)) SWIG_fail_arg("plvpas",2,"PLFLT");
10682  if(!lua_isnumber(L,3)) SWIG_fail_arg("plvpas",3,"PLFLT");
10683  if(!lua_isnumber(L,4)) SWIG_fail_arg("plvpas",4,"PLFLT");
10684  if(!lua_isnumber(L,5)) SWIG_fail_arg("plvpas",5,"PLFLT");
10685  arg1 = (PLFLT)lua_tonumber(L, 1);
10686  arg2 = (PLFLT)lua_tonumber(L, 2);
10687  arg3 = (PLFLT)lua_tonumber(L, 3);
10688  arg4 = (PLFLT)lua_tonumber(L, 4);
10689  arg5 = (PLFLT)lua_tonumber(L, 5);
10690  plvpas(arg1,arg2,arg3,arg4,arg5);
10691 
10692  return SWIG_arg;
10693 
10694  if(0) SWIG_fail;
10695 
10696 fail:
10697  lua_error(L);
10698  return SWIG_arg;
10699 }
10700 
10701 
10702 static int _wrap_vpor(lua_State* L) {
10703  int SWIG_arg = 0;
10704  PLFLT arg1 ;
10705  PLFLT arg2 ;
10706  PLFLT arg3 ;
10707  PLFLT arg4 ;
10708 
10709  SWIG_check_num_args("plvpor",4,4)
10710  if(!lua_isnumber(L,1)) SWIG_fail_arg("plvpor",1,"PLFLT");
10711  if(!lua_isnumber(L,2)) SWIG_fail_arg("plvpor",2,"PLFLT");
10712  if(!lua_isnumber(L,3)) SWIG_fail_arg("plvpor",3,"PLFLT");
10713  if(!lua_isnumber(L,4)) SWIG_fail_arg("plvpor",4,"PLFLT");
10714  arg1 = (PLFLT)lua_tonumber(L, 1);
10715  arg2 = (PLFLT)lua_tonumber(L, 2);
10716  arg3 = (PLFLT)lua_tonumber(L, 3);
10717  arg4 = (PLFLT)lua_tonumber(L, 4);
10718  plvpor(arg1,arg2,arg3,arg4);
10719 
10720  return SWIG_arg;
10721 
10722  if(0) SWIG_fail;
10723 
10724 fail:
10725  lua_error(L);
10726  return SWIG_arg;
10727 }
10728 
10729 
10730 static int _wrap_vsta(lua_State* L) {
10731  int SWIG_arg = 0;
10732 
10733  SWIG_check_num_args("plvsta",0,0)
10734  plvsta();
10735 
10736  return SWIG_arg;
10737 
10738  if(0) SWIG_fail;
10739 
10740 fail:
10741  lua_error(L);
10742  return SWIG_arg;
10743 }
10744 
10745 
10746 static int _wrap_w3d(lua_State* L) {
10747  int SWIG_arg = 0;
10748  PLFLT arg1 ;
10749  PLFLT arg2 ;
10750  PLFLT arg3 ;
10751  PLFLT arg4 ;
10752  PLFLT arg5 ;
10753  PLFLT arg6 ;
10754  PLFLT arg7 ;
10755  PLFLT arg8 ;
10756  PLFLT arg9 ;
10757  PLFLT arg10 ;
10758  PLFLT arg11 ;
10759 
10760  SWIG_check_num_args("plw3d",11,11)
10761  if(!lua_isnumber(L,1)) SWIG_fail_arg("plw3d",1,"PLFLT");
10762  if(!lua_isnumber(L,2)) SWIG_fail_arg("plw3d",2,"PLFLT");
10763  if(!lua_isnumber(L,3)) SWIG_fail_arg("plw3d",3,"PLFLT");
10764  if(!lua_isnumber(L,4)) SWIG_fail_arg("plw3d",4,"PLFLT");
10765  if(!lua_isnumber(L,5)) SWIG_fail_arg("plw3d",5,"PLFLT");
10766  if(!lua_isnumber(L,6)) SWIG_fail_arg("plw3d",6,"PLFLT");
10767  if(!lua_isnumber(L,7)) SWIG_fail_arg("plw3d",7,"PLFLT");
10768  if(!lua_isnumber(L,8)) SWIG_fail_arg("plw3d",8,"PLFLT");
10769  if(!lua_isnumber(L,9)) SWIG_fail_arg("plw3d",9,"PLFLT");
10770  if(!lua_isnumber(L,10)) SWIG_fail_arg("plw3d",10,"PLFLT");
10771  if(!lua_isnumber(L,11)) SWIG_fail_arg("plw3d",11,"PLFLT");
10772  arg1 = (PLFLT)lua_tonumber(L, 1);
10773  arg2 = (PLFLT)lua_tonumber(L, 2);
10774  arg3 = (PLFLT)lua_tonumber(L, 3);
10775  arg4 = (PLFLT)lua_tonumber(L, 4);
10776  arg5 = (PLFLT)lua_tonumber(L, 5);
10777  arg6 = (PLFLT)lua_tonumber(L, 6);
10778  arg7 = (PLFLT)lua_tonumber(L, 7);
10779  arg8 = (PLFLT)lua_tonumber(L, 8);
10780  arg9 = (PLFLT)lua_tonumber(L, 9);
10781  arg10 = (PLFLT)lua_tonumber(L, 10);
10782  arg11 = (PLFLT)lua_tonumber(L, 11);
10783  plw3d(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11);
10784 
10785  return SWIG_arg;
10786 
10787  if(0) SWIG_fail;
10788 
10789 fail:
10790  lua_error(L);
10791  return SWIG_arg;
10792 }
10793 
10794 
10795 static int _wrap_width(lua_State* L) {
10796  int SWIG_arg = 0;
10797  PLFLT arg1 ;
10798 
10799  SWIG_check_num_args("plwidth",1,1)
10800  if(!lua_isnumber(L,1)) SWIG_fail_arg("plwidth",1,"PLFLT");
10801  arg1 = (PLFLT)lua_tonumber(L, 1);
10802  plwidth(arg1);
10803 
10804  return SWIG_arg;
10805 
10806  if(0) SWIG_fail;
10807 
10808 fail:
10809  lua_error(L);
10810  return SWIG_arg;
10811 }
10812 
10813 
10814 static int _wrap_wind(lua_State* L) {
10815  int SWIG_arg = 0;
10816  PLFLT arg1 ;
10817  PLFLT arg2 ;
10818  PLFLT arg3 ;
10819  PLFLT arg4 ;
10820 
10821  SWIG_check_num_args("plwind",4,4)
10822  if(!lua_isnumber(L,1)) SWIG_fail_arg("plwind",1,"PLFLT");
10823  if(!lua_isnumber(L,2)) SWIG_fail_arg("plwind",2,"PLFLT");
10824  if(!lua_isnumber(L,3)) SWIG_fail_arg("plwind",3,"PLFLT");
10825  if(!lua_isnumber(L,4)) SWIG_fail_arg("plwind",4,"PLFLT");
10826  arg1 = (PLFLT)lua_tonumber(L, 1);
10827  arg2 = (PLFLT)lua_tonumber(L, 2);
10828  arg3 = (PLFLT)lua_tonumber(L, 3);
10829  arg4 = (PLFLT)lua_tonumber(L, 4);
10830  plwind(arg1,arg2,arg3,arg4);
10831 
10832  return SWIG_arg;
10833 
10834  if(0) SWIG_fail;
10835 
10836 fail:
10837  lua_error(L);
10838  return SWIG_arg;
10839 }
10840 
10841 
10842 static int _wrap_xormod(lua_State* L) {
10843  int SWIG_arg = 0;
10844  PLBOOL arg1 ;
10845  PLBOOL *arg2 = (PLBOOL *) 0 ;
10846  PLBOOL temp2 ;
10847 
10848  arg2 = &temp2;
10849  SWIG_check_num_args("plxormod",1,1)
10850  if(!lua_isnumber(L,1)) SWIG_fail_arg("plxormod",1,"PLBOOL");
10851  arg1 = (PLBOOL)lua_tonumber(L, 1);
10852  plxormod(arg1,arg2);
10853 
10854  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
10855  return SWIG_arg;
10856 
10857  if(0) SWIG_fail;
10858 
10859 fail:
10860  lua_error(L);
10861  return SWIG_arg;
10862 }
10863 
10864 
10865 static int _wrap_map(lua_State* L) {
10866  int SWIG_arg = 0;
10867  mapform_func arg1 = (mapform_func) 0 ;
10868  char *arg2 = (char *) 0 ;
10869  PLFLT arg3 ;
10870  PLFLT arg4 ;
10871  PLFLT arg5 ;
10872  PLFLT arg6 ;
10873 
10874  SWIG_check_num_args("plmap",6,6)
10875  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmap",2,"char const *");
10876  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmap",3,"PLFLT");
10877  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmap",4,"PLFLT");
10878  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmap",5,"PLFLT");
10879  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmap",6,"PLFLT");
10880  {
10881  arg1 = NULL;
10882  mapform_funcstr[0] = '\0';
10883 
10884  if ( lua_isnil( L, 1 ) )
10885  {
10886  arg1 = NULL;
10887  }
10888  else if ( lua_isstring( L, 1 ) )
10889  {
10890  arg1 = mapform;
10891  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
10892  myL = L;
10893  }
10894  else
10895  SWIG_fail_arg( "map", 1, "mapform_func" );
10896  }
10897  arg2 = (char *)lua_tostring(L, 2);
10898  arg3 = (PLFLT)lua_tonumber(L, 3);
10899  arg4 = (PLFLT)lua_tonumber(L, 4);
10900  arg5 = (PLFLT)lua_tonumber(L, 5);
10901  arg6 = (PLFLT)lua_tonumber(L, 6);
10902  plmap(arg1,(char const *)arg2,arg3,arg4,arg5,arg6);
10903 
10904  {
10905  mapform_funcstr[0] = '\0';
10906  }
10907  return SWIG_arg;
10908 
10909  if(0) SWIG_fail;
10910 
10911 fail:
10912  {
10913  mapform_funcstr[0] = '\0';
10914  }
10915  lua_error(L);
10916  return SWIG_arg;
10917 }
10918 
10919 
10920 static int _wrap_mapline(lua_State* L) {
10921  int SWIG_arg = 0;
10922  mapform_func arg1 = (mapform_func) 0 ;
10923  char *arg2 = (char *) 0 ;
10924  PLFLT arg3 ;
10925  PLFLT arg4 ;
10926  PLFLT arg5 ;
10927  PLFLT arg6 ;
10928  PLINT *arg7 = (PLINT *) 0 ;
10929  PLINT arg8 ;
10930  int temp7 ;
10931 
10932  SWIG_check_num_args("plmapline",7,7)
10933  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmapline",2,"char const *");
10934  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmapline",3,"PLFLT");
10935  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmapline",4,"PLFLT");
10936  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmapline",5,"PLFLT");
10937  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmapline",6,"PLFLT");
10938  {
10939  arg1 = NULL;
10940  mapform_funcstr[0] = '\0';
10941 
10942  if ( lua_isnil( L, 1 ) )
10943  {
10944  arg1 = NULL;
10945  }
10946  else if ( lua_isstring( L, 1 ) )
10947  {
10948  arg1 = mapform;
10949  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
10950  myL = L;
10951  }
10952  else
10953  SWIG_fail_arg( "mapline", 1, "mapform_func" );
10954  }
10955  arg2 = (char *)lua_tostring(L, 2);
10956  arg3 = (PLFLT)lua_tonumber(L, 3);
10957  arg4 = (PLFLT)lua_tonumber(L, 4);
10958  arg5 = (PLFLT)lua_tonumber(L, 5);
10959  arg6 = (PLFLT)lua_tonumber(L, 6);
10960  {
10961  if ( lua_isnil( L, 7 ) )
10962  {
10963  arg7 = NULL;
10964  arg8 = 0;
10965  }
10966  else
10967  {
10968  arg7 = (PLINT *) LUA_get_int_num_array_var( L, 7, &temp7 );
10969  if ( !arg7 )
10970  SWIG_fail;
10971  arg8 = temp7;
10972  }
10973  }
10974  plmapline(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,(int const *)arg7,arg8);
10975 
10976  {
10977  mapform_funcstr[0] = '\0';
10978  }
10979  {
10980  LUA_FREE_ARRAY( arg7 );
10981  }
10982  return SWIG_arg;
10983 
10984  if(0) SWIG_fail;
10985 
10986 fail:
10987  {
10988  mapform_funcstr[0] = '\0';
10989  }
10990  {
10991  LUA_FREE_ARRAY( arg7 );
10992  }
10993  lua_error(L);
10994  return SWIG_arg;
10995 }
10996 
10997 
10998 static int _wrap_mapstring(lua_State* L) {
10999  int SWIG_arg = 0;
11000  mapform_func arg1 = (mapform_func) 0 ;
11001  char *arg2 = (char *) 0 ;
11002  char *arg3 = (char *) 0 ;
11003  PLFLT arg4 ;
11004  PLFLT arg5 ;
11005  PLFLT arg6 ;
11006  PLFLT arg7 ;
11007  PLINT *arg8 = (PLINT *) 0 ;
11008  PLINT arg9 ;
11009  int temp8 ;
11010 
11011  SWIG_check_num_args("plmapstring",8,8)
11012  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmapstring",2,"char const *");
11013  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("plmapstring",3,"char const *");
11014  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmapstring",4,"PLFLT");
11015  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmapstring",5,"PLFLT");
11016  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmapstring",6,"PLFLT");
11017  if(!lua_isnumber(L,7)) SWIG_fail_arg("plmapstring",7,"PLFLT");
11018  {
11019  arg1 = NULL;
11020  mapform_funcstr[0] = '\0';
11021 
11022  if ( lua_isnil( L, 1 ) )
11023  {
11024  arg1 = NULL;
11025  }
11026  else if ( lua_isstring( L, 1 ) )
11027  {
11028  arg1 = mapform;
11029  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11030  myL = L;
11031  }
11032  else
11033  SWIG_fail_arg( "mapstring", 1, "mapform_func" );
11034  }
11035  arg2 = (char *)lua_tostring(L, 2);
11036  arg3 = (char *)lua_tostring(L, 3);
11037  arg4 = (PLFLT)lua_tonumber(L, 4);
11038  arg5 = (PLFLT)lua_tonumber(L, 5);
11039  arg6 = (PLFLT)lua_tonumber(L, 6);
11040  arg7 = (PLFLT)lua_tonumber(L, 7);
11041  {
11042  if ( lua_isnil( L, 8 ) )
11043  {
11044  arg8 = NULL;
11045  arg9 = 0;
11046  }
11047  else
11048  {
11049  arg8 = (PLINT *) LUA_get_int_num_array_var( L, 8, &temp8 );
11050  if ( !arg8 )
11051  SWIG_fail;
11052  arg9 = temp8;
11053  }
11054  }
11055  plmapstring(arg1,(char const *)arg2,(char const *)arg3,arg4,arg5,arg6,arg7,(int const *)arg8,arg9);
11056 
11057  {
11058  mapform_funcstr[0] = '\0';
11059  }
11060  {
11061  LUA_FREE_ARRAY( arg8 );
11062  }
11063  return SWIG_arg;
11064 
11065  if(0) SWIG_fail;
11066 
11067 fail:
11068  {
11069  mapform_funcstr[0] = '\0';
11070  }
11071  {
11072  LUA_FREE_ARRAY( arg8 );
11073  }
11074  lua_error(L);
11075  return SWIG_arg;
11076 }
11077 
11078 
11079 static int _wrap_maptex(lua_State* L) {
11080  int SWIG_arg = 0;
11081  mapform_func arg1 = (mapform_func) 0 ;
11082  char *arg2 = (char *) 0 ;
11083  PLFLT arg3 ;
11084  PLFLT arg4 ;
11085  PLFLT arg5 ;
11086  char *arg6 = (char *) 0 ;
11087  PLFLT arg7 ;
11088  PLFLT arg8 ;
11089  PLFLT arg9 ;
11090  PLFLT arg10 ;
11091  PLINT arg11 ;
11092 
11093  SWIG_check_num_args("plmaptex",11,11)
11094  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmaptex",2,"char const *");
11095  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmaptex",3,"PLFLT");
11096  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmaptex",4,"PLFLT");
11097  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmaptex",5,"PLFLT");
11098  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plmaptex",6,"char const *");
11099  if(!lua_isnumber(L,7)) SWIG_fail_arg("plmaptex",7,"PLFLT");
11100  if(!lua_isnumber(L,8)) SWIG_fail_arg("plmaptex",8,"PLFLT");
11101  if(!lua_isnumber(L,9)) SWIG_fail_arg("plmaptex",9,"PLFLT");
11102  if(!lua_isnumber(L,10)) SWIG_fail_arg("plmaptex",10,"PLFLT");
11103  if(!lua_isnumber(L,11)) SWIG_fail_arg("plmaptex",11,"PLINT");
11104  {
11105  arg1 = NULL;
11106  mapform_funcstr[0] = '\0';
11107 
11108  if ( lua_isnil( L, 1 ) )
11109  {
11110  arg1 = NULL;
11111  }
11112  else if ( lua_isstring( L, 1 ) )
11113  {
11114  arg1 = mapform;
11115  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11116  myL = L;
11117  }
11118  else
11119  SWIG_fail_arg( "maptex", 1, "mapform_func" );
11120  }
11121  arg2 = (char *)lua_tostring(L, 2);
11122  arg3 = (PLFLT)lua_tonumber(L, 3);
11123  arg4 = (PLFLT)lua_tonumber(L, 4);
11124  arg5 = (PLFLT)lua_tonumber(L, 5);
11125  arg6 = (char *)lua_tostring(L, 6);
11126  arg7 = (PLFLT)lua_tonumber(L, 7);
11127  arg8 = (PLFLT)lua_tonumber(L, 8);
11128  arg9 = (PLFLT)lua_tonumber(L, 9);
11129  arg10 = (PLFLT)lua_tonumber(L, 10);
11130  arg11 = (PLINT)lua_tonumber(L, 11);
11131  plmaptex(arg1,(char const *)arg2,arg3,arg4,arg5,(char const *)arg6,arg7,arg8,arg9,arg10,arg11);
11132 
11133  {
11134  mapform_funcstr[0] = '\0';
11135  }
11136  return SWIG_arg;
11137 
11138  if(0) SWIG_fail;
11139 
11140 fail:
11141  {
11142  mapform_funcstr[0] = '\0';
11143  }
11144  lua_error(L);
11145  return SWIG_arg;
11146 }
11147 
11148 
11149 static int _wrap_mapfill(lua_State* L) {
11150  int SWIG_arg = 0;
11151  mapform_func arg1 = (mapform_func) 0 ;
11152  char *arg2 = (char *) 0 ;
11153  PLFLT arg3 ;
11154  PLFLT arg4 ;
11155  PLFLT arg5 ;
11156  PLFLT arg6 ;
11157  PLINT *arg7 = (PLINT *) 0 ;
11158  PLINT arg8 ;
11159  int temp7 ;
11160 
11161  SWIG_check_num_args("plmapfill",7,7)
11162  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmapfill",2,"char const *");
11163  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmapfill",3,"PLFLT");
11164  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmapfill",4,"PLFLT");
11165  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmapfill",5,"PLFLT");
11166  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmapfill",6,"PLFLT");
11167  {
11168  arg1 = NULL;
11169  mapform_funcstr[0] = '\0';
11170 
11171  if ( lua_isnil( L, 1 ) )
11172  {
11173  arg1 = NULL;
11174  }
11175  else if ( lua_isstring( L, 1 ) )
11176  {
11177  arg1 = mapform;
11178  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11179  myL = L;
11180  }
11181  else
11182  SWIG_fail_arg( "mapfill", 1, "mapform_func" );
11183  }
11184  arg2 = (char *)lua_tostring(L, 2);
11185  arg3 = (PLFLT)lua_tonumber(L, 3);
11186  arg4 = (PLFLT)lua_tonumber(L, 4);
11187  arg5 = (PLFLT)lua_tonumber(L, 5);
11188  arg6 = (PLFLT)lua_tonumber(L, 6);
11189  {
11190  if ( lua_isnil( L, 7 ) )
11191  {
11192  arg7 = NULL;
11193  arg8 = 0;
11194  }
11195  else
11196  {
11197  arg7 = (PLINT *) LUA_get_int_num_array_var( L, 7, &temp7 );
11198  if ( !arg7 )
11199  SWIG_fail;
11200  arg8 = temp7;
11201  }
11202  }
11203  plmapfill(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,(int const *)arg7,arg8);
11204 
11205  {
11206  mapform_funcstr[0] = '\0';
11207  }
11208  {
11209  LUA_FREE_ARRAY( arg7 );
11210  }
11211  return SWIG_arg;
11212 
11213  if(0) SWIG_fail;
11214 
11215 fail:
11216  {
11217  mapform_funcstr[0] = '\0';
11218  }
11219  {
11220  LUA_FREE_ARRAY( arg7 );
11221  }
11222  lua_error(L);
11223  return SWIG_arg;
11224 }
11225 
11226 
11227 static int _wrap_meridians(lua_State* L) {
11228  int SWIG_arg = 0;
11229  mapform_func arg1 = (mapform_func) 0 ;
11230  PLFLT arg2 ;
11231  PLFLT arg3 ;
11232  PLFLT arg4 ;
11233  PLFLT arg5 ;
11234  PLFLT arg6 ;
11235  PLFLT arg7 ;
11236 
11237  SWIG_check_num_args("plmeridians",7,7)
11238  if(!lua_isnumber(L,2)) SWIG_fail_arg("plmeridians",2,"PLFLT");
11239  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmeridians",3,"PLFLT");
11240  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmeridians",4,"PLFLT");
11241  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmeridians",5,"PLFLT");
11242  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmeridians",6,"PLFLT");
11243  if(!lua_isnumber(L,7)) SWIG_fail_arg("plmeridians",7,"PLFLT");
11244  {
11245  arg1 = NULL;
11246  mapform_funcstr[0] = '\0';
11247 
11248  if ( lua_isnil( L, 1 ) )
11249  {
11250  arg1 = NULL;
11251  }
11252  else if ( lua_isstring( L, 1 ) )
11253  {
11254  arg1 = mapform;
11255  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11256  myL = L;
11257  }
11258  else
11259  SWIG_fail_arg( "meridians", 1, "mapform_func" );
11260  }
11261  arg2 = (PLFLT)lua_tonumber(L, 2);
11262  arg3 = (PLFLT)lua_tonumber(L, 3);
11263  arg4 = (PLFLT)lua_tonumber(L, 4);
11264  arg5 = (PLFLT)lua_tonumber(L, 5);
11265  arg6 = (PLFLT)lua_tonumber(L, 6);
11266  arg7 = (PLFLT)lua_tonumber(L, 7);
11267  plmeridians(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
11268 
11269  {
11270  mapform_funcstr[0] = '\0';
11271  }
11272  return SWIG_arg;
11273 
11274  if(0) SWIG_fail;
11275 
11276 fail:
11277  {
11278  mapform_funcstr[0] = '\0';
11279  }
11280  lua_error(L);
11281  return SWIG_arg;
11282 }
11283 
11284 
11285 static int _wrap_image(lua_State* L) {
11286  int SWIG_arg = 0;
11287  PLFLT **arg1 = (PLFLT **) 0 ;
11288  PLINT arg2 ;
11289  PLINT arg3 ;
11290  PLFLT arg4 ;
11291  PLFLT arg5 ;
11292  PLFLT arg6 ;
11293  PLFLT arg7 ;
11294  PLFLT arg8 ;
11295  PLFLT arg9 ;
11296  PLFLT arg10 ;
11297  PLFLT arg11 ;
11298  PLFLT arg12 ;
11299  PLFLT arg13 ;
11300  int ii1 ;
11301 
11302  SWIG_check_num_args("plimage",11,11)
11303  if(!lua_isnumber(L,2)) SWIG_fail_arg("plimage",2,"PLFLT");
11304  if(!lua_isnumber(L,3)) SWIG_fail_arg("plimage",3,"PLFLT");
11305  if(!lua_isnumber(L,4)) SWIG_fail_arg("plimage",4,"PLFLT");
11306  if(!lua_isnumber(L,5)) SWIG_fail_arg("plimage",5,"PLFLT");
11307  if(!lua_isnumber(L,6)) SWIG_fail_arg("plimage",6,"PLFLT");
11308  if(!lua_isnumber(L,7)) SWIG_fail_arg("plimage",7,"PLFLT");
11309  if(!lua_isnumber(L,8)) SWIG_fail_arg("plimage",8,"PLFLT");
11310  if(!lua_isnumber(L,9)) SWIG_fail_arg("plimage",9,"PLFLT");
11311  if(!lua_isnumber(L,10)) SWIG_fail_arg("plimage",10,"PLFLT");
11312  if(!lua_isnumber(L,11)) SWIG_fail_arg("plimage",11,"PLFLT");
11313  {
11314  int jj;
11315 
11316  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
11317  if ( !arg1 )
11318  SWIG_fail;
11319  Xlen = arg2 = ii1;
11320  Ylen = arg3 = jj;
11321  }
11322  arg4 = (PLFLT)lua_tonumber(L, 2);
11323  arg5 = (PLFLT)lua_tonumber(L, 3);
11324  arg6 = (PLFLT)lua_tonumber(L, 4);
11325  arg7 = (PLFLT)lua_tonumber(L, 5);
11326  arg8 = (PLFLT)lua_tonumber(L, 6);
11327  arg9 = (PLFLT)lua_tonumber(L, 7);
11328  arg10 = (PLFLT)lua_tonumber(L, 8);
11329  arg11 = (PLFLT)lua_tonumber(L, 9);
11330  arg12 = (PLFLT)lua_tonumber(L, 10);
11331  arg13 = (PLFLT)lua_tonumber(L, 11);
11332  plimage((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13);
11333 
11334  {
11335  int i;
11336 
11337  if ( arg1 )
11338  {
11339  for ( i = 0; i < ii1; i++ )
11340  LUA_FREE_ARRAY( arg1[i] );
11341  LUA_FREE_ARRAY( arg1 );
11342  }
11343  }
11344  return SWIG_arg;
11345 
11346  if(0) SWIG_fail;
11347 
11348 fail:
11349  {
11350  int i;
11351 
11352  if ( arg1 )
11353  {
11354  for ( i = 0; i < ii1; i++ )
11355  LUA_FREE_ARRAY( arg1[i] );
11356  LUA_FREE_ARRAY( arg1 );
11357  }
11358  }
11359  lua_error(L);
11360  return SWIG_arg;
11361 }
11362 
11363 
11364 static int _wrap_imagefr(lua_State* L) {
11365  int SWIG_arg = 0;
11366  PLFLT **arg1 = (PLFLT **) 0 ;
11367  PLINT arg2 ;
11368  PLINT arg3 ;
11369  PLFLT arg4 ;
11370  PLFLT arg5 ;
11371  PLFLT arg6 ;
11372  PLFLT arg7 ;
11373  PLFLT arg8 ;
11374  PLFLT arg9 ;
11375  PLFLT arg10 ;
11376  PLFLT arg11 ;
11377  pltr_func arg12 = (pltr_func) 0 ;
11378  PLPointer arg13 = (PLPointer) 0 ;
11379  int ii1 ;
11380  PLcGrid cgrid113 ;
11381  PLcGrid2 cgrid213 ;
11382 
11383  {
11384  cgrid113.xg = cgrid113.yg = cgrid113.zg = NULL;
11385  cgrid113.nx = cgrid113.ny = cgrid113.nz = 0;
11386  cgrid213.xg = cgrid213.yg = cgrid213.zg = NULL;
11387  cgrid213.nx = cgrid213.ny = 0;
11388  }
11389  {
11390  arg12 = NULL;
11391  }
11392  {
11393  arg13 = NULL;
11394  }
11395  SWIG_check_num_args("plimagefr",9,11)
11396  if(!lua_isnumber(L,2)) SWIG_fail_arg("plimagefr",2,"PLFLT");
11397  if(!lua_isnumber(L,3)) SWIG_fail_arg("plimagefr",3,"PLFLT");
11398  if(!lua_isnumber(L,4)) SWIG_fail_arg("plimagefr",4,"PLFLT");
11399  if(!lua_isnumber(L,5)) SWIG_fail_arg("plimagefr",5,"PLFLT");
11400  if(!lua_isnumber(L,6)) SWIG_fail_arg("plimagefr",6,"PLFLT");
11401  if(!lua_isnumber(L,7)) SWIG_fail_arg("plimagefr",7,"PLFLT");
11402  if(!lua_isnumber(L,8)) SWIG_fail_arg("plimagefr",8,"PLFLT");
11403  if(!lua_isnumber(L,9)) SWIG_fail_arg("plimagefr",9,"PLFLT");
11404  {
11405  int jj;
11406 
11407  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
11408  if ( !arg1 )
11409  SWIG_fail;
11410  Xlen = arg2 = ii1;
11411  Ylen = arg3 = jj;
11412  }
11413  arg4 = (PLFLT)lua_tonumber(L, 2);
11414  arg5 = (PLFLT)lua_tonumber(L, 3);
11415  arg6 = (PLFLT)lua_tonumber(L, 4);
11416  arg7 = (PLFLT)lua_tonumber(L, 5);
11417  arg8 = (PLFLT)lua_tonumber(L, 6);
11418  arg9 = (PLFLT)lua_tonumber(L, 7);
11419  arg10 = (PLFLT)lua_tonumber(L, 8);
11420  arg11 = (PLFLT)lua_tonumber(L, 9);
11421  if(lua_gettop(L)>=10){
11422  {
11423  arg12 = NULL;
11424  mypltr_funcstr[0] = '\0';
11425 
11426  if ( lua_isstring( L, 10 ) )
11427  {
11428  const char* funcstr = lua_tostring( L, 10 );
11429  if ( strcmp( "pltr0", funcstr ) == 0 )
11430  {
11431  arg12 = pltr0;
11432  }
11433  else if ( strcmp( "pltr1", funcstr ) == 0 )
11434  {
11435  arg12 = pltr1;
11436  }
11437  else if ( strcmp( "pltr2", funcstr ) == 0 )
11438  {
11439  arg12 = pltr2;
11440  }
11441  else
11442  {
11443  arg12 = mypltr;
11444  strncpy( mypltr_funcstr, funcstr, 255 );
11445  myL = L;
11446  }
11447  }
11448  else
11449  SWIG_fail_arg( "imagefr", 12, "pltr_func" );
11450  }
11451  }
11452  if(lua_gettop(L)>=11){
11453  {
11454  int nx, ny;
11455  int gridmode = 0;
11456 
11457  lua_pushstring( L, "xg" );
11458  lua_gettable( L, 11 );
11459  if ( !lua_istable( L, -1 ) )
11460  {
11461  lua_pop( L, 1 ); // pop "xg"
11462  lua_pushstring( L, "expected a table xg" );
11463  SWIG_fail;
11464  }
11465  lua_rawgeti( L, -1, 1 );
11466  if ( lua_istable( L, -1 ) )
11467  gridmode = 2; // two dimensional array
11468  else if ( lua_isnumber( L, -1 ) )
11469  gridmode = 1; // one dimensional array
11470  else
11471  {
11472  lua_pop( L, 1 ); // pop "1"
11473  lua_pop( L, 1 ); // pop "xg"
11474  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
11475  SWIG_fail;
11476  }
11477  lua_pop( L, 1 ); // pop test element
11478  if ( gridmode == 1 )
11479  {
11480  cgrid113.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
11481  if ( !cgrid113.xg )
11482  {
11483  lua_pop( L, 1 ); // pop "xg"
11484  SWIG_fail;
11485  }
11486  if ( nx != Xlen )
11487  {
11488  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
11489  SWIG_fail;
11490  }
11491  cgrid113.nx = nx;
11492  }
11493  else
11494  {
11495  cgrid213.xg = read_double_Matrix( L, -1, &nx, &ny );
11496  if ( !cgrid213.xg )
11497  {
11498  lua_pop( L, 1 ); // pop "xg"
11499  SWIG_fail;
11500  }
11501  if ( ( nx != Xlen ) || ( ny != Ylen ) )
11502  {
11503  lua_pop( L, 1 ); // pop "xg"
11504  lua_pushfstring( L, "Vectors must match matrix." );
11505  SWIG_fail;
11506  }
11507  cgrid213.nx = nx;
11508  cgrid213.ny = ny;
11509  }
11510  lua_pop( L, 1 ); // pop "xg"
11511 
11512  lua_pushstring( L, "yg" );
11513  lua_gettable( L, 11 );
11514  if ( !lua_istable( L, -1 ) )
11515  {
11516  lua_pop( L, 1 );
11517  lua_pushstring( L, "expected a table yg" );
11518  SWIG_fail;
11519  }
11520  lua_rawgeti( L, -1, 1 );
11521  if ( gridmode == 2 )
11522  {
11523  if ( !lua_istable( L, -1 ) )
11524  {
11525  lua_pop( L, 1 ); // pop "1"
11526  lua_pop( L, 1 ); // pop "yg"
11527  lua_pushstring( L, "expected a two dimensional array/table in yg" );
11528  SWIG_fail;
11529  }
11530  }
11531  else
11532  {
11533  if ( !lua_isnumber( L, -1 ) )
11534  {
11535  lua_pop( L, 1 ); // pop "1"
11536  lua_pop( L, 1 ); // pop "yg"
11537  lua_pushstring( L, "expected a one dimensional array/table in yg" );
11538  SWIG_fail;
11539  }
11540  }
11541  lua_pop( L, 1 ); // pop "1"
11542  if ( gridmode == 1 )
11543  {
11544  cgrid113.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
11545  if ( !cgrid113.yg )
11546  {
11547  lua_pop( L, 1 ); // pop "yg"
11548  SWIG_fail;
11549  }
11550  if ( ny != Ylen )
11551  {
11552  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
11553  SWIG_fail;
11554  }
11555  cgrid113.ny = ny;
11556  }
11557  else
11558  {
11559  cgrid213.yg = read_double_Matrix( L, -1, &nx, &ny );
11560  if ( !cgrid213.yg )
11561  {
11562  lua_pop( L, 1 ); // pop "xg"
11563  SWIG_fail;
11564  }
11565  if ( ( nx != Xlen ) || ( ny != Ylen ) )
11566  {
11567  lua_pop( L, 1 ); // pop "xg"
11568  lua_pushfstring( L, "Vectors must match matrix." );
11569  SWIG_fail;
11570  }
11571  // cgrid213.nx/ny already set
11572  }
11573  lua_pop( L, 1 ); // pop "yg"
11574 
11575  if ( gridmode == 1 )
11576  arg13 = &cgrid113;
11577  else if ( gridmode == 2 )
11578  arg13 = &cgrid213;
11579  }
11580  }
11581  plimagefr((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13);
11582 
11583  {
11584  int i;
11585 
11586  if ( arg1 )
11587  {
11588  for ( i = 0; i < ii1; i++ )
11589  LUA_FREE_ARRAY( arg1[i] );
11590  LUA_FREE_ARRAY( arg1 );
11591  }
11592  }
11593  {
11594  mypltr_funcstr[0] = '\0';
11595  }
11596  {
11597  int i;
11598 
11599  LUA_FREE_ARRAY( cgrid113.xg );
11600  LUA_FREE_ARRAY( cgrid113.yg );
11601 
11602  if ( cgrid213.xg )
11603  {
11604  for ( i = 0; i < Xlen; i++ )
11605  LUA_FREE_ARRAY( cgrid213.xg[i] );
11606  LUA_FREE_ARRAY( cgrid213.xg );
11607  }
11608  if ( cgrid213.yg )
11609  {
11610  for ( i = 0; i < Xlen; i++ )
11611  LUA_FREE_ARRAY( cgrid213.yg[i] );
11612  LUA_FREE_ARRAY( cgrid213.yg );
11613  }
11614  }
11615  return SWIG_arg;
11616 
11617  if(0) SWIG_fail;
11618 
11619 fail:
11620  {
11621  int i;
11622 
11623  if ( arg1 )
11624  {
11625  for ( i = 0; i < ii1; i++ )
11626  LUA_FREE_ARRAY( arg1[i] );
11627  LUA_FREE_ARRAY( arg1 );
11628  }
11629  }
11630  {
11631  mypltr_funcstr[0] = '\0';
11632  }
11633  {
11634  int i;
11635 
11636  LUA_FREE_ARRAY( cgrid113.xg );
11637  LUA_FREE_ARRAY( cgrid113.yg );
11638 
11639  if ( cgrid213.xg )
11640  {
11641  for ( i = 0; i < Xlen; i++ )
11642  LUA_FREE_ARRAY( cgrid213.xg[i] );
11643  LUA_FREE_ARRAY( cgrid213.xg );
11644  }
11645  if ( cgrid213.yg )
11646  {
11647  for ( i = 0; i < Xlen; i++ )
11648  LUA_FREE_ARRAY( cgrid213.yg[i] );
11649  LUA_FREE_ARRAY( cgrid213.yg );
11650  }
11651  }
11652  lua_error(L);
11653  return SWIG_arg;
11654 }
11655 
11656 
11657 static int _wrap_plClearOpts(lua_State* L) {
11658  int SWIG_arg = 0;
11659 
11660  SWIG_check_num_args("plClearOpts",0,0)
11661  plClearOpts();
11662 
11663  return SWIG_arg;
11664 
11665  if(0) SWIG_fail;
11666 
11667 fail:
11668  lua_error(L);
11669  return SWIG_arg;
11670 }
11671 
11672 
11673 static int _wrap_plResetOpts(lua_State* L) {
11674  int SWIG_arg = 0;
11675 
11676  SWIG_check_num_args("plResetOpts",0,0)
11677  plResetOpts();
11678 
11679  return SWIG_arg;
11680 
11681  if(0) SWIG_fail;
11682 
11683 fail:
11684  lua_error(L);
11685  return SWIG_arg;
11686 }
11687 
11688 
11689 static int _wrap_plSetUsage(lua_State* L) {
11690  int SWIG_arg = 0;
11691  char *arg1 = (char *) 0 ;
11692  char *arg2 = (char *) 0 ;
11693 
11694  SWIG_check_num_args("plSetUsage",2,2)
11695  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plSetUsage",1,"char const *");
11696  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plSetUsage",2,"char const *");
11697  arg1 = (char *)lua_tostring(L, 1);
11698  arg2 = (char *)lua_tostring(L, 2);
11699  plSetUsage((char const *)arg1,(char const *)arg2);
11700 
11701  return SWIG_arg;
11702 
11703  if(0) SWIG_fail;
11704 
11705 fail:
11706  lua_error(L);
11707  return SWIG_arg;
11708 }
11709 
11710 
11711 static int _wrap_plOptUsage(lua_State* L) {
11712  int SWIG_arg = 0;
11713 
11714  SWIG_check_num_args("plOptUsage",0,0)
11715  plOptUsage();
11716 
11717  return SWIG_arg;
11718 
11719  if(0) SWIG_fail;
11720 
11721 fail:
11722  lua_error(L);
11723  return SWIG_arg;
11724 }
11725 
11726 
11727 static int _wrap_MinMax2dGrid(lua_State* L) {
11728  int SWIG_arg = 0;
11729  PLFLT **arg1 = (PLFLT **) 0 ;
11730  PLINT arg2 ;
11731  PLINT arg3 ;
11732  PLFLT *arg4 = (PLFLT *) 0 ;
11733  PLFLT *arg5 = (PLFLT *) 0 ;
11734  int ii1 ;
11735  PLFLT temp4 ;
11736  PLFLT temp5 ;
11737 
11738  arg4 = &temp4;
11739  arg5 = &temp5;
11740  SWIG_check_num_args("plMinMax2dGrid",1,1)
11741  {
11742  int jj;
11743 
11744  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
11745  if ( !arg1 )
11746  SWIG_fail;
11747  Xlen = arg2 = ii1;
11748  Ylen = arg3 = jj;
11749  }
11750  plMinMax2dGrid((double const **)arg1,arg2,arg3,arg4,arg5);
11751 
11752  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
11753  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
11754  {
11755  int i;
11756 
11757  if ( arg1 )
11758  {
11759  for ( i = 0; i < ii1; i++ )
11760  LUA_FREE_ARRAY( arg1[i] );
11761  LUA_FREE_ARRAY( arg1 );
11762  }
11763  }
11764  return SWIG_arg;
11765 
11766  if(0) SWIG_fail;
11767 
11768 fail:
11769  {
11770  int i;
11771 
11772  if ( arg1 )
11773  {
11774  for ( i = 0; i < ii1; i++ )
11775  LUA_FREE_ARRAY( arg1[i] );
11776  LUA_FREE_ARRAY( arg1 );
11777  }
11778  }
11779  lua_error(L);
11780  return SWIG_arg;
11781 }
11782 
11783 
11784 static int _wrap_plGetCursor(lua_State* L) {
11785  int SWIG_arg = 0;
11786  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
11787  PLINT result;
11788 
11789  SWIG_check_num_args("plGetCursor",1,1)
11790  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("plGetCursor",1,"PLGraphicsIn *");
11791 
11792  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
11793  SWIG_fail_ptr("plGetCursor",1,SWIGTYPE_p_PLGraphicsIn);
11794  }
11795 
11796  result = (PLINT)plGetCursor(arg1);
11797  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
11798  return SWIG_arg;
11799 
11800  if(0) SWIG_fail;
11801 
11802 fail:
11803  lua_error(L);
11804  return SWIG_arg;
11805 }
11806 
11807 
11808 static int _wrap_warn(lua_State* L) {
11809  int SWIG_arg = 0;
11810  char *arg1 = (char *) 0 ;
11811 
11812  SWIG_check_num_args("plwarn",1,1)
11813  if(!lua_isstring(L,1)) SWIG_fail_arg("plwarn",1,"char const *");
11814  {
11815  arg1 = (char *) lua_tostring( L, 1 );
11816  }
11817  plwarn((char const *)arg1);
11818 
11819  return SWIG_arg;
11820 
11821  if(0) SWIG_fail;
11822 
11823 fail:
11824  lua_error(L);
11825  return SWIG_arg;
11826 }
11827 
11828 
11829 static int _wrap_abort(lua_State* L) {
11830  int SWIG_arg = 0;
11831  char *arg1 = (char *) 0 ;
11832 
11833  SWIG_check_num_args("plabort",1,1)
11834  if(!lua_isstring(L,1)) SWIG_fail_arg("plabort",1,"char const *");
11835  {
11836  arg1 = (char *) lua_tostring( L, 1 );
11837  }
11838  plabort((char const *)arg1);
11839 
11840  return SWIG_arg;
11841 
11842  if(0) SWIG_fail;
11843 
11844 fail:
11845  lua_error(L);
11846  return SWIG_arg;
11847 }
11848 
11849 
11850 #ifdef __cplusplus
11851 }
11852 #endif
11853 
11854 static const struct luaL_Reg swig_commands[] = {
11855  { "setcontlabelformat", _wrap_setcontlabelformat},
11856  { "setcontlabelparam", _wrap_setcontlabelparam},
11857  { "adv", _wrap_adv},
11858  { "arc", _wrap_arc},
11859  { "axes", _wrap_axes},
11860  { "bin", _wrap_bin},
11861  { "btime", _wrap_btime},
11862  { "bop", _wrap_bop},
11863  { "box", _wrap_box},
11864  { "box3", _wrap_box3},
11865  { "calc_world", _wrap_calc_world},
11866  { "clear", _wrap_clear},
11867  { "col0", _wrap_col0},
11868  { "col1", _wrap_col1},
11869  { "configtime", _wrap_configtime},
11870  { "cont", _wrap_cont},
11871  { "ctime", _wrap_ctime},
11872  { "cpstrm", _wrap_cpstrm},
11873  { "plend", _wrap_plend},
11874  { "plend1", _wrap_plend1},
11875  { "env", _wrap_env},
11876  { "env0", _wrap_env0},
11877  { "eop", _wrap_eop},
11878  { "errx", _wrap_errx},
11879  { "erry", _wrap_erry},
11880  { "famadv", _wrap_famadv},
11881  { "fill", _wrap_fill},
11882  { "fill3", _wrap_fill3},
11883  { "gradient", _wrap_gradient},
11884  { "flush", _wrap_flush},
11885  { "font", _wrap_font},
11886  { "fontld", _wrap_fontld},
11887  { "gchr", _wrap_gchr},
11888  { "gcol0", _wrap_gcol0},
11889  { "gcol0a", _wrap_gcol0a},
11890  { "gcolbg", _wrap_gcolbg},
11891  { "gcolbga", _wrap_gcolbga},
11892  { "gcompression", _wrap_gcompression},
11893  { "gdev", _wrap_gdev},
11894  { "gdidev", _wrap_gdidev},
11895  { "gdiori", _wrap_gdiori},
11896  { "gdiplt", _wrap_gdiplt},
11897  { "gfam", _wrap_gfam},
11898  { "gfci", _wrap_gfci},
11899  { "gfnam", _wrap_gfnam},
11900  { "gfont", _wrap_gfont},
11901  { "glevel", _wrap_glevel},
11902  { "gpage", _wrap_gpage},
11903  { "gra", _wrap_gra},
11904  { "griddata", _wrap_griddata},
11905  { "gspa", _wrap_gspa},
11906  { "gstrm", _wrap_gstrm},
11907  { "gver", _wrap_gver},
11908  { "gvpd", _wrap_gvpd},
11909  { "gvpw", _wrap_gvpw},
11910  { "gxax", _wrap_gxax},
11911  { "gyax", _wrap_gyax},
11912  { "gzax", _wrap_gzax},
11913  { "hist", _wrap_hist},
11914  { "hlsrgb", _wrap_hlsrgb},
11915  { "init", _wrap_init},
11916  { "join", _wrap_join},
11917  { "lab", _wrap_lab},
11918  { "legend", _wrap_legend},
11919  { "colorbar", _wrap_colorbar},
11920  { "lightsource", _wrap_lightsource},
11921  { "line", _wrap_line},
11922  { "line3", _wrap_line3},
11923  { "lsty", _wrap_lsty},
11924  { "mesh", _wrap_mesh},
11925  { "meshc", _wrap_meshc},
11926  { "mkstrm", _wrap_mkstrm},
11927  { "mtex", _wrap_mtex},
11928  { "mtex3", _wrap_mtex3},
11929  { "plot3d", _wrap_plot3d},
11930  { "plot3dc", _wrap_plot3dc},
11931  { "plot3dcl", _wrap_plot3dcl},
11932  { "surf3d", _wrap_surf3d},
11933  { "surf3dl", _wrap_surf3dl},
11934  { "parseopts", _wrap_parseopts},
11935  { "pat", _wrap_pat},
11936  { "path", _wrap_path},
11937  { "poin", _wrap_poin},
11938  { "poin3", _wrap_poin3},
11939  { "poly3", _wrap_poly3},
11940  { "prec", _wrap_prec},
11941  { "psty", _wrap_psty},
11942  { "ptex", _wrap_ptex},
11943  { "ptex3", _wrap_ptex3},
11944  { "randd", _wrap_randd},
11945  { "replot", _wrap_replot},
11946  { "rgbhls", _wrap_rgbhls},
11947  { "schr", _wrap_schr},
11948  { "scmap0", _wrap_scmap0},
11949  { "scmap0a", _wrap_scmap0a},
11950  { "scmap0n", _wrap_scmap0n},
11951  { "scmap1", _wrap_scmap1},
11952  { "scmap1a", _wrap_scmap1a},
11953  { "scmap1l", _wrap_scmap1l},
11954  { "scmap1la", _wrap_scmap1la},
11955  { "scmap1n", _wrap_scmap1n},
11956  { "scmap1_range", _wrap_scmap1_range},
11957  { "gcmap1_range", _wrap_gcmap1_range},
11958  { "scol0", _wrap_scol0},
11959  { "scol0a", _wrap_scol0a},
11960  { "scolbg", _wrap_scolbg},
11961  { "scolbga", _wrap_scolbga},
11962  { "scolor", _wrap_scolor},
11963  { "scompression", _wrap_scompression},
11964  { "sdev", _wrap_sdev},
11965  { "sdidev", _wrap_sdidev},
11966  { "sdimap", _wrap_sdimap},
11967  { "sdiori", _wrap_sdiori},
11968  { "sdiplt", _wrap_sdiplt},
11969  { "sdiplz", _wrap_sdiplz},
11970  { "seed", _wrap_seed},
11971  { "sesc", _wrap_sesc},
11972  { "setopt", _wrap_setopt},
11973  { "sfam", _wrap_sfam},
11974  { "sfci", _wrap_sfci},
11975  { "sfnam", _wrap_sfnam},
11976  { "sfont", _wrap_sfont},
11977  { "shades", _wrap_shades},
11978  { "shade", _wrap_shade},
11979  { "slabelfunc", _wrap_slabelfunc},
11980  { "smaj", _wrap_smaj},
11981  { "smin", _wrap_smin},
11982  { "sori", _wrap_sori},
11983  { "spage", _wrap_spage},
11984  { "spal0", _wrap_spal0},
11985  { "spal1", _wrap_spal1},
11986  { "spause", _wrap_spause},
11987  { "sstrm", _wrap_sstrm},
11988  { "ssub", _wrap_ssub},
11989  { "ssym", _wrap_ssym},
11990  { "star", _wrap_star},
11991  { "start", _wrap_start},
11992  { "stransform", _wrap_stransform},
11993  { "string", _wrap_string},
11994  { "string3", _wrap_string3},
11995  { "stripa", _wrap_stripa},
11996  { "stripc", _wrap_stripc},
11997  { "stripd", _wrap_stripd},
11998  { "styl", _wrap_styl},
11999  { "svect", _wrap_svect},
12000  { "svpa", _wrap_svpa},
12001  { "sxax", _wrap_sxax},
12002  { "syax", _wrap_syax},
12003  { "sym", _wrap_sym},
12004  { "szax", _wrap_szax},
12005  { "text", _wrap_text},
12006  { "timefmt", _wrap_timefmt},
12007  { "vasp", _wrap_vasp},
12008  { "vect", _wrap_vect},
12009  { "vpas", _wrap_vpas},
12010  { "vpor", _wrap_vpor},
12011  { "vsta", _wrap_vsta},
12012  { "w3d", _wrap_w3d},
12013  { "width", _wrap_width},
12014  { "wind", _wrap_wind},
12015  { "xormod", _wrap_xormod},
12016  { "map", _wrap_map},
12017  { "mapline", _wrap_mapline},
12018  { "mapstring", _wrap_mapstring},
12019  { "maptex", _wrap_maptex},
12020  { "mapfill", _wrap_mapfill},
12021  { "meridians", _wrap_meridians},
12022  { "image", _wrap_image},
12023  { "imagefr", _wrap_imagefr},
12024  { "plClearOpts", _wrap_plClearOpts},
12025  { "plResetOpts", _wrap_plResetOpts},
12026  { "plSetUsage", _wrap_plSetUsage},
12027  { "plOptUsage", _wrap_plOptUsage},
12028  { "MinMax2dGrid", _wrap_MinMax2dGrid},
12029  { "plGetCursor", _wrap_plGetCursor},
12030  { "warn", _wrap_warn},
12031  { "abort", _wrap_abort},
12032  {0,0}
12033 };
12034 
12036  {0,0,0}
12037 };
12038 
12040  {SWIG_LUA_CONSTTAB_INT("PLESC_SET_RGB", 1)},
12041  {SWIG_LUA_CONSTTAB_INT("PLESC_ALLOC_NCOL", 2)},
12042  {SWIG_LUA_CONSTTAB_INT("PLESC_SET_LPB", 3)},
12043  {SWIG_LUA_CONSTTAB_INT("PLESC_EXPOSE", 4)},
12044  {SWIG_LUA_CONSTTAB_INT("PLESC_RESIZE", 5)},
12045  {SWIG_LUA_CONSTTAB_INT("PLESC_REDRAW", 6)},
12046  {SWIG_LUA_CONSTTAB_INT("PLESC_TEXT", 7)},
12047  {SWIG_LUA_CONSTTAB_INT("PLESC_GRAPH", 8)},
12048  {SWIG_LUA_CONSTTAB_INT("PLESC_FILL", 9)},
12049  {SWIG_LUA_CONSTTAB_INT("PLESC_DI", 10)},
12050  {SWIG_LUA_CONSTTAB_INT("PLESC_FLUSH", 11)},
12051  {SWIG_LUA_CONSTTAB_INT("PLESC_EH", 12)},
12052  {SWIG_LUA_CONSTTAB_INT("PLESC_GETC", 13)},
12053  {SWIG_LUA_CONSTTAB_INT("PLESC_SWIN", 14)},
12054  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING", 15)},
12055  {SWIG_LUA_CONSTTAB_INT("PLESC_XORMOD", 16)},
12056  {SWIG_LUA_CONSTTAB_INT("PLESC_SET_COMPRESSION", 17)},
12057  {SWIG_LUA_CONSTTAB_INT("PLESC_CLEAR", 18)},
12058  {SWIG_LUA_CONSTTAB_INT("PLESC_DASH", 19)},
12059  {SWIG_LUA_CONSTTAB_INT("PLESC_HAS_TEXT", 20)},
12060  {SWIG_LUA_CONSTTAB_INT("PLESC_IMAGE", 21)},
12061  {SWIG_LUA_CONSTTAB_INT("PLESC_IMAGEOPS", 22)},
12062  {SWIG_LUA_CONSTTAB_INT("PLESC_PL2DEVCOL", 23)},
12063  {SWIG_LUA_CONSTTAB_INT("PLESC_DEV2PLCOL", 24)},
12064  {SWIG_LUA_CONSTTAB_INT("PLESC_SETBGFG", 25)},
12065  {SWIG_LUA_CONSTTAB_INT("PLESC_DEVINIT", 26)},
12066  {SWIG_LUA_CONSTTAB_INT("PLESC_GETBACKEND", 27)},
12067  {SWIG_LUA_CONSTTAB_INT("PLESC_BEGIN_TEXT", 28)},
12068  {SWIG_LUA_CONSTTAB_INT("PLESC_TEXT_CHAR", 29)},
12069  {SWIG_LUA_CONSTTAB_INT("PLESC_CONTROL_CHAR", 30)},
12070  {SWIG_LUA_CONSTTAB_INT("PLESC_END_TEXT", 31)},
12071  {SWIG_LUA_CONSTTAB_INT("PLESC_START_RASTERIZE", 32)},
12072  {SWIG_LUA_CONSTTAB_INT("PLESC_END_RASTERIZE", 33)},
12073  {SWIG_LUA_CONSTTAB_INT("PLESC_ARC", 34)},
12074  {SWIG_LUA_CONSTTAB_INT("PLESC_GRADIENT", 35)},
12075  {SWIG_LUA_CONSTTAB_INT("PLESC_MODESET", 36)},
12076  {SWIG_LUA_CONSTTAB_INT("PLESC_MODEGET", 37)},
12077  {SWIG_LUA_CONSTTAB_INT("PLESC_FIXASPECT", 38)},
12078  {SWIG_LUA_CONSTTAB_INT("PLESC_IMPORT_BUFFER", 39)},
12079  {SWIG_LUA_CONSTTAB_INT("PLESC_APPEND_BUFFER", 40)},
12080  {SWIG_LUA_CONSTTAB_INT("PLESC_FLUSH_REMAINING_BUFFER", 41)},
12081  {SWIG_LUA_CONSTTAB_INT("PLTEXT_FONTCHANGE", 0)},
12082  {SWIG_LUA_CONSTTAB_INT("PLTEXT_SUPERSCRIPT", 1)},
12083  {SWIG_LUA_CONSTTAB_INT("PLTEXT_SUBSCRIPT", 2)},
12084  {SWIG_LUA_CONSTTAB_INT("PLTEXT_BACKCHAR", 3)},
12085  {SWIG_LUA_CONSTTAB_INT("PLTEXT_OVERLINE", 4)},
12086  {SWIG_LUA_CONSTTAB_INT("PLTEXT_UNDERLINE", 5)},
12087  {SWIG_LUA_CONSTTAB_INT("ZEROW2B", 1)},
12088  {SWIG_LUA_CONSTTAB_INT("ZEROW2D", 2)},
12089  {SWIG_LUA_CONSTTAB_INT("ONEW2B", 3)},
12090  {SWIG_LUA_CONSTTAB_INT("ONEW2D", 4)},
12091  {SWIG_LUA_CONSTTAB_INT("PLSWIN_DEVICE", 1)},
12092  {SWIG_LUA_CONSTTAB_INT("PLSWIN_WORLD", 2)},
12093  {SWIG_LUA_CONSTTAB_INT("PL_X_AXIS", 1)},
12094  {SWIG_LUA_CONSTTAB_INT("PL_Y_AXIS", 2)},
12095  {SWIG_LUA_CONSTTAB_INT("PL_Z_AXIS", 3)},
12096  {SWIG_LUA_CONSTTAB_INT("PL_OPT_ENABLED", 0x0001)},
12097  {SWIG_LUA_CONSTTAB_INT("PL_OPT_ARG", 0x0002)},
12098  {SWIG_LUA_CONSTTAB_INT("PL_OPT_NODELETE", 0x0004)},
12099  {SWIG_LUA_CONSTTAB_INT("PL_OPT_INVISIBLE", 0x0008)},
12100  {SWIG_LUA_CONSTTAB_INT("PL_OPT_DISABLED", 0x0010)},
12101  {SWIG_LUA_CONSTTAB_INT("PL_OPT_FUNC", 0x0100)},
12102  {SWIG_LUA_CONSTTAB_INT("PL_OPT_BOOL", 0x0200)},
12103  {SWIG_LUA_CONSTTAB_INT("PL_OPT_INT", 0x0400)},
12104  {SWIG_LUA_CONSTTAB_INT("PL_OPT_FLOAT", 0x0800)},
12105  {SWIG_LUA_CONSTTAB_INT("PL_OPT_STRING", 0x1000)},
12106  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_PARTIAL", 0x0000)},
12107  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_FULL", 0x0001)},
12108  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_QUIET", 0x0002)},
12109  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_NODELETE", 0x0004)},
12110  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_SHOWALL", 0x0008)},
12111  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_OVERRIDE", 0x0010)},
12112  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_NOPROGRAM", 0x0020)},
12113  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_NODASH", 0x0040)},
12114  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_SKIP", 0x0080)},
12115  {SWIG_LUA_CONSTTAB_INT("PL_FCI_MARK", 0x80000000)},
12116  {SWIG_LUA_CONSTTAB_INT("PL_FCI_IMPOSSIBLE", 0x00000000)},
12117  {SWIG_LUA_CONSTTAB_INT("PL_FCI_HEXDIGIT_MASK", 0xf)},
12118  {SWIG_LUA_CONSTTAB_INT("PL_FCI_HEXPOWER_MASK", 0x7)},
12119  {SWIG_LUA_CONSTTAB_INT("PL_FCI_HEXPOWER_IMPOSSIBLE", 0xf)},
12120  {SWIG_LUA_CONSTTAB_INT("PL_FCI_FAMILY", 0x0)},
12121  {SWIG_LUA_CONSTTAB_INT("PL_FCI_STYLE", 0x1)},
12122  {SWIG_LUA_CONSTTAB_INT("PL_FCI_WEIGHT", 0x2)},
12123  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SANS", 0x0)},
12124  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SERIF", 0x1)},
12125  {SWIG_LUA_CONSTTAB_INT("PL_FCI_MONO", 0x2)},
12126  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SCRIPT", 0x3)},
12127  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SYMBOL", 0x4)},
12128  {SWIG_LUA_CONSTTAB_INT("PL_FCI_UPRIGHT", 0x0)},
12129  {SWIG_LUA_CONSTTAB_INT("PL_FCI_ITALIC", 0x1)},
12130  {SWIG_LUA_CONSTTAB_INT("PL_FCI_OBLIQUE", 0x2)},
12131  {SWIG_LUA_CONSTTAB_INT("PL_FCI_MEDIUM", 0x0)},
12132  {SWIG_LUA_CONSTTAB_INT("PL_FCI_BOLD", 0x1)},
12133  {SWIG_LUA_CONSTTAB_INT("PL_MAXKEY", 16)},
12134  {SWIG_LUA_CONSTTAB_INT("PL_MASK_SHIFT", 0x1)},
12135  {SWIG_LUA_CONSTTAB_INT("PL_MASK_CAPS", 0x2)},
12136  {SWIG_LUA_CONSTTAB_INT("PL_MASK_CONTROL", 0x4)},
12137  {SWIG_LUA_CONSTTAB_INT("PL_MASK_ALT", 0x8)},
12138  {SWIG_LUA_CONSTTAB_INT("PL_MASK_NUM", 0x10)},
12139  {SWIG_LUA_CONSTTAB_INT("PL_MASK_ALTGR", 0x20)},
12140  {SWIG_LUA_CONSTTAB_INT("PL_MASK_WIN", 0x40)},
12141  {SWIG_LUA_CONSTTAB_INT("PL_MASK_SCROLL", 0x80)},
12142  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON1", 0x100)},
12143  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON2", 0x200)},
12144  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON3", 0x400)},
12145  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON4", 0x800)},
12146  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON5", 0x1000)},
12147  {SWIG_LUA_CONSTTAB_INT("PL_MAXWINDOWS", 64)},
12148  {SWIG_LUA_CONSTTAB_INT("PL_NOTSET", (-42))},
12149  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING_ENABLE", 1)},
12150  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING_DISABLE", 2)},
12151  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING_QUERY", 3)},
12152  {SWIG_LUA_CONSTTAB_INT("PL_BIN_DEFAULT", 0x0)},
12153  {SWIG_LUA_CONSTTAB_INT("PL_BIN_CENTRED", 0x1)},
12154  {SWIG_LUA_CONSTTAB_INT("PL_BIN_NOEXPAND", 0x2)},
12155  {SWIG_LUA_CONSTTAB_INT("PL_BIN_NOEMPTY", 0x4)},
12156  {SWIG_LUA_CONSTTAB_INT("GRID_CSA", 1)},
12157  {SWIG_LUA_CONSTTAB_INT("GRID_DTLI", 2)},
12158  {SWIG_LUA_CONSTTAB_INT("GRID_NNI", 3)},
12159  {SWIG_LUA_CONSTTAB_INT("GRID_NNIDW", 4)},
12160  {SWIG_LUA_CONSTTAB_INT("GRID_NNLI", 5)},
12161  {SWIG_LUA_CONSTTAB_INT("GRID_NNAIDW", 6)},
12162  {SWIG_LUA_CONSTTAB_INT("PL_HIST_DEFAULT", 0x00)},
12163  {SWIG_LUA_CONSTTAB_INT("PL_HIST_NOSCALING", 0x01)},
12164  {SWIG_LUA_CONSTTAB_INT("PL_HIST_IGNORE_OUTLIERS", 0x02)},
12165  {SWIG_LUA_CONSTTAB_INT("PL_HIST_NOEXPAND", 0x08)},
12166  {SWIG_LUA_CONSTTAB_INT("PL_HIST_NOEMPTY", 0x10)},
12167  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_LEFT", 0x1)},
12168  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_RIGHT", 0x2)},
12169  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_TOP", 0x4)},
12170  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_BOTTOM", 0x8)},
12171  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_INSIDE", 0x10)},
12172  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_OUTSIDE", 0x20)},
12173  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_VIEWPORT", 0x40)},
12174  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_SUBPAGE", 0x80)},
12175  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_NONE", 0x1)},
12176  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_COLOR_BOX", 0x2)},
12177  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_LINE", 0x4)},
12178  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_SYMBOL", 0x8)},
12179  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_TEXT_LEFT", 0x10)},
12180  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_BACKGROUND", 0x20)},
12181  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_BOUNDING_BOX", 0x40)},
12182  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_ROW_MAJOR", 0x80)},
12183  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_LEFT", 0x1)},
12184  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_RIGHT", 0x2)},
12185  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_TOP", 0x4)},
12186  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_BOTTOM", 0x8)},
12187  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_IMAGE", 0x10)},
12188  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_SHADE", 0x20)},
12189  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_GRADIENT", 0x40)},
12190  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_CAP_NONE", 0x80)},
12191  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_CAP_LOW", 0x100)},
12192  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_CAP_HIGH", 0x200)},
12193  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_SHADE_LABEL", 0x400)},
12194  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_RIGHT", 0x800)},
12195  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_TOP", 0x1000)},
12196  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_LEFT", 0x2000)},
12197  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_BOTTOM", 0x4000)},
12198  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_BACKGROUND", 0x8000)},
12199  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_BOUNDING_BOX", 0x10000)},
12200  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_UNKNOWN", 0x0)},
12201  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_DEFAULT", 0x1)},
12202  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_REPLACE", 0x2)},
12203  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_XOR", 0x4)},
12204  {SWIG_LUA_CONSTTAB_INT("DRAW_LINEX", 0x001)},
12205  {SWIG_LUA_CONSTTAB_INT("DRAW_LINEY", 0x002)},
12206  {SWIG_LUA_CONSTTAB_INT("DRAW_LINEXY", 0x003)},
12207  {SWIG_LUA_CONSTTAB_INT("MAG_COLOR", 0x004)},
12208  {SWIG_LUA_CONSTTAB_INT("BASE_CONT", 0x008)},
12209  {SWIG_LUA_CONSTTAB_INT("TOP_CONT", 0x010)},
12210  {SWIG_LUA_CONSTTAB_INT("SURF_CONT", 0x020)},
12211  {SWIG_LUA_CONSTTAB_INT("DRAW_SIDES", 0x040)},
12212  {SWIG_LUA_CONSTTAB_INT("FACETED", 0x080)},
12213  {SWIG_LUA_CONSTTAB_INT("MESH", 0x100)},
12214  {0,0,0,0,0,0}
12215 };
12216 
12217 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
12218 
12219 static swig_type_info _swigt__p_PLGraphicsIn = {"_p_PLGraphicsIn", "PLGraphicsIn *", 0, 0, (void*)&_wrap_class_PLGraphicsIn, 0};
12220 static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
12221 static swig_type_info _swigt__p_double = {"_p_double", "double *|PLFLT *", 0, 0, (void*)0, 0};
12222 static swig_type_info _swigt__p_f_double_double__int = {"_p_f_double_double__int", "defined_func|int (*)(double,double)", 0, 0, (void*)0, 0};
12223 static swig_type_info _swigt__p_f_double_double_p_double_p_double_p_void__void = {"_p_f_double_double_p_double_p_double_p_void__void", "ct_func|pltr_func|void (*)(double,double,double *,double *,void *)", 0, 0, (void*)0, 0};
12224 static swig_type_info _swigt__p_f_int_double_p_char_int_p_void__void = {"_p_f_int_double_p_char_int_p_void__void", "void (*)(int,double,char *,int,void *)|label_func", 0, 0, (void*)0, 0};
12225 static swig_type_info _swigt__p_f_int_p_double_p_double__void = {"_p_f_int_p_double_p_double__void", "mapform_func|void (*)(int,double *,double *)", 0, 0, (void*)0, 0};
12226 static swig_type_info _swigt__p_f_int_p_q_const__double_p_q_const__double__void = {"_p_f_int_p_q_const__double_p_q_const__double__void", "void (*)(int,double const *,double const *)|fill_func", 0, 0, (void*)0, 0};
12227 static swig_type_info _swigt__p_int = {"_p_int", "PLBOOL *|int *|PLINT *", 0, 0, (void*)0, 0};
12228 static swig_type_info _swigt__p_p_char = {"_p_p_char", "char **", 0, 0, (void*)0, 0};
12229 static swig_type_info _swigt__p_p_double = {"_p_p_double", "PLFLT **|double **", 0, 0, (void*)0, 0};
12230 static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "unsigned int *|PLUNICODE *", 0, 0, (void*)0, 0};
12231 
12234  &_swigt__p_char,
12241  &_swigt__p_int,
12245 };
12246 
12247 static swig_cast_info _swigc__p_PLGraphicsIn[] = { {&_swigt__p_PLGraphicsIn, 0, 0, 0},{0, 0, 0, 0}};
12248 static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
12249 static swig_cast_info _swigc__p_double[] = { {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}};
12255 static swig_cast_info _swigc__p_int[] = { {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
12256 static swig_cast_info _swigc__p_p_char[] = { {&_swigt__p_p_char, 0, 0, 0},{0, 0, 0, 0}};
12257 static swig_cast_info _swigc__p_p_double[] = { {&_swigt__p_p_double, 0, 0, 0},{0, 0, 0, 0}};
12258 static swig_cast_info _swigc__p_unsigned_int[] = { {&_swigt__p_unsigned_int, 0, 0, 0},{0, 0, 0, 0}};
12259 
12269  _swigc__p_int,
12273 };
12274 
12275 
12276 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */
12277 
12278 /* -----------------------------------------------------------------------------
12279  * Type initialization:
12280  * This problem is tough by the requirement that no dynamic
12281  * memory is used. Also, since swig_type_info structures store pointers to
12282  * swig_cast_info structures and swig_cast_info structures store pointers back
12283  * to swig_type_info structures, we need some lookup code at initialization.
12284  * The idea is that swig generates all the structures that are needed.
12285  * The runtime then collects these partially filled structures.
12286  * The SWIG_InitializeModule function takes these initial arrays out of
12287  * swig_module, and does all the lookup, filling in the swig_module.types
12288  * array with the correct data and linking the correct swig_cast_info
12289  * structures together.
12290  *
12291  * The generated swig_type_info structures are assigned staticly to an initial
12292  * array. We just loop through that array, and handle each type individually.
12293  * First we lookup if this type has been already loaded, and if so, use the
12294  * loaded structure instead of the generated one. Then we have to fill in the
12295  * cast linked list. The cast data is initially stored in something like a
12296  * two-dimensional array. Each row corresponds to a type (there are the same
12297  * number of rows as there are in the swig_type_initial array). Each entry in
12298  * a column is one of the swig_cast_info structures for that type.
12299  * The cast_initial array is actually an array of arrays, because each row has
12300  * a variable number of columns. So to actually build the cast linked list,
12301  * we find the array of casts associated with the type, and loop through it
12302  * adding the casts to the list. The one last trick we need to do is making
12303  * sure the type pointer in the swig_cast_info struct is correct.
12304  *
12305  * First off, we lookup the cast->type name to see if it is already loaded.
12306  * There are three cases to handle:
12307  * 1) If the cast->type has already been loaded AND the type we are adding
12308  * casting info to has not been loaded (it is in this module), THEN we
12309  * replace the cast->type pointer with the type pointer that has already
12310  * been loaded.
12311  * 2) If BOTH types (the one we are adding casting info to, and the
12312  * cast->type) are loaded, THEN the cast info has already been loaded by
12313  * the previous module so we just ignore it.
12314  * 3) Finally, if cast->type has not already been loaded, then we add that
12315  * swig_cast_info to the linked list (because the cast->type) pointer will
12316  * be correct.
12317  * ----------------------------------------------------------------------------- */
12318 
12319 #ifdef __cplusplus
12320 extern "C" {
12321 #if 0
12322 } /* c-mode */
12323 #endif
12324 #endif
12325 
12326 #if 0
12327 #define SWIGRUNTIME_DEBUG
12328 #endif
12329 
12330 
12331 SWIGRUNTIME void
12332 SWIG_InitializeModule(void *clientdata) {
12333  size_t i;
12334  swig_module_info *module_head, *iter;
12335  int found, init;
12336 
12337  /* check to see if the circular list has been setup, if not, set it up */
12338  if (swig_module.next==0) {
12339  /* Initialize the swig_module */
12340  swig_module.type_initial = swig_type_initial;
12341  swig_module.cast_initial = swig_cast_initial;
12342  swig_module.next = &swig_module;
12343  init = 1;
12344  } else {
12345  init = 0;
12346  }
12347 
12348  /* Try and load any already created modules */
12349  module_head = SWIG_GetModule(clientdata);
12350  if (!module_head) {
12351  /* This is the first module loaded for this interpreter */
12352  /* so set the swig module into the interpreter */
12353  SWIG_SetModule(clientdata, &swig_module);
12354  module_head = &swig_module;
12355  } else {
12356  /* the interpreter has loaded a SWIG module, but has it loaded this one? */
12357  found=0;
12358  iter=module_head;
12359  do {
12360  if (iter==&swig_module) {
12361  found=1;
12362  break;
12363  }
12364  iter=iter->next;
12365  } while (iter!= module_head);
12366 
12367  /* if the is found in the list, then all is done and we may leave */
12368  if (found) return;
12369  /* otherwise we must add out module into the list */
12370  swig_module.next = module_head->next;
12371  module_head->next = &swig_module;
12372  }
12373 
12374  /* When multiple interpreters are used, a module could have already been initialized in
12375  a different interpreter, but not yet have a pointer in this interpreter.
12376  In this case, we do not want to continue adding types... everything should be
12377  set up already */
12378  if (init == 0) return;
12379 
12380  /* Now work on filling in swig_module.types */
12381 #ifdef SWIGRUNTIME_DEBUG
12382  printf("SWIG_InitializeModule: size %d\n", swig_module.size);
12383 #endif
12384  for (i = 0; i < swig_module.size; ++i) {
12385  swig_type_info *type = 0;
12386  swig_type_info *ret;
12387  swig_cast_info *cast;
12388 
12389 #ifdef SWIGRUNTIME_DEBUG
12390  printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
12391 #endif
12392 
12393  /* if there is another module already loaded */
12394  if (swig_module.next != &swig_module) {
12395  type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name);
12396  }
12397  if (type) {
12398  /* Overwrite clientdata field */
12399 #ifdef SWIGRUNTIME_DEBUG
12400  printf("SWIG_InitializeModule: found type %s\n", type->name);
12401 #endif
12402  if (swig_module.type_initial[i]->clientdata) {
12403  type->clientdata = swig_module.type_initial[i]->clientdata;
12404 #ifdef SWIGRUNTIME_DEBUG
12405  printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
12406 #endif
12407  }
12408  } else {
12409  type = swig_module.type_initial[i];
12410  }
12411 
12412  /* Insert casting types */
12413  cast = swig_module.cast_initial[i];
12414  while (cast->type) {
12415 
12416  /* Don't need to add information already in the list */
12417  ret = 0;
12418 #ifdef SWIGRUNTIME_DEBUG
12419  printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
12420 #endif
12421  if (swig_module.next != &swig_module) {
12422  ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
12423 #ifdef SWIGRUNTIME_DEBUG
12424  if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
12425 #endif
12426  }
12427  if (ret) {
12428  if (type == swig_module.type_initial[i]) {
12429 #ifdef SWIGRUNTIME_DEBUG
12430  printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
12431 #endif
12432  cast->type = ret;
12433  ret = 0;
12434  } else {
12435  /* Check for casting already in the list */
12436  swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
12437 #ifdef SWIGRUNTIME_DEBUG
12438  if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
12439 #endif
12440  if (!ocast) ret = 0;
12441  }
12442  }
12443 
12444  if (!ret) {
12445 #ifdef SWIGRUNTIME_DEBUG
12446  printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
12447 #endif
12448  if (type->cast) {
12449  type->cast->prev = cast;
12450  cast->next = type->cast;
12451  }
12452  type->cast = cast;
12453  }
12454  cast++;
12455  }
12456  /* Set entry in modules->types array equal to the type */
12457  swig_module.types[i] = type;
12458  }
12459  swig_module.types[i] = 0;
12460 
12461 #ifdef SWIGRUNTIME_DEBUG
12462  printf("**** SWIG_InitializeModule: Cast List ******\n");
12463  for (i = 0; i < swig_module.size; ++i) {
12464  int j = 0;
12465  swig_cast_info *cast = swig_module.cast_initial[i];
12466  printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
12467  while (cast->type) {
12468  printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
12469  cast++;
12470  ++j;
12471  }
12472  printf("---- Total casts: %d\n",j);
12473  }
12474  printf("**** SWIG_InitializeModule: Cast List ******\n");
12475 #endif
12476 }
12477 
12478 /* This function will propagate the clientdata field of type to
12479 * any new swig_type_info structures that have been added into the list
12480 * of equivalent types. It is like calling
12481 * SWIG_TypeClientData(type, clientdata) a second time.
12482 */
12483 SWIGRUNTIME void
12485  size_t i;
12486  swig_cast_info *equiv;
12487  static int init_run = 0;
12488 
12489  if (init_run) return;
12490  init_run = 1;
12491 
12492  for (i = 0; i < swig_module.size; i++) {
12493  if (swig_module.types[i]->clientdata) {
12494  equiv = swig_module.types[i]->cast;
12495  while (equiv) {
12496  if (!equiv->converter) {
12497  if (equiv->type && !equiv->type->clientdata)
12498  SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata);
12499  }
12500  equiv = equiv->next;
12501  }
12502  }
12503  }
12504 }
12505 
12506 #ifdef __cplusplus
12507 #if 0
12508 { /* c-mode */
12509 #endif
12510 }
12511 #endif
12512 
12513 
12514 
12515 /* Forward declaration of where the user's %init{} gets inserted */
12516 void SWIG_init_user(lua_State* L );
12517 
12518 #ifdef __cplusplus
12519 extern "C" {
12520 #endif
12521 /* this is the initialization function
12522  added at the very end of the code
12523  the function is always called SWIG_init, but an earlier #define will rename it
12524 */
12525 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
12526 LUALIB_API int SWIG_init(lua_State* L)
12527 #else
12528 SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */
12529 #endif
12530 {
12531 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC) /* valid for both Lua and eLua */
12532  int i;
12533  /* start with global table */
12534  lua_pushglobaltable (L);
12535  /* SWIG's internal initalisation */
12536  SWIG_InitializeModule((void*)L);
12538 #endif
12539 
12540 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
12541  /* add a global fn */
12542  SWIG_Lua_add_function(L,"swig_type",SWIG_Lua_type);
12543  SWIG_Lua_add_function(L,"swig_equals",SWIG_Lua_equal);
12544  /* begin the module (its a table with the same name as the module) */
12546  /* add commands/functions */
12547  for (i = 0; swig_commands[i].name; i++){
12548  SWIG_Lua_module_add_function(L,swig_commands[i].name,swig_commands[i].func);
12549  }
12550  /* add variables */
12551  for (i = 0; swig_variables[i].name; i++){
12552  SWIG_Lua_module_add_variable(L,swig_variables[i].name,swig_variables[i].get,swig_variables[i].set);
12553  }
12554 #endif
12555 
12556 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
12557  /* set up base class pointers (the hierarchy) */
12558  for (i = 0; swig_types[i]; i++){
12559  if (swig_types[i]->clientdata){
12560  SWIG_Lua_init_base_class(L,(swig_lua_class*)(swig_types[i]->clientdata));
12561  }
12562  }
12563  /* additional registration structs & classes in lua */
12564  for (i = 0; swig_types[i]; i++){
12565  if (swig_types[i]->clientdata){
12566  SWIG_Lua_class_register(L,(swig_lua_class*)(swig_types[i]->clientdata));
12567  }
12568  }
12569 #endif
12570 
12571 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
12572  /* constants */
12573  SWIG_Lua_InstallConstants(L,swig_constants);
12574 #endif
12575 
12576 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
12577  /* invoke user-specific initialization */
12578  SWIG_init_user(L);
12579  /* end module */
12580  /* Note: We do not clean up the stack here (Lua will do this for us). At this
12581  point, we have the globals table and out module table on the stack. Returning
12582  one value makes the module table the result of the require command. */
12583  return 1;
12584 #else
12585  return 0;
12586 #endif
12587 }
12588 
12589 #ifdef __cplusplus
12590 }
12591 #endif
12592 
12593 
12594 const char* SWIG_LUACODE=
12595  "\n"
12596  " pl = plplotluac";
12597 
12598 void SWIG_init_user(lua_State* L)
12599 {
12600  /* exec Lua code if applicable */
12601  SWIG_Lua_dostring(L,SWIG_LUACODE);
12602 }
12603 
static int _wrap_bin(lua_State *L)
static swig_cast_info _swigc__p_f_double_double__int[]
struct swig_type_info swig_type_info
#define SWIG_fail
static int _wrap_rgbhls(lua_State *L)
static lua_State * myL
#define plsfam
Definition: plplot.h:819
static char myct_funcstr[255]
#define plw3d
Definition: plplot.h:864
void(* label_func)(PLINT, PLFLT, char *, PLINT, PLPointer)
static int _wrap_box(lua_State *L)
static int _wrap_PLGraphicsIn_pX_get(lua_State *L)
static const char * name
Definition: tkMain.c:135
#define plpath
Definition: plplot.h:760
static swig_module_info swig_module
SWIGINTERN void SWIG_Lua_get_class_registry(lua_State *L)
SWIGRUNTIME char * SWIG_PackData(char *c, void *ptr, size_t sz)
static int _wrap_mtex3(lua_State *L)
#define plgxax
Definition: plplot.h:744
#define plsstrm
Definition: plplot.h:837
void(* ct_func)(PLFLT, PLFLT, PLFLT *, PLFLT *, PLPointer)
static int _wrap_PLGraphicsIn_string_set(lua_State *L)
PLINT plGetCursor(PLGraphicsIn *plg)
Definition: plpage.c:244
static swig_lua_attribute swig_PLGraphicsIn_attributes[]
static int _wrap_plot3d(lua_State *L)
static int _wrap_spal1(lua_State *L)
static swig_type_info _swigt__p_char
#define plspage
Definition: plplot.h:833
static int _wrap_scmap1a(lua_State *L)
#define plvpor
Definition: plplot.h:862
SWIGINTERN void SWIG_write_ptr_array(lua_State *L, void **array, int size, swig_type_info *type, int own)
static swig_lua_method swig_PLGraphicsIn_cls_methods[]
static int _wrap_sfont(lua_State *L)
static int _wrap_imagefr(lua_State *L)
static int _wrap_gfam(lua_State *L)
#define SWIG_name
static int _wrap_gra(lua_State *L)
static int _wrap_PLGraphicsIn_keysym_set(lua_State *L)
#define SWIG_LUA_CONSTTAB_INT(B, C)
#define plmtex3
Definition: plplot.h:773
#define plerry
Definition: plplot.h:712
static int _wrap_PLGraphicsIn_wX_get(lua_State *L)
SWIGRUNTIME swig_type_info * SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr)
#define plsyax
Definition: plplot.h:854
SWIGINTERN void SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[])
#define plschr
Definition: plplot.h:793
#define plsdev
Definition: plplot.h:810
SWIGINTERN void ** SWIG_get_ptr_array_fixed(lua_State *L, int index, int size, swig_type_info *type)
static void swig_delete_PLGraphicsIn(void *obj)
#define plgdev
Definition: plplot.h:725
static int _wrap_scolor(lua_State *L)
static int _wrap_setopt(lua_State *L)
#define SWIG_Lua_get_table(L, n)
static int _wrap_vsta(lua_State *L)
static int _wrap_PLGraphicsIn_subwindow_get(lua_State *L)
#define pllegend
Definition: plplot.h:757
static int _wrap_plGetCursor(lua_State *L)
SWIGINTERN void SWIG_Lua_get_class_metatable(lua_State *L, const char *cname)
#define SWIG_LUA_INT
static char mylabel_funcstr[255]
static int _wrap_pat(lua_State *L)
static int _wrap_PLGraphicsIn_dY_set(lua_State *L)
static int _wrap_scmap1la(lua_State *L)
#define plshade
Definition: plplot.h:823
#define plscompression
Definition: plplot.h:809
static int _wrap_scompression(lua_State *L)
#define plarc
Definition: plplot.h:690
SWIGRUNTIME int SWIG_Lua_equal(lua_State *L)
PLFLT(* f2eval_func)(PLINT, PLINT, PLPointer)
PLUINT PLUNICODE
Definition: plplot.h:194
static int _wrap_spause(lua_State *L)
SWIGINTERN int SWIG_Lua_class_set(lua_State *L)
static int _wrap_poin(lua_State *L)
SWIGINTERN int SWIG_Lua_namespace_set(lua_State *L)
PLINT nz
Definition: plplot.h:521
#define plot3dc
Definition: plplot.h:775
#define plot3dcl
Definition: plplot.h:776
static int _wrap_arc(lua_State *L)
SWIGRUNTIME int SWIG_TypeCmp(const char *nb, const char *tb)
SWIGINTERN void SWIG_Lua_class_register(lua_State *L, swig_lua_class *clss)
#define pllsty
Definition: plplot.h:762
static int _wrap_eop(lua_State *L)
SWIGRUNTIMEINLINE const char * SWIG_TypeName(const swig_type_info *ty)
SWIGINTERN void SWIG_Lua_init_base_class(lua_State *L, swig_lua_class *clss)
#define plsmin
Definition: plplot.h:830
#define plwind
Definition: plplot.h:869
#define plclear
Definition: plplot.h:698
#define plfill
Definition: plplot.h:714
#define plconfigtime
Definition: plplot.h:702
#define plsurf3dl
Definition: plplot.h:850
SWIGINTERN void ** SWIG_get_ptr_array_var(lua_State *L, int index, int *size, swig_type_info *type)
SWIGINTERN void SWIG_Lua_add_class_details(lua_State *L, swig_lua_class *clss)
SWIGINTERN int SWIG_Lua_dostring(lua_State *L, const char *str)
static int _wrap_gdev(lua_State *L)
static int _wrap_mapline(lua_State *L)
void plmapline(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:628
static int _wrap_scolbg(lua_State *L)
#define plbtime
Definition: plplot.h:696
#define pl_setcontlabelparam
Definition: plplot.h:688
#define SWIG_DOSTRING_FAIL(S)
static int _wrap_szax(lua_State *L)
#define LUA_DECLARE_TYPEMAP_ARR_FN(NAME, TYPE)
static int _wrap_vpas(lua_State *L)
static int _wrap_plClearOpts(lua_State *L)
static int _wrap_scol0a(lua_State *L)
static int _wrap_PLGraphicsIn_pY_set(lua_State *L)
static swig_type_info _swigt__p_p_double
#define plscolbg
Definition: plplot.h:806
swig_dycast_func dcast
static int _wrap_PLGraphicsIn_dX_set(lua_State *L)
struct swig_cast_info * cast
#define plfont
Definition: plplot.h:717
static int _wrap_PLGraphicsIn_type_get(lua_State *L)
#define plstyl
Definition: plplot.h:848
#define plpoly3
Definition: plplot.h:781
#define SWIG_ConvertPtr(L, idx, ptr, type, flags)
swig_type_info ** type
#define plimage
Definition: plplot.h:752
swig_type_info * type
static int _wrap_lightsource(lua_State *L)
SWIGRUNTIME swig_cast_info * SWIG_TypeCheck(const char *c, swig_type_info *ty)
SWIGINTERN void SWIG_Lua_module_add_function(lua_State *L, const char *name, lua_CFunction fn)
#define plfontld
Definition: plplot.h:718
#define SWIG_RUNTIME_VERSION
static int _wrap_image(lua_State *L)
#define plscolbga
Definition: plplot.h:807
#define SWIGRUNTIMEINLINE
#define plbin
Definition: plplot.h:692
static int _wrap_plot3dcl(lua_State *L)
static int _wrap_setcontlabelformat(lua_State *L)
#define plsdiori
Definition: plplot.h:813
static int _wrap_PLGraphicsIn_dY_get(lua_State *L)
SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State *L, void *ptr, swig_type_info *type, int own)
void plmeridians(PLMAPFORM_callback mapform, PLFLT dlong, PLFLT dlat, PLFLT minlong, PLFLT maxlong, PLFLT minlat, PLFLT maxlat)
Definition: plmap.c:742
#define plparseopts
Definition: plplot.h:777
void plmaptex(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT dx, PLFLT dy, PLFLT just, PLCHAR_VECTOR text, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT plotentry)
Definition: plmap.c:673
#define SWIGRUNTIME
#define plsym
Definition: plplot.h:855
static int _wrap_scol0(lua_State *L)
#define plscmap1
Definition: plplot.h:797
struct swig_type_info *(* swig_dycast_func)(void **)
static int _wrap_poin3(lua_State *L)
#define plinit
Definition: plplot.h:754
#define plctime
Definition: plplot.h:705
#define pltimefmt
Definition: plplot.h:858
SWIGINTERN int SWIG_Lua_class_tostring(lua_State *L)
#define plscmap1n
Definition: plplot.h:801
static int _wrap_gcol0(lua_State *L)
static int _wrap_prec(lua_State *L)
#define plbop
Definition: plplot.h:693
static int _wrap_scolbga(lua_State *L)
static int _wrap_plend(lua_State *L)
static int _wrap_slabelfunc(lua_State *L)
void plabort(PLCHAR_VECTOR errormsg)
Definition: plctrl.c:1884
static int _wrap_plOptUsage(lua_State *L)
#define plsdiplt
Definition: plplot.h:814
#define plsvect
Definition: plplot.h:851
#define plscmap1a
Definition: plplot.h:798
#define plssub
Definition: plplot.h:838
static int _wrap_start(lua_State *L)
static swig_type_info _swigt__p_int
static swig_type_info _swigt__p_double
void * PLPointer
Definition: plplot.h:202
#define plspal1
Definition: plplot.h:835
#define plsetopt
Definition: plplot.h:818
static int _wrap_lab(lua_State *L)
#define plmeshc
Definition: plplot.h:770
#define plgcompression
Definition: plplot.h:724
static int _wrap_sesc(lua_State *L)
#define SWIG_DECLARE_TYPEMAP_ARR_FN(NAME, TYPE)
#define SWIG_GetModule(clientdata)
#define plszax
Definition: plplot.h:856
#define plvsta
Definition: plplot.h:863
static int _wrap_map(lua_State *L)
static swig_type_info _swigt__p_f_int_p_double_p_double__void
static int _wrap_replot(lua_State *L)
void *(* swig_converter_func)(void *, int *)
SWIGINTERN int SWIG_Lua_class_get(lua_State *L)
static int _wrap_gcolbga(lua_State *L)
SWIGINTERN int SWIG_itable_size(lua_State *L, int index)
#define plgpage
Definition: plplot.h:735
#define plaxes
Definition: plplot.h:691
#define plsori
Definition: plplot.h:832
static char mapform_funcstr[255]
#define plgdiplt
Definition: plplot.h:728
#define plscmap0a
Definition: plplot.h:795
PLINT ny
Definition: plplot.h:533
static const char * swig_PLGraphicsIn_base_names[]
#define plfamadv
Definition: plplot.h:713
static int _wrap_gcolbg(lua_State *L)
static int _wrap_schr(lua_State *L)
SWIGINTERN int SWIG_Lua_class_disown(lua_State *L)
static int _wrap_randd(lua_State *L)
#define plend
Definition: plplot.h:706
SWIGRUNTIME int SWIG_Lua_ConvertPtr(lua_State *L, int index, void **ptr, swig_type_info *type, int flags)
static int _wrap_poly3(lua_State *L)
SWIGRUNTIME swig_cast_info * SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty)
swig_lua_attribute * attributes
SWIGINTERN void SWIG_Lua_class_register_static(lua_State *L, swig_lua_class *clss)
static int _wrap_string3(lua_State *L)
static swig_type_info _swigt__p_f_double_double_p_double_p_double_p_void__void
SWIGRUNTIME int SWIG_TypeEquiv(const char *nb, const char *tb)
static int _wrap_PLGraphicsIn_wY_get(lua_State *L)
static int _wrap_stripa(lua_State *L)
#define plgfont
Definition: plplot.h:733
#define SWIG_init
static int _wrap_PLGraphicsIn_state_set(lua_State *L)
#define plend1
Definition: plplot.h:707
int PLINT
Definition: plplot.h:174
#define plenv0
Definition: plplot.h:709
static int _wrap_mapstring(lua_State *L)
static int _wrap_sdiori(lua_State *L)
static int _wrap_erry(lua_State *L)
#define plgdiori
Definition: plplot.h:727
SWIGRUNTIME swig_type_info * SWIG_TypeQueryModule(swig_module_info *start, swig_module_info *end, const char *name)
#define plshades
Definition: plplot.h:825
static int _wrap_scmap1n(lua_State *L)
PLINT PLBOOL
Definition: plplot.h:197
#define SWIG_LUA_FLOAT
#define SWIG_fail_arg(func_name, argnum, type)
void(* fill_func)(PLINT, const PLFLT *, const PLFLT *)
#define SWIG_FREE_ARRAY(PTR)
static int _wrap_meshc(lua_State *L)
static swig_type_info _swigt__p_PLGraphicsIn
static int _wrap_PLGraphicsIn_wX_set(lua_State *L)
#define plssym
Definition: plplot.h:839
static int _wrap_smaj(lua_State *L)
PLFLT_NC_MATRIX yg
Definition: plplot.h:532
#define pljoin
Definition: plplot.h:755
#define plgzax
Definition: plplot.h:746
static int _wrap_sori(lua_State *L)
static int _wrap_surf3d(lua_State *L)
static int _wrap_line(lua_State *L)
#define SWIGEXPORT
SWIGRUNTIME int SWIG_Lua_ConvertPacked(lua_State *L, int index, void *ptr, size_t size, swig_type_info *type)
static int _wrap_new_PLGraphicsIn(lua_State *L)
#define plgfam
Definition: plplot.h:730
PLINT ny
Definition: plplot.h:521
#define plgdidev
Definition: plplot.h:726
static int _wrap_col1(lua_State *L)
static int _wrap_legend(lua_State *L)
#define plstar
Definition: plplot.h:840
static int _wrap_stransform(lua_State *L)
static int _wrap_glevel(lua_State *L)
void(* pltr_func)(PLFLT, PLFLT, PLFLT *, PLFLT *, PLPointer)
static swig_cast_info _swigc__p_f_int_p_double_p_double__void[]
#define plcpstrm
Definition: plplot.h:704
#define plimagefr
Definition: plplot.h:753
#define plcalc_world
Definition: plplot.h:697
void mypltr(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void *pltr_data)
static swig_cast_info _swigc__p_double[]
#define lua_pushglobaltable(L)
#define plsfnam
Definition: plplot.h:821
swig_type_info * type
#define plhist
Definition: plplot.h:747
static int _wrap_font(lua_State *L)
static int _wrap_scmap1(lua_State *L)
SWIGRUNTIME void SWIG_InitializeModule(void *clientdata)
static int _wrap_ssym(lua_State *L)
#define plgchr
Definition: plplot.h:719
SWIGINTERN int SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns)
struct swig_module_info * next
#define SWIG_ERROR
#define SWIGTYPE_p_PLGraphicsIn
static int _wrap_path(lua_State *L)
#define plsdidev
Definition: plplot.h:811
SWIGRUNTIME void SWIG_Lua_SetModule(lua_State *L, swig_module_info *module)
#define SWIG_SetModule(clientdata, pointer)
#define plspal0
Definition: plplot.h:834
static int _wrap_scmap0n(lua_State *L)
plSetUsage
Definition: plplotc.py:8413
#define plfill3
Definition: plplot.h:715
static int _wrap_box3(lua_State *L)
const char ** base_names
static int _wrap_spal0(lua_State *L)
SWIGRUNTIME int SWIG_TypeNameComp(const char *f1, const char *l1, const char *f2, const char *l2)
static int _wrap_plend1(lua_State *L)
static int _wrap_gspa(lua_State *L)
static int _wrap_plSetUsage(lua_State *L)
static int _wrap_gfont(lua_State *L)
static int _wrap_sdiplz(lua_State *L)
static int _wrap_gdidev(lua_State *L)
swig_converter_func converter
static int _wrap_ptex3(lua_State *L)
#define plseed
Definition: plplot.h:816
static int _wrap_PLGraphicsIn_type_set(lua_State *L)
PLFLT_NC_FE_POINTER yg
Definition: plplot.h:520
#define plstring
Definition: plplot.h:843
plOptUsage
Definition: plplotc.py:8417
#define plstransform
Definition: plplot.h:842
#define plvect
Definition: plplot.h:860
SWIGINTERN void SWIG_Lua_add_class_variable(lua_State *L, const char *name, lua_CFunction getFn, lua_CFunction setFn)
swig_type_info * type
static int _wrap_adv(lua_State *L)
PLFLT_NC_FE_POINTER zg
Definition: plplot.h:520
void mapform(PLINT n, PLFLT *x, PLFLT *y)
static int _wrap_sfam(lua_State *L)
#define plscmap1la
Definition: plplot.h:800
#define plgfnam
Definition: plplot.h:732
static swig_cast_info _swigc__p_f_double_double_p_double_p_double_p_void__void[]
static swig_lua_const_info swig_PLGraphicsIn_cls_constants[]
static int _wrap_vasp(lua_State *L)
#define plcont
Definition: plplot.h:703
#define plsxax
Definition: plplot.h:853
#define plstart
Definition: plplot.h:841
plClearOpts
Definition: plplotc.py:8405
#define pleop
Definition: plplot.h:710
static swig_type_info _swigt__p_p_char
#define plmesh
Definition: plplot.h:769
static int _wrap_PLGraphicsIn_button_set(lua_State *L)
static int _wrap_bop(lua_State *L)
#define plhlsrgb
Definition: plplot.h:751
swig_type_info ** types
static int _wrap_cont(lua_State *L)
SWIGINTERN int SWIG_Lua_module_get(lua_State *L)
#define plsmaj
Definition: plplot.h:827
PLINT nx
Definition: plplot.h:533
#define SWIG_fail_ptr(func_name, argnum, type)
static int _wrap_plot3dc(lua_State *L)
static int _wrap_surf3dl(lua_State *L)
SWIGRUNTIME swig_module_info * SWIG_Lua_GetModule(lua_State *L)
PLFLT ** read_double_Matrix(lua_State *L, int index, int *nx, int *ny)
SWIGINTERN int SWIG_lua_isnilstring(lua_State *L, int idx)
static swig_lua_class * swig_PLGraphicsIn_bases[]
#define plcol1
Definition: plplot.h:700
#define pllab
Definition: plplot.h:756
#define pllightsource
Definition: plplot.h:758
SWIGINTERN void SWIG_Lua_add_class_static_details(lua_State *L, swig_lua_class *clss)
swig_lua_namespace cls_static
#define SWIGINTERN
#define plbox
Definition: plplot.h:694
pl_setcontlabelformat
Definition: tclgen_s.h:1
#define SWIG_init_user
SWIGRUNTIMEINLINE void * SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory)
lua_CFunction constructor
#define pltext
Definition: plplot.h:857
plMinMax2dGrid
Definition: plplotc.py:8421
static int _wrap_lsty(lua_State *L)
#define plwidth
Definition: plplot.h:868
#define plgver
Definition: plplot.h:741
static int _wrap_smin(lua_State *L)
static int _wrap_mkstrm(lua_State *L)
#define plscol0a
Definition: plplot.h:805
static swig_cast_info _swigc__p_p_char[]
static int _wrap_wind(lua_State *L)
#define plptex3
Definition: plplot.h:785
static int _wrap_vect(lua_State *L)
static const struct luaL_Reg swig_commands[]
static int _wrap_cpstrm(lua_State *L)
#define plsdiplz
Definition: plplot.h:815
static int _wrap_sfci(lua_State *L)
static int _wrap_text(lua_State *L)
static int _wrap_parseopts(lua_State *L)
#define SWIG_TYPE_TABLE_NAME
#define plspause
Definition: plplot.h:836
SWIGRUNTIME const char * SWIG_Lua_typename(lua_State *L, int tp)
static int _wrap_hist(lua_State *L)
static PLINT Ylen
#define plline3
Definition: plplot.h:761
static char mypltr_funcstr[255]
#define plstripd
Definition: plplot.h:847
#define plgfci
Definition: plplot.h:731
#define plgspa
Definition: plplot.h:739
#define plgcolbg
Definition: plplot.h:722
#define plstripc
Definition: plplot.h:846
static int _wrap_gpage(lua_State *L)
static swig_lua_attribute swig_PLGraphicsIn_cls_attributes[]
SWIGRUNTIME void SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata)
#define plstripa
Definition: plplot.h:845
#define SWIG_LUA_STRING
static int _wrap_mapfill(lua_State *L)
static int _wrap_svpa(lua_State *L)
#define plstring3
Definition: plplot.h:844
static PLINT Alen
#define SWIG_NewMemberObj(L, ptr, sz, type)
#define plvpas
Definition: plplot.h:861
void(* mapform_func)(PLINT, PLFLT *, PLFLT *)
void myct(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void *pltr_data)
SWIGINTERN void _SWIG_Lua_AddMetatable(lua_State *L, swig_type_info *type)
static swig_type_info _swigt__p_f_int_double_p_char_int_p_void__void
#define plsfont
Definition: plplot.h:822
void plmapfill(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:695
static int _wrap_fill(lua_State *L)
SWIGINTERN int SWIG_table_size(lua_State *L, int index)
static int _wrap_gver(lua_State *L)
PLINT(* defined_func)(PLFLT, PLFLT)
static int _wrap_gfci(lua_State *L)
static int _wrap_famadv(lua_State *L)
static int _wrap_fontld(lua_State *L)
#define plpsty
Definition: plplot.h:783
SWIGINTERN void SWIG_Lua_module_begin(lua_State *L, const char *name)
static int _wrap_sym(lua_State *L)
static int _wrap_gyax(lua_State *L)
SWIGRUNTIME void SWIG_TypeClientData(swig_type_info *ti, void *clientdata)
static PLFLT value(double n1, double n2, double hue)
Definition: plctrl.c:1209
SWIGRUNTIME int SWIG_Lua_type(lua_State *L)
SWIGRUNTIME const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz)
#define plgvpd
Definition: plplot.h:742
#define plpoin
Definition: plplot.h:779
#define plgriddata
Definition: plplot.h:738
#define plgvpw
Definition: plplot.h:743
static int _wrap_plResetOpts(lua_State *L)
static int _wrap_PLGraphicsIn_state_get(lua_State *L)
#define SWIG_NewPointerObj(L, ptr, type, owner)
static int _wrap_ptex(lua_State *L)
SWIGINTERN int SWIG_Lua_class_destruct(lua_State *L)
static int _wrap_env(lua_State *L)
#define SWIG_ALLOC_ARRAY(TYPE, LEN)
static int _wrap_mesh(lua_State *L)
SWIGRUNTIME swig_type_info * SWIG_MangledTypeQueryModule(swig_module_info *start, swig_module_info *end, const char *name)
static int _wrap_maptex(lua_State *L)
SWIGINTERN int SWIG_read_ptr_array(lua_State *L, int index, void **array, int size, swig_type_info *type)
static int _wrap_gvpw(lua_State *L)
#define SWIG_Lua_add_function(L, n, f)
static int _wrap_w3d(lua_State *L)
static int _wrap_griddata(lua_State *L)
static int _wrap_MinMax2dGrid(lua_State *L)
SWIGRUNTIME char * SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz)
#define plmkstrm
Definition: plplot.h:771
#define PL_UNUSED(x)
Definition: plplot.h:128
float PLFLT
Definition: plplot.h:157
void mylabel(PLINT axis, PLFLT value, char *label, PLINT length, PLPointer data)
#define plscol0
Definition: plplot.h:804
struct swig_module_info swig_module_info
static int _wrap_warn(lua_State *L)
#define plxormod
Definition: plplot.h:870
static int _wrap_mtex(lua_State *L)
swig_lua_method * methods
static int _wrap_flush(lua_State *L)
#define plflush
Definition: plplot.h:716
#define plerrx
Definition: plplot.h:711
PLFLT_NC_MATRIX zg
Definition: plplot.h:532
SWIGRUNTIME const char * SWIG_TypePrettyName(const swig_type_info *type)
#define SWIG_LUACODE
#define SWIG_LUA_CHAR
static int _wrap_configtime(lua_State *L)
#define plgcol0a
Definition: plplot.h:721
SWIGINTERN void SWIG_Lua_module_add_variable(lua_State *L, const char *name, lua_CFunction getFn, lua_CFunction setFn)
static swig_type_info * swig_types[13]
static int _wrap_sxax(lua_State *L)
SWIGRUNTIME void SWIG_PropagateClientData(void)
#define plgcolbga
Definition: plplot.h:723
SWIGINTERN int SWIG_Lua_module_set(lua_State *L)
static swig_cast_info _swigc__p_f_int_p_q_const__double_p_q_const__double__void[]
static int _wrap_init(lua_State *L)
lua_CFunction method
static int _wrap_shades(lua_State *L)
#define plgyax
Definition: plplot.h:745
#define plsesc
Definition: plplot.h:817
static swig_type_info _swigt__p_f_int_p_q_const__double_p_q_const__double__void
static int _wrap_gzax(lua_State *L)
#define SWIG_isptrtype(L, I)
swig_lua_const_info * ns_constants
#define plenv
Definition: plplot.h:708
static int _wrap_star(lua_State *L)
#define SWIG_LUA_BINARY
static swig_cast_info * swig_cast_initial[]
static int _wrap_scmap1l(lua_State *L)
struct swig_cast_info * next
static int _wrap_meridians(lua_State *L)
struct swig_lua_class swig_lua_class
swig_lua_method * ns_methods
static swig_cast_info _swigc__p_int[]
#define plgcmap1_range
Definition: plplot.h:803
#define plcol0
Definition: plplot.h:699
static int _wrap_PLGraphicsIn_pX_set(lua_State *L)
static int _wrap_gcompression(lua_State *L)
#define plbox3
Definition: plplot.h:695
static int _wrap_ctime(lua_State *L)
static int _wrap_scmap0(lua_State *L)
#define LUA_FREE_ARRAY(PTR)
#define SWIG_CheckState(r)
static int _wrap_timefmt(lua_State *L)
#define plcolorbar
Definition: plplot.h:701
static int _wrap_axes(lua_State *L)
static PLINT Xlen
static int _wrap_gcmap1_range(lua_State *L)
static swig_cast_info _swigc__p_p_double[]
#define LUA_ALLOC_ARRAY(TYPE, LEN)
static int _wrap_stripd(lua_State *L)
#define plglevel
Definition: plplot.h:734
PLFLT_NC_FE_POINTER xg
Definition: plplot.h:520
static int _wrap_PLGraphicsIn_pY_get(lua_State *L)
static swig_lua_class _wrap_class_PLGraphicsIn
static swig_type_info _swigt__p_unsigned_int
static swig_type_info _swigt__p_f_double_double__int
static swig_lua_const_info swig_constants[]
static int _wrap_sdev(lua_State *L)
static int _wrap_stripc(lua_State *L)
#define SWIG_LUA_POINTER
#define plpoin3
Definition: plplot.h:780
static int _wrap_PLGraphicsIn_keysym_get(lua_State *L)
static int _wrap_gxax(lua_State *L)
void plwarn(PLCHAR_VECTOR errormsg)
Definition: plctrl.c:1853
static int _wrap_PLGraphicsIn_string_get(lua_State *L)
#define plscmap0n
Definition: plplot.h:796
#define SWIG_AddCast(r)
#define plscolor
Definition: plplot.h:808
#define plsvpa
Definition: plplot.h:852
#define plpat
Definition: plplot.h:778
static int _wrap_gvpd(lua_State *L)
struct swig_lua_class ** bases
static int _wrap_gchr(lua_State *L)
#define plscmap1_range
Definition: plplot.h:802
#define SWIG_check_num_args(func_name, a, b)
struct swig_cast_info * prev
#define plgcol0
Definition: plplot.h:720
static int _wrap_sdidev(lua_State *L)
static swig_lua_method swig_PLGraphicsIn_methods[]
static int _wrap_scmap1_range(lua_State *L)
#define plreplot
Definition: plplot.h:787
swig_cast_info ** cast_initial
#define SWIG_POINTER_DISOWN
static int _wrap_PLGraphicsIn_button_get(lua_State *L)
swig_lua_attribute * ns_attributes
static int _wrap_colorbar(lua_State *L)
#define plscmap1l
Definition: plplot.h:799
void plmap(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy)
Definition: plmap.c:599
#define plprec
Definition: plplot.h:782
void(* destructor)(void *)
#define plptex
Definition: plplot.h:784
#define plline
Definition: plplot.h:759
PLFLT_NC_MATRIX xg
Definition: plplot.h:532
#define SWIG_contract_assert(expr, msg)
static int _wrap_width(lua_State *L)
static swig_cast_info _swigc__p_char[]
SWIGINTERN int SWIG_Lua_constructor_proxy(lua_State *L)
struct swig_cast_info swig_cast_info
#define plgradient
Definition: plplot.h:737
SWIGRUNTIME const char * SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name)
static int _wrap_shade(lua_State *L)
static swig_lua_var_info swig_variables[]
swig_type_info ** ptype
static int _wrap_gradient(lua_State *L)
static int _wrap_join(lua_State *L)
swig_type_info ** type_initial
static int _wrap_PLGraphicsIn_dX_get(lua_State *L)
static int _wrap_hlsrgb(lua_State *L)
static int _wrap_psty(lua_State *L)
static int _wrap_gdiplt(lua_State *L)
static int _wrap_setcontlabelparam(lua_State *L)
static int _wrap_gdiori(lua_State *L)
SWIGINTERN int SWIG_Lua_namespace_get(lua_State *L)
#define pladv
Definition: plplot.h:689
#define SWIG_OK
#define SWIGINTERNINLINE
SWIGRUNTIME char * SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz)
#define plvasp
Definition: plplot.h:859
static int _wrap_line3(lua_State *L)
#define plrandd
Definition: plplot.h:786
static int _wrap_sstrm(lua_State *L)
SWIGRUNTIME void SWIG_Lua_pusherrstring(lua_State *L, const char *str)
static swig_type_info * swig_type_initial[]
#define plscmap0
Definition: plplot.h:794
static swig_cast_info _swigc__p_unsigned_int[]
void plmapstring(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLCHAR_VECTOR string, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:650
static int _wrap_sfnam(lua_State *L)
#define plgstrm
Definition: plplot.h:740
#define SWIG_IsOK(r)
static int _wrap_seed(lua_State *L)
static int _wrap_abort(lua_State *L)
static swig_cast_info _swigc__p_PLGraphicsIn[]
static int _wrap_gfnam(lua_State *L)
static int _wrap_sdimap(lua_State *L)
#define plsfci
Definition: plplot.h:820
static int _wrap_col0(lua_State *L)
SWIGINTERN void SWIG_Lua_module_end(lua_State *L)
static int _wrap_svect(lua_State *L)
static int _wrap_styl(lua_State *L)
static int _wrap_gstrm(lua_State *L)
static int _wrap_clear(lua_State *L)
static int _wrap_spage(lua_State *L)
char string[PL_MAXKEY]
Definition: plplot.h:452
plResetOpts
Definition: plplotc.py:8409
static swig_cast_info _swigc__p_f_int_double_p_char_int_p_void__void[]
static int _wrap_vpor(lua_State *L)
#define plmtex
Definition: plplot.h:772
#define plrgbhls
Definition: plplot.h:792
#define plsurf3d
Definition: plplot.h:849
static int _wrap_errx(lua_State *L)
#define plgra
Definition: plplot.h:736
static int _wrap_gcol0a(lua_State *L)
#define plsdimap
Definition: plplot.h:812
static int _wrap_scmap0a(lua_State *L)
static int _wrap_calc_world(lua_State *L)
SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State *L, void *ptr, size_t size, swig_type_info *type)
static int _wrap_sdiplt(lua_State *L)
static int _wrap_string(lua_State *L)
static int _wrap_PLGraphicsIn_wY_set(lua_State *L)
static int _wrap_btime(lua_State *L)
SWIGRUNTIME void * SWIG_Lua_MustGetPtr(lua_State *L, int index, swig_type_info *type, int flags, int argnum, const char *func_name)
#define plot3d
Definition: plplot.h:774
SWIGINTERN int SWIG_Lua_set_immutable(lua_State *L)
static int _wrap_env0(lua_State *L)
SWIGINTERN int SWIG_Lua_add_namespace_details(lua_State *L, swig_lua_namespace *ns)
static int _wrap_PLGraphicsIn_subwindow_set(lua_State *L)
#define plslabelfunc
Definition: plplot.h:826
PLINT nx
Definition: plplot.h:521
SWIGRUNTIME void SWIG_Lua_pushferrstring(lua_State *L, const char *fmt,...)
static int _wrap_ssub(lua_State *L)
SWIGRUNTIME const char * SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name)
static int _wrap_xormod(lua_State *L)
static int _wrap_fill3(lua_State *L)
static int _wrap_syax(lua_State *L)