PLplot  5.14.0
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 4.0.0
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 
12 #ifndef SWIGLUA
13 #define SWIGLUA
14 #endif
15 
16 #define SWIG_LUA_TARGET SWIG_LUA_FLAVOR_LUA
17 #define SWIG_LUA_MODULE_GLOBAL
18 
19 /* -----------------------------------------------------------------------------
20  * This section contains generic SWIG labels for method/variable
21  * declarations/attributes, and other compiler dependent labels.
22  * ----------------------------------------------------------------------------- */
23 
24 /* template workaround for compilers that cannot correctly implement the C++ standard */
25 #ifndef SWIGTEMPLATEDISAMBIGUATOR
26 # if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
27 # define SWIGTEMPLATEDISAMBIGUATOR template
28 # elif defined(__HP_aCC)
29 /* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
30 /* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
31 # define SWIGTEMPLATEDISAMBIGUATOR template
32 # else
33 # define SWIGTEMPLATEDISAMBIGUATOR
34 # endif
35 #endif
36 
37 /* inline attribute */
38 #ifndef SWIGINLINE
39 # if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
40 # define SWIGINLINE inline
41 # else
42 # define SWIGINLINE
43 # endif
44 #endif
45 
46 /* attribute recognised by some compilers to avoid 'unused' warnings */
47 #ifndef SWIGUNUSED
48 # if defined(__GNUC__)
49 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
50 # define SWIGUNUSED __attribute__ ((__unused__))
51 # else
52 # define SWIGUNUSED
53 # endif
54 # elif defined(__ICC)
55 # define SWIGUNUSED __attribute__ ((__unused__))
56 # else
57 # define SWIGUNUSED
58 # endif
59 #endif
60 
61 #ifndef SWIG_MSC_UNSUPPRESS_4505
62 # if defined(_MSC_VER)
63 # pragma warning(disable : 4505) /* unreferenced local function has been removed */
64 # endif
65 #endif
66 
67 #ifndef SWIGUNUSEDPARM
68 # ifdef __cplusplus
69 # define SWIGUNUSEDPARM(p)
70 # else
71 # define SWIGUNUSEDPARM(p) p SWIGUNUSED
72 # endif
73 #endif
74 
75 /* internal SWIG method */
76 #ifndef SWIGINTERN
77 # define SWIGINTERN static SWIGUNUSED
78 #endif
79 
80 /* internal inline SWIG method */
81 #ifndef SWIGINTERNINLINE
82 # define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
83 #endif
84 
85 /* exporting methods */
86 #if defined(__GNUC__)
87 # if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
88 # ifndef GCC_HASCLASSVISIBILITY
89 # define GCC_HASCLASSVISIBILITY
90 # endif
91 # endif
92 #endif
93 
94 #ifndef SWIGEXPORT
95 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
96 # if defined(STATIC_LINKED)
97 # define SWIGEXPORT
98 # else
99 # define SWIGEXPORT __declspec(dllexport)
100 # endif
101 # else
102 # if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
103 # define SWIGEXPORT __attribute__ ((visibility("default")))
104 # else
105 # define SWIGEXPORT
106 # endif
107 # endif
108 #endif
109 
110 /* calling conventions for Windows */
111 #ifndef SWIGSTDCALL
112 # if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
113 # define SWIGSTDCALL __stdcall
114 # else
115 # define SWIGSTDCALL
116 # endif
117 #endif
118 
119 /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
120 #if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
121 # define _CRT_SECURE_NO_DEPRECATE
122 #endif
123 
124 /* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
125 #if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
126 # define _SCL_SECURE_NO_DEPRECATE
127 #endif
128 
129 /* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */
130 #if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES)
131 # define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
132 #endif
133 
134 /* Intel's compiler complains if a variable which was never initialised is
135  * cast to void, which is a common idiom which we use to indicate that we
136  * are aware a variable isn't used. So we just silence that warning.
137  * See: https://github.com/swig/swig/issues/192 for more discussion.
138  */
139 #ifdef __INTEL_COMPILER
140 # pragma warning disable 592
141 #endif
142 
143 /* -----------------------------------------------------------------------------
144  * swigrun.swg
145  *
146  * This file contains generic C API SWIG runtime support for pointer
147  * type checking.
148  * ----------------------------------------------------------------------------- */
149 
150 /* This should only be incremented when either the layout of swig_type_info changes,
151  or for whatever reason, the runtime changes incompatibly */
152 #define SWIG_RUNTIME_VERSION "4"
153 
154 /* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
155 #ifdef SWIG_TYPE_TABLE
156 # define SWIG_QUOTE_STRING(x) #x
157 # define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
158 # define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
159 #else
160 # define SWIG_TYPE_TABLE_NAME
161 #endif
162 
163 /*
164  You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
165  creating a static or dynamic library from the SWIG runtime code.
166  In 99.9% of the cases, SWIG just needs to declare them as 'static'.
167 
168  But only do this if strictly necessary, ie, if you have problems
169  with your compiler or suchlike.
170 */
171 
172 #ifndef SWIGRUNTIME
173 # define SWIGRUNTIME SWIGINTERN
174 #endif
175 
176 #ifndef SWIGRUNTIMEINLINE
177 # define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
178 #endif
179 
180 /* Generic buffer size */
181 #ifndef SWIG_BUFFER_SIZE
182 # define SWIG_BUFFER_SIZE 1024
183 #endif
184 
185 /* Flags for pointer conversions */
186 #define SWIG_POINTER_DISOWN 0x1
187 #define SWIG_CAST_NEW_MEMORY 0x2
188 #define SWIG_POINTER_NO_NULL 0x4
189 
190 /* Flags for new pointer objects */
191 #define SWIG_POINTER_OWN 0x1
192 
193 
194 /*
195  Flags/methods for returning states.
196 
197  The SWIG conversion methods, as ConvertPtr, return an integer
198  that tells if the conversion was successful or not. And if not,
199  an error code can be returned (see swigerrors.swg for the codes).
200 
201  Use the following macros/flags to set or process the returning
202  states.
203 
204  In old versions of SWIG, code such as the following was usually written:
205 
206  if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
207  // success code
208  } else {
209  //fail code
210  }
211 
212  Now you can be more explicit:
213 
214  int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
215  if (SWIG_IsOK(res)) {
216  // success code
217  } else {
218  // fail code
219  }
220 
221  which is the same really, but now you can also do
222 
223  Type *ptr;
224  int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
225  if (SWIG_IsOK(res)) {
226  // success code
227  if (SWIG_IsNewObj(res) {
228  ...
229  delete *ptr;
230  } else {
231  ...
232  }
233  } else {
234  // fail code
235  }
236 
237  I.e., now SWIG_ConvertPtr can return new objects and you can
238  identify the case and take care of the deallocation. Of course that
239  also requires SWIG_ConvertPtr to return new result values, such as
240 
241  int SWIG_ConvertPtr(obj, ptr,...) {
242  if (<obj is ok>) {
243  if (<need new object>) {
244  *ptr = <ptr to new allocated object>;
245  return SWIG_NEWOBJ;
246  } else {
247  *ptr = <ptr to old object>;
248  return SWIG_OLDOBJ;
249  }
250  } else {
251  return SWIG_BADOBJ;
252  }
253  }
254 
255  Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
256  more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
257  SWIG errors code.
258 
259  Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
260  allows to return the 'cast rank', for example, if you have this
261 
262  int food(double)
263  int fooi(int);
264 
265  and you call
266 
267  food(1) // cast rank '1' (1 -> 1.0)
268  fooi(1) // cast rank '0'
269 
270  just use the SWIG_AddCast()/SWIG_CheckState()
271 */
272 
273 #define SWIG_OK (0)
274 #define SWIG_ERROR (-1)
275 #define SWIG_IsOK(r) (r >= 0)
276 #define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
277 
278 /* The CastRankLimit says how many bits are used for the cast rank */
279 #define SWIG_CASTRANKLIMIT (1 << 8)
280 /* The NewMask denotes the object was created (using new/malloc) */
281 #define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1)
282 /* The TmpMask is for in/out typemaps that use temporal objects */
283 #define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1)
284 /* Simple returning values */
285 #define SWIG_BADOBJ (SWIG_ERROR)
286 #define SWIG_OLDOBJ (SWIG_OK)
287 #define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK)
288 #define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK)
289 /* Check, add and del mask methods */
290 #define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
291 #define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
292 #define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
293 #define SWIG_AddTmpMask(r) (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
294 #define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
295 #define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
296 
297 /* Cast-Rank Mode */
298 #if defined(SWIG_CASTRANK_MODE)
299 # ifndef SWIG_TypeRank
300 # define SWIG_TypeRank unsigned long
301 # endif
302 # ifndef SWIG_MAXCASTRANK /* Default cast allowed */
303 # define SWIG_MAXCASTRANK (2)
304 # endif
305 # define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
306 # define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
307 SWIGINTERNINLINE int SWIG_AddCast(int r) {
308  return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
309 }
311  return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
312 }
313 #else /* no cast-rank mode */
314 # define SWIG_AddCast(r) (r)
315 # define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
316 #endif
317 
318 
319 #include <string.h>
320 
321 #ifdef __cplusplus
322 extern "C" {
323 #endif
324 
325 typedef void *(*swig_converter_func)(void *, int *);
326 typedef struct swig_type_info *(*swig_dycast_func)(void **);
327 
328 /* Structure to store information on one type */
329 typedef struct swig_type_info {
330  const char *name; /* mangled name of this type */
331  const char *str; /* human readable name of this type */
332  swig_dycast_func dcast; /* dynamic cast function down a hierarchy */
333  struct swig_cast_info *cast; /* linked list of types that can cast into this type */
334  void *clientdata; /* language specific type data */
335  int owndata; /* flag if the structure owns the clientdata */
337 
338 /* Structure to store a type and conversion function used for casting */
339 typedef struct swig_cast_info {
340  swig_type_info *type; /* pointer to type that is equivalent to this type */
341  swig_converter_func converter; /* function to cast the void pointers */
342  struct swig_cast_info *next; /* pointer to next cast in linked list */
343  struct swig_cast_info *prev; /* pointer to the previous cast */
345 
346 /* Structure used to store module information
347  * Each module generates one structure like this, and the runtime collects
348  * all of these structures and stores them in a circularly linked list.*/
349 typedef struct swig_module_info {
350  swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */
351  size_t size; /* Number of types in this module */
352  struct swig_module_info *next; /* Pointer to next element in circularly linked list */
353  swig_type_info **type_initial; /* Array of initially generated type structures */
354  swig_cast_info **cast_initial; /* Array of initially generated casting structures */
355  void *clientdata; /* Language specific module data */
357 
358 /*
359  Compare two type names skipping the space characters, therefore
360  "char*" == "char *" and "Class<int>" == "Class<int >", etc.
361 
362  Return 0 when the two name types are equivalent, as in
363  strncmp, but skipping ' '.
364 */
365 SWIGRUNTIME int
366 SWIG_TypeNameComp(const char *f1, const char *l1,
367  const char *f2, const char *l2) {
368  for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
369  while ((*f1 == ' ') && (f1 != l1)) ++f1;
370  while ((*f2 == ' ') && (f2 != l2)) ++f2;
371  if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
372  }
373  return (int)((l1 - f1) - (l2 - f2));
374 }
375 
376 /*
377  Check type equivalence in a name list like <name1>|<name2>|...
378  Return 0 if equal, -1 if nb < tb, 1 if nb > tb
379 */
380 SWIGRUNTIME int
381 SWIG_TypeCmp(const char *nb, const char *tb) {
382  int equiv = 1;
383  const char* te = tb + strlen(tb);
384  const char* ne = nb;
385  while (equiv != 0 && *ne) {
386  for (nb = ne; *ne; ++ne) {
387  if (*ne == '|') break;
388  }
389  equiv = SWIG_TypeNameComp(nb, ne, tb, te);
390  if (*ne) ++ne;
391  }
392  return equiv;
393 }
394 
395 /*
396  Check type equivalence in a name list like <name1>|<name2>|...
397  Return 0 if not equal, 1 if equal
398 */
399 SWIGRUNTIME int
400 SWIG_TypeEquiv(const char *nb, const char *tb) {
401  return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
402 }
403 
404 /*
405  Check the typename
406 */
408 SWIG_TypeCheck(const char *c, swig_type_info *ty) {
409  if (ty) {
410  swig_cast_info *iter = ty->cast;
411  while (iter) {
412  if (strcmp(iter->type->name, c) == 0) {
413  if (iter == ty->cast)
414  return iter;
415  /* Move iter to the top of the linked list */
416  iter->prev->next = iter->next;
417  if (iter->next)
418  iter->next->prev = iter->prev;
419  iter->next = ty->cast;
420  iter->prev = 0;
421  if (ty->cast) ty->cast->prev = iter;
422  ty->cast = iter;
423  return iter;
424  }
425  iter = iter->next;
426  }
427  }
428  return 0;
429 }
430 
431 /*
432  Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
433 */
436  if (ty) {
437  swig_cast_info *iter = ty->cast;
438  while (iter) {
439  if (iter->type == from) {
440  if (iter == ty->cast)
441  return iter;
442  /* Move iter to the top of the linked list */
443  iter->prev->next = iter->next;
444  if (iter->next)
445  iter->next->prev = iter->prev;
446  iter->next = ty->cast;
447  iter->prev = 0;
448  if (ty->cast) ty->cast->prev = iter;
449  ty->cast = iter;
450  return iter;
451  }
452  iter = iter->next;
453  }
454  }
455  return 0;
456 }
457 
458 /*
459  Cast a pointer up an inheritance hierarchy
460 */
461 SWIGRUNTIMEINLINE void *
462 SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
463  return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
464 }
465 
466 /*
467  Dynamic pointer casting. Down an inheritance hierarchy
468 */
471  swig_type_info *lastty = ty;
472  if (!ty || !ty->dcast) return ty;
473  while (ty && (ty->dcast)) {
474  ty = (*ty->dcast)(ptr);
475  if (ty) lastty = ty;
476  }
477  return lastty;
478 }
479 
480 /*
481  Return the name associated with this type
482 */
483 SWIGRUNTIMEINLINE const char *
485  return ty->name;
486 }
487 
488 /*
489  Return the pretty name associated with this type,
490  that is an unmangled type name in a form presentable to the user.
491 */
492 SWIGRUNTIME const char *
494  /* The "str" field contains the equivalent pretty names of the
495  type, separated by vertical-bar characters. We choose
496  to print the last name, as it is often (?) the most
497  specific. */
498  if (!type) return NULL;
499  if (type->str != NULL) {
500  const char *last_name = type->str;
501  const char *s;
502  for (s = type->str; *s; s++)
503  if (*s == '|') last_name = s+1;
504  return last_name;
505  }
506  else
507  return type->name;
508 }
509 
510 /*
511  Set the clientdata field for a type
512 */
513 SWIGRUNTIME void
515  swig_cast_info *cast = ti->cast;
516  /* if (ti->clientdata == clientdata) return; */
517  ti->clientdata = clientdata;
518 
519  while (cast) {
520  if (!cast->converter) {
521  swig_type_info *tc = cast->type;
522  if (!tc->clientdata) {
524  }
525  }
526  cast = cast->next;
527  }
528 }
529 SWIGRUNTIME void
532  ti->owndata = 1;
533 }
534 
535 /*
536  Search for a swig_type_info structure only by mangled name
537  Search is a O(log #types)
538 
539  We start searching at module start, and finish searching when start == end.
540  Note: if start == end at the beginning of the function, we go all the way around
541  the circular list.
542 */
545  swig_module_info *end,
546  const char *name) {
547  swig_module_info *iter = start;
548  do {
549  if (iter->size) {
550  size_t l = 0;
551  size_t r = iter->size - 1;
552  do {
553  /* since l+r >= 0, we can (>> 1) instead (/ 2) */
554  size_t i = (l + r) >> 1;
555  const char *iname = iter->types[i]->name;
556  if (iname) {
557  int compare = strcmp(name, iname);
558  if (compare == 0) {
559  return iter->types[i];
560  } else if (compare < 0) {
561  if (i) {
562  r = i - 1;
563  } else {
564  break;
565  }
566  } else if (compare > 0) {
567  l = i + 1;
568  }
569  } else {
570  break; /* should never happen */
571  }
572  } while (l <= r);
573  }
574  iter = iter->next;
575  } while (iter != end);
576  return 0;
577 }
578 
579 /*
580  Search for a swig_type_info structure for either a mangled name or a human readable name.
581  It first searches the mangled names of the types, which is a O(log #types)
582  If a type is not found it then searches the human readable names, which is O(#types).
583 
584  We start searching at module start, and finish searching when start == end.
585  Note: if start == end at the beginning of the function, we go all the way around
586  the circular list.
587 */
590  swig_module_info *end,
591  const char *name) {
592  /* STEP 1: Search the name field using binary search */
593  swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
594  if (ret) {
595  return ret;
596  } else {
597  /* STEP 2: If the type hasn't been found, do a complete search
598  of the str field (the human readable name) */
599  swig_module_info *iter = start;
600  do {
601  size_t i = 0;
602  for (; i < iter->size; ++i) {
603  if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
604  return iter->types[i];
605  }
606  iter = iter->next;
607  } while (iter != end);
608  }
609 
610  /* neither found a match */
611  return 0;
612 }
613 
614 /*
615  Pack binary data into a string
616 */
617 SWIGRUNTIME char *
618 SWIG_PackData(char *c, void *ptr, size_t sz) {
619  static const char hex[17] = "0123456789abcdef";
620  const unsigned char *u = (unsigned char *) ptr;
621  const unsigned char *eu = u + sz;
622  for (; u != eu; ++u) {
623  unsigned char uu = *u;
624  *(c++) = hex[(uu & 0xf0) >> 4];
625  *(c++) = hex[uu & 0xf];
626  }
627  return c;
628 }
629 
630 /*
631  Unpack binary data from a string
632 */
633 SWIGRUNTIME const char *
634 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
635  unsigned char *u = (unsigned char *) ptr;
636  const unsigned char *eu = u + sz;
637  for (; u != eu; ++u) {
638  char d = *(c++);
639  unsigned char uu;
640  if ((d >= '0') && (d <= '9'))
641  uu = (unsigned char)((d - '0') << 4);
642  else if ((d >= 'a') && (d <= 'f'))
643  uu = (unsigned char)((d - ('a'-10)) << 4);
644  else
645  return (char *) 0;
646  d = *(c++);
647  if ((d >= '0') && (d <= '9'))
648  uu |= (unsigned char)(d - '0');
649  else if ((d >= 'a') && (d <= 'f'))
650  uu |= (unsigned char)(d - ('a'-10));
651  else
652  return (char *) 0;
653  *u = uu;
654  }
655  return c;
656 }
657 
658 /*
659  Pack 'void *' into a string buffer.
660 */
661 SWIGRUNTIME char *
662 SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
663  char *r = buff;
664  if ((2*sizeof(void *) + 2) > bsz) return 0;
665  *(r++) = '_';
666  r = SWIG_PackData(r,&ptr,sizeof(void *));
667  if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
668  strcpy(r,name);
669  return buff;
670 }
671 
672 SWIGRUNTIME const char *
673 SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
674  if (*c != '_') {
675  if (strcmp(c,"NULL") == 0) {
676  *ptr = (void *) 0;
677  return name;
678  } else {
679  return 0;
680  }
681  }
682  return SWIG_UnpackData(++c,ptr,sizeof(void *));
683 }
684 
685 SWIGRUNTIME char *
686 SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
687  char *r = buff;
688  size_t lname = (name ? strlen(name) : 0);
689  if ((2*sz + 2 + lname) > bsz) return 0;
690  *(r++) = '_';
691  r = SWIG_PackData(r,ptr,sz);
692  if (lname) {
693  strncpy(r,name,lname+1);
694  } else {
695  *r = 0;
696  }
697  return buff;
698 }
699 
700 SWIGRUNTIME const char *
701 SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
702  if (*c != '_') {
703  if (strcmp(c,"NULL") == 0) {
704  memset(ptr,0,sz);
705  return name;
706  } else {
707  return 0;
708  }
709  }
710  return SWIG_UnpackData(++c,ptr,sz);
711 }
712 
713 #ifdef __cplusplus
714 }
715 #endif
716 
717 /* Errors in SWIG */
718 #define SWIG_UnknownError -1
719 #define SWIG_IOError -2
720 #define SWIG_RuntimeError -3
721 #define SWIG_IndexError -4
722 #define SWIG_TypeError -5
723 #define SWIG_DivisionByZero -6
724 #define SWIG_OverflowError -7
725 #define SWIG_SyntaxError -8
726 #define SWIG_ValueError -9
727 #define SWIG_SystemError -10
728 #define SWIG_AttributeError -11
729 #define SWIG_MemoryError -12
730 #define SWIG_NullReferenceError -13
731 
732 
733 
734 /* -----------------------------------------------------------------------------
735  * luarun.swg
736  *
737  * This file contains the runtime support for Lua modules
738  * and includes code for managing global variables and pointer
739  * type checking.
740  * ----------------------------------------------------------------------------- */
741 
742 #ifdef __cplusplus
743 extern "C" {
744 #endif
745 
746 #include "lua.h"
747 #include "lauxlib.h"
748 #include <stdlib.h> /* for malloc */
749 #include <assert.h> /* for a few sanity tests */
750 
751 /* -----------------------------------------------------------------------------
752  * Lua flavors
753  * ----------------------------------------------------------------------------- */
754 
755 #define SWIG_LUA_FLAVOR_LUA 1
756 #define SWIG_LUA_FLAVOR_ELUA 2
757 #define SWIG_LUA_FLAVOR_ELUAC 3
758 
759 #if !defined(SWIG_LUA_TARGET)
760 # error SWIG_LUA_TARGET not defined
761 #endif
762 
763 #if defined(SWIG_LUA_ELUA_EMULATE)
764 
765 struct swig_elua_entry;
766 
767 typedef struct swig_elua_key {
768  int type;
769  union {
770  const char* strkey;
771  lua_Number numkey;
772  } key;
773 } swig_elua_key;
774 
775 typedef struct swig_elua_val {
776  int type;
777  union {
778  lua_Number number;
779  const struct swig_elua_entry *table;
780  const char *string;
781  lua_CFunction function;
782  struct {
783  char member;
784  long lvalue;
785  void *pvalue;
786  swig_type_info **ptype;
787  } userdata;
788  } value;
789 } swig_elua_val;
790 
791 typedef struct swig_elua_entry {
792  swig_elua_key key;
793  swig_elua_val value;
794 } swig_elua_entry;
795 
796 #define LSTRKEY(x) {LUA_TSTRING, {.strkey = x} }
797 #define LNUMKEY(x) {LUA_TNUMBER, {.numkey = x} }
798 #define LNILKEY {LUA_TNIL, {.strkey = 0} }
799 
800 #define LNUMVAL(x) {LUA_TNUMBER, {.number = x} }
801 #define LFUNCVAL(x) {LUA_TFUNCTION, {.function = x} }
802 #define LROVAL(x) {LUA_TTABLE, {.table = x} }
803 #define LNILVAL {LUA_TNIL, {.string = 0} }
804 #define LSTRVAL(x) {LUA_TSTRING, {.string = x} }
805 
806 #define LUA_REG_TYPE swig_elua_entry
807 
808 #define SWIG_LUA_ELUA_EMUL_METATABLE_KEY "__metatable"
809 
810 #define lua_pushrotable(L,p)\
811  lua_newtable(L);\
812  assert(p);\
813  SWIG_Lua_elua_emulate_register(L,(swig_elua_entry*)(p));
814 
815 #define SWIG_LUA_CONSTTAB_POINTER(B,C,D)\
816  LSTRKEY(B), {LUA_TUSERDATA, { .userdata={0,0,(void*)(C),&D} } }
817 
818 #define SWIG_LUA_CONSTTAB_BINARY(B,S,C,D)\
819  LSTRKEY(B), {LUA_TUSERDATA, { .userdata={1,S,(void*)(C),&D} } }
820 #endif
821 
822 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
823 # define SWIG_LUA_CONSTTAB_INT(B, C) LSTRKEY(B), LNUMVAL(C)
824 # define SWIG_LUA_CONSTTAB_FLOAT(B, C) LSTRKEY(B), LNUMVAL(C)
825 # define SWIG_LUA_CONSTTAB_STRING(B, C) LSTRKEY(B), LSTRVAL(C)
826 # define SWIG_LUA_CONSTTAB_CHAR(B, C) LSTRKEY(B), LNUMVAL(C)
827  /* Those two types of constants are not supported in elua */
828 
829 #ifndef SWIG_LUA_CONSTTAB_POINTER
830 #warning eLua does not support pointers as constants. By default, nil will be used as value
831 #define SWIG_LUA_CONSTTAB_POINTER(B,C,D) LSTRKEY(B), LNILVAL
832 #endif
833 
834 #ifndef SWIG_LUA_CONSTTAB_BINARY
835 #warning eLua does not support pointers to member as constants. By default, nil will be used as value
836 #define SWIG_LUA_CONSTTAB_BINARY(B, S, C, D) LSTRKEY(B), LNILVAL
837 #endif
838 #else /* SWIG_LUA_FLAVOR_LUA */
839 # define SWIG_LUA_CONSTTAB_INT(B, C) SWIG_LUA_INT, (char *)B, (long)C, 0, 0, 0
840 # define SWIG_LUA_CONSTTAB_FLOAT(B, C) SWIG_LUA_FLOAT, (char *)B, 0, (double)C, 0, 0
841 # define SWIG_LUA_CONSTTAB_STRING(B, C) SWIG_LUA_STRING, (char *)B, 0, 0, (void *)C, 0
842 # define SWIG_LUA_CONSTTAB_CHAR(B, C) SWIG_LUA_CHAR, (char *)B, (long)C, 0, 0, 0
843 # define SWIG_LUA_CONSTTAB_POINTER(B,C,D)\
844  SWIG_LUA_POINTER, (char *)B, 0, 0, (void *)C, &D
845 # define SWIG_LUA_CONSTTAB_BINARY(B, S, C, D)\
846  SWIG_LUA_BINARY, (char *)B, S, 0, (void *)C, &D
847 #endif
848 
849 #ifndef SWIG_LUA_ELUA_EMULATE
850 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
851 # define LRO_STRVAL(v) {{.p = (char *) v}, LUA_TSTRING}
852 # define LSTRVAL LRO_STRVAL
853 #endif
854 #endif /* SWIG_LUA_ELUA_EMULATE*/
855 
856 #ifndef SWIG_LUA_ELUA_EMULATE
857 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
858 
859 #ifndef MIN_OPT_LEVEL
860 #define MIN_OPT_LEVEL 2
861 #endif
862 
863 #include "lrodefs.h"
864 #include "lrotable.h"
865 #endif
866 #endif /* SWIG_LUA_ELUA_EMULATE*/
867 /* -----------------------------------------------------------------------------
868  * compatibility defines
869  * ----------------------------------------------------------------------------- */
870 
871 /* History of Lua C API length functions: In Lua 5.0 (and before?)
872  there was "lua_strlen". In Lua 5.1, this was renamed "lua_objlen",
873  but a compatibility define of "lua_strlen" was added. In Lua 5.2,
874  this function was again renamed, to "lua_rawlen" (to emphasize that
875  it doesn't call the "__len" metamethod), and the compatibility
876  define of lua_strlen was removed. All SWIG uses have been updated
877  to "lua_rawlen", and we add our own defines of that here for older
878  versions of Lua. */
879 #if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 501
880 # define lua_rawlen lua_strlen
881 #elif LUA_VERSION_NUM == 501
882 # define lua_rawlen lua_objlen
883 #endif
884 
885 
886 /* lua_pushglobaltable is the recommended "future-proof" way to get
887  the global table for Lua 5.2 and later. Here we define
888  lua_pushglobaltable ourselves for Lua versions before 5.2. */
889 #if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 502
890 # define lua_pushglobaltable(L) lua_pushvalue(L, LUA_GLOBALSINDEX)
891 #endif
892 
893 /* lua_absindex was introduced in Lua 5.2 */
894 #if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 502
895 # define lua_absindex(L,i) ((i)>0 || (i) <= LUA_REGISTRYINDEX ? (i) : lua_gettop(L) + (i) + 1)
896 #endif
897 
898 /* lua_rawsetp was introduced in Lua 5.2 */
899 #if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 502
900 #define lua_rawsetp(L,index,ptr)\
901  lua_pushlightuserdata(L,(void*)(ptr));\
902  lua_insert(L,-2);\
903  lua_rawset(L,index);
904 
905 #define lua_rawgetp(L,index,ptr)\
906  lua_pushlightuserdata(L,(void*)(ptr));\
907  lua_rawget(L,index);
908 
909 #endif
910 
911 /* --------------------------------------------------------------------------
912  * Helper functions for error handling
913  * -------------------------------------------------------------------------- */
914 
915 /* Push the string STR on the Lua stack, like lua_pushstring, but
916  prefixed with the location of the innermost Lua call-point
917  (as formatted by luaL_where). */
918 SWIGRUNTIME void
919 SWIG_Lua_pusherrstring (lua_State *L, const char *str)
920 {
921  luaL_where (L, 1);
922  lua_pushstring (L, str);
923  lua_concat (L, 2);
924 }
925 
926 /* Push a formatted string generated from FMT and following args on
927  the Lua stack, like lua_pushfstring, but prefixed with the
928  location of the innermost Lua call-point (as formatted by luaL_where). */
929 SWIGRUNTIME void
930 SWIG_Lua_pushferrstring (lua_State *L, const char *fmt, ...)
931 {
932  va_list argp;
933  va_start(argp, fmt);
934  luaL_where(L, 1);
935  lua_pushvfstring(L, fmt, argp);
936  va_end(argp);
937  lua_concat(L, 2);
938 }
939 
940 
941 /* -----------------------------------------------------------------------------
942  * global swig types
943  * ----------------------------------------------------------------------------- */
944 /* Constant table */
945 #define SWIG_LUA_INT 1
946 #define SWIG_LUA_FLOAT 2
947 #define SWIG_LUA_STRING 3
948 #define SWIG_LUA_POINTER 4
949 #define SWIG_LUA_BINARY 5
950 #define SWIG_LUA_CHAR 6
951 
952 /* Structure for variable linking table */
953 typedef struct {
954  const char *name;
955  lua_CFunction get;
956  lua_CFunction set;
958 
959 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
960 typedef const LUA_REG_TYPE swig_lua_method;
961 typedef const LUA_REG_TYPE swig_lua_const_info;
962 #else /* Normal lua */
963 typedef luaL_Reg swig_lua_method;
964 
965 /* Constant information structure */
966 typedef struct {
967  int type;
968  char *name;
969  long lvalue;
970  double dvalue;
971  void *pvalue;
974 
975 #endif
976 
977 typedef struct {
978  const char *name;
979  lua_CFunction getmethod;
980  lua_CFunction setmethod;
982 
983 
984 struct swig_lua_class;
985 /* Can be used to create namespaces. Currently used to wrap class static methods/variables/constants */
986 typedef struct swig_lua_namespace {
987  const char *name;
994 
995 typedef struct swig_lua_class {
996  const char *name; /* Name that this class has in Lua */
997  const char *fqname; /* Fully qualified name - Scope + class name */
999  lua_CFunction constructor;
1000  void (*destructor)(void *);
1004  swig_lua_method *metatable; /* 0 for -eluac */
1006  const char **base_names;
1007 } swig_lua_class;
1008 
1009 /* this is the struct for wrapping all pointers in SwigLua
1010 */
1011 typedef struct {
1013  int own; /* 1 if owned & must be destroyed */
1014  void *ptr;
1016 
1017 /* this is the struct for wrapping arbitrary packed binary data
1018 (currently it is only used for member function pointers)
1019 the data ordering is similar to swig_lua_userdata, but it is currently not possible
1020 to tell the two structures apart within SWIG, other than by looking at the type
1021 */
1022 typedef struct {
1024  int own; /* 1 if owned & must be destroyed */
1025  char data[1]; /* arbitrary amount of data */
1027 
1028 /* Common SWIG API */
1029 #define SWIG_NewPointerObj(L, ptr, type, owner) SWIG_Lua_NewPointerObj(L, (void *)ptr, type, owner)
1030 #define SWIG_ConvertPtr(L,idx, ptr, type, flags) SWIG_Lua_ConvertPtr(L,idx,ptr,type,flags)
1031 #define SWIG_MustGetPtr(L,idx, type,flags, argnum,fnname) SWIG_Lua_MustGetPtr(L,idx, type,flags, argnum,fnname)
1032 /* for C++ member pointers, ie, member methods */
1033 #define SWIG_ConvertMember(L, idx, ptr, sz, ty) SWIG_Lua_ConvertPacked(L, idx, ptr, sz, ty)
1034 #define SWIG_NewMemberObj(L, ptr, sz, type) SWIG_Lua_NewPackedObj(L, ptr, sz, type)
1035 
1036 /* Runtime API */
1037 #define SWIG_GetModule(clientdata) SWIG_Lua_GetModule((lua_State*)(clientdata))
1038 #define SWIG_SetModule(clientdata, pointer) SWIG_Lua_SetModule((lua_State*) (clientdata), pointer)
1039 #define SWIG_MODULE_CLIENTDATA_TYPE lua_State*
1040 
1041 /* Contract support */
1042 #define SWIG_contract_assert(expr, msg) \
1043  if (!(expr)) { SWIG_Lua_pusherrstring(L, (char *) msg); goto fail; } else
1044 
1045 
1046 /* helper #defines */
1047 #define SWIG_fail {goto fail;}
1048 #define SWIG_fail_arg(func_name,argnum,type) \
1049  {SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'",\
1050  func_name,argnum,type,SWIG_Lua_typename(L,argnum));\
1051  goto fail;}
1052 #define SWIG_fail_ptr(func_name,argnum,type) \
1053  SWIG_fail_arg(func_name,argnum,(type && type->str)?type->str:"void*")
1054 #define SWIG_check_num_args(func_name,a,b) \
1055  if (lua_gettop(L)<a || lua_gettop(L)>b) \
1056  {SWIG_Lua_pushferrstring(L,"Error in %s expected %d..%d args, got %d",func_name,a,b,lua_gettop(L));\
1057  goto fail;}
1058 
1059 
1060 #define SWIG_Lua_get_table(L,n) \
1061  (lua_pushstring(L, n), lua_rawget(L,-2))
1062 
1063 #define SWIG_Lua_add_function(L,n,f) \
1064  (lua_pushstring(L, n), \
1065  lua_pushcfunction(L, f), \
1066  lua_rawset(L,-3))
1067 
1068 #define SWIG_Lua_add_boolean(L,n,b) \
1069  (lua_pushstring(L, n), \
1070  lua_pushboolean(L, b), \
1071  lua_rawset(L,-3))
1072 
1073 /* special helper for allowing 'nil' for usertypes */
1074 #define SWIG_isptrtype(L,I) (lua_isuserdata(L,I) || lua_isnil(L,I))
1075 
1076 #ifdef __cplusplus
1077 /* Special helper for member function pointers
1078 it gets the address, casts it, then dereferences it */
1079 /*#define SWIG_mem_fn_as_voidptr(a) (*((char**)&(a))) */
1080 #endif
1081 
1082 /* storing/access of swig_module_info */
1084 SWIG_Lua_GetModule(lua_State *L) {
1085  swig_module_info *ret = 0;
1086  lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
1087  lua_rawget(L,LUA_REGISTRYINDEX);
1088  if (lua_islightuserdata(L,-1))
1089  ret=(swig_module_info*)lua_touserdata(L,-1);
1090  lua_pop(L,1); /* tidy */
1091  return ret;
1092 }
1093 
1094 SWIGRUNTIME void
1095 SWIG_Lua_SetModule(lua_State *L, swig_module_info *module) {
1096  /* add this all into the Lua registry: */
1097  lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
1098  lua_pushlightuserdata(L,(void*)module);
1099  lua_rawset(L,LUA_REGISTRYINDEX);
1100 }
1101 
1102 /* -----------------------------------------------------------------------------
1103  * global variable support code: modules
1104  * ----------------------------------------------------------------------------- */
1105 
1106 /* this function is called when trying to set an immutable.
1107 default action is to print an error.
1108 This can removed with a compile flag SWIGLUA_IGNORE_SET_IMMUTABLE */
1110 {
1111 /* there should be 1 param passed in: the new value */
1112 #ifndef SWIGLUA_IGNORE_SET_IMMUTABLE
1113  lua_pop(L,1); /* remove it */
1114  luaL_error(L,"This variable is immutable");
1115 #endif
1116  return 0; /* should not return anything */
1117 }
1118 
1119 #ifdef SWIG_LUA_ELUA_EMULATE
1120 
1121 SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State *L,void *ptr,swig_type_info *type, int own);
1122 SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State *L,void *ptr,size_t size,swig_type_info *type);
1123 static int swig_lua_elua_emulate_unique_key;
1124 
1125 /* This function emulates eLua rotables behaviour. It loads a rotable definition into the usual lua table. */
1126 SWIGINTERN void SWIG_Lua_elua_emulate_register(lua_State *L, const swig_elua_entry *table)
1127 {
1128  int i, table_parsed, parsed_tables_array, target_table;
1129  assert(lua_istable(L,-1));
1130  target_table = lua_gettop(L);
1131  /* Get the registry where we put all parsed tables to avoid loops */
1132  lua_rawgetp(L, LUA_REGISTRYINDEX, &swig_lua_elua_emulate_unique_key);
1133  if(lua_isnil(L,-1)) {
1134  lua_pop(L,1);
1135  lua_newtable(L);
1136  lua_pushvalue(L,-1);
1137  lua_rawsetp(L,LUA_REGISTRYINDEX,(void*)(&swig_lua_elua_emulate_unique_key));
1138  }
1139  parsed_tables_array = lua_gettop(L);
1140  lua_pushvalue(L,target_table);
1141  lua_rawsetp(L, parsed_tables_array, table);
1142  table_parsed = 0;
1143  const int SWIGUNUSED pairs_start = lua_gettop(L);
1144  for(i = 0;table[i].key.type != LUA_TNIL || table[i].value.type != LUA_TNIL;i++)
1145  {
1146  const swig_elua_entry *entry = table + i;
1147  int is_metatable = 0;
1148  switch(entry->key.type) {
1149  case LUA_TSTRING:
1150  lua_pushstring(L,entry->key.key.strkey);
1151  if(strcmp(entry->key.key.strkey, SWIG_LUA_ELUA_EMUL_METATABLE_KEY) == 0)
1152  is_metatable = 1;
1153  break;
1154  case LUA_TNUMBER:
1155  lua_pushnumber(L,entry->key.key.numkey);
1156  break;
1157  case LUA_TNIL:
1158  lua_pushnil(L);
1159  break;
1160  default:
1161  assert(0);
1162  }
1163  switch(entry->value.type) {
1164  case LUA_TSTRING:
1165  lua_pushstring(L,entry->value.value.string);
1166  break;
1167  case LUA_TNUMBER:
1168  lua_pushnumber(L,entry->value.value.number);
1169  break;
1170  case LUA_TFUNCTION:
1171  lua_pushcfunction(L,entry->value.value.function);
1172  break;
1173  case LUA_TTABLE:
1174  lua_rawgetp(L,parsed_tables_array, entry->value.value.table);
1175  table_parsed = !lua_isnil(L,-1);
1176  if(!table_parsed) {
1177  lua_pop(L,1); /*remove nil */
1178  lua_newtable(L);
1179  SWIG_Lua_elua_emulate_register(L,entry->value.value.table);
1180  }
1181  if(is_metatable) {
1182  assert(lua_istable(L,-1));
1183  lua_pushvalue(L,-1);
1184  lua_setmetatable(L,target_table);
1185  }
1186 
1187  break;
1188  case LUA_TUSERDATA:
1189  if(entry->value.value.userdata.member)
1190  SWIG_NewMemberObj(L,entry->value.value.userdata.pvalue,
1191  entry->value.value.userdata.lvalue,
1192  *(entry->value.value.userdata.ptype));
1193  else
1194  SWIG_NewPointerObj(L,entry->value.value.userdata.pvalue,
1195  *(entry->value.value.userdata.ptype),0);
1196  break;
1197  case LUA_TNIL:
1198  lua_pushnil(L);
1199  break;
1200  default:
1201  assert(0);
1202  }
1203  assert(lua_gettop(L) == pairs_start + 2);
1204  lua_rawset(L,target_table);
1205  }
1206  lua_pop(L,1); /* Removing parsed tables storage */
1207  assert(lua_gettop(L) == target_table);
1208 }
1209 
1210 SWIGINTERN void SWIG_Lua_elua_emulate_register_clear(lua_State *L)
1211 {
1212  lua_pushnil(L);
1213  lua_rawsetp(L, LUA_REGISTRYINDEX, &swig_lua_elua_emulate_unique_key);
1214 }
1215 
1216 SWIGINTERN void SWIG_Lua_get_class_registry(lua_State *L);
1217 
1218 SWIGINTERN int SWIG_Lua_emulate_elua_getmetatable(lua_State *L)
1219 {
1220  SWIG_check_num_args("getmetatable(SWIG eLua emulation)", 1, 1);
1222  lua_getfield(L,-1,"lua_getmetatable");
1223  lua_remove(L,-2); /* remove the registry*/
1224  assert(!lua_isnil(L,-1));
1225  lua_pushvalue(L,1);
1226  assert(lua_gettop(L) == 3); /* object | function | object again */
1227  lua_call(L,1,1);
1228  if(!lua_isnil(L,-1)) /*There is an ordinary metatable */
1229  return 1;
1230  /*if it is a table, then emulate elua behaviour - check for __metatable attribute of a table*/
1231  assert(lua_gettop(L) == 2);
1232  if(lua_istable(L,-2)) {
1233  lua_pop(L,1); /*remove the nil*/
1234  lua_getfield(L,-1, SWIG_LUA_ELUA_EMUL_METATABLE_KEY);
1235  }
1236  assert(lua_gettop(L) == 2);
1237  return 1;
1238 
1239 fail:
1240  lua_error(L);
1241  return 0;
1242 }
1243 
1244 SWIGINTERN void SWIG_Lua_emulate_elua_swap_getmetatable(lua_State *L)
1245 {
1248  lua_pushstring(L,"lua_getmetatable");
1249  lua_getfield(L,-2,"getmetatable");
1250  assert(!lua_isnil(L,-1));
1251  lua_rawset(L,-4);
1252  lua_pushstring(L, "getmetatable");
1253  lua_pushcfunction(L, SWIG_Lua_emulate_elua_getmetatable);
1254  lua_rawset(L,-3);
1255  lua_pop(L,2);
1256 
1257 }
1258 /* END OF REMOVE */
1259 
1260 #endif
1261 /* -----------------------------------------------------------------------------
1262  * global variable support code: namespaces and modules (which are the same thing)
1263  * ----------------------------------------------------------------------------- */
1264 
1266 {
1267 /* there should be 2 params passed in
1268  (1) table (not the meta table)
1269  (2) string name of the attribute
1270 */
1271  assert(lua_istable(L,-2)); /* just in case */
1272  lua_getmetatable(L,-2);
1273  assert(lua_istable(L,-1));
1274  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1275  assert(lua_istable(L,-1));
1276  /* look for the key in the .get table */
1277  lua_pushvalue(L,2); /* key */
1278  lua_rawget(L,-2);
1279  lua_remove(L,-2); /* stack tidy, remove .get table */
1280  if (lua_iscfunction(L,-1))
1281  { /* found it so call the fn & return its value */
1282  lua_call(L,0,1); /* 1 value in (userdata),1 out (result) */
1283  lua_remove(L,-2); /* stack tidy, remove metatable */
1284  return 1;
1285  }
1286  lua_pop(L,1); /* remove whatever was there */
1287  /* ok, so try the .fn table */
1288  SWIG_Lua_get_table(L,".fn"); /* find the .get table */
1289  assert(lua_istable(L,-1)); /* just in case */
1290  lua_pushvalue(L,2); /* key */
1291  lua_rawget(L,-2); /* look for the fn */
1292  lua_remove(L,-2); /* stack tidy, remove .fn table */
1293  if (lua_isfunction(L,-1)) /* note: whether it's a C function or lua function */
1294  { /* found it so return the fn & let lua call it */
1295  lua_remove(L,-2); /* stack tidy, remove metatable */
1296  return 1;
1297  }
1298  lua_pop(L,1); /* remove whatever was there */
1299  return 0;
1300 }
1301 
1303 {
1304 /* there should be 3 params passed in
1305  (1) table (not the meta table)
1306  (2) string name of the attribute
1307  (3) any for the new value
1308 */
1309 
1310  assert(lua_istable(L,1));
1311  lua_getmetatable(L,1); /* get the meta table */
1312  assert(lua_istable(L,-1));
1313 
1314  SWIG_Lua_get_table(L,".set"); /* find the .set table */
1315  if (lua_istable(L,-1))
1316  {
1317  /* look for the key in the .set table */
1318  lua_pushvalue(L,2); /* key */
1319  lua_rawget(L,-2);
1320  if (lua_iscfunction(L,-1))
1321  { /* found it so call the fn & return its value */
1322  lua_pushvalue(L,3); /* value */
1323  lua_call(L,1,0);
1324  return 0;
1325  }
1326  lua_pop(L,1); /* remove the value */
1327  }
1328  lua_pop(L,1); /* remove the value .set table */
1329  lua_pop(L,1); /* remote metatable */
1330  lua_rawset(L,-3);
1331  return 0;
1332 }
1333 
1334 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) /* In elua this is useless */
1335 SWIGINTERN void SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[]); /* forward declaration */
1336 SWIGINTERN void SWIG_Lua_add_variable(lua_State *L,const char *name,lua_CFunction getFn,lua_CFunction setFn); /* forward declaration */
1337 SWIGINTERN void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss);
1338 
1339 /* helper function - register namespace methods and attributes into namespace */
1341 {
1342  int i;
1343  /* There must be namespace table (not metatable) at the top of the stack */
1344  assert(lua_istable(L,-1));
1346 
1347  /* add methods to the namespace/module table */
1348  for(i=0;ns->ns_methods[i].name;i++){
1349  SWIG_Lua_add_function(L,ns->ns_methods[i].name,ns->ns_methods[i].func);
1350  }
1351  lua_getmetatable(L,-1);
1352 
1353  /* add fns */
1354  for(i=0;ns->ns_attributes[i].name;i++){
1356  }
1357 
1358  /* clear stack - remove metatble */
1359  lua_pop(L,1);
1360  return 0;
1361 }
1362 
1363 /* Register all classes in the namespace */
1365 {
1366  swig_lua_class **classes;
1367 
1368  /* There must be a module/namespace table at the top of the stack */
1369  assert(lua_istable(L,-1));
1370 
1371  classes = ns->ns_classes;
1372 
1373  if( classes != 0 ) {
1374  while(*classes != 0) {
1375  SWIG_Lua_class_register(L, *classes);
1376  classes++;
1377  }
1378  }
1379 }
1380 
1381 /* Helper function. Creates namespace table and adds it to module table
1382  if 'reg' is true, then will register namespace table to parent one (must be on top of the stack
1383  when function is called).
1384  Function always returns newly registered table on top of the stack.
1385 */
1387 {
1388  swig_lua_namespace **sub_namespace;
1389  /* 1 argument - table on the top of the stack */
1390  const int SWIGUNUSED begin = lua_gettop(L);
1391  assert(lua_istable(L,-1)); /* just in case. This is supposed to be module table or parent namespace table */
1392  lua_checkstack(L,5);
1393  lua_newtable(L); /* namespace itself */
1394  lua_newtable(L); /* metatable for namespace */
1395 
1396  /* add a table called ".get" */
1397  lua_pushstring(L,".get");
1398  lua_newtable(L);
1399  lua_rawset(L,-3);
1400  /* add a table called ".set" */
1401  lua_pushstring(L,".set");
1402  lua_newtable(L);
1403  lua_rawset(L,-3);
1404  /* add a table called ".fn" */
1405  lua_pushstring(L,".fn");
1406  lua_newtable(L);
1407  lua_rawset(L,-3);
1408 
1409  /* add accessor fns for using the .get,.set&.fn */
1412 
1413  lua_setmetatable(L,-2); /* set metatable */
1414 
1415  /* Register all functions, variables etc */
1417  /* Register classes */
1419 
1420  sub_namespace = ns->ns_namespaces;
1421  if( sub_namespace != 0) {
1422  while(*sub_namespace != 0) {
1423  SWIG_Lua_namespace_register(L, *sub_namespace, 1);
1424  lua_pop(L,1); /* removing sub-namespace table */
1425  sub_namespace++;
1426  }
1427  }
1428 
1429  if (reg) {
1430  lua_pushstring(L,ns->name);
1431  lua_pushvalue(L,-2);
1432  lua_rawset(L,-4); /* add namespace to module table */
1433  }
1434  assert(lua_gettop(L) == begin+1);
1435 }
1436 #endif /* SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA */
1437 
1438 /* -----------------------------------------------------------------------------
1439  * global variable support code: classes
1440  * ----------------------------------------------------------------------------- */
1441 
1442 SWIGINTERN void SWIG_Lua_get_class_metatable(lua_State *L,const char *cname);
1443 
1444 typedef int (*swig_lua_base_iterator_func)(lua_State*,swig_type_info*, int, int *ret);
1445 
1447  int first_arg, swig_lua_base_iterator_func func, int *const ret)
1448 {
1449  /* first_arg - position of the object in stack. Everything that is above are arguments
1450  * and is passed to every evocation of the func */
1451  int last_arg = lua_gettop(L);/* position of last argument */
1452  int original_metatable = last_arg + 1;
1453  size_t bases_count;
1454  int result = SWIG_ERROR;
1455  int bases_table;
1456  (void)swig_type;
1457  lua_getmetatable(L,first_arg);
1458 
1459  /* initialise base search */
1460 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
1461  SWIG_Lua_get_table(L,".bases");
1462  assert(lua_istable(L,-1));
1463  bases_count = lua_rawlen(L,-1);
1464  bases_table = lua_gettop(L);
1465 #else
1466  /* In elua .bases table doesn't exist. Use table from swig_lua_class */
1467  (void)bases_table;
1468  assert(swig_type!=0);
1469  swig_module_info *module=SWIG_GetModule(L);
1470  swig_lua_class **bases= ((swig_lua_class*)(swig_type->clientdata))->bases;
1471  const char **base_names= ((swig_lua_class*)(swig_type->clientdata))->base_names;
1472  bases_count = 0;
1473  for(;base_names[bases_count];
1474  bases_count++);/* get length of bases */
1475 #endif
1476 
1477  if(ret)
1478  *ret = 0;
1479  if(bases_count>0)
1480  {
1481  int to_remove;
1482  size_t i;
1483  int j;
1484  int subcall_last_arg;
1485  int subcall_first_arg = lua_gettop(L) + 1;/* Here a copy of first_arg and arguments begin */
1486  int valid = 1;
1487  swig_type_info *base_swig_type = 0;
1488  for(j=first_arg;j<=last_arg;j++)
1489  lua_pushvalue(L,j);
1490  subcall_last_arg = lua_gettop(L);
1491 
1492  /* Trick: temporarily replacing original metatable with metatable for base class and call getter */
1493  for(i=0;i<bases_count;i++) {
1494  /* Iteration through class bases */
1495 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
1496  lua_rawgeti(L,bases_table,i+1);
1497  base_swig_type = 0;
1498  if(lua_isnil(L,-1)) {
1499  valid = 0;
1500  lua_pop(L,1);
1501  } else {
1502  valid = 1;
1503  }
1504 #else /* In elua .bases table doesn't exist. Use table from swig_lua_class */
1505  swig_lua_class *base_class = bases[i];
1506  if(!base_class) {
1507  valid = 0;
1508  } else {
1509  valid = 1;
1510  SWIG_Lua_get_class_metatable(L,base_class->fqname);
1511  base_swig_type = SWIG_TypeQueryModule(module,module,base_names[i]);
1512  assert(base_swig_type != 0);
1513  }
1514 #endif
1515 
1516  if(!valid)
1517  continue;
1518  assert(lua_isuserdata(L, subcall_first_arg));
1519  assert(lua_istable(L,-1));
1520  lua_setmetatable(L,subcall_first_arg); /* Set new metatable */
1521  assert(lua_gettop(L) == subcall_last_arg);
1522  result = func(L, base_swig_type,subcall_first_arg, ret); /* Forward call */
1523  if(result != SWIG_ERROR) {
1524  break;
1525  }
1526  }
1527  /* Restore original metatable */
1528  lua_pushvalue(L,original_metatable);
1529  lua_setmetatable(L,first_arg);
1530  /* Clear - remove everything between last_arg and subcall_last_arg including */
1531  to_remove = subcall_last_arg - last_arg;
1532  for(j=0;j<to_remove;j++)
1533  lua_remove(L,last_arg+1);
1534  } else {
1535  /* Remove everything after last_arg */
1536  lua_pop(L, lua_gettop(L) - last_arg);
1537  }
1538  if(ret) assert(lua_gettop(L) == last_arg + *ret);
1539  return result;
1540 }
1541 
1542 /* The class.get method helper, performs the lookup of class attributes.
1543  * It returns an error code. Number of function return values is passed inside 'ret'.
1544  * first_arg is not used in this function because function always has 2 arguments.
1545  */
1546 SWIGINTERN int SWIG_Lua_class_do_get_item(lua_State *L, swig_type_info *type, int SWIGUNUSED first_arg, int *ret)
1547 {
1548 /* there should be 2 params passed in
1549  (1) userdata (not the meta table)
1550  (2) string name of the attribute
1551 */
1552  int bases_search_result;
1553  int substack_start = lua_gettop(L)-2;
1554  assert(first_arg == substack_start+1);
1555  lua_checkstack(L,5);
1556  assert(lua_isuserdata(L,-2)); /* just in case */
1557  lua_getmetatable(L,-2); /* get the meta table */
1558  assert(lua_istable(L,-1)); /* just in case */
1559  /* NEW: looks for the __getitem() fn
1560  this is a user provided get fn */
1561  SWIG_Lua_get_table(L,"__getitem"); /* find the __getitem fn */
1562  if (lua_iscfunction(L,-1)) /* if its there */
1563  { /* found it so call the fn & return its value */
1564  lua_pushvalue(L,substack_start+1); /* the userdata */
1565  lua_pushvalue(L,substack_start+2); /* the parameter */
1566  lua_call(L,2,1); /* 2 value in (userdata),1 out (result) */
1567  lua_remove(L,-2); /* stack tidy, remove metatable */
1568  if(ret) *ret = 1;
1569  return SWIG_OK;
1570  }
1571  lua_pop(L,1);
1572  /* Remove the metatable */
1573  lua_pop(L,1);
1574  /* Search in base classes */
1575  bases_search_result = SWIG_Lua_iterate_bases(L,type,substack_start+1,SWIG_Lua_class_do_get_item,ret);
1576  return bases_search_result; /* sorry not known */
1577 }
1578 
1579 
1580 /* The class.get method helper, performs the lookup of class attributes.
1581  * It returns an error code. Number of function return values is passed inside 'ret'.
1582  * first_arg is not used in this function because function always has 2 arguments.
1583  */
1584 SWIGINTERN int SWIG_Lua_class_do_get(lua_State *L, swig_type_info *type, int SWIGUNUSED first_arg, int *ret)
1585 {
1586 /* there should be 2 params passed in
1587  (1) userdata (not the meta table)
1588  (2) string name of the attribute
1589 */
1590  int bases_search_result;
1591  int substack_start = lua_gettop(L)-2;
1592  assert(first_arg == substack_start+1);
1593  lua_checkstack(L,5);
1594  assert(lua_isuserdata(L,-2)); /* just in case */
1595  lua_getmetatable(L,-2); /* get the meta table */
1596  assert(lua_istable(L,-1)); /* just in case */
1597  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1598  assert(lua_istable(L,-1)); /* just in case */
1599  /* look for the key in the .get table */
1600  lua_pushvalue(L,substack_start+2); /* key */
1601  lua_rawget(L,-2);
1602  lua_remove(L,-2); /* stack tidy, remove .get table */
1603  if (lua_iscfunction(L,-1))
1604  { /* found it so call the fn & return its value */
1605  lua_pushvalue(L,substack_start+1); /* the userdata */
1606  lua_call(L,1,1); /* 1 value in (userdata),1 out (result) */
1607  lua_remove(L,-2); /* stack tidy, remove metatable */
1608  if(ret)
1609  *ret = 1;
1610  return SWIG_OK;
1611  }
1612  lua_pop(L,1); /* remove whatever was there */
1613  /* ok, so try the .fn table */
1614  SWIG_Lua_get_table(L,".fn"); /* find the .fn table */
1615  assert(lua_istable(L,-1)); /* just in case */
1616  lua_pushvalue(L,substack_start+2); /* key */
1617  lua_rawget(L,-2); /* look for the fn */
1618  lua_remove(L,-2); /* stack tidy, remove .fn table */
1619  if (lua_isfunction(L,-1)) /* note: if its a C function or lua function */
1620  { /* found it so return the fn & let lua call it */
1621  lua_remove(L,-2); /* stack tidy, remove metatable */
1622  if(ret)
1623  *ret = 1;
1624  return SWIG_OK;
1625  }
1626  lua_pop(L,1); /* remove whatever was there */
1627  /* Remove the metatable */
1628  lua_pop(L,1);
1629  /* Search in base classes */
1630  bases_search_result = SWIG_Lua_iterate_bases(L,type,substack_start+1,SWIG_Lua_class_do_get,ret);
1631  return bases_search_result; /* sorry not known */
1632 }
1633 
1634 /* the class.get method, performs the lookup of class attributes
1635  */
1637 {
1638 /* there should be 2 params passed in
1639  (1) userdata (not the meta table)
1640  (2) string name of the attribute
1641 */
1642  int result;
1643  swig_lua_userdata *usr;
1644  swig_type_info *type;
1645  int ret = 0;
1646  assert(lua_isuserdata(L,1));
1647  usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */
1648  type = usr->type;
1649  result = SWIG_Lua_class_do_get(L,type,1,&ret);
1650  if(result == SWIG_OK)
1651  return ret;
1652 
1653  result = SWIG_Lua_class_do_get_item(L,type,1,&ret);
1654  if(result == SWIG_OK)
1655  return ret;
1656 
1657  return 0;
1658 }
1659 
1660 /* helper for the class.set method, performs the lookup of class attributes
1661  * It returns error code. Number of function return values is passed inside 'ret'
1662  */
1663 SWIGINTERN int SWIG_Lua_class_do_set(lua_State *L, swig_type_info *type, int first_arg, int *ret)
1664 {
1665 /* there should be 3 params passed in
1666  (1) table (not the meta table)
1667  (2) string name of the attribute
1668  (3) any for the new value
1669  */
1670 
1671  int bases_search_result;
1672  int substack_start = lua_gettop(L) - 3;
1673  lua_checkstack(L,5);
1674  assert(lua_isuserdata(L,substack_start+1)); /* just in case */
1675  lua_getmetatable(L,substack_start+1); /* get the meta table */
1676  assert(lua_istable(L,-1)); /* just in case */
1677  if(ret)
1678  *ret = 0; /* it is setter - number of return values is always 0 */
1679 
1680  SWIG_Lua_get_table(L,".set"); /* find the .set table */
1681  if (lua_istable(L,-1))
1682  {
1683  /* look for the key in the .set table */
1684  lua_pushvalue(L,substack_start+2); /* key */
1685  lua_rawget(L,-2);
1686  lua_remove(L,-2); /* tidy stack, remove .set table */
1687  if (lua_iscfunction(L,-1))
1688  { /* found it so call the fn & return its value */
1689  lua_pushvalue(L,substack_start+1); /* userdata */
1690  lua_pushvalue(L,substack_start+3); /* value */
1691  lua_call(L,2,0);
1692  lua_remove(L,substack_start+4); /*remove metatable*/
1693  return SWIG_OK;
1694  }
1695  lua_pop(L,1); /* remove the value */
1696  } else {
1697  lua_pop(L,1); /* remove the answer for .set table request*/
1698  }
1699  /* NEW: looks for the __setitem() fn
1700  this is a user provided set fn */
1701  SWIG_Lua_get_table(L,"__setitem"); /* find the fn */
1702  if (lua_iscfunction(L,-1)) /* if its there */
1703  { /* found it so call the fn & return its value */
1704  lua_pushvalue(L,substack_start+1); /* the userdata */
1705  lua_pushvalue(L,substack_start+2); /* the parameter */
1706  lua_pushvalue(L,substack_start+3); /* the value */
1707  lua_call(L,3,0); /* 3 values in ,0 out */
1708  lua_remove(L,-2); /* stack tidy, remove metatable */
1709  return SWIG_OK;
1710  }
1711  lua_pop(L,1); /* remove value */
1712 
1713  lua_pop(L,1); /* remove metatable */
1714  /* Search among bases */
1715  bases_search_result = SWIG_Lua_iterate_bases(L,type,first_arg,SWIG_Lua_class_do_set,ret);
1716  if(ret)
1717  assert(*ret == 0);
1718  assert(lua_gettop(L) == substack_start + 3);
1719  return bases_search_result;
1720 }
1721 
1722 /* This is the actual method exported to Lua. It calls SWIG_Lua_class_do_set and correctly
1723  * handles return values.
1724  */
1726 {
1727 /* There should be 3 params passed in
1728  (1) table (not the meta table)
1729  (2) string name of the attribute
1730  (3) any for the new value
1731  */
1732  int ret = 0;
1733  int result;
1734  swig_lua_userdata *usr;
1735  swig_type_info *type;
1736  assert(lua_isuserdata(L,1));
1737  usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */
1738  type = usr->type;
1739  result = SWIG_Lua_class_do_set(L,type,1,&ret);
1740  if(result != SWIG_OK) {
1741  SWIG_Lua_pushferrstring(L,"Assignment not possible. No setter/member with this name. For custom assignments implement __setitem method.");
1742  lua_error(L);
1743  } else {
1744  assert(ret==0);
1745  }
1746  return 0;
1747 }
1748 
1749 /* the class.destruct method called by the interpreter */
1751 {
1752 /* there should be 1 params passed in
1753  (1) userdata (not the meta table) */
1754  swig_lua_userdata *usr;
1755  swig_lua_class *clss;
1756  assert(lua_isuserdata(L,-1)); /* just in case */
1757  usr=(swig_lua_userdata*)lua_touserdata(L,-1); /* get it */
1758  /* if must be destroyed & has a destructor */
1759  if (usr->own) /* if must be destroyed */
1760  {
1761  clss=(swig_lua_class*)usr->type->clientdata; /* get the class */
1762  if (clss && clss->destructor) /* there is a destroy fn */
1763  {
1764  clss->destructor(usr->ptr); /* bye bye */
1765  }
1766  }
1767  return 0;
1768 }
1769 
1770 /* the class.__tostring method called by the interpreter and print */
1772 {
1773 /* there should be 1 param passed in
1774  (1) userdata (not the metatable) */
1775  const char *className;
1776  void* userData;
1777  assert(lua_isuserdata(L,1)); /* just in case */
1778  userData = lua_touserdata(L,1); /* get the userdata address for later */
1779  lua_getmetatable(L,1); /* get the meta table */
1780  assert(lua_istable(L,-1)); /* just in case */
1781 
1782  lua_getfield(L, -1, ".type");
1783  className = lua_tostring(L, -1);
1784 
1785  lua_pushfstring(L, "<%s userdata: %p>", className, userData);
1786  return 1;
1787 }
1788 
1789 /* to manually disown some userdata */
1791 {
1792 /* there should be 1 params passed in
1793  (1) userdata (not the meta table) */
1794  swig_lua_userdata *usr;
1795  assert(lua_isuserdata(L,-1)); /* just in case */
1796  usr=(swig_lua_userdata*)lua_touserdata(L,-1); /* get it */
1797 
1798  usr->own = 0; /* clear our ownership */
1799  return 0;
1800 }
1801 
1802 /* lua callable function to compare userdata's value
1803 the issue is that two userdata may point to the same thing
1804 but to lua, they are different objects */
1806 {
1807  int result;
1808  swig_lua_userdata *usr1,*usr2;
1809  if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2)) /* just in case */
1810  return 0; /* nil reply */
1811  usr1=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */
1812  usr2=(swig_lua_userdata*)lua_touserdata(L,2); /* get data */
1813  /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/
1814  result=(usr1->ptr==usr2->ptr);
1815  lua_pushboolean(L,result);
1816  return 1;
1817 }
1818 
1819 /* populate table at the top of the stack with metamethods that ought to be inherited */
1821 {
1822  SWIG_Lua_add_boolean(L, "__add", 1);
1823  SWIG_Lua_add_boolean(L, "__sub", 1);
1824  SWIG_Lua_add_boolean(L, "__mul", 1);
1825  SWIG_Lua_add_boolean(L, "__div", 1);
1826  SWIG_Lua_add_boolean(L, "__mod", 1);
1827  SWIG_Lua_add_boolean(L, "__pow", 1);
1828  SWIG_Lua_add_boolean(L, "__unm", 1);
1829  SWIG_Lua_add_boolean(L, "__len", 1 );
1830  SWIG_Lua_add_boolean(L, "__concat", 1 );
1831  SWIG_Lua_add_boolean(L, "__eq", 1);
1832  SWIG_Lua_add_boolean(L, "__lt", 1);
1833  SWIG_Lua_add_boolean(L, "__le", 1);
1834  SWIG_Lua_add_boolean(L, "__call", 1);
1835  SWIG_Lua_add_boolean(L, "__tostring", 1);
1836  SWIG_Lua_add_boolean(L, "__gc", 0);
1837 }
1838 
1839 /* creates the swig registry */
1841 {
1842  /* create main SWIG registry table */
1843  lua_pushstring(L,"SWIG");
1844  lua_newtable(L);
1845  /* populate it with some predefined data */
1846 
1847  /* .library table. Placeholder */
1848  lua_pushstring(L,".library");
1849  lua_newtable(L);
1850  {
1851  /* list of metamethods that class inherits from its bases */
1852  lua_pushstring(L,"inheritable_metamethods");
1853  lua_newtable(L);
1854  /* populate with list of metamethods */
1856  lua_rawset(L,-3);
1857  }
1858  lua_rawset(L,-3);
1859 
1860  lua_rawset(L,LUA_REGISTRYINDEX);
1861 }
1862 
1863 /* gets the swig registry (or creates it) */
1865 {
1866  /* add this all into the swig registry: */
1867  lua_pushstring(L,"SWIG");
1868  lua_rawget(L,LUA_REGISTRYINDEX); /* get the registry */
1869  if (!lua_istable(L,-1)) /* not there */
1870  { /* must be first time, so add it */
1871  lua_pop(L,1); /* remove the result */
1873  /* then get it */
1874  lua_pushstring(L,"SWIG");
1875  lua_rawget(L,LUA_REGISTRYINDEX);
1876  }
1877 }
1878 
1880 {
1882  lua_pushstring(L, ".library");
1883  lua_rawget(L,-2);
1884  assert( !lua_isnil(L,-1) );
1885  lua_pushstring(L, "inheritable_metamethods");
1886  lua_rawget(L,-2);
1887 
1888  /* Remove class registry and library table */
1889  lua_remove(L,-2);
1890  lua_remove(L,-2);
1891 }
1892 
1893 /* Helper function to get the classes metatable from the register */
1894 SWIGINTERN void SWIG_Lua_get_class_metatable(lua_State *L,const char *cname)
1895 {
1896  SWIG_Lua_get_class_registry(L); /* get the registry */
1897  lua_pushstring(L,cname); /* get the name */
1898  lua_rawget(L,-2); /* get it */
1899  lua_remove(L,-2); /* tidy up (remove registry) */
1900 }
1901 
1902 /* Set up the base classes pointers.
1903 Each class structure has a list of pointers to the base class structures.
1904 This function fills them.
1905 It cannot be done at compile time, as this will not work with hireachies
1906 spread over more than one swig file.
1907 Therefore it must be done at runtime, querying the SWIG type system.
1908 */
1910 {
1911  int i=0;
1912  swig_module_info *module=SWIG_GetModule(L);
1913  for(i=0;clss->base_names[i];i++)
1914  {
1915  if (clss->bases[i]==0) /* not found yet */
1916  {
1917  /* lookup and cache the base class */
1918  swig_type_info *info = SWIG_TypeQueryModule(module,module,clss->base_names[i]);
1919  if (info) clss->bases[i] = (swig_lua_class *) info->clientdata;
1920  }
1921  }
1922 }
1923 
1924 #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
1925 /* Merges two tables */
1926 SWIGINTERN void SWIG_Lua_merge_tables_by_index(lua_State *L, int target, int source)
1927 {
1928  /* iterating */
1929  lua_pushnil(L);
1930  while (lua_next(L,source) != 0) {
1931  /* -1 - value, -2 - index */
1932  /* have to copy to assign */
1933  lua_pushvalue(L,-2); /* copy of index */
1934  lua_pushvalue(L,-2); /* copy of value */
1935  lua_rawset(L, target);
1936  lua_pop(L,1);
1937  /* only key is left */
1938  }
1939 }
1940 
1941 /* Merges two tables with given name. original - index of target metatable, base - index of source metatable */
1942 SWIGINTERN void SWIG_Lua_merge_tables(lua_State *L, const char* name, int original, int base)
1943 {
1944  /* push original[name], then base[name] */
1945  lua_pushstring(L,name);
1946  lua_rawget(L,original);
1947  int original_table = lua_gettop(L);
1948  lua_pushstring(L,name);
1949  lua_rawget(L,base);
1950  int base_table = lua_gettop(L);
1951  SWIG_Lua_merge_tables_by_index(L, original_table, base_table);
1952  /* clearing stack */
1953  lua_pop(L,2);
1954 }
1955 
1956 /* Function takes all symbols from base and adds it to derived class. It's just a helper. */
1957 SWIGINTERN void SWIG_Lua_class_squash_base(lua_State *L, swig_lua_class *base_cls)
1958 {
1959  /* There is one parameter - original, i.e. 'derived' class metatable */
1960  assert(lua_istable(L,-1));
1961  int original = lua_gettop(L);
1962  SWIG_Lua_get_class_metatable(L,base_cls->fqname);
1963  int base = lua_gettop(L);
1964  SWIG_Lua_merge_tables(L, ".fn", original, base );
1965  SWIG_Lua_merge_tables(L, ".set", original, base );
1966  SWIG_Lua_merge_tables(L, ".get", original, base );
1967  lua_pop(L,1);
1968 }
1969 
1970 /* Function squashes all symbols from 'clss' bases into itself */
1971 SWIGINTERN void SWIG_Lua_class_squash_bases(lua_State *L, swig_lua_class *clss)
1972 {
1973  int i;
1975  for(i=0;clss->base_names[i];i++)
1976  {
1977  if (clss->bases[i]==0) /* Somehow it's not found. Skip it */
1978  continue;
1979  /* Thing is: all bases are already registered. Thus they have already executed
1980  * this function. So we just need to squash them into us, because their bases
1981  * are already squashed into them. No need for recursion here!
1982  */
1983  SWIG_Lua_class_squash_base(L, clss->bases[i]);
1984  }
1985  lua_pop(L,1); /*tidy stack*/
1986 }
1987 #endif
1988 
1989 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) /* In elua this is useless */
1990 /* helper add a variable to a registered class */
1991 SWIGINTERN void SWIG_Lua_add_variable(lua_State *L,const char *name,lua_CFunction getFn,lua_CFunction setFn)
1992 {
1993  assert(lua_istable(L,-1)); /* just in case */
1994  SWIG_Lua_get_table(L,".get"); /* find the .get table */
1995  assert(lua_istable(L,-1)); /* just in case */
1996  SWIG_Lua_add_function(L,name,getFn);
1997  lua_pop(L,1); /* tidy stack (remove table) */
1998  if (setFn)
1999  {
2000  SWIG_Lua_get_table(L,".set"); /* find the .set table */
2001  assert(lua_istable(L,-1)); /* just in case */
2002  SWIG_Lua_add_function(L,name,setFn);
2003  lua_pop(L,1); /* tidy stack (remove table) */
2004  }
2005 }
2006 
2007 /* helper to recursively add class static details (static attributes, operations and constants) */
2009 {
2010  int i = 0;
2011  /* The class namespace table must be on the top of the stack */
2012  assert(lua_istable(L,-1));
2013  /* call all the base classes first: we can then override these later: */
2014  for(i=0;clss->bases[i];i++)
2015  {
2017  }
2018 
2020 }
2021 
2022 SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss); /* forward declaration */
2023 
2024 /* helper to recursively add class details (attributes & operations) */
2026 {
2027  int i;
2028  size_t bases_count = 0;
2029  /* Add bases to .bases table */
2030  SWIG_Lua_get_table(L,".bases");
2031  assert(lua_istable(L,-1)); /* just in case */
2032  for(i=0;clss->bases[i];i++)
2033  {
2035  /* Base class must be already registered */
2036  assert(lua_istable(L,-1));
2037  lua_rawseti(L,-2,i+1); /* In lua indexing starts from 1 */
2038  bases_count++;
2039  }
2040  assert(lua_rawlen(L,-1) == bases_count);
2041  lua_pop(L,1); /* remove .bases table */
2042  /* add attributes */
2043  for(i=0;clss->attributes[i].name;i++){
2045  }
2046  /* add methods to the metatable */
2047  SWIG_Lua_get_table(L,".fn"); /* find the .fn table */
2048  assert(lua_istable(L,-1)); /* just in case */
2049  for(i=0;clss->methods[i].name;i++){
2050  SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].func);
2051  }
2052  lua_pop(L,1); /* tidy stack (remove table) */
2053  /* add operator overloads
2054  This adds methods from metatable array to metatable. Can mess up garbage
2055  collectind if someone defines __gc method
2056  */
2057  if(clss->metatable) {
2058  for(i=0;clss->metatable[i].name;i++) {
2059  SWIG_Lua_add_function(L,clss->metatable[i].name,clss->metatable[i].func);
2060  }
2061  }
2062 
2063 #if !defined(SWIG_LUA_SQUASH_BASES)
2064  /* Adding metamethods that are defined in base classes. If bases were squashed
2065  * then it is obviously unnecessary
2066  */
2068 #endif
2069 }
2070 
2071 /* Helpers to add user defined class metamedhods - __add, __sub etc. The helpers are needed
2072  for the following issue: Lua runtime checks for metamethod existence with rawget function
2073  ignoring our SWIG-provided __index and __newindex functions. Thus our inheritance-aware method
2074  search algorithm doesn't work in such case. (Not to say that Lua runtime queries metamethod directly
2075  in metatable and not in object).
2076  Current solution is this: if somewhere in hierarchy metamethod __x is defined, then all descendants
2077  are automatically given a special proxy __x that calls the real __x method.
2078  Obvious idea - to copy __x instead of creating __x-proxy is wrong because if someone changes __x in runtime,
2079  those changes must be reflected in all descendants.
2080 */
2081 
2082 SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L); /*forward declaration*/
2083 
2084 /* The real function that resolves a metamethod.
2085  * Function searches given class and all it's bases(recursively) for first instance of something that is
2086  * not equal to SWIG_Lua_resolve_metatmethod. (Almost always this 'something' is actual metamethod implementation
2087  * and it is a SWIG-generated C function.). It returns value on the top of the L and there is no garbage below the
2088  * answer.
2089  * Returns 1 if found, 0 otherwise.
2090  * clss is class which metatable we will search for method
2091  * metamethod_name_idx is index in L where metamethod name (as string) lies
2092  * skip_check allows to skip searching metamethod in givel clss and immideatelly go to searching in bases. skip_check
2093  * is not caried to subsequent recursive calls - false is always passed. It is set to true only at first call from
2094  * SWIG_Lua_resolve_metamethod
2095  * */
2096 SWIGINTERN int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class *clss, int metamethod_name_idx,
2097  int skip_check)
2098 {
2099  /* This function is called recursively */
2100  int result = 0;
2101  int i = 0;
2102 
2103  if (!skip_check) {
2105  lua_pushvalue(L, metamethod_name_idx);
2106  lua_rawget(L,-2);
2107  /* If this is cfunction and it is equal to SWIG_Lua_resolve_metamethod then
2108  * this isn't the function we are looking for :)
2109  * lua_tocfunction will return NULL if not cfunction
2110  */
2111  if (!lua_isnil(L,-1) && lua_tocfunction(L,-1) != SWIG_Lua_resolve_metamethod ) {
2112  lua_remove(L,-2); /* removing class metatable */
2113  return 1;
2114  }
2115  lua_pop(L,2); /* remove class metatable and query result */
2116  }
2117 
2118  /* Forwarding calls to bases */
2119  for(i=0;clss->bases[i];i++)
2120  {
2121  result = SWIG_Lua_do_resolve_metamethod(L, clss->bases[i], metamethod_name_idx, 0);
2122  if (result)
2123  break;
2124  }
2125 
2126  return result;
2127 }
2128 
2129 /* The proxy function for metamethod. All parameters are passed as cclosure. Searches for actual method
2130  * and calls it */
2132 {
2133  int numargs;
2134  int metamethod_name_idx;
2135  const swig_lua_class* clss;
2136  int result;
2137 
2138  lua_checkstack(L,5);
2139  numargs = lua_gettop(L); /* number of arguments to pass to actual metamethod */
2140 
2141  /* Get upvalues from closure */
2142  lua_pushvalue(L, lua_upvalueindex(1)); /*Get function name*/
2143  metamethod_name_idx = lua_gettop(L);
2144 
2145  lua_pushvalue(L, lua_upvalueindex(2));
2146  clss = (const swig_lua_class*)(lua_touserdata(L,-1));
2147  lua_pop(L,1); /* remove lightuserdata with clss from stack */
2148 
2149  /* Actual work */
2150  result = SWIG_Lua_do_resolve_metamethod(L, clss, metamethod_name_idx, 1);
2151  if (!result) {
2152  SWIG_Lua_pushferrstring(L,"The metamethod proxy is set, but it failed to find actual metamethod. Memory corruption is most likely explanation.");
2153  lua_error(L);
2154  return 0;
2155  }
2156 
2157  lua_remove(L,-2); /* remove metamethod key */
2158  lua_insert(L,1); /* move function to correct position */
2159  lua_call(L, numargs, LUA_MULTRET);
2160  return lua_gettop(L); /* return all results */
2161 }
2162 
2163 
2164 /* If given metamethod must be present in given class, then creates appropriate proxy
2165  * Returns 1 if successfully added, 0 if not added because no base class has it, -1
2166  * if method is defined in the class metatable itself
2167  */
2168 SWIGINTERN int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class *clss, const int metatable_index)
2169 {
2170  int key_index;
2171  int success = 0;
2172  int i = 0;
2173 
2174  /* metamethod name - on the top of the stack */
2175  assert(lua_isstring(L,-1));
2176 
2177  key_index = lua_gettop(L);
2178 
2179  /* Check whether method is already defined in metatable */
2180  lua_pushvalue(L,key_index); /* copy of the key */
2181  lua_gettable(L,metatable_index);
2182  if( !lua_isnil(L,-1) ) {
2183  lua_pop(L,1);
2184  return -1;
2185  }
2186  lua_pop(L,1);
2187 
2188  /* Iterating over immediate bases */
2189  for(i=0;clss->bases[i];i++)
2190  {
2191  const swig_lua_class *base = clss->bases[i];
2193  lua_pushvalue(L, key_index);
2194  lua_rawget(L, -2);
2195  if( !lua_isnil(L,-1) ) {
2196  lua_pushvalue(L, key_index);
2197 
2198  /* Add proxy function */
2199  lua_pushvalue(L, key_index); /* first closure value is function name */
2200  lua_pushlightuserdata(L, clss); /* second closure value is swig_lua_class structure */
2201  lua_pushcclosure(L, SWIG_Lua_resolve_metamethod, 2);
2202 
2203  lua_rawset(L, metatable_index);
2204  success = 1;
2205  }
2206  lua_pop(L,1); /* remove function or nil */
2207  lua_pop(L,1); /* remove base class metatable */
2208 
2209  if( success )
2210  break;
2211  }
2212 
2213  return success;
2214 }
2215 
2217 {
2218  int metatable_index;
2219  int metamethods_info_index;
2220  int tostring_undefined;
2221  int eq_undefined = 0;
2222 
2224  metatable_index = lua_gettop(L);
2226  assert(lua_istable(L,-1));
2227  metamethods_info_index = lua_gettop(L);
2228  lua_pushnil(L); /* first key */
2229  while(lua_next(L, metamethods_info_index) != 0 ) {
2230  /* key at index -2, value at index -1 */
2231  const int is_inheritable = lua_toboolean(L,-2);
2232  lua_pop(L,1); /* remove value - we don't need it anymore */
2233 
2234  if(is_inheritable) { /* if metamethod is inheritable */
2235  SWIG_Lua_add_class_user_metamethod(L,clss,metatable_index);
2236  }
2237  }
2238 
2239  lua_pop(L,1); /* remove inheritable metatmethods table */
2240 
2241  /* Special handling for __tostring method */
2242  lua_pushstring(L, "__tostring");
2243  lua_pushvalue(L,-1);
2244  lua_rawget(L,metatable_index);
2245  tostring_undefined = lua_isnil(L,-1);
2246  lua_pop(L,1);
2247  if( tostring_undefined ) {
2248  lua_pushcfunction(L, SWIG_Lua_class_tostring);
2249  lua_rawset(L, metatable_index);
2250  } else {
2251  lua_pop(L,1); /* remove copy of the key */
2252  }
2253 
2254  /* Special handling for __eq method */
2255  lua_pushstring(L, "__eq");
2256  lua_pushvalue(L,-1);
2257  lua_rawget(L,metatable_index);
2258  eq_undefined = lua_isnil(L,-1);
2259  lua_pop(L,1);
2260  if( eq_undefined ) {
2261  lua_pushcfunction(L, SWIG_Lua_class_equal);
2262  lua_rawset(L, metatable_index);
2263  } else {
2264  lua_pop(L,1); /* remove copy of the key */
2265  }
2266  /* Warning: __index and __newindex are SWIG-defined. For user-defined operator[]
2267  * a __getitem/__setitem method should be defined
2268  */
2269  lua_pop(L,1); /* pop class metatable */
2270 }
2271 
2272 /* Register class static methods,attributes etc as well as constructor proxy */
2274 {
2275  const int SWIGUNUSED begin = lua_gettop(L);
2276  lua_checkstack(L,5); /* just in case */
2277  assert(lua_istable(L,-1)); /* just in case */
2278  assert(strcmp(clss->name, clss->cls_static->name) == 0); /* in class those 2 must be equal */
2279 
2281 
2282  assert(lua_istable(L,-1)); /* just in case */
2283 
2284  /* add its constructor to module with the name of the class
2285  so you can do MyClass(...) as well as new_MyClass(...)
2286  BUT only if a constructor is defined
2287  (this overcomes the problem of pure virtual classes without constructors)*/
2288  if (clss->constructor)
2289  {
2290  lua_getmetatable(L,-1);
2291  assert(lua_istable(L,-1)); /* just in case */
2292  SWIG_Lua_add_function(L,"__call", clss->constructor);
2293  lua_pop(L,1);
2294  }
2295 
2296  assert(lua_istable(L,-1)); /* just in case */
2298 
2299  /* clear stack */
2300  lua_pop(L,1);
2301  assert( lua_gettop(L) == begin );
2302 }
2303 
2304 /* Performs the instance (non-static) class registration process. Metatable for class is created
2305  * and added to the class registry.
2306  */
2308 {
2309  const int SWIGUNUSED begin = lua_gettop(L);
2310  int i;
2311  /* if name already there (class is already registered) then do nothing */
2312  SWIG_Lua_get_class_registry(L); /* get the registry */
2313  lua_pushstring(L,clss->fqname); /* get the name */
2314  lua_rawget(L,-2);
2315  if(!lua_isnil(L,-1)) {
2316  lua_pop(L,2);
2317  assert(lua_gettop(L)==begin);
2318  return;
2319  }
2320  lua_pop(L,2); /* tidy stack */
2321  /* Recursively initialize all bases */
2322  for(i=0;clss->bases[i];i++)
2323  {
2325  }
2326  /* Again, get registry and push name */
2327  SWIG_Lua_get_class_registry(L); /* get the registry */
2328  lua_pushstring(L,clss->fqname); /* get the name */
2329  lua_newtable(L); /* create the metatable */
2330 #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
2331  /* If squashing is requested, then merges all bases metatable into this one.
2332  * It would get us all special methods: __getitem, __add etc.
2333  * This would set .fn, .type, and other .xxx incorrectly, but we will overwrite it right away
2334  */
2335  {
2336  int new_metatable_index = lua_absindex(L,-1);
2337  for(i=0;clss->bases[i];i++)
2338  {
2339  int base_metatable;
2341  base_metatable = lua_absindex(L,-1);
2342  SWIG_Lua_merge_tables_by_index(L,new_metatable_index, base_metatable);
2343  lua_pop(L,1);
2344  }
2345  }
2346  /* And now we will overwrite all incorrectly set data */
2347 #endif
2348  /* add string of class name called ".type" */
2349  lua_pushstring(L,".type");
2350  lua_pushstring(L,clss->fqname);
2351  lua_rawset(L,-3);
2352  /* add a table called bases */
2353  lua_pushstring(L,".bases");
2354  lua_newtable(L);
2355  lua_rawset(L,-3);
2356  /* add a table called ".get" */
2357  lua_pushstring(L,".get");
2358  lua_newtable(L);
2359  lua_rawset(L,-3);
2360  /* add a table called ".set" */
2361  lua_pushstring(L,".set");
2362  lua_newtable(L);
2363  lua_rawset(L,-3);
2364  /* add a table called ".fn" */
2365  lua_pushstring(L,".fn");
2366  lua_newtable(L);
2367  /* add manual disown method */
2369  lua_rawset(L,-3);
2370  /* add accessor fns for using the .get,.set&.fn */
2372  SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_class_set);
2374  /* add it */
2375  lua_rawset(L,-3); /* metatable into registry */
2376  lua_pop(L,1); /* tidy stack (remove registry) */
2377  assert(lua_gettop(L) == begin);
2378 
2379 #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
2380  /* Now merge all symbols from .fn, .set, .get etc from bases to our tables */
2381  SWIG_Lua_class_squash_bases(L,clss);
2382 #endif
2384  SWIG_Lua_add_class_instance_details(L,clss); /* recursive adding of details (atts & ops) */
2385  lua_pop(L,1); /* tidy stack (remove class metatable) */
2386  assert( lua_gettop(L) == begin );
2387 }
2388 
2390 {
2391  int SWIGUNUSED begin;
2392  assert(lua_istable(L,-1)); /* This is a table (module or namespace) where classes will be added */
2395 
2396  /* Add links from static part to instance part and vice versa */
2397  /* [SWIG registry] [Module]
2398  * "MyClass" ----> [MyClass metatable] <===== "MyClass" -+> [static part]
2399  * ".get" ----> ... | | getmetatable()----|
2400  * ".set" ----> ... | | |
2401  * ".static" --------------)----------------/ [static part metatable]
2402  * | ".get" --> ...
2403  * | ".set" --> ....
2404  * |=============================== ".instance"
2405  */
2406  begin = lua_gettop(L);
2407  lua_pushstring(L,clss->cls_static->name);
2408  lua_rawget(L,-2); /* get class static table */
2409  assert(lua_istable(L,-1));
2410  lua_getmetatable(L,-1);
2411  assert(lua_istable(L,-1)); /* get class static metatable */
2412  lua_pushstring(L,".instance"); /* prepare key */
2413 
2414  SWIG_Lua_get_class_metatable(L,clss->fqname); /* get class metatable */
2415  assert(lua_istable(L,-1));
2416  lua_pushstring(L,".static"); /* prepare key */
2417  lua_pushvalue(L, -4); /* push static class TABLE */
2418  assert(lua_istable(L,-1));
2419  lua_rawset(L,-3); /* assign static class table(!NOT metatable) as ".static" member of class metatable */
2420  lua_rawset(L,-3); /* assign class metatable as ".instance" member of class static METATABLE */
2421  lua_pop(L,2);
2422  assert(lua_gettop(L) == begin);
2423 }
2424 #endif /* SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA */
2425 
2426 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
2427 SWIGINTERN void SWIG_Lua_elua_class_register_instance(lua_State *L, swig_lua_class *clss)
2428 {
2429  const int SWIGUNUSED begin = lua_gettop(L);
2430  int i;
2431  /* if name already there (class is already registered) then do nothing */
2432  SWIG_Lua_get_class_registry(L); /* get the registry */
2433  lua_pushstring(L,clss->fqname); /* get the name */
2434  lua_rawget(L,-2);
2435  if(!lua_isnil(L,-1)) {
2436  lua_pop(L,2);
2437  assert(lua_gettop(L)==begin);
2438  return;
2439  }
2440  lua_pop(L,2); /* tidy stack */
2441  /* Recursively initialize all bases */
2442  for(i=0;clss->bases[i];i++)
2443  {
2444  SWIG_Lua_elua_class_register_instance(L,clss->bases[i]);
2445  }
2446  /* Again, get registry and push name */
2447  SWIG_Lua_get_class_registry(L); /* get the registry */
2448  lua_pushstring(L,clss->fqname); /* get the name */
2449  assert(clss->metatable);
2450  lua_pushrotable(L, (void*)(clss->metatable)); /* create the metatable */
2451  lua_rawset(L,-3);
2452  lua_pop(L,1);
2453  assert(lua_gettop(L) == begin);
2454 }
2455 #endif /* elua && eluac */
2456 
2457 /* -----------------------------------------------------------------------------
2458  * Class/structure conversion fns
2459  * ----------------------------------------------------------------------------- */
2460 
2461 /* helper to add metatable to new lua object */
2463 {
2464  if (type->clientdata) /* there is clientdata: so add the metatable */
2465  {
2467  if (lua_istable(L,-1))
2468  {
2469  lua_setmetatable(L,-2);
2470  }
2471  else
2472  {
2473  lua_pop(L,1);
2474  }
2475  }
2476 }
2477 
2478 /* pushes a new object into the lua stack */
2479 SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State *L,void *ptr,swig_type_info *type, int own)
2480 {
2481  swig_lua_userdata *usr;
2482  if (!ptr){
2483  lua_pushnil(L);
2484  return;
2485  }
2486  usr=(swig_lua_userdata*)lua_newuserdata(L,sizeof(swig_lua_userdata)); /* get data */
2487  usr->ptr=ptr; /* set the ptr */
2488  usr->type=type;
2489  usr->own=own;
2490 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
2491  SWIG_Lua_AddMetatable(L,type); /* add metatable */
2492 #endif
2493 }
2494 
2495 /* takes a object from the lua stack & converts it into an object of the correct type
2496  (if possible) */
2497 SWIGRUNTIME int SWIG_Lua_ConvertPtr(lua_State *L,int index,void **ptr,swig_type_info *type,int flags)
2498 {
2499  swig_lua_userdata *usr;
2500  swig_cast_info *cast;
2501  /* special case: lua nil => NULL pointer */
2502  if (lua_isnil(L,index))
2503  {
2504  *ptr=0;
2506  }
2507  usr=(swig_lua_userdata*)lua_touserdata(L,index); /* get data */
2508  if (usr)
2509  {
2510  if (flags & SWIG_POINTER_DISOWN) /* must disown the object */
2511  {
2512  usr->own=0;
2513  }
2514  if (!type) /* special cast void*, no casting fn */
2515  {
2516  *ptr=usr->ptr;
2517  return SWIG_OK; /* ok */
2518  }
2519  cast=SWIG_TypeCheckStruct(usr->type,type); /* performs normal type checking */
2520  if (cast)
2521  {
2522  int newmemory = 0;
2523  *ptr=SWIG_TypeCast(cast,usr->ptr,&newmemory);
2524  assert(!newmemory); /* newmemory handling not yet implemented */
2525  return SWIG_OK; /* ok */
2526  }
2527  }
2528  return SWIG_ERROR; /* error */
2529 }
2530 
2531 SWIGRUNTIME void* SWIG_Lua_MustGetPtr(lua_State *L,int index,swig_type_info *type,int flags,
2532  int argnum,const char *func_name){
2533  void *result;
2534  if (!SWIG_IsOK(SWIG_ConvertPtr(L,index,&result,type,flags))){
2535  luaL_error (L,"Error in %s, expected a %s at argument number %d\n",
2536  func_name,(type && type->str)?type->str:"void*",argnum);
2537  }
2538  return result;
2539 }
2540 
2541 /* pushes a packed userdata. user for member fn pointers only */
2542 SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State *L,void *ptr,size_t size,swig_type_info *type)
2543 {
2544  swig_lua_rawdata *raw;
2545  assert(ptr); /* not acceptable to pass in a NULL value */
2546  raw=(swig_lua_rawdata*)lua_newuserdata(L,sizeof(swig_lua_rawdata)-1+size); /* alloc data */
2547  raw->type=type;
2548  raw->own=0;
2549  memcpy(raw->data,ptr,size); /* copy the data */
2550  SWIG_Lua_AddMetatable(L,type); /* add metatable */
2551 }
2552 
2553 /* converts a packed userdata. user for member fn pointers only */
2554 SWIGRUNTIME int SWIG_Lua_ConvertPacked(lua_State *L,int index,void *ptr,size_t size,swig_type_info *type)
2555 {
2556  swig_lua_rawdata *raw;
2557  raw=(swig_lua_rawdata*)lua_touserdata(L,index); /* get data */
2558  if (!raw) return SWIG_ERROR; /* error */
2559  if (type==0 || type==raw->type) /* void* or identical type */
2560  {
2561  memcpy(ptr,raw->data,size); /* copy it */
2562  return SWIG_OK; /* ok */
2563  }
2564  return SWIG_ERROR; /* error */
2565 }
2566 
2567 /* a function to get the typestring of a piece of data */
2568 SWIGRUNTIME const char *SWIG_Lua_typename(lua_State *L, int tp)
2569 {
2570  swig_lua_userdata *usr;
2571  if (lua_isuserdata(L,tp))
2572  {
2573  usr=(swig_lua_userdata*)lua_touserdata(L,tp); /* get data */
2574  if (usr && usr->type && usr->type->str)
2575  return usr->type->str;
2576  return "userdata (unknown type)";
2577  }
2578  return lua_typename(L,lua_type(L,tp));
2579 }
2580 
2581 /* lua callable function to get the userdata's type */
2582 SWIGRUNTIME int SWIG_Lua_type(lua_State *L)
2583 {
2584  lua_pushstring(L,SWIG_Lua_typename(L,1));
2585  return 1;
2586 }
2587 
2588 /* -----------------------------------------------------------------------------
2589  * global variable support code: class/struct typemap functions
2590  * ----------------------------------------------------------------------------- */
2591 
2592 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
2593 /* Install Constants */
2594 SWIGINTERN void
2596  int i;
2597  for (i = 0; constants[i].type; i++) {
2598  switch(constants[i].type) {
2599  case SWIG_LUA_INT:
2600  lua_pushstring(L,constants[i].name);
2601  lua_pushinteger(L,(lua_Integer)constants[i].lvalue);
2602  lua_rawset(L,-3);
2603  break;
2604  case SWIG_LUA_FLOAT:
2605  lua_pushstring(L,constants[i].name);
2606  lua_pushnumber(L,(lua_Number)constants[i].dvalue);
2607  lua_rawset(L,-3);
2608  break;
2609  case SWIG_LUA_CHAR:
2610  lua_pushstring(L,constants[i].name);
2611  {
2612  char c = (char)constants[i].lvalue;
2613  lua_pushlstring(L,&c,1);
2614  }
2615  lua_rawset(L,-3);
2616  break;
2617  case SWIG_LUA_STRING:
2618  lua_pushstring(L,constants[i].name);
2619  lua_pushstring(L,(char *) constants[i].pvalue);
2620  lua_rawset(L,-3);
2621  break;
2622  case SWIG_LUA_POINTER:
2623  lua_pushstring(L,constants[i].name);
2624  SWIG_NewPointerObj(L,constants[i].pvalue, *(constants[i]).ptype,0);
2625  lua_rawset(L,-3);
2626  break;
2627  case SWIG_LUA_BINARY:
2628  lua_pushstring(L,constants[i].name);
2629  SWIG_NewMemberObj(L,constants[i].pvalue,constants[i].lvalue,*(constants[i]).ptype);
2630  lua_rawset(L,-3);
2631  break;
2632  default:
2633  break;
2634  }
2635  }
2636 }
2637 #endif
2638 
2639 /* -----------------------------------------------------------------------------
2640  * executing lua code from within the wrapper
2641  * ----------------------------------------------------------------------------- */
2642 
2643 #ifndef SWIG_DOSTRING_FAIL /* Allows redefining of error function */
2644 #define SWIG_DOSTRING_FAIL(S) fprintf(stderr,"%s\n",S)
2645 #endif
2646 /* Executes a C string in Lua which is a really simple way of calling lua from C
2647 Unfortunately lua keeps changing its APIs, so we need a conditional compile
2648 In lua 5.0.X it's lua_dostring()
2649 In lua 5.1.X it's luaL_dostring()
2650 */
2651 SWIGINTERN int
2652 SWIG_Lua_dostring(lua_State *L, const char *str) {
2653  int ok,top;
2654  if (str==0 || str[0]==0) return 0; /* nothing to do */
2655  top=lua_gettop(L); /* save stack */
2656 #if (defined(LUA_VERSION_NUM) && (LUA_VERSION_NUM>=501))
2657  ok=luaL_dostring(L,str); /* looks like this is lua 5.1.X or later, good */
2658 #else
2659  ok=lua_dostring(L,str); /* might be lua 5.0.x, using lua_dostring */
2660 #endif
2661  if (ok!=0) {
2662  SWIG_DOSTRING_FAIL(lua_tostring(L,-1));
2663  }
2664  lua_settop(L,top); /* restore the stack */
2665  return ok;
2666 }
2667 
2668 #ifdef __cplusplus
2669 }
2670 #endif
2671 
2672 /* ------------------------------ end luarun.swg ------------------------------ */
2673 
2674 
2675 /* -------- TYPES TABLE (BEGIN) -------- */
2676 
2677 #define SWIGTYPE_p_PLGraphicsIn swig_types[0]
2678 #define SWIGTYPE_p_char swig_types[1]
2679 #define SWIGTYPE_p_double swig_types[2]
2680 #define SWIGTYPE_p_f_double_double__int swig_types[3]
2681 #define SWIGTYPE_p_f_double_double_p_double_p_double_p_void__void swig_types[4]
2682 #define SWIGTYPE_p_f_int_double_p_char_int_p_void__void swig_types[5]
2683 #define SWIGTYPE_p_f_int_p_double_p_double__void swig_types[6]
2684 #define SWIGTYPE_p_f_int_p_q_const__double_p_q_const__double__void swig_types[7]
2685 #define SWIGTYPE_p_int swig_types[8]
2686 #define SWIGTYPE_p_p_char swig_types[9]
2687 #define SWIGTYPE_p_p_double swig_types[10]
2688 #define SWIGTYPE_p_unsigned_int swig_types[11]
2690 static swig_module_info swig_module = {swig_types, 12, 0, 0, 0, 0};
2691 #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
2692 #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
2693 
2694 /* -------- TYPES TABLE (END) -------- */
2695 
2696 #define SWIG_name "plplotluac"
2697 #define SWIG_init luaopen_plplotluac
2698 #define SWIG_init_user luaopen_plplotluac_user
2699 
2700 #define SWIG_LUACODE luaopen_plplotluac_luacode
2701 
2702 #include "plplotP.h"
2703 
2704 
2705 #define LUA_ALLOC_ARRAY( TYPE, LEN ) (TYPE *) malloc( LEN * sizeof ( TYPE ) )
2706 #define LUA_FREE_ARRAY( PTR ) if ( PTR ) { free( PTR ); PTR = NULL;}
2707 
2708 // super macro to declare array typemap helper fns
2709  SWIGINTERN int SWIG_itable_size( lua_State* L, int index );
2710 #define LUA_DECLARE_TYPEMAP_ARR_FN( NAME, TYPE ) \
2711  SWIGINTERN int LUA_read_ ## NAME ## _num_array( lua_State * L, int index, TYPE * array, int size ){ \
2712  int i; \
2713  for ( i = 0; i < size; i++ ) { \
2714  lua_rawgeti( L, index, i + 1 ); \
2715  if ( lua_isnumber( L, -1 ) ) { \
2716  array[i] = (TYPE) lua_tonumber( L, -1 ); \
2717  } else { \
2718  lua_pop( L, 1 ); \
2719  return 0; \
2720  } \
2721  lua_pop( L, 1 ); \
2722  } \
2723  return 1; \
2724  } \
2725  SWIGINTERN TYPE* LUA_get_ ## NAME ## _num_array_var( lua_State * L, int index, int* size ) \
2726  { \
2727  TYPE *array; \
2728  if ( !lua_istable( L, index ) ) { \
2729  lua_pushstring( L, "expected a table" ); \
2730  return 0; \
2731  } \
2732  *size = SWIG_itable_size( L, index ); \
2733  if ( *size < 1 ) { \
2734  array = LUA_ALLOC_ARRAY( TYPE, 1 ); \
2735  array[0] = (TYPE) 0; \
2736  return array; \
2737  } \
2738  array = LUA_ALLOC_ARRAY( TYPE, *size ); \
2739  if ( !LUA_read_ ## NAME ## _num_array( L, index, array, *size ) ) { \
2740  lua_pushstring( L, "table must contain numbers" ); \
2741  LUA_FREE_ARRAY( array ); \
2742  return 0; \
2743  } \
2744  return array; \
2745  }
2746 
2747  LUA_DECLARE_TYPEMAP_ARR_FN( double, double );
2748  LUA_DECLARE_TYPEMAP_ARR_FN( int, int );
2749 
2750 
2751  static PLINT Alen = 0;
2752  static PLINT Xlen = 0, Ylen = 0;
2753 
2754 
2755 #ifdef __cplusplus /* generic alloc/dealloc fns*/
2756 #define SWIG_ALLOC_ARRAY(TYPE,LEN) new TYPE[LEN]
2757 #define SWIG_FREE_ARRAY(PTR) delete[] PTR
2758 #else
2759 #define SWIG_ALLOC_ARRAY(TYPE,LEN) (TYPE *)malloc(LEN*sizeof(TYPE))
2760 #define SWIG_FREE_ARRAY(PTR) free(PTR)
2761 #endif
2762 /* counting the size of arrays:*/
2763 SWIGINTERN int SWIG_itable_size(lua_State* L, int index)
2764 {
2765  int n=0;
2766  while(1){
2767  lua_rawgeti(L,index,n+1);
2768  if (lua_isnil(L,-1))break;
2769  ++n;
2770  lua_pop(L,1);
2771  }
2772  lua_pop(L,1);
2773  return n;
2774 }
2775 
2776 SWIGINTERN int SWIG_table_size(lua_State* L, int index)
2777 {
2778  int n=0;
2779  lua_pushnil(L); /* first key*/
2780  while (lua_next(L, index) != 0) {
2781  ++n;
2782  lua_pop(L, 1); /* removes `value'; keeps `key' for next iteration*/
2783  }
2784  return n;
2785 }
2786 
2787 /* super macro to declare array typemap helper fns */
2788 #define SWIG_DECLARE_TYPEMAP_ARR_FN(NAME,TYPE)\
2789  SWIGINTERN int SWIG_read_##NAME##_num_array(lua_State* L,int index,TYPE *array,int size){\
2790  int i;\
2791  for (i = 0; i < size; i++) {\
2792  lua_rawgeti(L,index,i+1);\
2793  if (lua_isnumber(L,-1)){\
2794  array[i] = (TYPE)lua_tonumber(L,-1);\
2795  } else {\
2796  lua_pop(L,1);\
2797  return 0;\
2798  }\
2799  lua_pop(L,1);\
2800  }\
2801  return 1;\
2802  }\
2803  SWIGINTERN TYPE* SWIG_get_##NAME##_num_array_fixed(lua_State* L, int index, int size){\
2804  TYPE *array;\
2805  if (!lua_istable(L,index) || SWIG_itable_size(L,index) != size) {\
2806  SWIG_Lua_pushferrstring(L,"expected a table of size %d",size);\
2807  return 0;\
2808  }\
2809  array=SWIG_ALLOC_ARRAY(TYPE,size);\
2810  if (!SWIG_read_##NAME##_num_array(L,index,array,size)){\
2811  SWIG_Lua_pusherrstring(L,"table must contain numbers");\
2812  SWIG_FREE_ARRAY(array);\
2813  return 0;\
2814  }\
2815  return array;\
2816  }\
2817  SWIGINTERN TYPE* SWIG_get_##NAME##_num_array_var(lua_State* L, int index, int* size)\
2818  {\
2819  TYPE *array;\
2820  if (!lua_istable(L,index)) {\
2821  SWIG_Lua_pusherrstring(L,"expected a table");\
2822  return 0;\
2823  }\
2824  *size=SWIG_itable_size(L,index);\
2825  if (*size<1){\
2826  SWIG_Lua_pusherrstring(L,"table appears to be empty");\
2827  return 0;\
2828  }\
2829  array=SWIG_ALLOC_ARRAY(TYPE,*size);\
2830  if (!SWIG_read_##NAME##_num_array(L,index,array,*size)){\
2831  SWIG_Lua_pusherrstring(L,"table must contain numbers");\
2832  SWIG_FREE_ARRAY(array);\
2833  return 0;\
2834  }\
2835  return array;\
2836  }\
2837  SWIGINTERN void SWIG_write_##NAME##_num_array(lua_State* L,TYPE *array,int size){\
2838  int i;\
2839  lua_newtable(L);\
2840  for (i = 0; i < size; i++){\
2841  lua_pushnumber(L,(lua_Number)array[i]);\
2842  lua_rawseti(L,-2,i+1);/* -1 is the number, -2 is the table*/ \
2843  }\
2844  }
2845 
2846 SWIG_DECLARE_TYPEMAP_ARR_FN(schar,signed char)
2847 SWIG_DECLARE_TYPEMAP_ARR_FN(uchar,unsigned char)
2849 SWIG_DECLARE_TYPEMAP_ARR_FN(uint,unsigned int)
2850 SWIG_DECLARE_TYPEMAP_ARR_FN(short,short)
2851 SWIG_DECLARE_TYPEMAP_ARR_FN(ushort,unsigned short)
2852 SWIG_DECLARE_TYPEMAP_ARR_FN(long,long)
2853 SWIG_DECLARE_TYPEMAP_ARR_FN(ulong,unsigned long)
2854 SWIG_DECLARE_TYPEMAP_ARR_FN(float,float)
2855 SWIG_DECLARE_TYPEMAP_ARR_FN(double,double)
2856 
2857 SWIGINTERN int SWIG_read_ptr_array(lua_State* L,int index,void **array,int size,swig_type_info *type){
2858  int i;
2859  for (i = 0; i < size; i++) {
2860  lua_rawgeti(L,index,i+1);
2861  if (!lua_isuserdata(L,-1) || SWIG_ConvertPtr(L,-1,&array[i],type,0)==-1){
2862  lua_pop(L,1);
2863  return 0;
2864  }
2865  lua_pop(L,1);
2866  }
2867  return 1;
2868 }
2869 SWIGINTERN void** SWIG_get_ptr_array_fixed(lua_State* L, int index, int size,swig_type_info *type){
2870  void **array;
2871  if (!lua_istable(L,index) || SWIG_itable_size(L,index) != size) {
2872  SWIG_Lua_pushferrstring(L,"expected a table of size %d",size);
2873  return 0;
2874  }
2875  array=SWIG_ALLOC_ARRAY(void*,size);
2876  if (!SWIG_read_ptr_array(L,index,array,size,type)){
2877  SWIG_Lua_pushferrstring(L,"table must contain pointers of type %s",type->name);
2878  SWIG_FREE_ARRAY(array);
2879  return 0;
2880  }
2881  return array;
2882 }
2883 SWIGINTERN void** SWIG_get_ptr_array_var(lua_State* L, int index, int* size,swig_type_info *type){
2884  void **array;
2885  if (!lua_istable(L,index)) {
2886  SWIG_Lua_pusherrstring(L,"expected a table");
2887  return 0;
2888  }
2889  *size=SWIG_itable_size(L,index);
2890  if (*size<1){
2891  SWIG_Lua_pusherrstring(L,"table appears to be empty");
2892  return 0;
2893  }
2894  array=SWIG_ALLOC_ARRAY(void*,*size);
2895  if (!SWIG_read_ptr_array(L,index,array,*size,type)){
2896  SWIG_Lua_pushferrstring(L,"table must contain pointers of type %s",type->name);
2897  SWIG_FREE_ARRAY(array);
2898  return 0;
2899  }
2900  return array;
2901 }
2902 SWIGINTERN void SWIG_write_ptr_array(lua_State* L,void **array,int size,swig_type_info *type,int own){
2903  int i;
2904  lua_newtable(L);
2905  for (i = 0; i < size; i++){
2906  SWIG_NewPointerObj(L,array[i],type,own);
2907  lua_rawseti(L,-2,i+1);/* -1 is the number, -2 is the table*/
2908  }
2909 }
2910 
2911 
2912  PLFLT** read_double_Matrix( lua_State* L, int index, int* nx, int *ny );
2913 
2914  PLFLT** read_double_Matrix( lua_State* L, int index, int* nx, int *ny )
2915  {
2916  int i, j;
2917  PLFLT** matrix;
2918 
2919  *nx = 0;
2920  *ny = 0;
2921 
2922  if ( !lua_istable( L, index ) )
2923  {
2924  lua_pushstring( L, "expected a table" );
2925  return NULL;
2926  }
2927  *nx = SWIG_itable_size( L, index );
2928  if ( *nx < 1 )
2929  {
2930  lua_pushstring( L, "table appears to be empty" );
2931  return NULL;
2932  }
2933  matrix = LUA_ALLOC_ARRAY( PLFLT *, *nx );
2934  for ( i = 0; i < *nx; i++ )
2935  matrix[i] = NULL;
2936 
2937  lua_rawgeti( L, index, 1 );
2938  if ( !lua_istable( L, -1 ) )
2939  {
2940  lua_pop( L, 1 );
2941  lua_pushstring( L, "expected a table" );
2942  LUA_FREE_ARRAY( matrix );
2943  return NULL;
2944  }
2945  *ny = SWIG_itable_size( L, -1 );
2946  if ( *ny < 1 )
2947  {
2948  lua_pushstring( L, "table appears to be empty" );
2949  LUA_FREE_ARRAY( matrix );
2950  return NULL;
2951  }
2952  lua_pop( L, 1 );
2953 
2954  for ( i = 0; i < *nx; i++ )
2955  {
2956  lua_rawgeti( L, index, i + 1 );
2957  if ( !lua_istable( L, -1 ) )
2958  {
2959  lua_pop( L, 1 );
2960  lua_pushstring( L, "expected a table" );
2961  for ( j = 0; j < *ny; j++ )
2962  LUA_FREE_ARRAY( matrix[j] );
2963  LUA_FREE_ARRAY( matrix );
2964  return NULL;
2965  }
2966  if ( *ny != SWIG_itable_size( L, -1 ) )
2967  {
2968  lua_pop( L, 1 );
2969  lua_pushstring( L, "inconsistent table sizes" );
2970  for ( j = 0; j < i; j++ )
2971  LUA_FREE_ARRAY( matrix[j] );
2972  LUA_FREE_ARRAY( matrix );
2973  return NULL;
2974  }
2975  matrix[i] = LUA_ALLOC_ARRAY( PLFLT, *ny );
2976  for ( j = 0; j < *ny; j++ )
2977  {
2978  lua_rawgeti( L, -1, j + 1 );
2979  if ( lua_isnumber( L, -1 ) )
2980  {
2981  matrix[i][j] = (PLFLT) lua_tonumber( L, -1 );
2982  }
2983  else
2984  {
2985  lua_pop( L, 1 );
2986  lua_pushstring( L, "table must contain numbers" );
2987  for ( j = 0; j < i + 1; j++ )
2988  LUA_FREE_ARRAY( matrix[j] );
2989  LUA_FREE_ARRAY( matrix );
2990  return NULL;
2991  }
2992  lua_pop( L, 1 );
2993  }
2994  lua_pop( L, 1 );
2995  }
2996 
2997  return matrix;
2998  }
2999 
3000 
3001  void mapform( PLINT n, PLFLT* x, PLFLT* y );
3002 
3003  static lua_State* myL = NULL;
3004  static char mapform_funcstr[255];
3005 
3006  void mapform( PLINT n, PLFLT* x, PLFLT* y )
3007  {
3008  PLFLT *xtemp, *ytemp;
3009  int len, i;
3010 
3011  // check Lua state
3012  if ( myL == NULL )
3013  {
3014  fprintf( stderr, "Lua state is not set!" );
3015  return;
3016  }
3017 
3018  // push functions and arguments
3019  lua_getglobal( myL, mapform_funcstr ); // function to be called
3020  lua_pushnumber( myL, n ); // push 1st argument
3021  SWIG_write_double_num_array( myL, x, n ); // push 2nd argument
3022  SWIG_write_double_num_array( myL, y, n ); // push 3rd argument
3023 
3024  // do the call (3 arguments, 2 result)
3025  if ( lua_pcall( myL, 3, 2, 0 ) != 0 )
3026  fprintf( stderr, "error running function `%s':%s",
3027  mapform_funcstr, lua_tostring( myL, -1 ) );
3028 
3029  // retrieve results
3030  if ( !lua_istable( myL, -2 ) )
3031  {
3032  fprintf( stderr, "function `%s' must return a table as 1st result", mapform_funcstr );
3033  return;
3034  }
3035  if ( !lua_istable( myL, -1 ) )
3036  {
3037  fprintf( stderr, "function `%s' must return a table as 2nd result", mapform_funcstr );
3038  return;
3039  }
3040  xtemp = (PLFLT *) LUA_get_double_num_array_var( myL, -2, &len );
3041  if ( !xtemp || len != n )
3042  {
3043  fprintf( stderr, "function `%s' must return a table of length%d", mapform_funcstr, n );
3044  return;
3045  }
3046  for ( i = 0; i < n; i++ )
3047  x[i] = xtemp[i];
3048  LUA_FREE_ARRAY( xtemp );
3049 
3050  ytemp = (PLFLT *) LUA_get_double_num_array_var( myL, -1, &len );
3051  if ( !ytemp || len != n )
3052  {
3053  fprintf( stderr, "function `%s' must return a table of length%d", mapform_funcstr, n );
3054  return;
3055  }
3056  for ( i = 0; i < n; i++ )
3057  y[i] = ytemp[i];
3058  LUA_FREE_ARRAY( ytemp );
3059 
3060  lua_pop( myL, 2 ); // pop returned values
3061 
3062  return;
3063  }
3064 
3065 
3066  typedef PLINT ( *defined_func )( PLFLT, PLFLT );
3067  typedef void ( *fill_func )( PLINT, const PLFLT*, const PLFLT* );
3068  typedef void ( *pltr_func )( PLFLT, PLFLT, PLFLT *, PLFLT*, PLPointer );
3069  typedef void ( *ct_func )( PLFLT, PLFLT, PLFLT *, PLFLT*, PLPointer );
3070  typedef void ( *mapform_func )( PLINT, PLFLT *, PLFLT* );
3072  typedef void ( *label_func )( PLINT, PLFLT, char*, PLINT, PLPointer );
3073 
3074 // Function prototypes
3075  void mypltr( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * pltr_data );
3076  void myct( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * pltr_data );
3077  void mylabel( PLINT axis, PLFLT value, char* label, PLINT length, PLPointer data );
3078 
3079  static char mypltr_funcstr[255];
3080 
3081 // This is the callback that gets handed to the C code.
3082 // It, in turn, calls the Lua callback
3083  void mypltr( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * PL_UNUSED( pltr_data ) )
3084  {
3085  *tx = 0;
3086  *ty = 0;
3087 
3088  // check Lua state
3089  if ( myL == NULL )
3090  {
3091  fprintf( stderr, "Lua state is not set!" );
3092  return;
3093  }
3094 
3095  // push functions and arguments
3096  lua_getglobal( myL, mypltr_funcstr ); // function to be called
3097  lua_pushnumber( myL, x ); // push 1st argument
3098  lua_pushnumber( myL, y ); // push 2nd argument
3099 
3100  // do the call (2 arguments, 2 result)
3101  if ( lua_pcall( myL, 2, 2, 0 ) != 0 )
3102  fprintf( stderr, "error running function `%s':%s",
3103  mypltr_funcstr, lua_tostring( myL, -1 ) );
3104 
3105  // retrieve results
3106  if ( !lua_isnumber( myL, -2 ) )
3107  {
3108  fprintf( stderr, "function `%s' must return a number as 1st result", mypltr_funcstr );
3109  return;
3110  }
3111  if ( !lua_isnumber( myL, -1 ) )
3112  {
3113  fprintf( stderr, "function `%s' must return a number as 2nd result", mypltr_funcstr );
3114  return;
3115  }
3116  *tx = lua_tonumber( myL, -2 );
3117  *ty = lua_tonumber( myL, -1 );
3118  lua_pop( myL, 2 ); // pop returned values
3119 
3120  return;
3121  }
3122 
3123  static char myct_funcstr[255];
3124 
3125 // This is the callback that gets handed to the C code.
3126 // It, in turn, calls the Lua callback
3127  void myct( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void * PL_UNUSED( pltr_data ) )
3128  {
3129  *tx = 0;
3130  *ty = 0;
3131 
3132  // check Lua state
3133  if ( myL == NULL )
3134  {
3135  fprintf( stderr, "Lua state is not set!" );
3136  return;
3137  }
3138 
3139  // push functions and arguments
3140  lua_getglobal( myL, myct_funcstr ); // function to be called
3141  lua_pushnumber( myL, x ); // push 1st argument
3142  lua_pushnumber( myL, y ); // push 2nd argument
3143 
3144  // do the call (2 arguments, 2 result)
3145  if ( lua_pcall( myL, 2, 2, 0 ) != 0 )
3146  fprintf( stderr, "error running function `%s':%s",
3147  myct_funcstr, lua_tostring( myL, -1 ) );
3148 
3149  // retrieve results
3150  if ( !lua_isnumber( myL, -2 ) )
3151  {
3152  fprintf( stderr, "function `%s' must return a number as 1st result", myct_funcstr );
3153  return;
3154  }
3155  if ( !lua_isnumber( myL, -1 ) )
3156  {
3157  fprintf( stderr, "function `%s' must return a number as 2nd result", myct_funcstr );
3158  return;
3159  }
3160  *tx = lua_tonumber( myL, -2 );
3161  *ty = lua_tonumber( myL, -1 );
3162  lua_pop( myL, 2 ); // pop returned values
3163 
3164  return;
3165  }
3166 
3167  static char mylabel_funcstr[255];
3168 
3169  void mylabel( PLINT axis, PLFLT value, char* label, PLINT length, PLPointer PL_UNUSED( data ) )
3170  {
3171  // check Lua state
3172  if ( myL == NULL )
3173  {
3174  fprintf( stderr, "Lua state is not set!" );
3175  return;
3176  }
3177 
3178  // push functions and arguments
3179  lua_getglobal( myL, mylabel_funcstr ); // function to be called
3180  lua_pushnumber( myL, axis ); // push 1st argument
3181  lua_pushnumber( myL, value ); // push 1st argument
3182 
3183  // do the call (2 arguments, 1 result)
3184  if ( lua_pcall( myL, 2, 1, 0 ) != 0 )
3185  fprintf( stderr, "error running function `%s':%s",
3186  mylabel_funcstr, lua_tostring( myL, -1 ) );
3187 
3188  // retrieve results
3189  if ( !lua_isstring( myL, -1 ) )
3190  {
3191  fprintf( stderr, "function `%s' must return a string as result", mylabel_funcstr );
3192  return;
3193  }
3194  strncpy( label, lua_tostring( myL, -1 ), length );
3195 
3196  lua_pop( myL, 1 ); // pop returned values
3197 
3198  return;
3199  }
3200 
3201 
3202 SWIGINTERN int SWIG_lua_isnilstring(lua_State *L, int idx) {
3203  int ret = lua_isstring(L, idx);
3204  if (!ret)
3205  ret = lua_isnil(L, idx);
3206  return ret;
3207 }
3208 
3209 #ifdef __cplusplus
3210 extern "C" {
3211 #endif
3212 static int _wrap_PLGraphicsIn_type_set(lua_State* L) {
3213  int SWIG_arg = 0;
3214  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3215  int arg2 ;
3216 
3217  SWIG_check_num_args("PLGraphicsIn::type",2,2)
3218  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::type",1,"PLGraphicsIn *");
3219  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::type",2,"int");
3220 
3221  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3222  SWIG_fail_ptr("PLGraphicsIn_type_set",1,SWIGTYPE_p_PLGraphicsIn);
3223  }
3224 
3225  arg2 = (int)lua_tonumber(L, 2);
3226  if (arg1) (arg1)->type = arg2;
3227 
3228  return SWIG_arg;
3229 
3230  if(0) SWIG_fail;
3231 
3232 fail:
3233  lua_error(L);
3234  return SWIG_arg;
3235 }
3236 
3237 
3238 static int _wrap_PLGraphicsIn_type_get(lua_State* L) {
3239  int SWIG_arg = 0;
3240  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3241  int result;
3242 
3243  SWIG_check_num_args("PLGraphicsIn::type",1,1)
3244  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::type",1,"PLGraphicsIn *");
3245 
3246  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3247  SWIG_fail_ptr("PLGraphicsIn_type_get",1,SWIGTYPE_p_PLGraphicsIn);
3248  }
3249 
3250  result = (int) ((arg1)->type);
3251  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3252  return SWIG_arg;
3253 
3254  if(0) SWIG_fail;
3255 
3256 fail:
3257  lua_error(L);
3258  return SWIG_arg;
3259 }
3260 
3261 
3262 static int _wrap_PLGraphicsIn_state_set(lua_State* L) {
3263  int SWIG_arg = 0;
3264  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3265  unsigned int arg2 ;
3266 
3267  SWIG_check_num_args("PLGraphicsIn::state",2,2)
3268  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::state",1,"PLGraphicsIn *");
3269  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::state",2,"unsigned int");
3270 
3271  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3272  SWIG_fail_ptr("PLGraphicsIn_state_set",1,SWIGTYPE_p_PLGraphicsIn);
3273  }
3274 
3275  SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")
3276  arg2 = (unsigned int)lua_tonumber(L, 2);
3277  if (arg1) (arg1)->state = arg2;
3278 
3279  return SWIG_arg;
3280 
3281  if(0) SWIG_fail;
3282 
3283 fail:
3284  lua_error(L);
3285  return SWIG_arg;
3286 }
3287 
3288 
3289 static int _wrap_PLGraphicsIn_state_get(lua_State* L) {
3290  int SWIG_arg = 0;
3291  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3292  unsigned int result;
3293 
3294  SWIG_check_num_args("PLGraphicsIn::state",1,1)
3295  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::state",1,"PLGraphicsIn *");
3296 
3297  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3298  SWIG_fail_ptr("PLGraphicsIn_state_get",1,SWIGTYPE_p_PLGraphicsIn);
3299  }
3300 
3301  result = (unsigned int) ((arg1)->state);
3302  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3303  return SWIG_arg;
3304 
3305  if(0) SWIG_fail;
3306 
3307 fail:
3308  lua_error(L);
3309  return SWIG_arg;
3310 }
3311 
3312 
3313 static int _wrap_PLGraphicsIn_keysym_set(lua_State* L) {
3314  int SWIG_arg = 0;
3315  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3316  unsigned int arg2 ;
3317 
3318  SWIG_check_num_args("PLGraphicsIn::keysym",2,2)
3319  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::keysym",1,"PLGraphicsIn *");
3320  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::keysym",2,"unsigned int");
3321 
3322  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3323  SWIG_fail_ptr("PLGraphicsIn_keysym_set",1,SWIGTYPE_p_PLGraphicsIn);
3324  }
3325 
3326  SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")
3327  arg2 = (unsigned int)lua_tonumber(L, 2);
3328  if (arg1) (arg1)->keysym = arg2;
3329 
3330  return SWIG_arg;
3331 
3332  if(0) SWIG_fail;
3333 
3334 fail:
3335  lua_error(L);
3336  return SWIG_arg;
3337 }
3338 
3339 
3340 static int _wrap_PLGraphicsIn_keysym_get(lua_State* L) {
3341  int SWIG_arg = 0;
3342  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3343  unsigned int result;
3344 
3345  SWIG_check_num_args("PLGraphicsIn::keysym",1,1)
3346  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::keysym",1,"PLGraphicsIn *");
3347 
3348  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3349  SWIG_fail_ptr("PLGraphicsIn_keysym_get",1,SWIGTYPE_p_PLGraphicsIn);
3350  }
3351 
3352  result = (unsigned int) ((arg1)->keysym);
3353  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3354  return SWIG_arg;
3355 
3356  if(0) SWIG_fail;
3357 
3358 fail:
3359  lua_error(L);
3360  return SWIG_arg;
3361 }
3362 
3363 
3364 static int _wrap_PLGraphicsIn_button_set(lua_State* L) {
3365  int SWIG_arg = 0;
3366  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3367  unsigned int arg2 ;
3368 
3369  SWIG_check_num_args("PLGraphicsIn::button",2,2)
3370  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::button",1,"PLGraphicsIn *");
3371  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::button",2,"unsigned int");
3372 
3373  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3374  SWIG_fail_ptr("PLGraphicsIn_button_set",1,SWIGTYPE_p_PLGraphicsIn);
3375  }
3376 
3377  SWIG_contract_assert((lua_tonumber(L,2)>=0),"number must not be negative")
3378  arg2 = (unsigned int)lua_tonumber(L, 2);
3379  if (arg1) (arg1)->button = arg2;
3380 
3381  return SWIG_arg;
3382 
3383  if(0) SWIG_fail;
3384 
3385 fail:
3386  lua_error(L);
3387  return SWIG_arg;
3388 }
3389 
3390 
3391 static int _wrap_PLGraphicsIn_button_get(lua_State* L) {
3392  int SWIG_arg = 0;
3393  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3394  unsigned int result;
3395 
3396  SWIG_check_num_args("PLGraphicsIn::button",1,1)
3397  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::button",1,"PLGraphicsIn *");
3398 
3399  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3400  SWIG_fail_ptr("PLGraphicsIn_button_get",1,SWIGTYPE_p_PLGraphicsIn);
3401  }
3402 
3403  result = (unsigned int) ((arg1)->button);
3404  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3405  return SWIG_arg;
3406 
3407  if(0) SWIG_fail;
3408 
3409 fail:
3410  lua_error(L);
3411  return SWIG_arg;
3412 }
3413 
3414 
3415 static int _wrap_PLGraphicsIn_subwindow_set(lua_State* L) {
3416  int SWIG_arg = 0;
3417  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3418  PLINT arg2 ;
3419 
3420  SWIG_check_num_args("PLGraphicsIn::subwindow",2,2)
3421  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::subwindow",1,"PLGraphicsIn *");
3422  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::subwindow",2,"PLINT");
3423 
3424  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3425  SWIG_fail_ptr("PLGraphicsIn_subwindow_set",1,SWIGTYPE_p_PLGraphicsIn);
3426  }
3427 
3428  arg2 = (PLINT)lua_tonumber(L, 2);
3429  if (arg1) (arg1)->subwindow = arg2;
3430 
3431  return SWIG_arg;
3432 
3433  if(0) SWIG_fail;
3434 
3435 fail:
3436  lua_error(L);
3437  return SWIG_arg;
3438 }
3439 
3440 
3441 static int _wrap_PLGraphicsIn_subwindow_get(lua_State* L) {
3442  int SWIG_arg = 0;
3443  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3444  PLINT result;
3445 
3446  SWIG_check_num_args("PLGraphicsIn::subwindow",1,1)
3447  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::subwindow",1,"PLGraphicsIn *");
3448 
3449  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3450  SWIG_fail_ptr("PLGraphicsIn_subwindow_get",1,SWIGTYPE_p_PLGraphicsIn);
3451  }
3452 
3453  result = (PLINT) ((arg1)->subwindow);
3454  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3455  return SWIG_arg;
3456 
3457  if(0) SWIG_fail;
3458 
3459 fail:
3460  lua_error(L);
3461  return SWIG_arg;
3462 }
3463 
3464 
3465 static int _wrap_PLGraphicsIn_string_set(lua_State* L) {
3466  int SWIG_arg = 0;
3467  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3468  char *arg2 ;
3469 
3470  SWIG_check_num_args("PLGraphicsIn::string",2,2)
3471  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::string",1,"PLGraphicsIn *");
3472  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("PLGraphicsIn::string",2,"char [16]");
3473 
3474  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3475  SWIG_fail_ptr("PLGraphicsIn_string_set",1,SWIGTYPE_p_PLGraphicsIn);
3476  }
3477 
3478  arg2 = (char *)lua_tostring(L, 2);
3479  {
3480  if(arg2) {
3481  strncpy((char*)arg1->string, (const char *)arg2, 16-1);
3482  arg1->string[16-1] = 0;
3483  } else {
3484  arg1->string[0] = 0;
3485  }
3486  }
3487 
3488  return SWIG_arg;
3489 
3490  if(0) SWIG_fail;
3491 
3492 fail:
3493  lua_error(L);
3494  return SWIG_arg;
3495 }
3496 
3497 
3498 static int _wrap_PLGraphicsIn_string_get(lua_State* L) {
3499  int SWIG_arg = 0;
3500  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3501  char *result = 0 ;
3502 
3503  SWIG_check_num_args("PLGraphicsIn::string",1,1)
3504  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::string",1,"PLGraphicsIn *");
3505 
3506  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3507  SWIG_fail_ptr("PLGraphicsIn_string_get",1,SWIGTYPE_p_PLGraphicsIn);
3508  }
3509 
3510  result = (char *)(char *) ((arg1)->string);
3511  lua_pushstring(L,(const char *)result); SWIG_arg++;
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_PLGraphicsIn_pX_set(lua_State* L) {
3523  int SWIG_arg = 0;
3524  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3525  int arg2 ;
3526 
3527  SWIG_check_num_args("PLGraphicsIn::pX",2,2)
3528  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pX",1,"PLGraphicsIn *");
3529  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::pX",2,"int");
3530 
3531  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3532  SWIG_fail_ptr("PLGraphicsIn_pX_set",1,SWIGTYPE_p_PLGraphicsIn);
3533  }
3534 
3535  arg2 = (int)lua_tonumber(L, 2);
3536  if (arg1) (arg1)->pX = arg2;
3537 
3538  return SWIG_arg;
3539 
3540  if(0) SWIG_fail;
3541 
3542 fail:
3543  lua_error(L);
3544  return SWIG_arg;
3545 }
3546 
3547 
3548 static int _wrap_PLGraphicsIn_pX_get(lua_State* L) {
3549  int SWIG_arg = 0;
3550  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3551  int result;
3552 
3553  SWIG_check_num_args("PLGraphicsIn::pX",1,1)
3554  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pX",1,"PLGraphicsIn *");
3555 
3556  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3557  SWIG_fail_ptr("PLGraphicsIn_pX_get",1,SWIGTYPE_p_PLGraphicsIn);
3558  }
3559 
3560  result = (int) ((arg1)->pX);
3561  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3562  return SWIG_arg;
3563 
3564  if(0) SWIG_fail;
3565 
3566 fail:
3567  lua_error(L);
3568  return SWIG_arg;
3569 }
3570 
3571 
3572 static int _wrap_PLGraphicsIn_pY_set(lua_State* L) {
3573  int SWIG_arg = 0;
3574  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3575  int arg2 ;
3576 
3577  SWIG_check_num_args("PLGraphicsIn::pY",2,2)
3578  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pY",1,"PLGraphicsIn *");
3579  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::pY",2,"int");
3580 
3581  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3582  SWIG_fail_ptr("PLGraphicsIn_pY_set",1,SWIGTYPE_p_PLGraphicsIn);
3583  }
3584 
3585  arg2 = (int)lua_tonumber(L, 2);
3586  if (arg1) (arg1)->pY = arg2;
3587 
3588  return SWIG_arg;
3589 
3590  if(0) SWIG_fail;
3591 
3592 fail:
3593  lua_error(L);
3594  return SWIG_arg;
3595 }
3596 
3597 
3598 static int _wrap_PLGraphicsIn_pY_get(lua_State* L) {
3599  int SWIG_arg = 0;
3600  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3601  int result;
3602 
3603  SWIG_check_num_args("PLGraphicsIn::pY",1,1)
3604  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::pY",1,"PLGraphicsIn *");
3605 
3606  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3607  SWIG_fail_ptr("PLGraphicsIn_pY_get",1,SWIGTYPE_p_PLGraphicsIn);
3608  }
3609 
3610  result = (int) ((arg1)->pY);
3611  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3612  return SWIG_arg;
3613 
3614  if(0) SWIG_fail;
3615 
3616 fail:
3617  lua_error(L);
3618  return SWIG_arg;
3619 }
3620 
3621 
3622 static int _wrap_PLGraphicsIn_dX_set(lua_State* L) {
3623  int SWIG_arg = 0;
3624  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3625  PLFLT arg2 ;
3626 
3627  SWIG_check_num_args("PLGraphicsIn::dX",2,2)
3628  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dX",1,"PLGraphicsIn *");
3629  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::dX",2,"PLFLT");
3630 
3631  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3632  SWIG_fail_ptr("PLGraphicsIn_dX_set",1,SWIGTYPE_p_PLGraphicsIn);
3633  }
3634 
3635  arg2 = (PLFLT)lua_tonumber(L, 2);
3636  if (arg1) (arg1)->dX = arg2;
3637 
3638  return SWIG_arg;
3639 
3640  if(0) SWIG_fail;
3641 
3642 fail:
3643  lua_error(L);
3644  return SWIG_arg;
3645 }
3646 
3647 
3648 static int _wrap_PLGraphicsIn_dX_get(lua_State* L) {
3649  int SWIG_arg = 0;
3650  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3651  PLFLT result;
3652 
3653  SWIG_check_num_args("PLGraphicsIn::dX",1,1)
3654  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dX",1,"PLGraphicsIn *");
3655 
3656  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3657  SWIG_fail_ptr("PLGraphicsIn_dX_get",1,SWIGTYPE_p_PLGraphicsIn);
3658  }
3659 
3660  result = (PLFLT) ((arg1)->dX);
3661  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3662  return SWIG_arg;
3663 
3664  if(0) SWIG_fail;
3665 
3666 fail:
3667  lua_error(L);
3668  return SWIG_arg;
3669 }
3670 
3671 
3672 static int _wrap_PLGraphicsIn_dY_set(lua_State* L) {
3673  int SWIG_arg = 0;
3674  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3675  PLFLT arg2 ;
3676 
3677  SWIG_check_num_args("PLGraphicsIn::dY",2,2)
3678  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dY",1,"PLGraphicsIn *");
3679  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::dY",2,"PLFLT");
3680 
3681  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3682  SWIG_fail_ptr("PLGraphicsIn_dY_set",1,SWIGTYPE_p_PLGraphicsIn);
3683  }
3684 
3685  arg2 = (PLFLT)lua_tonumber(L, 2);
3686  if (arg1) (arg1)->dY = arg2;
3687 
3688  return SWIG_arg;
3689 
3690  if(0) SWIG_fail;
3691 
3692 fail:
3693  lua_error(L);
3694  return SWIG_arg;
3695 }
3696 
3697 
3698 static int _wrap_PLGraphicsIn_dY_get(lua_State* L) {
3699  int SWIG_arg = 0;
3700  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3701  PLFLT result;
3702 
3703  SWIG_check_num_args("PLGraphicsIn::dY",1,1)
3704  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::dY",1,"PLGraphicsIn *");
3705 
3706  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3707  SWIG_fail_ptr("PLGraphicsIn_dY_get",1,SWIGTYPE_p_PLGraphicsIn);
3708  }
3709 
3710  result = (PLFLT) ((arg1)->dY);
3711  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3712  return SWIG_arg;
3713 
3714  if(0) SWIG_fail;
3715 
3716 fail:
3717  lua_error(L);
3718  return SWIG_arg;
3719 }
3720 
3721 
3722 static int _wrap_PLGraphicsIn_wX_set(lua_State* L) {
3723  int SWIG_arg = 0;
3724  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3725  PLFLT arg2 ;
3726 
3727  SWIG_check_num_args("PLGraphicsIn::wX",2,2)
3728  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wX",1,"PLGraphicsIn *");
3729  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::wX",2,"PLFLT");
3730 
3731  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3732  SWIG_fail_ptr("PLGraphicsIn_wX_set",1,SWIGTYPE_p_PLGraphicsIn);
3733  }
3734 
3735  arg2 = (PLFLT)lua_tonumber(L, 2);
3736  if (arg1) (arg1)->wX = arg2;
3737 
3738  return SWIG_arg;
3739 
3740  if(0) SWIG_fail;
3741 
3742 fail:
3743  lua_error(L);
3744  return SWIG_arg;
3745 }
3746 
3747 
3748 static int _wrap_PLGraphicsIn_wX_get(lua_State* L) {
3749  int SWIG_arg = 0;
3750  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3751  PLFLT result;
3752 
3753  SWIG_check_num_args("PLGraphicsIn::wX",1,1)
3754  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wX",1,"PLGraphicsIn *");
3755 
3756  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3757  SWIG_fail_ptr("PLGraphicsIn_wX_get",1,SWIGTYPE_p_PLGraphicsIn);
3758  }
3759 
3760  result = (PLFLT) ((arg1)->wX);
3761  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3762  return SWIG_arg;
3763 
3764  if(0) SWIG_fail;
3765 
3766 fail:
3767  lua_error(L);
3768  return SWIG_arg;
3769 }
3770 
3771 
3772 static int _wrap_PLGraphicsIn_wY_set(lua_State* L) {
3773  int SWIG_arg = 0;
3774  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3775  PLFLT arg2 ;
3776 
3777  SWIG_check_num_args("PLGraphicsIn::wY",2,2)
3778  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wY",1,"PLGraphicsIn *");
3779  if(!lua_isnumber(L,2)) SWIG_fail_arg("PLGraphicsIn::wY",2,"PLFLT");
3780 
3781  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3782  SWIG_fail_ptr("PLGraphicsIn_wY_set",1,SWIGTYPE_p_PLGraphicsIn);
3783  }
3784 
3785  arg2 = (PLFLT)lua_tonumber(L, 2);
3786  if (arg1) (arg1)->wY = arg2;
3787 
3788  return SWIG_arg;
3789 
3790  if(0) SWIG_fail;
3791 
3792 fail:
3793  lua_error(L);
3794  return SWIG_arg;
3795 }
3796 
3797 
3798 static int _wrap_PLGraphicsIn_wY_get(lua_State* L) {
3799  int SWIG_arg = 0;
3800  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
3801  PLFLT result;
3802 
3803  SWIG_check_num_args("PLGraphicsIn::wY",1,1)
3804  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("PLGraphicsIn::wY",1,"PLGraphicsIn *");
3805 
3806  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
3807  SWIG_fail_ptr("PLGraphicsIn_wY_get",1,SWIGTYPE_p_PLGraphicsIn);
3808  }
3809 
3810  result = (PLFLT) ((arg1)->wY);
3811  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
3812  return SWIG_arg;
3813 
3814  if(0) SWIG_fail;
3815 
3816 fail:
3817  lua_error(L);
3818  return SWIG_arg;
3819 }
3820 
3821 
3822 static int _wrap_new_PLGraphicsIn(lua_State* L) {
3823  int SWIG_arg = 0;
3824  PLGraphicsIn *result = 0 ;
3825 
3826  SWIG_check_num_args("PLGraphicsIn::PLGraphicsIn",0,0)
3827  result = (PLGraphicsIn *)calloc(1, sizeof(PLGraphicsIn));
3828  SWIG_NewPointerObj(L,result,SWIGTYPE_p_PLGraphicsIn,1); SWIG_arg++;
3829  return SWIG_arg;
3830 
3831  if(0) SWIG_fail;
3832 
3833 fail:
3834  lua_error(L);
3835  return SWIG_arg;
3836 }
3837 
3838 
3839 static void swig_delete_PLGraphicsIn(void *obj) {
3840 PLGraphicsIn *arg1 = (PLGraphicsIn *) obj;
3841 free((char *) arg1);
3842 }
3843 static int _proxy__wrap_new_PLGraphicsIn(lua_State *L) {
3844  assert(lua_istable(L,1));
3845  lua_pushcfunction(L,_wrap_new_PLGraphicsIn);
3846  assert(!lua_isnil(L,-1));
3847  lua_replace(L,1); /* replace our table with real constructor */
3848  lua_call(L,lua_gettop(L)-1,1);
3849  return 1;
3850 }
3864  {0,0,0}
3865 };
3867  {0,0}
3868 };
3870  {0,0}
3871 };
3872 
3874  {0,0,0}
3875 };
3877  {0,0,0,0,0,0}
3878 };
3880  {0,0}
3881 };
3883  0
3884 };
3885 
3887  "PLGraphicsIn",
3892  0
3893 };
3895 static const char *swig_PLGraphicsIn_base_names[] = {0};
3897 
3898 static int _wrap_setcontlabelformat(lua_State* L) {
3899  int SWIG_arg = 0;
3900  PLINT arg1 ;
3901  PLINT arg2 ;
3902 
3903  SWIG_check_num_args("pl_setcontlabelformat",2,2)
3904  if(!lua_isnumber(L,1)) SWIG_fail_arg("pl_setcontlabelformat",1,"PLINT");
3905  if(!lua_isnumber(L,2)) SWIG_fail_arg("pl_setcontlabelformat",2,"PLINT");
3906  arg1 = (PLINT)lua_tonumber(L, 1);
3907  arg2 = (PLINT)lua_tonumber(L, 2);
3908  pl_setcontlabelformat(arg1,arg2);
3909 
3910  return SWIG_arg;
3911 
3912  if(0) SWIG_fail;
3913 
3914 fail:
3915  lua_error(L);
3916  return SWIG_arg;
3917 }
3918 
3919 
3920 static int _wrap_setcontlabelparam(lua_State* L) {
3921  int SWIG_arg = 0;
3922  PLFLT arg1 ;
3923  PLFLT arg2 ;
3924  PLFLT arg3 ;
3925  PLINT arg4 ;
3926 
3927  SWIG_check_num_args("pl_setcontlabelparam",4,4)
3928  if(!lua_isnumber(L,1)) SWIG_fail_arg("pl_setcontlabelparam",1,"PLFLT");
3929  if(!lua_isnumber(L,2)) SWIG_fail_arg("pl_setcontlabelparam",2,"PLFLT");
3930  if(!lua_isnumber(L,3)) SWIG_fail_arg("pl_setcontlabelparam",3,"PLFLT");
3931  if(!lua_isnumber(L,4)) SWIG_fail_arg("pl_setcontlabelparam",4,"PLINT");
3932  arg1 = (PLFLT)lua_tonumber(L, 1);
3933  arg2 = (PLFLT)lua_tonumber(L, 2);
3934  arg3 = (PLFLT)lua_tonumber(L, 3);
3935  arg4 = (PLINT)lua_tonumber(L, 4);
3936  pl_setcontlabelparam(arg1,arg2,arg3,arg4);
3937 
3938  return SWIG_arg;
3939 
3940  if(0) SWIG_fail;
3941 
3942 fail:
3943  lua_error(L);
3944  return SWIG_arg;
3945 }
3946 
3947 
3948 static int _wrap_adv(lua_State* L) {
3949  int SWIG_arg = 0;
3950  PLINT arg1 ;
3951 
3952  SWIG_check_num_args("pladv",1,1)
3953  if(!lua_isnumber(L,1)) SWIG_fail_arg("pladv",1,"PLINT");
3954  arg1 = (PLINT)lua_tonumber(L, 1);
3955  pladv(arg1);
3956 
3957  return SWIG_arg;
3958 
3959  if(0) SWIG_fail;
3960 
3961 fail:
3962  lua_error(L);
3963  return SWIG_arg;
3964 }
3965 
3966 
3967 static int _wrap_arc(lua_State* L) {
3968  int SWIG_arg = 0;
3969  PLFLT arg1 ;
3970  PLFLT arg2 ;
3971  PLFLT arg3 ;
3972  PLFLT arg4 ;
3973  PLFLT arg5 ;
3974  PLFLT arg6 ;
3975  PLFLT arg7 ;
3976  PLBOOL arg8 ;
3977 
3978  SWIG_check_num_args("plarc",8,8)
3979  if(!lua_isnumber(L,1)) SWIG_fail_arg("plarc",1,"PLFLT");
3980  if(!lua_isnumber(L,2)) SWIG_fail_arg("plarc",2,"PLFLT");
3981  if(!lua_isnumber(L,3)) SWIG_fail_arg("plarc",3,"PLFLT");
3982  if(!lua_isnumber(L,4)) SWIG_fail_arg("plarc",4,"PLFLT");
3983  if(!lua_isnumber(L,5)) SWIG_fail_arg("plarc",5,"PLFLT");
3984  if(!lua_isnumber(L,6)) SWIG_fail_arg("plarc",6,"PLFLT");
3985  if(!lua_isnumber(L,7)) SWIG_fail_arg("plarc",7,"PLFLT");
3986  if(!lua_isnumber(L,8)) SWIG_fail_arg("plarc",8,"PLBOOL");
3987  arg1 = (PLFLT)lua_tonumber(L, 1);
3988  arg2 = (PLFLT)lua_tonumber(L, 2);
3989  arg3 = (PLFLT)lua_tonumber(L, 3);
3990  arg4 = (PLFLT)lua_tonumber(L, 4);
3991  arg5 = (PLFLT)lua_tonumber(L, 5);
3992  arg6 = (PLFLT)lua_tonumber(L, 6);
3993  arg7 = (PLFLT)lua_tonumber(L, 7);
3994  arg8 = (PLBOOL)lua_tonumber(L, 8);
3995  plarc(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
3996 
3997  return SWIG_arg;
3998 
3999  if(0) SWIG_fail;
4000 
4001 fail:
4002  lua_error(L);
4003  return SWIG_arg;
4004 }
4005 
4006 
4007 static int _wrap_axes(lua_State* L) {
4008  int SWIG_arg = 0;
4009  PLFLT arg1 ;
4010  PLFLT arg2 ;
4011  char *arg3 = (char *) 0 ;
4012  PLFLT arg4 ;
4013  PLINT arg5 ;
4014  char *arg6 = (char *) 0 ;
4015  PLFLT arg7 ;
4016  PLINT arg8 ;
4017 
4018  SWIG_check_num_args("plaxes",8,8)
4019  if(!lua_isnumber(L,1)) SWIG_fail_arg("plaxes",1,"PLFLT");
4020  if(!lua_isnumber(L,2)) SWIG_fail_arg("plaxes",2,"PLFLT");
4021  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("plaxes",3,"char const *");
4022  if(!lua_isnumber(L,4)) SWIG_fail_arg("plaxes",4,"PLFLT");
4023  if(!lua_isnumber(L,5)) SWIG_fail_arg("plaxes",5,"PLINT");
4024  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plaxes",6,"char const *");
4025  if(!lua_isnumber(L,7)) SWIG_fail_arg("plaxes",7,"PLFLT");
4026  if(!lua_isnumber(L,8)) SWIG_fail_arg("plaxes",8,"PLINT");
4027  arg1 = (PLFLT)lua_tonumber(L, 1);
4028  arg2 = (PLFLT)lua_tonumber(L, 2);
4029  arg3 = (char *)lua_tostring(L, 3);
4030  arg4 = (PLFLT)lua_tonumber(L, 4);
4031  arg5 = (PLINT)lua_tonumber(L, 5);
4032  arg6 = (char *)lua_tostring(L, 6);
4033  arg7 = (PLFLT)lua_tonumber(L, 7);
4034  arg8 = (PLINT)lua_tonumber(L, 8);
4035  plaxes(arg1,arg2,(char const *)arg3,arg4,arg5,(char const *)arg6,arg7,arg8);
4036 
4037  return SWIG_arg;
4038 
4039  if(0) SWIG_fail;
4040 
4041 fail:
4042  lua_error(L);
4043  return SWIG_arg;
4044 }
4045 
4046 
4047 static int _wrap_bin(lua_State* L) {
4048  int SWIG_arg = 0;
4049  PLINT arg1 ;
4050  PLFLT *arg2 = (PLFLT *) 0 ;
4051  PLFLT *arg3 = (PLFLT *) 0 ;
4052  PLINT arg4 ;
4053  int temp3 ;
4054 
4055  SWIG_check_num_args("plbin",3,3)
4056  if(!lua_isnumber(L,3)) SWIG_fail_arg("plbin",3,"PLINT");
4057  {
4058  int temp;
4059  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4060  if ( !arg2 )
4061  SWIG_fail;
4062  arg1 = Alen = temp;
4063  }
4064  {
4065  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4066  if ( !arg3 )
4067  SWIG_fail;
4068  if ( temp3 != Alen )
4069  {
4070  lua_pushfstring( L, "Tables must be of same length." );
4071  SWIG_fail;
4072  }
4073  }
4074  arg4 = (PLINT)lua_tonumber(L, 3);
4075  plbin(arg1,(double const *)arg2,(double const *)arg3,arg4);
4076 
4077  {
4078  LUA_FREE_ARRAY( arg2 );
4079  }
4080  {
4081  LUA_FREE_ARRAY( arg3 );
4082  }
4083  return SWIG_arg;
4084 
4085  if(0) SWIG_fail;
4086 
4087 fail:
4088  {
4089  LUA_FREE_ARRAY( arg2 );
4090  }
4091  {
4092  LUA_FREE_ARRAY( arg3 );
4093  }
4094  lua_error(L);
4095  return SWIG_arg;
4096 }
4097 
4098 
4099 static int _wrap_btime(lua_State* L) {
4100  int SWIG_arg = 0;
4101  PLINT *arg1 = (PLINT *) 0 ;
4102  PLINT *arg2 = (PLINT *) 0 ;
4103  PLINT *arg3 = (PLINT *) 0 ;
4104  PLINT *arg4 = (PLINT *) 0 ;
4105  PLINT *arg5 = (PLINT *) 0 ;
4106  PLFLT *arg6 = (PLFLT *) 0 ;
4107  PLFLT arg7 ;
4108  PLINT temp1 ;
4109  PLINT temp2 ;
4110  PLINT temp3 ;
4111  PLINT temp4 ;
4112  PLINT temp5 ;
4113  PLFLT temp6 ;
4114 
4115  arg1 = &temp1;
4116  arg2 = &temp2;
4117  arg3 = &temp3;
4118  arg4 = &temp4;
4119  arg5 = &temp5;
4120  arg6 = &temp6;
4121  SWIG_check_num_args("plbtime",1,1)
4122  if(!lua_isnumber(L,1)) SWIG_fail_arg("plbtime",1,"PLFLT");
4123  arg7 = (PLFLT)lua_tonumber(L, 1);
4124  plbtime(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
4125 
4126  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
4127  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
4128  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4129  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4130  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
4131  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
4132  return SWIG_arg;
4133 
4134  if(0) SWIG_fail;
4135 
4136 fail:
4137  lua_error(L);
4138  return SWIG_arg;
4139 }
4140 
4141 
4142 static int _wrap_bop(lua_State* L) {
4143  int SWIG_arg = 0;
4144 
4145  SWIG_check_num_args("plbop",0,0)
4146  plbop();
4147 
4148  return SWIG_arg;
4149 
4150  if(0) SWIG_fail;
4151 
4152 fail:
4153  lua_error(L);
4154  return SWIG_arg;
4155 }
4156 
4157 
4158 static int _wrap_box(lua_State* L) {
4159  int SWIG_arg = 0;
4160  char *arg1 = (char *) 0 ;
4161  PLFLT arg2 ;
4162  PLINT arg3 ;
4163  char *arg4 = (char *) 0 ;
4164  PLFLT arg5 ;
4165  PLINT arg6 ;
4166 
4167  SWIG_check_num_args("plbox",6,6)
4168  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plbox",1,"char const *");
4169  if(!lua_isnumber(L,2)) SWIG_fail_arg("plbox",2,"PLFLT");
4170  if(!lua_isnumber(L,3)) SWIG_fail_arg("plbox",3,"PLINT");
4171  if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("plbox",4,"char const *");
4172  if(!lua_isnumber(L,5)) SWIG_fail_arg("plbox",5,"PLFLT");
4173  if(!lua_isnumber(L,6)) SWIG_fail_arg("plbox",6,"PLINT");
4174  arg1 = (char *)lua_tostring(L, 1);
4175  arg2 = (PLFLT)lua_tonumber(L, 2);
4176  arg3 = (PLINT)lua_tonumber(L, 3);
4177  arg4 = (char *)lua_tostring(L, 4);
4178  arg5 = (PLFLT)lua_tonumber(L, 5);
4179  arg6 = (PLINT)lua_tonumber(L, 6);
4180  plbox((char const *)arg1,arg2,arg3,(char const *)arg4,arg5,arg6);
4181 
4182  return SWIG_arg;
4183 
4184  if(0) SWIG_fail;
4185 
4186 fail:
4187  lua_error(L);
4188  return SWIG_arg;
4189 }
4190 
4191 
4192 static int _wrap_box3(lua_State* L) {
4193  int SWIG_arg = 0;
4194  char *arg1 = (char *) 0 ;
4195  char *arg2 = (char *) 0 ;
4196  PLFLT arg3 ;
4197  PLINT arg4 ;
4198  char *arg5 = (char *) 0 ;
4199  char *arg6 = (char *) 0 ;
4200  PLFLT arg7 ;
4201  PLINT arg8 ;
4202  char *arg9 = (char *) 0 ;
4203  char *arg10 = (char *) 0 ;
4204  PLFLT arg11 ;
4205  PLINT arg12 ;
4206 
4207  SWIG_check_num_args("plbox3",12,12)
4208  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plbox3",1,"char const *");
4209  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plbox3",2,"char const *");
4210  if(!lua_isnumber(L,3)) SWIG_fail_arg("plbox3",3,"PLFLT");
4211  if(!lua_isnumber(L,4)) SWIG_fail_arg("plbox3",4,"PLINT");
4212  if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("plbox3",5,"char const *");
4213  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plbox3",6,"char const *");
4214  if(!lua_isnumber(L,7)) SWIG_fail_arg("plbox3",7,"PLFLT");
4215  if(!lua_isnumber(L,8)) SWIG_fail_arg("plbox3",8,"PLINT");
4216  if(!SWIG_lua_isnilstring(L,9)) SWIG_fail_arg("plbox3",9,"char const *");
4217  if(!SWIG_lua_isnilstring(L,10)) SWIG_fail_arg("plbox3",10,"char const *");
4218  if(!lua_isnumber(L,11)) SWIG_fail_arg("plbox3",11,"PLFLT");
4219  if(!lua_isnumber(L,12)) SWIG_fail_arg("plbox3",12,"PLINT");
4220  arg1 = (char *)lua_tostring(L, 1);
4221  arg2 = (char *)lua_tostring(L, 2);
4222  arg3 = (PLFLT)lua_tonumber(L, 3);
4223  arg4 = (PLINT)lua_tonumber(L, 4);
4224  arg5 = (char *)lua_tostring(L, 5);
4225  arg6 = (char *)lua_tostring(L, 6);
4226  arg7 = (PLFLT)lua_tonumber(L, 7);
4227  arg8 = (PLINT)lua_tonumber(L, 8);
4228  arg9 = (char *)lua_tostring(L, 9);
4229  arg10 = (char *)lua_tostring(L, 10);
4230  arg11 = (PLFLT)lua_tonumber(L, 11);
4231  arg12 = (PLINT)lua_tonumber(L, 12);
4232  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);
4233 
4234  return SWIG_arg;
4235 
4236  if(0) SWIG_fail;
4237 
4238 fail:
4239  lua_error(L);
4240  return SWIG_arg;
4241 }
4242 
4243 
4244 static int _wrap_calc_world(lua_State* L) {
4245  int SWIG_arg = 0;
4246  PLFLT arg1 ;
4247  PLFLT arg2 ;
4248  PLFLT *arg3 = (PLFLT *) 0 ;
4249  PLFLT *arg4 = (PLFLT *) 0 ;
4250  PLINT *arg5 = (PLINT *) 0 ;
4251  PLFLT temp3 ;
4252  PLFLT temp4 ;
4253  PLINT temp5 ;
4254 
4255  arg3 = &temp3;
4256  arg4 = &temp4;
4257  arg5 = &temp5;
4258  SWIG_check_num_args("plcalc_world",2,2)
4259  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcalc_world",1,"PLFLT");
4260  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcalc_world",2,"PLFLT");
4261  arg1 = (PLFLT)lua_tonumber(L, 1);
4262  arg2 = (PLFLT)lua_tonumber(L, 2);
4263  plcalc_world(arg1,arg2,arg3,arg4,arg5);
4264 
4265  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
4266  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
4267  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
4268  return SWIG_arg;
4269 
4270  if(0) SWIG_fail;
4271 
4272 fail:
4273  lua_error(L);
4274  return SWIG_arg;
4275 }
4276 
4277 
4278 static int _wrap_clear(lua_State* L) {
4279  int SWIG_arg = 0;
4280 
4281  SWIG_check_num_args("plclear",0,0)
4282  plclear();
4283 
4284  return SWIG_arg;
4285 
4286  if(0) SWIG_fail;
4287 
4288 fail:
4289  lua_error(L);
4290  return SWIG_arg;
4291 }
4292 
4293 
4294 static int _wrap_col0(lua_State* L) {
4295  int SWIG_arg = 0;
4296  PLINT arg1 ;
4297 
4298  SWIG_check_num_args("plcol0",1,1)
4299  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcol0",1,"PLINT");
4300  arg1 = (PLINT)lua_tonumber(L, 1);
4301  plcol0(arg1);
4302 
4303  return SWIG_arg;
4304 
4305  if(0) SWIG_fail;
4306 
4307 fail:
4308  lua_error(L);
4309  return SWIG_arg;
4310 }
4311 
4312 
4313 static int _wrap_col1(lua_State* L) {
4314  int SWIG_arg = 0;
4315  PLFLT arg1 ;
4316 
4317  SWIG_check_num_args("plcol1",1,1)
4318  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcol1",1,"PLFLT");
4319  arg1 = (PLFLT)lua_tonumber(L, 1);
4320  plcol1(arg1);
4321 
4322  return SWIG_arg;
4323 
4324  if(0) SWIG_fail;
4325 
4326 fail:
4327  lua_error(L);
4328  return SWIG_arg;
4329 }
4330 
4331 
4332 static int _wrap_configtime(lua_State* L) {
4333  int SWIG_arg = 0;
4334  PLFLT arg1 ;
4335  PLFLT arg2 ;
4336  PLFLT arg3 ;
4337  PLINT arg4 ;
4338  PLBOOL arg5 ;
4339  PLINT arg6 ;
4340  PLINT arg7 ;
4341  PLINT arg8 ;
4342  PLINT arg9 ;
4343  PLINT arg10 ;
4344  PLFLT arg11 ;
4345 
4346  SWIG_check_num_args("plconfigtime",11,11)
4347  if(!lua_isnumber(L,1)) SWIG_fail_arg("plconfigtime",1,"PLFLT");
4348  if(!lua_isnumber(L,2)) SWIG_fail_arg("plconfigtime",2,"PLFLT");
4349  if(!lua_isnumber(L,3)) SWIG_fail_arg("plconfigtime",3,"PLFLT");
4350  if(!lua_isnumber(L,4)) SWIG_fail_arg("plconfigtime",4,"PLINT");
4351  if(!lua_isnumber(L,5)) SWIG_fail_arg("plconfigtime",5,"PLBOOL");
4352  if(!lua_isnumber(L,6)) SWIG_fail_arg("plconfigtime",6,"PLINT");
4353  if(!lua_isnumber(L,7)) SWIG_fail_arg("plconfigtime",7,"PLINT");
4354  if(!lua_isnumber(L,8)) SWIG_fail_arg("plconfigtime",8,"PLINT");
4355  if(!lua_isnumber(L,9)) SWIG_fail_arg("plconfigtime",9,"PLINT");
4356  if(!lua_isnumber(L,10)) SWIG_fail_arg("plconfigtime",10,"PLINT");
4357  if(!lua_isnumber(L,11)) SWIG_fail_arg("plconfigtime",11,"PLFLT");
4358  arg1 = (PLFLT)lua_tonumber(L, 1);
4359  arg2 = (PLFLT)lua_tonumber(L, 2);
4360  arg3 = (PLFLT)lua_tonumber(L, 3);
4361  arg4 = (PLINT)lua_tonumber(L, 4);
4362  arg5 = (PLBOOL)lua_tonumber(L, 5);
4363  arg6 = (PLINT)lua_tonumber(L, 6);
4364  arg7 = (PLINT)lua_tonumber(L, 7);
4365  arg8 = (PLINT)lua_tonumber(L, 8);
4366  arg9 = (PLINT)lua_tonumber(L, 9);
4367  arg10 = (PLINT)lua_tonumber(L, 10);
4368  arg11 = (PLFLT)lua_tonumber(L, 11);
4369  plconfigtime(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11);
4370 
4371  return SWIG_arg;
4372 
4373  if(0) SWIG_fail;
4374 
4375 fail:
4376  lua_error(L);
4377  return SWIG_arg;
4378 }
4379 
4380 
4381 static int _wrap_cont(lua_State* L) {
4382  int SWIG_arg = 0;
4383  PLFLT **arg1 = (PLFLT **) 0 ;
4384  PLINT arg2 ;
4385  PLINT arg3 ;
4386  PLINT arg4 ;
4387  PLINT arg5 ;
4388  PLINT arg6 ;
4389  PLINT arg7 ;
4390  PLFLT *arg8 = (PLFLT *) 0 ;
4391  PLINT arg9 ;
4392  pltr_func arg10 = (pltr_func) 0 ;
4393  PLPointer arg11 = (PLPointer) 0 ;
4394  int ii1 ;
4395  PLcGrid cgrid111 ;
4396  PLcGrid2 cgrid211 ;
4397 
4398  {
4399  cgrid111.xg = cgrid111.yg = cgrid111.zg = NULL;
4400  cgrid111.nx = cgrid111.ny = cgrid111.nz = 0;
4401  cgrid211.xg = cgrid211.yg = cgrid211.zg = NULL;
4402  cgrid211.nx = cgrid211.ny = 0;
4403  }
4404  {
4405  arg10 = NULL;
4406  }
4407  {
4408  arg11 = NULL;
4409  }
4410  SWIG_check_num_args("plcont",6,8)
4411  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcont",2,"PLINT");
4412  if(!lua_isnumber(L,3)) SWIG_fail_arg("plcont",3,"PLINT");
4413  if(!lua_isnumber(L,4)) SWIG_fail_arg("plcont",4,"PLINT");
4414  if(!lua_isnumber(L,5)) SWIG_fail_arg("plcont",5,"PLINT");
4415  {
4416  int jj;
4417 
4418  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
4419  if ( !arg1 )
4420  SWIG_fail;
4421  Xlen = arg2 = ii1;
4422  Ylen = arg3 = jj;
4423  }
4424  arg4 = (PLINT)lua_tonumber(L, 2);
4425  arg5 = (PLINT)lua_tonumber(L, 3);
4426  arg6 = (PLINT)lua_tonumber(L, 4);
4427  arg7 = (PLINT)lua_tonumber(L, 5);
4428  {
4429  int temp;
4430  arg8 = (PLFLT *) LUA_get_double_num_array_var( L, 6, &temp );
4431  if ( !arg8 )
4432  SWIG_fail;
4433  arg9 = Alen = temp;
4434  }
4435  if(lua_gettop(L)>=7){
4436  {
4437  arg10 = NULL;
4438  mypltr_funcstr[0] = '\0';
4439 
4440  if ( lua_isstring( L, 7 ) )
4441  {
4442  const char* funcstr = lua_tostring( L, 7 );
4443  if ( strcmp( "pltr0", funcstr ) == 0 )
4444  {
4445  arg10 = pltr0;
4446  }
4447  else if ( strcmp( "pltr1", funcstr ) == 0 )
4448  {
4449  arg10 = pltr1;
4450  }
4451  else if ( strcmp( "pltr2", funcstr ) == 0 )
4452  {
4453  arg10 = pltr2;
4454  }
4455  else
4456  {
4457  arg10 = mypltr;
4458  strncpy( mypltr_funcstr, funcstr, 255 );
4459  myL = L;
4460  }
4461  }
4462  else
4463  SWIG_fail_arg( "cont", 10, "pltr_func" );
4464  }
4465  }
4466  if(lua_gettop(L)>=8){
4467  {
4468  int nx, ny;
4469  int gridmode = 0;
4470 
4471  lua_pushstring( L, "xg" );
4472  lua_gettable( L, 8 );
4473  if ( !lua_istable( L, -1 ) )
4474  {
4475  lua_pop( L, 1 ); // pop "xg"
4476  lua_pushstring( L, "expected a table xg" );
4477  SWIG_fail;
4478  }
4479  lua_rawgeti( L, -1, 1 );
4480  if ( lua_istable( L, -1 ) )
4481  gridmode = 2; // two dimensional array
4482  else if ( lua_isnumber( L, -1 ) )
4483  gridmode = 1; // one dimensional array
4484  else
4485  {
4486  lua_pop( L, 1 ); // pop "1"
4487  lua_pop( L, 1 ); // pop "xg"
4488  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
4489  SWIG_fail;
4490  }
4491  lua_pop( L, 1 ); // pop test element
4492  if ( gridmode == 1 )
4493  {
4494  cgrid111.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
4495  if ( !cgrid111.xg )
4496  {
4497  lua_pop( L, 1 ); // pop "xg"
4498  SWIG_fail;
4499  }
4500  if ( nx != Xlen )
4501  {
4502  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
4503  SWIG_fail;
4504  }
4505  cgrid111.nx = nx;
4506  }
4507  else
4508  {
4509  cgrid211.xg = read_double_Matrix( L, -1, &nx, &ny );
4510  if ( !cgrid211.xg )
4511  {
4512  lua_pop( L, 1 ); // pop "xg"
4513  SWIG_fail;
4514  }
4515  if ( ( nx != Xlen ) || ( ny != Ylen ) )
4516  {
4517  lua_pop( L, 1 ); // pop "xg"
4518  lua_pushfstring( L, "Vectors must match matrix." );
4519  SWIG_fail;
4520  }
4521  cgrid211.nx = nx;
4522  cgrid211.ny = ny;
4523  }
4524  lua_pop( L, 1 ); // pop "xg"
4525 
4526  lua_pushstring( L, "yg" );
4527  lua_gettable( L, 8 );
4528  if ( !lua_istable( L, -1 ) )
4529  {
4530  lua_pop( L, 1 );
4531  lua_pushstring( L, "expected a table yg" );
4532  SWIG_fail;
4533  }
4534  lua_rawgeti( L, -1, 1 );
4535  if ( gridmode == 2 )
4536  {
4537  if ( !lua_istable( L, -1 ) )
4538  {
4539  lua_pop( L, 1 ); // pop "1"
4540  lua_pop( L, 1 ); // pop "yg"
4541  lua_pushstring( L, "expected a two dimensional array/table in yg" );
4542  SWIG_fail;
4543  }
4544  }
4545  else
4546  {
4547  if ( !lua_isnumber( L, -1 ) )
4548  {
4549  lua_pop( L, 1 ); // pop "1"
4550  lua_pop( L, 1 ); // pop "yg"
4551  lua_pushstring( L, "expected a one dimensional array/table in yg" );
4552  SWIG_fail;
4553  }
4554  }
4555  lua_pop( L, 1 ); // pop "1"
4556  if ( gridmode == 1 )
4557  {
4558  cgrid111.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
4559  if ( !cgrid111.yg )
4560  {
4561  lua_pop( L, 1 ); // pop "yg"
4562  SWIG_fail;
4563  }
4564  if ( ny != Ylen )
4565  {
4566  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
4567  SWIG_fail;
4568  }
4569  cgrid111.ny = ny;
4570  }
4571  else
4572  {
4573  cgrid211.yg = read_double_Matrix( L, -1, &nx, &ny );
4574  if ( !cgrid211.yg )
4575  {
4576  lua_pop( L, 1 ); // pop "xg"
4577  SWIG_fail;
4578  }
4579  if ( ( nx != Xlen ) || ( ny != Ylen ) )
4580  {
4581  lua_pop( L, 1 ); // pop "xg"
4582  lua_pushfstring( L, "Vectors must match matrix." );
4583  SWIG_fail;
4584  }
4585  // cgrid211.nx/ny already set
4586  }
4587  lua_pop( L, 1 ); // pop "yg"
4588 
4589  if ( gridmode == 1 )
4590  arg11 = &cgrid111;
4591  else if ( gridmode == 2 )
4592  arg11 = &cgrid211;
4593  }
4594  }
4595  plcont((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,(double const *)arg8,arg9,arg10,arg11);
4596 
4597  {
4598  int i;
4599 
4600  if ( arg1 )
4601  {
4602  for ( i = 0; i < ii1; i++ )
4603  LUA_FREE_ARRAY( arg1[i] );
4604  LUA_FREE_ARRAY( arg1 );
4605  }
4606  }
4607  {
4608  LUA_FREE_ARRAY( arg8 );
4609  }
4610  {
4611  mypltr_funcstr[0] = '\0';
4612  }
4613  {
4614  int i;
4615 
4616  LUA_FREE_ARRAY( cgrid111.xg );
4617  LUA_FREE_ARRAY( cgrid111.yg );
4618 
4619  if ( cgrid211.xg )
4620  {
4621  for ( i = 0; i < Xlen; i++ )
4622  LUA_FREE_ARRAY( cgrid211.xg[i] );
4623  LUA_FREE_ARRAY( cgrid211.xg );
4624  }
4625  if ( cgrid211.yg )
4626  {
4627  for ( i = 0; i < Xlen; i++ )
4628  LUA_FREE_ARRAY( cgrid211.yg[i] );
4629  LUA_FREE_ARRAY( cgrid211.yg );
4630  }
4631  }
4632  return SWIG_arg;
4633 
4634  if(0) SWIG_fail;
4635 
4636 fail:
4637  {
4638  int i;
4639 
4640  if ( arg1 )
4641  {
4642  for ( i = 0; i < ii1; i++ )
4643  LUA_FREE_ARRAY( arg1[i] );
4644  LUA_FREE_ARRAY( arg1 );
4645  }
4646  }
4647  {
4648  LUA_FREE_ARRAY( arg8 );
4649  }
4650  {
4651  mypltr_funcstr[0] = '\0';
4652  }
4653  {
4654  int i;
4655 
4656  LUA_FREE_ARRAY( cgrid111.xg );
4657  LUA_FREE_ARRAY( cgrid111.yg );
4658 
4659  if ( cgrid211.xg )
4660  {
4661  for ( i = 0; i < Xlen; i++ )
4662  LUA_FREE_ARRAY( cgrid211.xg[i] );
4663  LUA_FREE_ARRAY( cgrid211.xg );
4664  }
4665  if ( cgrid211.yg )
4666  {
4667  for ( i = 0; i < Xlen; i++ )
4668  LUA_FREE_ARRAY( cgrid211.yg[i] );
4669  LUA_FREE_ARRAY( cgrid211.yg );
4670  }
4671  }
4672  lua_error(L);
4673  return SWIG_arg;
4674 }
4675 
4676 
4677 static int _wrap_ctime(lua_State* L) {
4678  int SWIG_arg = 0;
4679  PLINT arg1 ;
4680  PLINT arg2 ;
4681  PLINT arg3 ;
4682  PLINT arg4 ;
4683  PLINT arg5 ;
4684  PLFLT arg6 ;
4685  PLFLT *arg7 = (PLFLT *) 0 ;
4686  PLFLT temp7 ;
4687 
4688  arg7 = &temp7;
4689  SWIG_check_num_args("plctime",6,6)
4690  if(!lua_isnumber(L,1)) SWIG_fail_arg("plctime",1,"PLINT");
4691  if(!lua_isnumber(L,2)) SWIG_fail_arg("plctime",2,"PLINT");
4692  if(!lua_isnumber(L,3)) SWIG_fail_arg("plctime",3,"PLINT");
4693  if(!lua_isnumber(L,4)) SWIG_fail_arg("plctime",4,"PLINT");
4694  if(!lua_isnumber(L,5)) SWIG_fail_arg("plctime",5,"PLINT");
4695  if(!lua_isnumber(L,6)) SWIG_fail_arg("plctime",6,"PLFLT");
4696  arg1 = (PLINT)lua_tonumber(L, 1);
4697  arg2 = (PLINT)lua_tonumber(L, 2);
4698  arg3 = (PLINT)lua_tonumber(L, 3);
4699  arg4 = (PLINT)lua_tonumber(L, 4);
4700  arg5 = (PLINT)lua_tonumber(L, 5);
4701  arg6 = (PLFLT)lua_tonumber(L, 6);
4702  plctime(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
4703 
4704  lua_pushnumber(L, (lua_Number) *arg7); SWIG_arg++;
4705  return SWIG_arg;
4706 
4707  if(0) SWIG_fail;
4708 
4709 fail:
4710  lua_error(L);
4711  return SWIG_arg;
4712 }
4713 
4714 
4715 static int _wrap_cpstrm(lua_State* L) {
4716  int SWIG_arg = 0;
4717  PLINT arg1 ;
4718  PLBOOL arg2 ;
4719 
4720  SWIG_check_num_args("plcpstrm",2,2)
4721  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcpstrm",1,"PLINT");
4722  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcpstrm",2,"PLBOOL");
4723  arg1 = (PLINT)lua_tonumber(L, 1);
4724  arg2 = (PLBOOL)lua_tonumber(L, 2);
4725  plcpstrm(arg1,arg2);
4726 
4727  return SWIG_arg;
4728 
4729  if(0) SWIG_fail;
4730 
4731 fail:
4732  lua_error(L);
4733  return SWIG_arg;
4734 }
4735 
4736 
4737 static int _wrap_plend(lua_State* L) {
4738  int SWIG_arg = 0;
4739 
4740  SWIG_check_num_args("plend",0,0)
4741  plend();
4742 
4743  return SWIG_arg;
4744 
4745  if(0) SWIG_fail;
4746 
4747 fail:
4748  lua_error(L);
4749  return SWIG_arg;
4750 }
4751 
4752 
4753 static int _wrap_plend1(lua_State* L) {
4754  int SWIG_arg = 0;
4755 
4756  SWIG_check_num_args("plend1",0,0)
4757  plend1();
4758 
4759  return SWIG_arg;
4760 
4761  if(0) SWIG_fail;
4762 
4763 fail:
4764  lua_error(L);
4765  return SWIG_arg;
4766 }
4767 
4768 
4769 static int _wrap_env(lua_State* L) {
4770  int SWIG_arg = 0;
4771  PLFLT arg1 ;
4772  PLFLT arg2 ;
4773  PLFLT arg3 ;
4774  PLFLT arg4 ;
4775  PLINT arg5 ;
4776  PLINT arg6 ;
4777 
4778  SWIG_check_num_args("plenv",6,6)
4779  if(!lua_isnumber(L,1)) SWIG_fail_arg("plenv",1,"PLFLT");
4780  if(!lua_isnumber(L,2)) SWIG_fail_arg("plenv",2,"PLFLT");
4781  if(!lua_isnumber(L,3)) SWIG_fail_arg("plenv",3,"PLFLT");
4782  if(!lua_isnumber(L,4)) SWIG_fail_arg("plenv",4,"PLFLT");
4783  if(!lua_isnumber(L,5)) SWIG_fail_arg("plenv",5,"PLINT");
4784  if(!lua_isnumber(L,6)) SWIG_fail_arg("plenv",6,"PLINT");
4785  arg1 = (PLFLT)lua_tonumber(L, 1);
4786  arg2 = (PLFLT)lua_tonumber(L, 2);
4787  arg3 = (PLFLT)lua_tonumber(L, 3);
4788  arg4 = (PLFLT)lua_tonumber(L, 4);
4789  arg5 = (PLINT)lua_tonumber(L, 5);
4790  arg6 = (PLINT)lua_tonumber(L, 6);
4791  plenv(arg1,arg2,arg3,arg4,arg5,arg6);
4792 
4793  return SWIG_arg;
4794 
4795  if(0) SWIG_fail;
4796 
4797 fail:
4798  lua_error(L);
4799  return SWIG_arg;
4800 }
4801 
4802 
4803 static int _wrap_env0(lua_State* L) {
4804  int SWIG_arg = 0;
4805  PLFLT arg1 ;
4806  PLFLT arg2 ;
4807  PLFLT arg3 ;
4808  PLFLT arg4 ;
4809  PLINT arg5 ;
4810  PLINT arg6 ;
4811 
4812  SWIG_check_num_args("plenv0",6,6)
4813  if(!lua_isnumber(L,1)) SWIG_fail_arg("plenv0",1,"PLFLT");
4814  if(!lua_isnumber(L,2)) SWIG_fail_arg("plenv0",2,"PLFLT");
4815  if(!lua_isnumber(L,3)) SWIG_fail_arg("plenv0",3,"PLFLT");
4816  if(!lua_isnumber(L,4)) SWIG_fail_arg("plenv0",4,"PLFLT");
4817  if(!lua_isnumber(L,5)) SWIG_fail_arg("plenv0",5,"PLINT");
4818  if(!lua_isnumber(L,6)) SWIG_fail_arg("plenv0",6,"PLINT");
4819  arg1 = (PLFLT)lua_tonumber(L, 1);
4820  arg2 = (PLFLT)lua_tonumber(L, 2);
4821  arg3 = (PLFLT)lua_tonumber(L, 3);
4822  arg4 = (PLFLT)lua_tonumber(L, 4);
4823  arg5 = (PLINT)lua_tonumber(L, 5);
4824  arg6 = (PLINT)lua_tonumber(L, 6);
4825  plenv0(arg1,arg2,arg3,arg4,arg5,arg6);
4826 
4827  return SWIG_arg;
4828 
4829  if(0) SWIG_fail;
4830 
4831 fail:
4832  lua_error(L);
4833  return SWIG_arg;
4834 }
4835 
4836 
4837 static int _wrap_eop(lua_State* L) {
4838  int SWIG_arg = 0;
4839 
4840  SWIG_check_num_args("pleop",0,0)
4841  pleop();
4842 
4843  return SWIG_arg;
4844 
4845  if(0) SWIG_fail;
4846 
4847 fail:
4848  lua_error(L);
4849  return SWIG_arg;
4850 }
4851 
4852 
4853 static int _wrap_errx(lua_State* L) {
4854  int SWIG_arg = 0;
4855  PLINT arg1 ;
4856  PLFLT *arg2 = (PLFLT *) 0 ;
4857  PLFLT *arg3 = (PLFLT *) 0 ;
4858  PLFLT *arg4 = (PLFLT *) 0 ;
4859  int temp3 ;
4860  int temp4 ;
4861 
4862  SWIG_check_num_args("plerrx",3,3)
4863  {
4864  int temp;
4865  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4866  if ( !arg2 )
4867  SWIG_fail;
4868  arg1 = Alen = temp;
4869  }
4870  {
4871  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4872  if ( !arg3 )
4873  SWIG_fail;
4874  if ( temp3 != Alen )
4875  {
4876  lua_pushfstring( L, "Tables must be of same length." );
4877  SWIG_fail;
4878  }
4879  }
4880  {
4881  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
4882  if ( !arg4 )
4883  SWIG_fail;
4884  if ( temp4 != Alen )
4885  {
4886  lua_pushfstring( L, "Tables must be of same length." );
4887  SWIG_fail;
4888  }
4889  }
4890  plerrx(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
4891 
4892  {
4893  LUA_FREE_ARRAY( arg2 );
4894  }
4895  {
4896  LUA_FREE_ARRAY( arg3 );
4897  }
4898  {
4899  LUA_FREE_ARRAY( arg4 );
4900  }
4901  return SWIG_arg;
4902 
4903  if(0) SWIG_fail;
4904 
4905 fail:
4906  {
4907  LUA_FREE_ARRAY( arg2 );
4908  }
4909  {
4910  LUA_FREE_ARRAY( arg3 );
4911  }
4912  {
4913  LUA_FREE_ARRAY( arg4 );
4914  }
4915  lua_error(L);
4916  return SWIG_arg;
4917 }
4918 
4919 
4920 static int _wrap_erry(lua_State* L) {
4921  int SWIG_arg = 0;
4922  PLINT arg1 ;
4923  PLFLT *arg2 = (PLFLT *) 0 ;
4924  PLFLT *arg3 = (PLFLT *) 0 ;
4925  PLFLT *arg4 = (PLFLT *) 0 ;
4926  int temp3 ;
4927  int temp4 ;
4928 
4929  SWIG_check_num_args("plerry",3,3)
4930  {
4931  int temp;
4932  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
4933  if ( !arg2 )
4934  SWIG_fail;
4935  arg1 = Alen = temp;
4936  }
4937  {
4938  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
4939  if ( !arg3 )
4940  SWIG_fail;
4941  if ( temp3 != Alen )
4942  {
4943  lua_pushfstring( L, "Tables must be of same length." );
4944  SWIG_fail;
4945  }
4946  }
4947  {
4948  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
4949  if ( !arg4 )
4950  SWIG_fail;
4951  if ( temp4 != Alen )
4952  {
4953  lua_pushfstring( L, "Tables must be of same length." );
4954  SWIG_fail;
4955  }
4956  }
4957  plerry(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
4958 
4959  {
4960  LUA_FREE_ARRAY( arg2 );
4961  }
4962  {
4963  LUA_FREE_ARRAY( arg3 );
4964  }
4965  {
4966  LUA_FREE_ARRAY( arg4 );
4967  }
4968  return SWIG_arg;
4969 
4970  if(0) SWIG_fail;
4971 
4972 fail:
4973  {
4974  LUA_FREE_ARRAY( arg2 );
4975  }
4976  {
4977  LUA_FREE_ARRAY( arg3 );
4978  }
4979  {
4980  LUA_FREE_ARRAY( arg4 );
4981  }
4982  lua_error(L);
4983  return SWIG_arg;
4984 }
4985 
4986 
4987 static int _wrap_famadv(lua_State* L) {
4988  int SWIG_arg = 0;
4989 
4990  SWIG_check_num_args("plfamadv",0,0)
4991  plfamadv();
4992 
4993  return SWIG_arg;
4994 
4995  if(0) SWIG_fail;
4996 
4997 fail:
4998  lua_error(L);
4999  return SWIG_arg;
5000 }
5001 
5002 
5003 static int _wrap_fill(lua_State* L) {
5004  int SWIG_arg = 0;
5005  PLINT arg1 ;
5006  PLFLT *arg2 = (PLFLT *) 0 ;
5007  PLFLT *arg3 = (PLFLT *) 0 ;
5008  int temp3 ;
5009 
5010  SWIG_check_num_args("plfill",2,2)
5011  {
5012  int temp;
5013  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
5014  if ( !arg2 )
5015  SWIG_fail;
5016  arg1 = Alen = temp;
5017  }
5018  {
5019  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
5020  if ( !arg3 )
5021  SWIG_fail;
5022  if ( temp3 != Alen )
5023  {
5024  lua_pushfstring( L, "Tables must be of same length." );
5025  SWIG_fail;
5026  }
5027  }
5028  plfill(arg1,(double const *)arg2,(double const *)arg3);
5029 
5030  {
5031  LUA_FREE_ARRAY( arg2 );
5032  }
5033  {
5034  LUA_FREE_ARRAY( arg3 );
5035  }
5036  return SWIG_arg;
5037 
5038  if(0) SWIG_fail;
5039 
5040 fail:
5041  {
5042  LUA_FREE_ARRAY( arg2 );
5043  }
5044  {
5045  LUA_FREE_ARRAY( arg3 );
5046  }
5047  lua_error(L);
5048  return SWIG_arg;
5049 }
5050 
5051 
5052 static int _wrap_fill3(lua_State* L) {
5053  int SWIG_arg = 0;
5054  PLINT arg1 ;
5055  PLFLT *arg2 = (PLFLT *) 0 ;
5056  PLFLT *arg3 = (PLFLT *) 0 ;
5057  PLFLT *arg4 = (PLFLT *) 0 ;
5058  int temp3 ;
5059  int temp4 ;
5060 
5061  SWIG_check_num_args("plfill3",3,3)
5062  {
5063  int temp;
5064  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
5065  if ( !arg2 )
5066  SWIG_fail;
5067  arg1 = Alen = temp;
5068  }
5069  {
5070  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
5071  if ( !arg3 )
5072  SWIG_fail;
5073  if ( temp3 != Alen )
5074  {
5075  lua_pushfstring( L, "Tables must be of same length." );
5076  SWIG_fail;
5077  }
5078  }
5079  {
5080  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
5081  if ( !arg4 )
5082  SWIG_fail;
5083  if ( temp4 != Alen )
5084  {
5085  lua_pushfstring( L, "Tables must be of same length." );
5086  SWIG_fail;
5087  }
5088  }
5089  plfill3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
5090 
5091  {
5092  LUA_FREE_ARRAY( arg2 );
5093  }
5094  {
5095  LUA_FREE_ARRAY( arg3 );
5096  }
5097  {
5098  LUA_FREE_ARRAY( arg4 );
5099  }
5100  return SWIG_arg;
5101 
5102  if(0) SWIG_fail;
5103 
5104 fail:
5105  {
5106  LUA_FREE_ARRAY( arg2 );
5107  }
5108  {
5109  LUA_FREE_ARRAY( arg3 );
5110  }
5111  {
5112  LUA_FREE_ARRAY( arg4 );
5113  }
5114  lua_error(L);
5115  return SWIG_arg;
5116 }
5117 
5118 
5119 static int _wrap_gradient(lua_State* L) {
5120  int SWIG_arg = 0;
5121  PLINT arg1 ;
5122  PLFLT *arg2 = (PLFLT *) 0 ;
5123  PLFLT *arg3 = (PLFLT *) 0 ;
5124  PLFLT arg4 ;
5125  int temp3 ;
5126 
5127  SWIG_check_num_args("plgradient",3,3)
5128  if(!lua_isnumber(L,3)) SWIG_fail_arg("plgradient",3,"PLFLT");
5129  {
5130  int temp;
5131  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
5132  if ( !arg2 )
5133  SWIG_fail;
5134  arg1 = Alen = temp;
5135  }
5136  {
5137  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
5138  if ( !arg3 )
5139  SWIG_fail;
5140  if ( temp3 != Alen )
5141  {
5142  lua_pushfstring( L, "Tables must be of same length." );
5143  SWIG_fail;
5144  }
5145  }
5146  arg4 = (PLFLT)lua_tonumber(L, 3);
5147  plgradient(arg1,(double const *)arg2,(double const *)arg3,arg4);
5148 
5149  {
5150  LUA_FREE_ARRAY( arg2 );
5151  }
5152  {
5153  LUA_FREE_ARRAY( arg3 );
5154  }
5155  return SWIG_arg;
5156 
5157  if(0) SWIG_fail;
5158 
5159 fail:
5160  {
5161  LUA_FREE_ARRAY( arg2 );
5162  }
5163  {
5164  LUA_FREE_ARRAY( arg3 );
5165  }
5166  lua_error(L);
5167  return SWIG_arg;
5168 }
5169 
5170 
5171 static int _wrap_flush(lua_State* L) {
5172  int SWIG_arg = 0;
5173 
5174  SWIG_check_num_args("plflush",0,0)
5175  plflush();
5176 
5177  return SWIG_arg;
5178 
5179  if(0) SWIG_fail;
5180 
5181 fail:
5182  lua_error(L);
5183  return SWIG_arg;
5184 }
5185 
5186 
5187 static int _wrap_font(lua_State* L) {
5188  int SWIG_arg = 0;
5189  PLINT arg1 ;
5190 
5191  SWIG_check_num_args("plfont",1,1)
5192  if(!lua_isnumber(L,1)) SWIG_fail_arg("plfont",1,"PLINT");
5193  arg1 = (PLINT)lua_tonumber(L, 1);
5194  plfont(arg1);
5195 
5196  return SWIG_arg;
5197 
5198  if(0) SWIG_fail;
5199 
5200 fail:
5201  lua_error(L);
5202  return SWIG_arg;
5203 }
5204 
5205 
5206 static int _wrap_fontld(lua_State* L) {
5207  int SWIG_arg = 0;
5208  PLINT arg1 ;
5209 
5210  SWIG_check_num_args("plfontld",1,1)
5211  if(!lua_isnumber(L,1)) SWIG_fail_arg("plfontld",1,"PLINT");
5212  arg1 = (PLINT)lua_tonumber(L, 1);
5213  plfontld(arg1);
5214 
5215  return SWIG_arg;
5216 
5217  if(0) SWIG_fail;
5218 
5219 fail:
5220  lua_error(L);
5221  return SWIG_arg;
5222 }
5223 
5224 
5225 static int _wrap_gchr(lua_State* L) {
5226  int SWIG_arg = 0;
5227  PLFLT *arg1 = (PLFLT *) 0 ;
5228  PLFLT *arg2 = (PLFLT *) 0 ;
5229  PLFLT temp1 ;
5230  PLFLT temp2 ;
5231 
5232  arg1 = &temp1;
5233  arg2 = &temp2;
5234  SWIG_check_num_args("plgchr",0,0)
5235  plgchr(arg1,arg2);
5236 
5237  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5238  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5239  return SWIG_arg;
5240 
5241  if(0) SWIG_fail;
5242 
5243 fail:
5244  lua_error(L);
5245  return SWIG_arg;
5246 }
5247 
5248 
5249 static int _wrap_gcol0(lua_State* L) {
5250  int SWIG_arg = 0;
5251  PLINT arg1 ;
5252  PLINT *arg2 = (PLINT *) 0 ;
5253  PLINT *arg3 = (PLINT *) 0 ;
5254  PLINT *arg4 = (PLINT *) 0 ;
5255  PLINT temp2 ;
5256  PLINT temp3 ;
5257  PLINT temp4 ;
5258 
5259  arg2 = &temp2;
5260  arg3 = &temp3;
5261  arg4 = &temp4;
5262  SWIG_check_num_args("plgcol0",1,1)
5263  if(!lua_isnumber(L,1)) SWIG_fail_arg("plgcol0",1,"PLINT");
5264  arg1 = (PLINT)lua_tonumber(L, 1);
5265  plgcol0(arg1,arg2,arg3,arg4);
5266 
5267  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5268  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5269  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5270  return SWIG_arg;
5271 
5272  if(0) SWIG_fail;
5273 
5274 fail:
5275  lua_error(L);
5276  return SWIG_arg;
5277 }
5278 
5279 
5280 static int _wrap_gcol0a(lua_State* L) {
5281  int SWIG_arg = 0;
5282  PLINT arg1 ;
5283  PLINT *arg2 = (PLINT *) 0 ;
5284  PLINT *arg3 = (PLINT *) 0 ;
5285  PLINT *arg4 = (PLINT *) 0 ;
5286  PLFLT *arg5 = (PLFLT *) 0 ;
5287  PLINT temp2 ;
5288  PLINT temp3 ;
5289  PLINT temp4 ;
5290  PLFLT temp5 ;
5291 
5292  arg2 = &temp2;
5293  arg3 = &temp3;
5294  arg4 = &temp4;
5295  arg5 = &temp5;
5296  SWIG_check_num_args("plgcol0a",1,1)
5297  if(!lua_isnumber(L,1)) SWIG_fail_arg("plgcol0a",1,"PLINT");
5298  arg1 = (PLINT)lua_tonumber(L, 1);
5299  plgcol0a(arg1,arg2,arg3,arg4,arg5);
5300 
5301  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5302  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5303  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5304  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
5305  return SWIG_arg;
5306 
5307  if(0) SWIG_fail;
5308 
5309 fail:
5310  lua_error(L);
5311  return SWIG_arg;
5312 }
5313 
5314 
5315 static int _wrap_gcolbg(lua_State* L) {
5316  int SWIG_arg = 0;
5317  PLINT *arg1 = (PLINT *) 0 ;
5318  PLINT *arg2 = (PLINT *) 0 ;
5319  PLINT *arg3 = (PLINT *) 0 ;
5320  PLINT temp1 ;
5321  PLINT temp2 ;
5322  PLINT temp3 ;
5323 
5324  arg1 = &temp1;
5325  arg2 = &temp2;
5326  arg3 = &temp3;
5327  SWIG_check_num_args("plgcolbg",0,0)
5328  plgcolbg(arg1,arg2,arg3);
5329 
5330  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5331  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5332  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5333  return SWIG_arg;
5334 
5335  if(0) SWIG_fail;
5336 
5337 fail:
5338  lua_error(L);
5339  return SWIG_arg;
5340 }
5341 
5342 
5343 static int _wrap_gcolbga(lua_State* L) {
5344  int SWIG_arg = 0;
5345  PLINT *arg1 = (PLINT *) 0 ;
5346  PLINT *arg2 = (PLINT *) 0 ;
5347  PLINT *arg3 = (PLINT *) 0 ;
5348  PLFLT *arg4 = (PLFLT *) 0 ;
5349  PLINT temp1 ;
5350  PLINT temp2 ;
5351  PLINT temp3 ;
5352  PLFLT temp4 ;
5353 
5354  arg1 = &temp1;
5355  arg2 = &temp2;
5356  arg3 = &temp3;
5357  arg4 = &temp4;
5358  SWIG_check_num_args("plgcolbga",0,0)
5359  plgcolbga(arg1,arg2,arg3,arg4);
5360 
5361  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5362  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5363  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5364  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5365  return SWIG_arg;
5366 
5367  if(0) SWIG_fail;
5368 
5369 fail:
5370  lua_error(L);
5371  return SWIG_arg;
5372 }
5373 
5374 
5375 static int _wrap_gcompression(lua_State* L) {
5376  int SWIG_arg = 0;
5377  PLINT *arg1 = (PLINT *) 0 ;
5378  PLINT temp1 ;
5379 
5380  arg1 = &temp1;
5381  SWIG_check_num_args("plgcompression",0,0)
5382  plgcompression(arg1);
5383 
5384  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5385  return SWIG_arg;
5386 
5387  if(0) SWIG_fail;
5388 
5389 fail:
5390  lua_error(L);
5391  return SWIG_arg;
5392 }
5393 
5394 
5395 static int _wrap_gdev(lua_State* L) {
5396  int SWIG_arg = 0;
5397  char *arg1 = (char *) 0 ;
5398  char buff1[1000] ;
5399 
5400  {
5401  arg1 = buff1;
5402  }
5403  SWIG_check_num_args("plgdev",0,0)
5404  plgdev(arg1);
5405 
5406  {
5407  lua_pushstring( L, arg1 );
5408  SWIG_arg++;
5409  }
5410  return SWIG_arg;
5411 
5412  if(0) SWIG_fail;
5413 
5414 fail:
5415  lua_error(L);
5416  return SWIG_arg;
5417 }
5418 
5419 
5420 static int _wrap_gdidev(lua_State* L) {
5421  int SWIG_arg = 0;
5422  PLFLT *arg1 = (PLFLT *) 0 ;
5423  PLFLT *arg2 = (PLFLT *) 0 ;
5424  PLFLT *arg3 = (PLFLT *) 0 ;
5425  PLFLT *arg4 = (PLFLT *) 0 ;
5426  PLFLT temp1 ;
5427  PLFLT temp2 ;
5428  PLFLT temp3 ;
5429  PLFLT temp4 ;
5430 
5431  arg1 = &temp1;
5432  arg2 = &temp2;
5433  arg3 = &temp3;
5434  arg4 = &temp4;
5435  SWIG_check_num_args("plgdidev",0,0)
5436  plgdidev(arg1,arg2,arg3,arg4);
5437 
5438  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5439  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5440  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5441  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5442  return SWIG_arg;
5443 
5444  if(0) SWIG_fail;
5445 
5446 fail:
5447  lua_error(L);
5448  return SWIG_arg;
5449 }
5450 
5451 
5452 static int _wrap_gdiori(lua_State* L) {
5453  int SWIG_arg = 0;
5454  PLFLT *arg1 = (PLFLT *) 0 ;
5455  PLFLT temp1 ;
5456 
5457  arg1 = &temp1;
5458  SWIG_check_num_args("plgdiori",0,0)
5459  plgdiori(arg1);
5460 
5461  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5462  return SWIG_arg;
5463 
5464  if(0) SWIG_fail;
5465 
5466 fail:
5467  lua_error(L);
5468  return SWIG_arg;
5469 }
5470 
5471 
5472 static int _wrap_gdiplt(lua_State* L) {
5473  int SWIG_arg = 0;
5474  PLFLT *arg1 = (PLFLT *) 0 ;
5475  PLFLT *arg2 = (PLFLT *) 0 ;
5476  PLFLT *arg3 = (PLFLT *) 0 ;
5477  PLFLT *arg4 = (PLFLT *) 0 ;
5478  PLFLT temp1 ;
5479  PLFLT temp2 ;
5480  PLFLT temp3 ;
5481  PLFLT temp4 ;
5482 
5483  arg1 = &temp1;
5484  arg2 = &temp2;
5485  arg3 = &temp3;
5486  arg4 = &temp4;
5487  SWIG_check_num_args("plgdiplt",0,0)
5488  plgdiplt(arg1,arg2,arg3,arg4);
5489 
5490  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5491  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5492  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5493  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5494  return SWIG_arg;
5495 
5496  if(0) SWIG_fail;
5497 
5498 fail:
5499  lua_error(L);
5500  return SWIG_arg;
5501 }
5502 
5503 
5504 static int _wrap_gfam(lua_State* L) {
5505  int SWIG_arg = 0;
5506  PLINT *arg1 = (PLINT *) 0 ;
5507  PLINT *arg2 = (PLINT *) 0 ;
5508  PLINT *arg3 = (PLINT *) 0 ;
5509  PLINT temp1 ;
5510  PLINT temp2 ;
5511  PLINT temp3 ;
5512 
5513  arg1 = &temp1;
5514  arg2 = &temp2;
5515  arg3 = &temp3;
5516  SWIG_check_num_args("plgfam",0,0)
5517  plgfam(arg1,arg2,arg3);
5518 
5519  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5520  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5521  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5522  return SWIG_arg;
5523 
5524  if(0) SWIG_fail;
5525 
5526 fail:
5527  lua_error(L);
5528  return SWIG_arg;
5529 }
5530 
5531 
5532 static int _wrap_gfci(lua_State* L) {
5533  int SWIG_arg = 0;
5534  PLUNICODE *arg1 = (PLUNICODE *) 0 ;
5535  PLUNICODE temp1 ;
5536 
5537  arg1 = &temp1;
5538  SWIG_check_num_args("plgfci",0,0)
5539  plgfci(arg1);
5540 
5541  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5542  return SWIG_arg;
5543 
5544  if(0) SWIG_fail;
5545 
5546 fail:
5547  lua_error(L);
5548  return SWIG_arg;
5549 }
5550 
5551 
5552 static int _wrap_gfnam(lua_State* L) {
5553  int SWIG_arg = 0;
5554  char *arg1 = (char *) 0 ;
5555  char buff1[1000] ;
5556 
5557  {
5558  arg1 = buff1;
5559  }
5560  SWIG_check_num_args("plgfnam",0,0)
5561  plgfnam(arg1);
5562 
5563  {
5564  lua_pushstring( L, arg1 );
5565  SWIG_arg++;
5566  }
5567  return SWIG_arg;
5568 
5569  if(0) SWIG_fail;
5570 
5571 fail:
5572  lua_error(L);
5573  return SWIG_arg;
5574 }
5575 
5576 
5577 static int _wrap_gfont(lua_State* L) {
5578  int SWIG_arg = 0;
5579  PLINT *arg1 = (PLINT *) 0 ;
5580  PLINT *arg2 = (PLINT *) 0 ;
5581  PLINT *arg3 = (PLINT *) 0 ;
5582  PLINT temp1 ;
5583  PLINT temp2 ;
5584  PLINT temp3 ;
5585 
5586  arg1 = &temp1;
5587  arg2 = &temp2;
5588  arg3 = &temp3;
5589  SWIG_check_num_args("plgfont",0,0)
5590  plgfont(arg1,arg2,arg3);
5591 
5592  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5593  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5594  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5595  return SWIG_arg;
5596 
5597  if(0) SWIG_fail;
5598 
5599 fail:
5600  lua_error(L);
5601  return SWIG_arg;
5602 }
5603 
5604 
5605 static int _wrap_glevel(lua_State* L) {
5606  int SWIG_arg = 0;
5607  PLINT *arg1 = (PLINT *) 0 ;
5608  PLINT temp1 ;
5609 
5610  arg1 = &temp1;
5611  SWIG_check_num_args("plglevel",0,0)
5612  plglevel(arg1);
5613 
5614  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5615  return SWIG_arg;
5616 
5617  if(0) SWIG_fail;
5618 
5619 fail:
5620  lua_error(L);
5621  return SWIG_arg;
5622 }
5623 
5624 
5625 static int _wrap_gpage(lua_State* L) {
5626  int SWIG_arg = 0;
5627  PLFLT *arg1 = (PLFLT *) 0 ;
5628  PLFLT *arg2 = (PLFLT *) 0 ;
5629  PLINT *arg3 = (PLINT *) 0 ;
5630  PLINT *arg4 = (PLINT *) 0 ;
5631  PLINT *arg5 = (PLINT *) 0 ;
5632  PLINT *arg6 = (PLINT *) 0 ;
5633  PLFLT temp1 ;
5634  PLFLT temp2 ;
5635  PLINT temp3 ;
5636  PLINT temp4 ;
5637  PLINT temp5 ;
5638  PLINT temp6 ;
5639 
5640  arg1 = &temp1;
5641  arg2 = &temp2;
5642  arg3 = &temp3;
5643  arg4 = &temp4;
5644  arg5 = &temp5;
5645  arg6 = &temp6;
5646  SWIG_check_num_args("plgpage",0,0)
5647  plgpage(arg1,arg2,arg3,arg4,arg5,arg6);
5648 
5649  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5650  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5651  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5652  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5653  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
5654  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
5655  return SWIG_arg;
5656 
5657  if(0) SWIG_fail;
5658 
5659 fail:
5660  lua_error(L);
5661  return SWIG_arg;
5662 }
5663 
5664 
5665 static int _wrap_gra(lua_State* L) {
5666  int SWIG_arg = 0;
5667 
5668  SWIG_check_num_args("plgra",0,0)
5669  plgra();
5670 
5671  return SWIG_arg;
5672 
5673  if(0) SWIG_fail;
5674 
5675 fail:
5676  lua_error(L);
5677  return SWIG_arg;
5678 }
5679 
5680 
5681 static int _wrap_griddata(lua_State* L) {
5682  int SWIG_arg = 0;
5683  PLFLT *arg1 = (PLFLT *) 0 ;
5684  PLFLT *arg2 = (PLFLT *) 0 ;
5685  PLFLT *arg3 = (PLFLT *) 0 ;
5686  PLINT arg4 ;
5687  PLFLT *arg5 = (PLFLT *) 0 ;
5688  PLINT arg6 ;
5689  PLFLT *arg7 = (PLFLT *) 0 ;
5690  PLINT arg8 ;
5691  PLFLT **arg9 = (PLFLT **) 0 ;
5692  PLINT arg10 ;
5693  PLFLT arg11 ;
5694  int temp2 ;
5695 
5696  SWIG_check_num_args("plgriddata",7,7)
5697  if(!lua_isnumber(L,6)) SWIG_fail_arg("plgriddata",6,"PLINT");
5698  if(!lua_isnumber(L,7)) SWIG_fail_arg("plgriddata",7,"PLFLT");
5699  {
5700  int temp;
5701  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
5702  if ( !arg1 )
5703  SWIG_fail;
5704  Alen = temp;
5705  }
5706  {
5707  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp2 );
5708  if ( !arg2 )
5709  SWIG_fail;
5710  if ( temp2 != Alen )
5711  {
5712  lua_pushfstring( L, "Tables must be of same length." );
5713  SWIG_fail;
5714  }
5715  }
5716  {
5717  int temp;
5718  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp );
5719  if ( !arg3 )
5720  SWIG_fail;
5721  if ( temp != Alen )
5722  {
5723  lua_pushfstring( L, "Tables must be of same length." );
5724  SWIG_fail;
5725  }
5726  arg4 = temp;
5727  }
5728  {
5729  int temp;
5730  arg5 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp );
5731  if ( !arg5 )
5732  SWIG_fail;
5733  arg6 = Xlen = temp;
5734  }
5735  {
5736  int temp, i;
5737 
5738  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
5739  if ( !arg7 )
5740  SWIG_fail;
5741  arg8 = Ylen = temp;
5742 
5743  arg9 = LUA_ALLOC_ARRAY( PLFLT *, Xlen );
5744  if ( !arg9 )
5745  SWIG_fail;
5746  for ( i = 0; i < Xlen; i++ )
5747  arg9[i] = NULL;
5748 
5749  for ( i = 0; i < Xlen; i++ )
5750  {
5751  arg9[i] = LUA_ALLOC_ARRAY( PLFLT, Ylen );
5752  if ( !arg9[i] )
5753  SWIG_fail;
5754  }
5755  }
5756  arg10 = (PLINT)lua_tonumber(L, 6);
5757  arg11 = (PLFLT)lua_tonumber(L, 7);
5758  plgriddata((double const *)arg1,(double const *)arg2,(double const *)arg3,arg4,(double const *)arg5,arg6,(double const *)arg7,arg8,arg9,arg10,arg11);
5759 
5760  {
5761  int i;
5762 
5763  if ( arg9 )
5764  {
5765  lua_newtable( L );
5766  for ( i = 0; i < Xlen; i++ )
5767  {
5768  SWIG_write_double_num_array( L, arg9[i], Ylen );
5769  lua_rawseti( L, -2, i + 1 ); // -1 is the inner table, -2 is the outer table
5770  }
5771  SWIG_arg++;
5772  }
5773  }
5774  {
5775  LUA_FREE_ARRAY( arg1 );
5776  }
5777  {
5778  LUA_FREE_ARRAY( arg2 );
5779  }
5780  {
5781  LUA_FREE_ARRAY( arg3 );
5782  }
5783  {
5784  LUA_FREE_ARRAY( arg5 );
5785  }
5786  {
5787  int i;
5788 
5789  LUA_FREE_ARRAY( arg7 );
5790 
5791  if ( arg9 )
5792  {
5793  for ( i = 0; i < Xlen; i++ )
5794  LUA_FREE_ARRAY( arg9[i] );
5795  LUA_FREE_ARRAY( arg9 );
5796  }
5797  }
5798  return SWIG_arg;
5799 
5800  if(0) SWIG_fail;
5801 
5802 fail:
5803  {
5804  LUA_FREE_ARRAY( arg1 );
5805  }
5806  {
5807  LUA_FREE_ARRAY( arg2 );
5808  }
5809  {
5810  LUA_FREE_ARRAY( arg3 );
5811  }
5812  {
5813  LUA_FREE_ARRAY( arg5 );
5814  }
5815  {
5816  int i;
5817 
5818  LUA_FREE_ARRAY( arg7 );
5819 
5820  if ( arg9 )
5821  {
5822  for ( i = 0; i < Xlen; i++ )
5823  LUA_FREE_ARRAY( arg9[i] );
5824  LUA_FREE_ARRAY( arg9 );
5825  }
5826  }
5827  lua_error(L);
5828  return SWIG_arg;
5829 }
5830 
5831 
5832 static int _wrap_gspa(lua_State* L) {
5833  int SWIG_arg = 0;
5834  PLFLT *arg1 = (PLFLT *) 0 ;
5835  PLFLT *arg2 = (PLFLT *) 0 ;
5836  PLFLT *arg3 = (PLFLT *) 0 ;
5837  PLFLT *arg4 = (PLFLT *) 0 ;
5838  PLFLT temp1 ;
5839  PLFLT temp2 ;
5840  PLFLT temp3 ;
5841  PLFLT temp4 ;
5842 
5843  arg1 = &temp1;
5844  arg2 = &temp2;
5845  arg3 = &temp3;
5846  arg4 = &temp4;
5847  SWIG_check_num_args("plgspa",0,0)
5848  plgspa(arg1,arg2,arg3,arg4);
5849 
5850  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5851  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5852  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5853  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5854  return SWIG_arg;
5855 
5856  if(0) SWIG_fail;
5857 
5858 fail:
5859  lua_error(L);
5860  return SWIG_arg;
5861 }
5862 
5863 
5864 static int _wrap_gstrm(lua_State* L) {
5865  int SWIG_arg = 0;
5866  PLINT *arg1 = (PLINT *) 0 ;
5867  PLINT temp1 ;
5868 
5869  arg1 = &temp1;
5870  SWIG_check_num_args("plgstrm",0,0)
5871  plgstrm(arg1);
5872 
5873  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5874  return SWIG_arg;
5875 
5876  if(0) SWIG_fail;
5877 
5878 fail:
5879  lua_error(L);
5880  return SWIG_arg;
5881 }
5882 
5883 
5884 static int _wrap_gver(lua_State* L) {
5885  int SWIG_arg = 0;
5886  char *arg1 = (char *) 0 ;
5887  char buff1[1000] ;
5888 
5889  {
5890  arg1 = buff1;
5891  }
5892  SWIG_check_num_args("plgver",0,0)
5893  plgver(arg1);
5894 
5895  {
5896  lua_pushstring( L, arg1 );
5897  SWIG_arg++;
5898  }
5899  return SWIG_arg;
5900 
5901  if(0) SWIG_fail;
5902 
5903 fail:
5904  lua_error(L);
5905  return SWIG_arg;
5906 }
5907 
5908 
5909 static int _wrap_gvpd(lua_State* L) {
5910  int SWIG_arg = 0;
5911  PLFLT *arg1 = (PLFLT *) 0 ;
5912  PLFLT *arg2 = (PLFLT *) 0 ;
5913  PLFLT *arg3 = (PLFLT *) 0 ;
5914  PLFLT *arg4 = (PLFLT *) 0 ;
5915  PLFLT temp1 ;
5916  PLFLT temp2 ;
5917  PLFLT temp3 ;
5918  PLFLT temp4 ;
5919 
5920  arg1 = &temp1;
5921  arg2 = &temp2;
5922  arg3 = &temp3;
5923  arg4 = &temp4;
5924  SWIG_check_num_args("plgvpd",0,0)
5925  plgvpd(arg1,arg2,arg3,arg4);
5926 
5927  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5928  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5929  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5930  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5931  return SWIG_arg;
5932 
5933  if(0) SWIG_fail;
5934 
5935 fail:
5936  lua_error(L);
5937  return SWIG_arg;
5938 }
5939 
5940 
5941 static int _wrap_gvpw(lua_State* L) {
5942  int SWIG_arg = 0;
5943  PLFLT *arg1 = (PLFLT *) 0 ;
5944  PLFLT *arg2 = (PLFLT *) 0 ;
5945  PLFLT *arg3 = (PLFLT *) 0 ;
5946  PLFLT *arg4 = (PLFLT *) 0 ;
5947  PLFLT temp1 ;
5948  PLFLT temp2 ;
5949  PLFLT temp3 ;
5950  PLFLT temp4 ;
5951 
5952  arg1 = &temp1;
5953  arg2 = &temp2;
5954  arg3 = &temp3;
5955  arg4 = &temp4;
5956  SWIG_check_num_args("plgvpw",0,0)
5957  plgvpw(arg1,arg2,arg3,arg4);
5958 
5959  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5960  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5961  lua_pushnumber(L, (lua_Number) *arg3); SWIG_arg++;
5962  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
5963  return SWIG_arg;
5964 
5965  if(0) SWIG_fail;
5966 
5967 fail:
5968  lua_error(L);
5969  return SWIG_arg;
5970 }
5971 
5972 
5973 static int _wrap_gxax(lua_State* L) {
5974  int SWIG_arg = 0;
5975  PLINT *arg1 = (PLINT *) 0 ;
5976  PLINT *arg2 = (PLINT *) 0 ;
5977  PLINT temp1 ;
5978  PLINT temp2 ;
5979 
5980  arg1 = &temp1;
5981  arg2 = &temp2;
5982  SWIG_check_num_args("plgxax",0,0)
5983  plgxax(arg1,arg2);
5984 
5985  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
5986  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
5987  return SWIG_arg;
5988 
5989  if(0) SWIG_fail;
5990 
5991 fail:
5992  lua_error(L);
5993  return SWIG_arg;
5994 }
5995 
5996 
5997 static int _wrap_gyax(lua_State* L) {
5998  int SWIG_arg = 0;
5999  PLINT *arg1 = (PLINT *) 0 ;
6000  PLINT *arg2 = (PLINT *) 0 ;
6001  PLINT temp1 ;
6002  PLINT temp2 ;
6003 
6004  arg1 = &temp1;
6005  arg2 = &temp2;
6006  SWIG_check_num_args("plgyax",0,0)
6007  plgyax(arg1,arg2);
6008 
6009  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
6010  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
6011  return SWIG_arg;
6012 
6013  if(0) SWIG_fail;
6014 
6015 fail:
6016  lua_error(L);
6017  return SWIG_arg;
6018 }
6019 
6020 
6021 static int _wrap_gzax(lua_State* L) {
6022  int SWIG_arg = 0;
6023  PLINT *arg1 = (PLINT *) 0 ;
6024  PLINT *arg2 = (PLINT *) 0 ;
6025  PLINT temp1 ;
6026  PLINT temp2 ;
6027 
6028  arg1 = &temp1;
6029  arg2 = &temp2;
6030  SWIG_check_num_args("plgzax",0,0)
6031  plgzax(arg1,arg2);
6032 
6033  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
6034  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
6035  return SWIG_arg;
6036 
6037  if(0) SWIG_fail;
6038 
6039 fail:
6040  lua_error(L);
6041  return SWIG_arg;
6042 }
6043 
6044 
6045 static int _wrap_hist(lua_State* L) {
6046  int SWIG_arg = 0;
6047  PLINT arg1 ;
6048  PLFLT *arg2 = (PLFLT *) 0 ;
6049  PLFLT arg3 ;
6050  PLFLT arg4 ;
6051  PLINT arg5 ;
6052  PLINT arg6 ;
6053 
6054  SWIG_check_num_args("plhist",5,5)
6055  if(!lua_isnumber(L,2)) SWIG_fail_arg("plhist",2,"PLFLT");
6056  if(!lua_isnumber(L,3)) SWIG_fail_arg("plhist",3,"PLFLT");
6057  if(!lua_isnumber(L,4)) SWIG_fail_arg("plhist",4,"PLINT");
6058  if(!lua_isnumber(L,5)) SWIG_fail_arg("plhist",5,"PLINT");
6059  {
6060  int temp;
6061  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6062  if ( !arg2 )
6063  SWIG_fail;
6064  arg1 = Alen = temp;
6065  }
6066  arg3 = (PLFLT)lua_tonumber(L, 2);
6067  arg4 = (PLFLT)lua_tonumber(L, 3);
6068  arg5 = (PLINT)lua_tonumber(L, 4);
6069  arg6 = (PLINT)lua_tonumber(L, 5);
6070  plhist(arg1,(double const *)arg2,arg3,arg4,arg5,arg6);
6071 
6072  {
6073  LUA_FREE_ARRAY( arg2 );
6074  }
6075  return SWIG_arg;
6076 
6077  if(0) SWIG_fail;
6078 
6079 fail:
6080  {
6081  LUA_FREE_ARRAY( arg2 );
6082  }
6083  lua_error(L);
6084  return SWIG_arg;
6085 }
6086 
6087 
6088 static int _wrap_hlsrgb(lua_State* L) {
6089  int SWIG_arg = 0;
6090  PLFLT arg1 ;
6091  PLFLT arg2 ;
6092  PLFLT arg3 ;
6093  PLFLT *arg4 = (PLFLT *) 0 ;
6094  PLFLT *arg5 = (PLFLT *) 0 ;
6095  PLFLT *arg6 = (PLFLT *) 0 ;
6096  PLFLT temp4 ;
6097  PLFLT temp5 ;
6098  PLFLT temp6 ;
6099 
6100  arg4 = &temp4;
6101  arg5 = &temp5;
6102  arg6 = &temp6;
6103  SWIG_check_num_args("plhlsrgb",3,3)
6104  if(!lua_isnumber(L,1)) SWIG_fail_arg("plhlsrgb",1,"PLFLT");
6105  if(!lua_isnumber(L,2)) SWIG_fail_arg("plhlsrgb",2,"PLFLT");
6106  if(!lua_isnumber(L,3)) SWIG_fail_arg("plhlsrgb",3,"PLFLT");
6107  arg1 = (PLFLT)lua_tonumber(L, 1);
6108  arg2 = (PLFLT)lua_tonumber(L, 2);
6109  arg3 = (PLFLT)lua_tonumber(L, 3);
6110  plhlsrgb(arg1,arg2,arg3,arg4,arg5,arg6);
6111 
6112  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
6113  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
6114  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
6115  return SWIG_arg;
6116 
6117  if(0) SWIG_fail;
6118 
6119 fail:
6120  lua_error(L);
6121  return SWIG_arg;
6122 }
6123 
6124 
6125 static int _wrap_init(lua_State* L) {
6126  int SWIG_arg = 0;
6127 
6128  SWIG_check_num_args("plinit",0,0)
6129  plinit();
6130 
6131  return SWIG_arg;
6132 
6133  if(0) SWIG_fail;
6134 
6135 fail:
6136  lua_error(L);
6137  return SWIG_arg;
6138 }
6139 
6140 
6141 static int _wrap_join(lua_State* L) {
6142  int SWIG_arg = 0;
6143  PLFLT arg1 ;
6144  PLFLT arg2 ;
6145  PLFLT arg3 ;
6146  PLFLT arg4 ;
6147 
6148  SWIG_check_num_args("pljoin",4,4)
6149  if(!lua_isnumber(L,1)) SWIG_fail_arg("pljoin",1,"PLFLT");
6150  if(!lua_isnumber(L,2)) SWIG_fail_arg("pljoin",2,"PLFLT");
6151  if(!lua_isnumber(L,3)) SWIG_fail_arg("pljoin",3,"PLFLT");
6152  if(!lua_isnumber(L,4)) SWIG_fail_arg("pljoin",4,"PLFLT");
6153  arg1 = (PLFLT)lua_tonumber(L, 1);
6154  arg2 = (PLFLT)lua_tonumber(L, 2);
6155  arg3 = (PLFLT)lua_tonumber(L, 3);
6156  arg4 = (PLFLT)lua_tonumber(L, 4);
6157  pljoin(arg1,arg2,arg3,arg4);
6158 
6159  return SWIG_arg;
6160 
6161  if(0) SWIG_fail;
6162 
6163 fail:
6164  lua_error(L);
6165  return SWIG_arg;
6166 }
6167 
6168 
6169 static int _wrap_lab(lua_State* L) {
6170  int SWIG_arg = 0;
6171  char *arg1 = (char *) 0 ;
6172  char *arg2 = (char *) 0 ;
6173  char *arg3 = (char *) 0 ;
6174 
6175  SWIG_check_num_args("pllab",3,3)
6176  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("pllab",1,"char const *");
6177  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("pllab",2,"char const *");
6178  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("pllab",3,"char const *");
6179  arg1 = (char *)lua_tostring(L, 1);
6180  arg2 = (char *)lua_tostring(L, 2);
6181  arg3 = (char *)lua_tostring(L, 3);
6182  pllab((char const *)arg1,(char const *)arg2,(char const *)arg3);
6183 
6184  return SWIG_arg;
6185 
6186  if(0) SWIG_fail;
6187 
6188 fail:
6189  lua_error(L);
6190  return SWIG_arg;
6191 }
6192 
6193 
6194 static int _wrap_legend(lua_State* L) {
6195  int SWIG_arg = 0;
6196  PLFLT *arg1 = (PLFLT *) 0 ;
6197  PLFLT *arg2 = (PLFLT *) 0 ;
6198  PLINT arg3 ;
6199  PLINT arg4 ;
6200  PLFLT arg5 ;
6201  PLFLT arg6 ;
6202  PLFLT arg7 ;
6203  PLINT arg8 ;
6204  PLINT arg9 ;
6205  PLINT arg10 ;
6206  PLINT arg11 ;
6207  PLINT arg12 ;
6208  PLINT arg13 ;
6209  PLINT *arg14 = (PLINT *) 0 ;
6210  PLFLT arg15 ;
6211  PLFLT arg16 ;
6212  PLFLT arg17 ;
6213  PLFLT arg18 ;
6214  PLINT *arg19 = (PLINT *) 0 ;
6215  char **arg20 = (char **) 0 ;
6216  PLINT *arg21 = (PLINT *) 0 ;
6217  PLINT *arg22 = (PLINT *) 0 ;
6218  PLFLT *arg23 = (PLFLT *) 0 ;
6219  PLFLT *arg24 = (PLFLT *) 0 ;
6220  PLINT *arg25 = (PLINT *) 0 ;
6221  PLINT *arg26 = (PLINT *) 0 ;
6222  PLFLT *arg27 = (PLFLT *) 0 ;
6223  PLINT *arg28 = (PLINT *) 0 ;
6224  PLFLT *arg29 = (PLFLT *) 0 ;
6225  PLINT *arg30 = (PLINT *) 0 ;
6226  char **arg31 = (char **) 0 ;
6227  PLFLT temp1 ;
6228  PLFLT temp2 ;
6229  int temp19 ;
6230  int temp21 ;
6231  int temp22 ;
6232  int temp23 ;
6233  int temp24 ;
6234  int temp25 ;
6235  int temp26 ;
6236  int temp27 ;
6237  int temp28 ;
6238  int temp29 ;
6239  int temp30 ;
6240 
6241  {
6242  arg21 = NULL;
6243  }
6244  {
6245  arg22 = NULL;
6246  }
6247  {
6248  arg23 = NULL;
6249  }
6250  {
6251  arg24 = NULL;
6252  }
6253  {
6254  arg25 = NULL;
6255  }
6256  {
6257  arg26 = NULL;
6258  }
6259  {
6260  arg27 = NULL;
6261  }
6262  {
6263  arg28 = NULL;
6264  }
6265  {
6266  arg29 = NULL;
6267  }
6268  {
6269  arg30 = NULL;
6270  }
6271  arg1 = &temp1;
6272  arg2 = &temp2;
6273  SWIG_check_num_args("pllegend",17,28)
6274  if(!lua_isnumber(L,1)) SWIG_fail_arg("pllegend",1,"PLINT");
6275  if(!lua_isnumber(L,2)) SWIG_fail_arg("pllegend",2,"PLINT");
6276  if(!lua_isnumber(L,3)) SWIG_fail_arg("pllegend",3,"PLFLT");
6277  if(!lua_isnumber(L,4)) SWIG_fail_arg("pllegend",4,"PLFLT");
6278  if(!lua_isnumber(L,5)) SWIG_fail_arg("pllegend",5,"PLFLT");
6279  if(!lua_isnumber(L,6)) SWIG_fail_arg("pllegend",6,"PLINT");
6280  if(!lua_isnumber(L,7)) SWIG_fail_arg("pllegend",7,"PLINT");
6281  if(!lua_isnumber(L,8)) SWIG_fail_arg("pllegend",8,"PLINT");
6282  if(!lua_isnumber(L,9)) SWIG_fail_arg("pllegend",9,"PLINT");
6283  if(!lua_isnumber(L,10)) SWIG_fail_arg("pllegend",10,"PLINT");
6284  if(!lua_isnumber(L,12)) SWIG_fail_arg("pllegend",12,"PLFLT");
6285  if(!lua_isnumber(L,13)) SWIG_fail_arg("pllegend",13,"PLFLT");
6286  if(!lua_isnumber(L,14)) SWIG_fail_arg("pllegend",14,"PLFLT");
6287  if(!lua_isnumber(L,15)) SWIG_fail_arg("pllegend",15,"PLFLT");
6288  if(!lua_istable(L,17)) SWIG_fail_arg("pllegend",17,"char const **");
6289  if(lua_gettop(L)>=28 && !lua_istable(L,28)) SWIG_fail_arg("pllegend",28,"char const **");
6290  arg3 = (PLINT)lua_tonumber(L, 1);
6291  arg4 = (PLINT)lua_tonumber(L, 2);
6292  arg5 = (PLFLT)lua_tonumber(L, 3);
6293  arg6 = (PLFLT)lua_tonumber(L, 4);
6294  arg7 = (PLFLT)lua_tonumber(L, 5);
6295  arg8 = (PLINT)lua_tonumber(L, 6);
6296  arg9 = (PLINT)lua_tonumber(L, 7);
6297  arg10 = (PLINT)lua_tonumber(L, 8);
6298  arg11 = (PLINT)lua_tonumber(L, 9);
6299  arg12 = (PLINT)lua_tonumber(L, 10);
6300  {
6301  arg14 = (PLINT *) LUA_get_int_num_array_var( L, 11, &arg13 );
6302  if ( !arg14 )
6303  SWIG_fail;
6304  Alen = arg13;
6305  }
6306  arg15 = (PLFLT)lua_tonumber(L, 12);
6307  arg16 = (PLFLT)lua_tonumber(L, 13);
6308  arg17 = (PLFLT)lua_tonumber(L, 14);
6309  arg18 = (PLFLT)lua_tonumber(L, 15);
6310  {
6311  arg19 = (PLINT *) LUA_get_int_num_array_var( L, 16, &temp19 );
6312  if ( !arg19 )
6313  SWIG_fail;
6314  if ( temp19 != Alen )
6315  {
6316  lua_pushfstring( L, "Tables must be of same length." );
6317  SWIG_fail;
6318  }
6319  }
6320  {
6321  int i;
6322  arg20 = NULL;
6323 
6324  if ( SWIG_table_size( L, 17 ) != Alen )
6325  {
6326  lua_pushfstring( L, "Tables must be of same length." );
6327  SWIG_fail;
6328  }
6329  arg20 = malloc( sizeof ( char* ) * Alen );
6330  for ( i = 1; i <= Alen; i++ )
6331  {
6332  lua_rawgeti( L, 17, i );
6333  if ( lua_isstring( L, -1 ) )
6334  {
6335  arg20[i - 1] = (char *) lua_tostring( L, -1 );
6336  }
6337  else
6338  {
6339  lua_pop( L, 1 );
6340  lua_pushfstring( L, "Requires a sequence of strings." );
6341  SWIG_fail;
6342  // arg20 array is freed after 'fail:'
6343  }
6344  lua_pop( L, 1 );
6345  }
6346  }
6347  if(lua_gettop(L)>=18){
6348  {
6349  if ( lua_isnil( L, 18 ) )
6350  {
6351  arg21 = NULL;
6352  }
6353  else
6354  {
6355  arg21 = (PLINT *) LUA_get_int_num_array_var( L, 18, &temp21 );
6356  if ( !arg21 )
6357  SWIG_fail;
6358  if ( temp21 != Alen )
6359  {
6360  lua_pushfstring( L, "Tables must be of same length." );
6361  SWIG_fail;
6362  }
6363  }
6364  }
6365  }
6366  if(lua_gettop(L)>=19){
6367  {
6368  if ( lua_isnil( L, 19 ) )
6369  {
6370  arg22 = NULL;
6371  }
6372  else
6373  {
6374  arg22 = (PLINT *) LUA_get_int_num_array_var( L, 19, &temp22 );
6375  if ( !arg22 )
6376  SWIG_fail;
6377  if ( temp22 != Alen )
6378  {
6379  lua_pushfstring( L, "Tables must be of same length." );
6380  SWIG_fail;
6381  }
6382  }
6383  }
6384  }
6385  if(lua_gettop(L)>=20){
6386  {
6387  if ( lua_isnil( L, 20 ) )
6388  {
6389  arg23 = NULL;
6390  }
6391  else
6392  {
6393  arg23 = (PLFLT *) LUA_get_double_num_array_var( L, 20, &temp23 );
6394  if ( !arg23 )
6395  SWIG_fail;
6396  if ( temp23 != Alen )
6397  {
6398  lua_pushfstring( L, "Tables must be of same length." );
6399  SWIG_fail;
6400  }
6401  }
6402  }
6403  }
6404  if(lua_gettop(L)>=21){
6405  {
6406  if ( lua_isnil( L, 21 ) )
6407  {
6408  arg24 = NULL;
6409  }
6410  else
6411  {
6412  arg24 = (PLFLT *) LUA_get_double_num_array_var( L, 21, &temp24 );
6413  if ( !arg24 )
6414  SWIG_fail;
6415  if ( temp24 != Alen )
6416  {
6417  lua_pushfstring( L, "Tables must be of same length." );
6418  SWIG_fail;
6419  }
6420  }
6421  }
6422  }
6423  if(lua_gettop(L)>=22){
6424  {
6425  if ( lua_isnil( L, 22 ) )
6426  {
6427  arg25 = NULL;
6428  }
6429  else
6430  {
6431  arg25 = (PLINT *) LUA_get_int_num_array_var( L, 22, &temp25 );
6432  if ( !arg25 )
6433  SWIG_fail;
6434  if ( temp25 != Alen )
6435  {
6436  lua_pushfstring( L, "Tables must be of same length." );
6437  SWIG_fail;
6438  }
6439  }
6440  }
6441  }
6442  if(lua_gettop(L)>=23){
6443  {
6444  if ( lua_isnil( L, 23 ) )
6445  {
6446  arg26 = NULL;
6447  }
6448  else
6449  {
6450  arg26 = (PLINT *) LUA_get_int_num_array_var( L, 23, &temp26 );
6451  if ( !arg26 )
6452  SWIG_fail;
6453  if ( temp26 != Alen )
6454  {
6455  lua_pushfstring( L, "Tables must be of same length." );
6456  SWIG_fail;
6457  }
6458  }
6459  }
6460  }
6461  if(lua_gettop(L)>=24){
6462  {
6463  if ( lua_isnil( L, 24 ) )
6464  {
6465  arg27 = NULL;
6466  }
6467  else
6468  {
6469  arg27 = (PLFLT *) LUA_get_double_num_array_var( L, 24, &temp27 );
6470  if ( !arg27 )
6471  SWIG_fail;
6472  if ( temp27 != Alen )
6473  {
6474  lua_pushfstring( L, "Tables must be of same length." );
6475  SWIG_fail;
6476  }
6477  }
6478  }
6479  }
6480  if(lua_gettop(L)>=25){
6481  {
6482  if ( lua_isnil( L, 25 ) )
6483  {
6484  arg28 = NULL;
6485  }
6486  else
6487  {
6488  arg28 = (PLINT *) LUA_get_int_num_array_var( L, 25, &temp28 );
6489  if ( !arg28 )
6490  SWIG_fail;
6491  if ( temp28 != Alen )
6492  {
6493  lua_pushfstring( L, "Tables must be of same length." );
6494  SWIG_fail;
6495  }
6496  }
6497  }
6498  }
6499  if(lua_gettop(L)>=26){
6500  {
6501  if ( lua_isnil( L, 26 ) )
6502  {
6503  arg29 = NULL;
6504  }
6505  else
6506  {
6507  arg29 = (PLFLT *) LUA_get_double_num_array_var( L, 26, &temp29 );
6508  if ( !arg29 )
6509  SWIG_fail;
6510  if ( temp29 != Alen )
6511  {
6512  lua_pushfstring( L, "Tables must be of same length." );
6513  SWIG_fail;
6514  }
6515  }
6516  }
6517  }
6518  if(lua_gettop(L)>=27){
6519  {
6520  if ( lua_isnil( L, 27 ) )
6521  {
6522  arg30 = NULL;
6523  }
6524  else
6525  {
6526  arg30 = (PLINT *) LUA_get_int_num_array_var( L, 27, &temp30 );
6527  if ( !arg30 )
6528  SWIG_fail;
6529  if ( temp30 != Alen )
6530  {
6531  lua_pushfstring( L, "Tables must be of same length." );
6532  SWIG_fail;
6533  }
6534  }
6535  }
6536  }
6537  if(lua_gettop(L)>=28){
6538  {
6539  int i;
6540  arg31 = NULL;
6541 
6542  if ( SWIG_table_size( L, 28 ) != Alen )
6543  {
6544  lua_pushfstring( L, "Tables must be of same length." );
6545  SWIG_fail;
6546  }
6547  arg31 = malloc( sizeof ( char* ) * Alen );
6548  for ( i = 1; i <= Alen; i++ )
6549  {
6550  lua_rawgeti( L, 28, i );
6551  if ( lua_isstring( L, -1 ) )
6552  {
6553  arg31[i - 1] = (char *) lua_tostring( L, -1 );
6554  }
6555  else
6556  {
6557  lua_pop( L, 1 );
6558  lua_pushfstring( L, "Requires a sequence of strings." );
6559  SWIG_fail;
6560  // arg31 array is freed after 'fail:'
6561  }
6562  lua_pop( L, 1 );
6563  }
6564  }
6565  }
6566  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);
6567 
6568  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
6569  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
6570  {
6571  LUA_FREE_ARRAY( arg14 );
6572  }
6573  {
6574  LUA_FREE_ARRAY( arg19 );
6575  }
6576  {
6577  if ( arg20 )
6578  {
6579  free( arg20 ); arg20 = NULL;
6580  }
6581  }
6582  {
6583  LUA_FREE_ARRAY( arg21 );
6584  }
6585  {
6586  LUA_FREE_ARRAY( arg22 );
6587  }
6588  {
6589  LUA_FREE_ARRAY( arg23 );
6590  }
6591  {
6592  LUA_FREE_ARRAY( arg24 );
6593  }
6594  {
6595  LUA_FREE_ARRAY( arg25 );
6596  }
6597  {
6598  LUA_FREE_ARRAY( arg26 );
6599  }
6600  {
6601  LUA_FREE_ARRAY( arg27 );
6602  }
6603  {
6604  LUA_FREE_ARRAY( arg28 );
6605  }
6606  {
6607  LUA_FREE_ARRAY( arg29 );
6608  }
6609  {
6610  LUA_FREE_ARRAY( arg30 );
6611  }
6612  {
6613  if ( arg31 )
6614  {
6615  free( arg31 ); arg31 = NULL;
6616  }
6617  }
6618  return SWIG_arg;
6619 
6620  if(0) SWIG_fail;
6621 
6622 fail:
6623  {
6624  LUA_FREE_ARRAY( arg14 );
6625  }
6626  {
6627  LUA_FREE_ARRAY( arg19 );
6628  }
6629  {
6630  if ( arg20 )
6631  {
6632  free( arg20 ); arg20 = NULL;
6633  }
6634  }
6635  {
6636  LUA_FREE_ARRAY( arg21 );
6637  }
6638  {
6639  LUA_FREE_ARRAY( arg22 );
6640  }
6641  {
6642  LUA_FREE_ARRAY( arg23 );
6643  }
6644  {
6645  LUA_FREE_ARRAY( arg24 );
6646  }
6647  {
6648  LUA_FREE_ARRAY( arg25 );
6649  }
6650  {
6651  LUA_FREE_ARRAY( arg26 );
6652  }
6653  {
6654  LUA_FREE_ARRAY( arg27 );
6655  }
6656  {
6657  LUA_FREE_ARRAY( arg28 );
6658  }
6659  {
6660  LUA_FREE_ARRAY( arg29 );
6661  }
6662  {
6663  LUA_FREE_ARRAY( arg30 );
6664  }
6665  {
6666  if ( arg31 )
6667  {
6668  free( arg31 ); arg31 = NULL;
6669  }
6670  }
6671  lua_error(L);
6672  return SWIG_arg;
6673 }
6674 
6675 
6676 static int _wrap_colorbar(lua_State* L) {
6677  int SWIG_arg = 0;
6678  PLFLT *arg1 = (PLFLT *) 0 ;
6679  PLFLT *arg2 = (PLFLT *) 0 ;
6680  PLINT arg3 ;
6681  PLINT arg4 ;
6682  PLFLT arg5 ;
6683  PLFLT arg6 ;
6684  PLFLT arg7 ;
6685  PLFLT arg8 ;
6686  PLINT arg9 ;
6687  PLINT arg10 ;
6688  PLINT arg11 ;
6689  PLFLT arg12 ;
6690  PLFLT arg13 ;
6691  PLINT arg14 ;
6692  PLFLT arg15 ;
6693  PLINT arg16 ;
6694  PLINT *arg17 = (PLINT *) 0 ;
6695  char **arg18 = (char **) 0 ;
6696  PLINT arg19 ;
6697  char **arg20 = (char **) 0 ;
6698  PLFLT *arg21 = (PLFLT *) 0 ;
6699  PLINT *arg22 = (PLINT *) 0 ;
6700  PLINT *arg23 = (PLINT *) 0 ;
6701  PLFLT **arg24 = (PLFLT **) 0 ;
6702  PLFLT temp1 ;
6703  PLFLT temp2 ;
6704  int temp21 ;
6705  int temp22 ;
6706  int temp23 ;
6707  int ii24 ;
6708 
6709  arg1 = &temp1;
6710  arg2 = &temp2;
6711  SWIG_check_num_args("plcolorbar",20,20)
6712  if(!lua_isnumber(L,1)) SWIG_fail_arg("plcolorbar",1,"PLINT");
6713  if(!lua_isnumber(L,2)) SWIG_fail_arg("plcolorbar",2,"PLINT");
6714  if(!lua_isnumber(L,3)) SWIG_fail_arg("plcolorbar",3,"PLFLT");
6715  if(!lua_isnumber(L,4)) SWIG_fail_arg("plcolorbar",4,"PLFLT");
6716  if(!lua_isnumber(L,5)) SWIG_fail_arg("plcolorbar",5,"PLFLT");
6717  if(!lua_isnumber(L,6)) SWIG_fail_arg("plcolorbar",6,"PLFLT");
6718  if(!lua_isnumber(L,7)) SWIG_fail_arg("plcolorbar",7,"PLINT");
6719  if(!lua_isnumber(L,8)) SWIG_fail_arg("plcolorbar",8,"PLINT");
6720  if(!lua_isnumber(L,9)) SWIG_fail_arg("plcolorbar",9,"PLINT");
6721  if(!lua_isnumber(L,10)) SWIG_fail_arg("plcolorbar",10,"PLFLT");
6722  if(!lua_isnumber(L,11)) SWIG_fail_arg("plcolorbar",11,"PLFLT");
6723  if(!lua_isnumber(L,12)) SWIG_fail_arg("plcolorbar",12,"PLINT");
6724  if(!lua_isnumber(L,13)) SWIG_fail_arg("plcolorbar",13,"PLFLT");
6725  if(!lua_istable(L,15)) SWIG_fail_arg("plcolorbar",15,"char const **");
6726  arg3 = (PLINT)lua_tonumber(L, 1);
6727  arg4 = (PLINT)lua_tonumber(L, 2);
6728  arg5 = (PLFLT)lua_tonumber(L, 3);
6729  arg6 = (PLFLT)lua_tonumber(L, 4);
6730  arg7 = (PLFLT)lua_tonumber(L, 5);
6731  arg8 = (PLFLT)lua_tonumber(L, 6);
6732  arg9 = (PLINT)lua_tonumber(L, 7);
6733  arg10 = (PLINT)lua_tonumber(L, 8);
6734  arg11 = (PLINT)lua_tonumber(L, 9);
6735  arg12 = (PLFLT)lua_tonumber(L, 10);
6736  arg13 = (PLFLT)lua_tonumber(L, 11);
6737  arg14 = (PLINT)lua_tonumber(L, 12);
6738  arg15 = (PLFLT)lua_tonumber(L, 13);
6739  {
6740  arg17 = (PLINT *) LUA_get_int_num_array_var( L, 14, &arg16 );
6741  if ( !arg17 )
6742  SWIG_fail;
6743  Alen = arg16;
6744  }
6745  {
6746  int i;
6747  arg18 = NULL;
6748 
6749  if ( SWIG_table_size( L, 15 ) != Alen )
6750  {
6751  lua_pushfstring( L, "Tables must be of same length." );
6752  SWIG_fail;
6753  }
6754  arg18 = malloc( sizeof ( char* ) * Alen );
6755  for ( i = 1; i <= Alen; i++ )
6756  {
6757  lua_rawgeti( L, 15, i );
6758  if ( lua_isstring( L, -1 ) )
6759  {
6760  arg18[i - 1] = (char *) lua_tostring( L, -1 );
6761  }
6762  else
6763  {
6764  lua_pop( L, 1 );
6765  lua_pushfstring( L, "Requires a sequence of strings." );
6766  SWIG_fail;
6767  // arg18 array is freed after 'fail:'
6768  }
6769  lua_pop( L, 1 );
6770  }
6771  }
6772  {
6773  int i;
6774  arg19 = SWIG_table_size( L, 16 );
6775  Alen = arg19;
6776 
6777  arg20 = malloc( sizeof ( char* ) * Alen );
6778  for ( i = 1; i <= Alen; i++ )
6779  {
6780  lua_rawgeti( L, 16, i );
6781  if ( lua_isstring( L, -1 ) )
6782  {
6783  arg20[i - 1] = (char *) lua_tostring( L, -1 );
6784  }
6785  else
6786  {
6787  lua_pop( L, 1 );
6788  lua_pushfstring( L, "Requires a sequence of strings." );
6789  SWIG_fail;
6790  }
6791  lua_pop( L, 1 );
6792  }
6793  }
6794  {
6795  arg21 = (PLFLT *) LUA_get_double_num_array_var( L, 17, &temp21 );
6796  if ( !arg21 )
6797  SWIG_fail;
6798  if ( temp21 != Alen )
6799  {
6800  lua_pushfstring( L, "Tables must be of same length." );
6801  SWIG_fail;
6802  }
6803  }
6804  {
6805  arg22 = (PLINT *) LUA_get_int_num_array_var( L, 18, &temp22 );
6806  if ( !arg22 )
6807  SWIG_fail;
6808  if ( temp22 != Alen )
6809  {
6810  lua_pushfstring( L, "Tables must be of same length." );
6811  SWIG_fail;
6812  }
6813  }
6814  {
6815  int i;
6816 
6817  arg23 = (PLINT *) LUA_get_int_num_array_var( L, 19, &temp23 );
6818  if ( !arg23 )
6819  SWIG_fail;
6820  if ( temp23 != Alen )
6821  {
6822  lua_pushfstring( L, "Tables must be of same length." );
6823  SWIG_fail;
6824  }
6825 
6826  Xlen = temp23;
6827  Ylen = -1;
6828  for ( i = 0; i < Xlen; i++ )
6829  if ( arg23[i] > Ylen )
6830  Ylen = arg23[i];
6831  }
6832  {
6833  int jj;
6834 
6835  arg24 = read_double_Matrix( L, 20, &ii24, &jj );
6836  if ( !arg24 )
6837  SWIG_fail;
6838  if ( ( ii24 != Xlen ) || ( jj != Ylen ) )
6839  {
6840  lua_pushfstring( L, "Vectors must match matrix." );
6841  SWIG_fail;
6842  }
6843  }
6844  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);
6845 
6846  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
6847  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
6848  {
6849  LUA_FREE_ARRAY( arg17 );
6850  }
6851  {
6852  if ( arg18 )
6853  {
6854  free( arg18 ); arg18 = NULL;
6855  }
6856  }
6857  {
6858  if ( arg20 )
6859  {
6860  free( arg20 ); arg20 = NULL;
6861  }
6862  }
6863  {
6864  LUA_FREE_ARRAY( arg21 );
6865  }
6866  {
6867  LUA_FREE_ARRAY( arg22 );
6868  }
6869  {
6870  LUA_FREE_ARRAY( arg23 );
6871  }
6872  {
6873  int i;
6874 
6875  if ( arg24 )
6876  {
6877  for ( i = 0; i < ii24; i++ )
6878  LUA_FREE_ARRAY( arg24[i] );
6879  LUA_FREE_ARRAY( arg24 );
6880  }
6881  }
6882  return SWIG_arg;
6883 
6884  if(0) SWIG_fail;
6885 
6886 fail:
6887  {
6888  LUA_FREE_ARRAY( arg17 );
6889  }
6890  {
6891  if ( arg18 )
6892  {
6893  free( arg18 ); arg18 = NULL;
6894  }
6895  }
6896  {
6897  if ( arg20 )
6898  {
6899  free( arg20 ); arg20 = NULL;
6900  }
6901  }
6902  {
6903  LUA_FREE_ARRAY( arg21 );
6904  }
6905  {
6906  LUA_FREE_ARRAY( arg22 );
6907  }
6908  {
6909  LUA_FREE_ARRAY( arg23 );
6910  }
6911  {
6912  int i;
6913 
6914  if ( arg24 )
6915  {
6916  for ( i = 0; i < ii24; i++ )
6917  LUA_FREE_ARRAY( arg24[i] );
6918  LUA_FREE_ARRAY( arg24 );
6919  }
6920  }
6921  lua_error(L);
6922  return SWIG_arg;
6923 }
6924 
6925 
6926 static int _wrap_lightsource(lua_State* L) {
6927  int SWIG_arg = 0;
6928  PLFLT arg1 ;
6929  PLFLT arg2 ;
6930  PLFLT arg3 ;
6931 
6932  SWIG_check_num_args("pllightsource",3,3)
6933  if(!lua_isnumber(L,1)) SWIG_fail_arg("pllightsource",1,"PLFLT");
6934  if(!lua_isnumber(L,2)) SWIG_fail_arg("pllightsource",2,"PLFLT");
6935  if(!lua_isnumber(L,3)) SWIG_fail_arg("pllightsource",3,"PLFLT");
6936  arg1 = (PLFLT)lua_tonumber(L, 1);
6937  arg2 = (PLFLT)lua_tonumber(L, 2);
6938  arg3 = (PLFLT)lua_tonumber(L, 3);
6939  pllightsource(arg1,arg2,arg3);
6940 
6941  return SWIG_arg;
6942 
6943  if(0) SWIG_fail;
6944 
6945 fail:
6946  lua_error(L);
6947  return SWIG_arg;
6948 }
6949 
6950 
6951 static int _wrap_line(lua_State* L) {
6952  int SWIG_arg = 0;
6953  PLINT arg1 ;
6954  PLFLT *arg2 = (PLFLT *) 0 ;
6955  PLFLT *arg3 = (PLFLT *) 0 ;
6956  int temp3 ;
6957 
6958  SWIG_check_num_args("plline",2,2)
6959  {
6960  int temp;
6961  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
6962  if ( !arg2 )
6963  SWIG_fail;
6964  arg1 = Alen = temp;
6965  }
6966  {
6967  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
6968  if ( !arg3 )
6969  SWIG_fail;
6970  if ( temp3 != Alen )
6971  {
6972  lua_pushfstring( L, "Tables must be of same length." );
6973  SWIG_fail;
6974  }
6975  }
6976  plline(arg1,(double const *)arg2,(double const *)arg3);
6977 
6978  {
6979  LUA_FREE_ARRAY( arg2 );
6980  }
6981  {
6982  LUA_FREE_ARRAY( arg3 );
6983  }
6984  return SWIG_arg;
6985 
6986  if(0) SWIG_fail;
6987 
6988 fail:
6989  {
6990  LUA_FREE_ARRAY( arg2 );
6991  }
6992  {
6993  LUA_FREE_ARRAY( arg3 );
6994  }
6995  lua_error(L);
6996  return SWIG_arg;
6997 }
6998 
6999 
7000 static int _wrap_line3(lua_State* L) {
7001  int SWIG_arg = 0;
7002  PLINT arg1 ;
7003  PLFLT *arg2 = (PLFLT *) 0 ;
7004  PLFLT *arg3 = (PLFLT *) 0 ;
7005  PLFLT *arg4 = (PLFLT *) 0 ;
7006  int temp3 ;
7007  int temp4 ;
7008 
7009  SWIG_check_num_args("plline3",3,3)
7010  {
7011  int temp;
7012  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7013  if ( !arg2 )
7014  SWIG_fail;
7015  arg1 = Alen = temp;
7016  }
7017  {
7018  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
7019  if ( !arg3 )
7020  SWIG_fail;
7021  if ( temp3 != Alen )
7022  {
7023  lua_pushfstring( L, "Tables must be of same length." );
7024  SWIG_fail;
7025  }
7026  }
7027  {
7028  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
7029  if ( !arg4 )
7030  SWIG_fail;
7031  if ( temp4 != Alen )
7032  {
7033  lua_pushfstring( L, "Tables must be of same length." );
7034  SWIG_fail;
7035  }
7036  }
7037  plline3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4);
7038 
7039  {
7040  LUA_FREE_ARRAY( arg2 );
7041  }
7042  {
7043  LUA_FREE_ARRAY( arg3 );
7044  }
7045  {
7046  LUA_FREE_ARRAY( arg4 );
7047  }
7048  return SWIG_arg;
7049 
7050  if(0) SWIG_fail;
7051 
7052 fail:
7053  {
7054  LUA_FREE_ARRAY( arg2 );
7055  }
7056  {
7057  LUA_FREE_ARRAY( arg3 );
7058  }
7059  {
7060  LUA_FREE_ARRAY( arg4 );
7061  }
7062  lua_error(L);
7063  return SWIG_arg;
7064 }
7065 
7066 
7067 static int _wrap_lsty(lua_State* L) {
7068  int SWIG_arg = 0;
7069  PLINT arg1 ;
7070 
7071  SWIG_check_num_args("pllsty",1,1)
7072  if(!lua_isnumber(L,1)) SWIG_fail_arg("pllsty",1,"PLINT");
7073  arg1 = (PLINT)lua_tonumber(L, 1);
7074  pllsty(arg1);
7075 
7076  return SWIG_arg;
7077 
7078  if(0) SWIG_fail;
7079 
7080 fail:
7081  lua_error(L);
7082  return SWIG_arg;
7083 }
7084 
7085 
7086 static int _wrap_mesh(lua_State* L) {
7087  int SWIG_arg = 0;
7088  PLFLT *arg1 = (PLFLT *) 0 ;
7089  PLFLT *arg2 = (PLFLT *) 0 ;
7090  PLFLT **arg3 = (PLFLT **) 0 ;
7091  PLINT arg4 ;
7092  PLINT arg5 ;
7093  PLINT arg6 ;
7094  int ii3 ;
7095 
7096  SWIG_check_num_args("plmesh",4,4)
7097  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmesh",4,"PLINT");
7098  {
7099  int temp;
7100  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7101  if ( !arg1 )
7102  SWIG_fail;
7103  Xlen = temp;
7104  }
7105  {
7106  int temp;
7107  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7108  if ( !arg2 )
7109  SWIG_fail;
7110  Ylen = temp;
7111  }
7112  {
7113  int jj;
7114 
7115  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7116  if ( !arg3 )
7117  SWIG_fail;
7118  arg4 = ii3;
7119  arg5 = jj;
7120  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7121  {
7122  lua_pushfstring( L, "Vectors must match matrix." );
7123  SWIG_fail;
7124  }
7125  }
7126  arg6 = (PLINT)lua_tonumber(L, 4);
7127  plmesh((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6);
7128 
7129  {
7130  LUA_FREE_ARRAY( arg1 );
7131  }
7132  {
7133  LUA_FREE_ARRAY( arg2 );
7134  }
7135  {
7136  int i;
7137 
7138  if ( arg3 )
7139  {
7140  for ( i = 0; i < ii3; i++ )
7141  LUA_FREE_ARRAY( arg3[i] );
7142  LUA_FREE_ARRAY( arg3 );
7143  }
7144  }
7145  return SWIG_arg;
7146 
7147  if(0) SWIG_fail;
7148 
7149 fail:
7150  {
7151  LUA_FREE_ARRAY( arg1 );
7152  }
7153  {
7154  LUA_FREE_ARRAY( arg2 );
7155  }
7156  {
7157  int i;
7158 
7159  if ( arg3 )
7160  {
7161  for ( i = 0; i < ii3; i++ )
7162  LUA_FREE_ARRAY( arg3[i] );
7163  LUA_FREE_ARRAY( arg3 );
7164  }
7165  }
7166  lua_error(L);
7167  return SWIG_arg;
7168 }
7169 
7170 
7171 static int _wrap_meshc(lua_State* L) {
7172  int SWIG_arg = 0;
7173  PLFLT *arg1 = (PLFLT *) 0 ;
7174  PLFLT *arg2 = (PLFLT *) 0 ;
7175  PLFLT **arg3 = (PLFLT **) 0 ;
7176  PLINT arg4 ;
7177  PLINT arg5 ;
7178  PLINT arg6 ;
7179  PLFLT *arg7 = (PLFLT *) 0 ;
7180  PLINT arg8 ;
7181  int ii3 ;
7182 
7183  SWIG_check_num_args("plmeshc",5,5)
7184  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmeshc",4,"PLINT");
7185  {
7186  int temp;
7187  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7188  if ( !arg1 )
7189  SWIG_fail;
7190  Xlen = temp;
7191  }
7192  {
7193  int temp;
7194  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7195  if ( !arg2 )
7196  SWIG_fail;
7197  Ylen = temp;
7198  }
7199  {
7200  int jj;
7201 
7202  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7203  if ( !arg3 )
7204  SWIG_fail;
7205  arg4 = ii3;
7206  arg5 = jj;
7207  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7208  {
7209  lua_pushfstring( L, "Vectors must match matrix." );
7210  SWIG_fail;
7211  }
7212  }
7213  arg6 = (PLINT)lua_tonumber(L, 4);
7214  {
7215  int temp;
7216  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
7217  if ( !arg7 )
7218  SWIG_fail;
7219  arg8 = Alen = temp;
7220  }
7221  plmeshc((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8);
7222 
7223  {
7224  LUA_FREE_ARRAY( arg1 );
7225  }
7226  {
7227  LUA_FREE_ARRAY( arg2 );
7228  }
7229  {
7230  int i;
7231 
7232  if ( arg3 )
7233  {
7234  for ( i = 0; i < ii3; i++ )
7235  LUA_FREE_ARRAY( arg3[i] );
7236  LUA_FREE_ARRAY( arg3 );
7237  }
7238  }
7239  {
7240  LUA_FREE_ARRAY( arg7 );
7241  }
7242  return SWIG_arg;
7243 
7244  if(0) SWIG_fail;
7245 
7246 fail:
7247  {
7248  LUA_FREE_ARRAY( arg1 );
7249  }
7250  {
7251  LUA_FREE_ARRAY( arg2 );
7252  }
7253  {
7254  int i;
7255 
7256  if ( arg3 )
7257  {
7258  for ( i = 0; i < ii3; i++ )
7259  LUA_FREE_ARRAY( arg3[i] );
7260  LUA_FREE_ARRAY( arg3 );
7261  }
7262  }
7263  {
7264  LUA_FREE_ARRAY( arg7 );
7265  }
7266  lua_error(L);
7267  return SWIG_arg;
7268 }
7269 
7270 
7271 static int _wrap_mkstrm(lua_State* L) {
7272  int SWIG_arg = 0;
7273  PLINT *arg1 = (PLINT *) 0 ;
7274  PLINT temp1 ;
7275 
7276  arg1 = &temp1;
7277  SWIG_check_num_args("plmkstrm",0,0)
7278  plmkstrm(arg1);
7279 
7280  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
7281  return SWIG_arg;
7282 
7283  if(0) SWIG_fail;
7284 
7285 fail:
7286  lua_error(L);
7287  return SWIG_arg;
7288 }
7289 
7290 
7291 static int _wrap_mtex(lua_State* L) {
7292  int SWIG_arg = 0;
7293  char *arg1 = (char *) 0 ;
7294  PLFLT arg2 ;
7295  PLFLT arg3 ;
7296  PLFLT arg4 ;
7297  char *arg5 = (char *) 0 ;
7298 
7299  SWIG_check_num_args("plmtex",5,5)
7300  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plmtex",1,"char const *");
7301  if(!lua_isnumber(L,2)) SWIG_fail_arg("plmtex",2,"PLFLT");
7302  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmtex",3,"PLFLT");
7303  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmtex",4,"PLFLT");
7304  if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("plmtex",5,"char const *");
7305  arg1 = (char *)lua_tostring(L, 1);
7306  arg2 = (PLFLT)lua_tonumber(L, 2);
7307  arg3 = (PLFLT)lua_tonumber(L, 3);
7308  arg4 = (PLFLT)lua_tonumber(L, 4);
7309  arg5 = (char *)lua_tostring(L, 5);
7310  plmtex((char const *)arg1,arg2,arg3,arg4,(char const *)arg5);
7311 
7312  return SWIG_arg;
7313 
7314  if(0) SWIG_fail;
7315 
7316 fail:
7317  lua_error(L);
7318  return SWIG_arg;
7319 }
7320 
7321 
7322 static int _wrap_mtex3(lua_State* L) {
7323  int SWIG_arg = 0;
7324  char *arg1 = (char *) 0 ;
7325  PLFLT arg2 ;
7326  PLFLT arg3 ;
7327  PLFLT arg4 ;
7328  char *arg5 = (char *) 0 ;
7329 
7330  SWIG_check_num_args("plmtex3",5,5)
7331  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plmtex3",1,"char const *");
7332  if(!lua_isnumber(L,2)) SWIG_fail_arg("plmtex3",2,"PLFLT");
7333  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmtex3",3,"PLFLT");
7334  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmtex3",4,"PLFLT");
7335  if(!SWIG_lua_isnilstring(L,5)) SWIG_fail_arg("plmtex3",5,"char const *");
7336  arg1 = (char *)lua_tostring(L, 1);
7337  arg2 = (PLFLT)lua_tonumber(L, 2);
7338  arg3 = (PLFLT)lua_tonumber(L, 3);
7339  arg4 = (PLFLT)lua_tonumber(L, 4);
7340  arg5 = (char *)lua_tostring(L, 5);
7341  plmtex3((char const *)arg1,arg2,arg3,arg4,(char const *)arg5);
7342 
7343  return SWIG_arg;
7344 
7345  if(0) SWIG_fail;
7346 
7347 fail:
7348  lua_error(L);
7349  return SWIG_arg;
7350 }
7351 
7352 
7353 static int _wrap_plot3d(lua_State* L) {
7354  int SWIG_arg = 0;
7355  PLFLT *arg1 = (PLFLT *) 0 ;
7356  PLFLT *arg2 = (PLFLT *) 0 ;
7357  PLFLT **arg3 = (PLFLT **) 0 ;
7358  PLINT arg4 ;
7359  PLINT arg5 ;
7360  PLINT arg6 ;
7361  PLBOOL arg7 ;
7362  int ii3 ;
7363 
7364  SWIG_check_num_args("plot3d",5,5)
7365  if(!lua_isnumber(L,4)) SWIG_fail_arg("plot3d",4,"PLINT");
7366  if(!lua_isnumber(L,5)) SWIG_fail_arg("plot3d",5,"PLBOOL");
7367  {
7368  int temp;
7369  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7370  if ( !arg1 )
7371  SWIG_fail;
7372  Xlen = temp;
7373  }
7374  {
7375  int temp;
7376  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7377  if ( !arg2 )
7378  SWIG_fail;
7379  Ylen = temp;
7380  }
7381  {
7382  int jj;
7383 
7384  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7385  if ( !arg3 )
7386  SWIG_fail;
7387  arg4 = ii3;
7388  arg5 = jj;
7389  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7390  {
7391  lua_pushfstring( L, "Vectors must match matrix." );
7392  SWIG_fail;
7393  }
7394  }
7395  arg6 = (PLINT)lua_tonumber(L, 4);
7396  arg7 = (PLBOOL)lua_tonumber(L, 5);
7397  plot3d((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,arg7);
7398 
7399  {
7400  LUA_FREE_ARRAY( arg1 );
7401  }
7402  {
7403  LUA_FREE_ARRAY( arg2 );
7404  }
7405  {
7406  int i;
7407 
7408  if ( arg3 )
7409  {
7410  for ( i = 0; i < ii3; i++ )
7411  LUA_FREE_ARRAY( arg3[i] );
7412  LUA_FREE_ARRAY( arg3 );
7413  }
7414  }
7415  return SWIG_arg;
7416 
7417  if(0) SWIG_fail;
7418 
7419 fail:
7420  {
7421  LUA_FREE_ARRAY( arg1 );
7422  }
7423  {
7424  LUA_FREE_ARRAY( arg2 );
7425  }
7426  {
7427  int i;
7428 
7429  if ( arg3 )
7430  {
7431  for ( i = 0; i < ii3; i++ )
7432  LUA_FREE_ARRAY( arg3[i] );
7433  LUA_FREE_ARRAY( arg3 );
7434  }
7435  }
7436  lua_error(L);
7437  return SWIG_arg;
7438 }
7439 
7440 
7441 static int _wrap_plot3dc(lua_State* L) {
7442  int SWIG_arg = 0;
7443  PLFLT *arg1 = (PLFLT *) 0 ;
7444  PLFLT *arg2 = (PLFLT *) 0 ;
7445  PLFLT **arg3 = (PLFLT **) 0 ;
7446  PLINT arg4 ;
7447  PLINT arg5 ;
7448  PLINT arg6 ;
7449  PLFLT *arg7 = (PLFLT *) 0 ;
7450  PLINT arg8 ;
7451  int ii3 ;
7452 
7453  SWIG_check_num_args("plot3dc",5,5)
7454  if(!lua_isnumber(L,4)) SWIG_fail_arg("plot3dc",4,"PLINT");
7455  {
7456  int temp;
7457  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7458  if ( !arg1 )
7459  SWIG_fail;
7460  Xlen = temp;
7461  }
7462  {
7463  int temp;
7464  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7465  if ( !arg2 )
7466  SWIG_fail;
7467  Ylen = temp;
7468  }
7469  {
7470  int jj;
7471 
7472  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7473  if ( !arg3 )
7474  SWIG_fail;
7475  arg4 = ii3;
7476  arg5 = jj;
7477  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7478  {
7479  lua_pushfstring( L, "Vectors must match matrix." );
7480  SWIG_fail;
7481  }
7482  }
7483  arg6 = (PLINT)lua_tonumber(L, 4);
7484  {
7485  int temp;
7486  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
7487  if ( !arg7 )
7488  SWIG_fail;
7489  arg8 = Alen = temp;
7490  }
7491  plot3dc((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8);
7492 
7493  {
7494  LUA_FREE_ARRAY( arg1 );
7495  }
7496  {
7497  LUA_FREE_ARRAY( arg2 );
7498  }
7499  {
7500  int i;
7501 
7502  if ( arg3 )
7503  {
7504  for ( i = 0; i < ii3; i++ )
7505  LUA_FREE_ARRAY( arg3[i] );
7506  LUA_FREE_ARRAY( arg3 );
7507  }
7508  }
7509  {
7510  LUA_FREE_ARRAY( arg7 );
7511  }
7512  return SWIG_arg;
7513 
7514  if(0) SWIG_fail;
7515 
7516 fail:
7517  {
7518  LUA_FREE_ARRAY( arg1 );
7519  }
7520  {
7521  LUA_FREE_ARRAY( arg2 );
7522  }
7523  {
7524  int i;
7525 
7526  if ( arg3 )
7527  {
7528  for ( i = 0; i < ii3; i++ )
7529  LUA_FREE_ARRAY( arg3[i] );
7530  LUA_FREE_ARRAY( arg3 );
7531  }
7532  }
7533  {
7534  LUA_FREE_ARRAY( arg7 );
7535  }
7536  lua_error(L);
7537  return SWIG_arg;
7538 }
7539 
7540 
7541 static int _wrap_plot3dcl(lua_State* L) {
7542  int SWIG_arg = 0;
7543  PLFLT *arg1 = (PLFLT *) 0 ;
7544  PLFLT *arg2 = (PLFLT *) 0 ;
7545  PLFLT **arg3 = (PLFLT **) 0 ;
7546  PLINT arg4 ;
7547  PLINT arg5 ;
7548  PLINT arg6 ;
7549  PLFLT *arg7 = (PLFLT *) 0 ;
7550  PLINT arg8 ;
7551  PLINT arg9 ;
7552  PLINT arg10 ;
7553  PLINT *arg11 = (PLINT *) 0 ;
7554  PLINT *arg12 = (PLINT *) 0 ;
7555  int ii3 ;
7556  int temp12 ;
7557 
7558  SWIG_check_num_args("plot3dcl",8,8)
7559  if(!lua_isnumber(L,4)) SWIG_fail_arg("plot3dcl",4,"PLINT");
7560  if(!lua_isnumber(L,6)) SWIG_fail_arg("plot3dcl",6,"PLINT");
7561  {
7562  int temp;
7563  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7564  if ( !arg1 )
7565  SWIG_fail;
7566  Xlen = temp;
7567  }
7568  {
7569  int temp;
7570  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7571  if ( !arg2 )
7572  SWIG_fail;
7573  Ylen = temp;
7574  }
7575  {
7576  int jj;
7577 
7578  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7579  if ( !arg3 )
7580  SWIG_fail;
7581  arg4 = ii3;
7582  arg5 = jj;
7583  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7584  {
7585  lua_pushfstring( L, "Vectors must match matrix." );
7586  SWIG_fail;
7587  }
7588  }
7589  arg6 = (PLINT)lua_tonumber(L, 4);
7590  {
7591  int temp;
7592  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
7593  if ( !arg7 )
7594  SWIG_fail;
7595  arg8 = Alen = temp;
7596  }
7597  arg9 = (PLINT)lua_tonumber(L, 6);
7598  {
7599  arg11 = (PLINT *) LUA_get_int_num_array_var( L, 7, &arg10 );
7600  if ( !arg11 )
7601  SWIG_fail;
7602  Alen = arg10;
7603  }
7604  {
7605  arg12 = (PLINT *) LUA_get_int_num_array_var( L, 8, &temp12 );
7606  if ( !arg12 )
7607  SWIG_fail;
7608  if ( temp12 != Alen )
7609  {
7610  lua_pushfstring( L, "Tables must be of same length." );
7611  SWIG_fail;
7612  }
7613  }
7614  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);
7615 
7616  {
7617  LUA_FREE_ARRAY( arg1 );
7618  }
7619  {
7620  LUA_FREE_ARRAY( arg2 );
7621  }
7622  {
7623  int i;
7624 
7625  if ( arg3 )
7626  {
7627  for ( i = 0; i < ii3; i++ )
7628  LUA_FREE_ARRAY( arg3[i] );
7629  LUA_FREE_ARRAY( arg3 );
7630  }
7631  }
7632  {
7633  LUA_FREE_ARRAY( arg7 );
7634  }
7635  {
7636  LUA_FREE_ARRAY( arg11 );
7637  }
7638  {
7639  LUA_FREE_ARRAY( arg12 );
7640  }
7641  return SWIG_arg;
7642 
7643  if(0) SWIG_fail;
7644 
7645 fail:
7646  {
7647  LUA_FREE_ARRAY( arg1 );
7648  }
7649  {
7650  LUA_FREE_ARRAY( arg2 );
7651  }
7652  {
7653  int i;
7654 
7655  if ( arg3 )
7656  {
7657  for ( i = 0; i < ii3; i++ )
7658  LUA_FREE_ARRAY( arg3[i] );
7659  LUA_FREE_ARRAY( arg3 );
7660  }
7661  }
7662  {
7663  LUA_FREE_ARRAY( arg7 );
7664  }
7665  {
7666  LUA_FREE_ARRAY( arg11 );
7667  }
7668  {
7669  LUA_FREE_ARRAY( arg12 );
7670  }
7671  lua_error(L);
7672  return SWIG_arg;
7673 }
7674 
7675 
7676 static int _wrap_surf3d(lua_State* L) {
7677  int SWIG_arg = 0;
7678  PLFLT *arg1 = (PLFLT *) 0 ;
7679  PLFLT *arg2 = (PLFLT *) 0 ;
7680  PLFLT **arg3 = (PLFLT **) 0 ;
7681  PLINT arg4 ;
7682  PLINT arg5 ;
7683  PLINT arg6 ;
7684  PLFLT *arg7 = (PLFLT *) 0 ;
7685  PLINT arg8 ;
7686  int ii3 ;
7687 
7688  SWIG_check_num_args("plsurf3d",5,5)
7689  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsurf3d",4,"PLINT");
7690  {
7691  int temp;
7692  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7693  if ( !arg1 )
7694  SWIG_fail;
7695  Xlen = temp;
7696  }
7697  {
7698  int temp;
7699  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7700  if ( !arg2 )
7701  SWIG_fail;
7702  Ylen = temp;
7703  }
7704  {
7705  int jj;
7706 
7707  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7708  if ( !arg3 )
7709  SWIG_fail;
7710  arg4 = ii3;
7711  arg5 = jj;
7712  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7713  {
7714  lua_pushfstring( L, "Vectors must match matrix." );
7715  SWIG_fail;
7716  }
7717  }
7718  arg6 = (PLINT)lua_tonumber(L, 4);
7719  {
7720  int temp;
7721  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
7722  if ( !arg7 )
7723  SWIG_fail;
7724  arg8 = Alen = temp;
7725  }
7726  plsurf3d((double const *)arg1,(double const *)arg2,(double const **)arg3,arg4,arg5,arg6,(double const *)arg7,arg8);
7727 
7728  {
7729  LUA_FREE_ARRAY( arg1 );
7730  }
7731  {
7732  LUA_FREE_ARRAY( arg2 );
7733  }
7734  {
7735  int i;
7736 
7737  if ( arg3 )
7738  {
7739  for ( i = 0; i < ii3; i++ )
7740  LUA_FREE_ARRAY( arg3[i] );
7741  LUA_FREE_ARRAY( arg3 );
7742  }
7743  }
7744  {
7745  LUA_FREE_ARRAY( arg7 );
7746  }
7747  return SWIG_arg;
7748 
7749  if(0) SWIG_fail;
7750 
7751 fail:
7752  {
7753  LUA_FREE_ARRAY( arg1 );
7754  }
7755  {
7756  LUA_FREE_ARRAY( arg2 );
7757  }
7758  {
7759  int i;
7760 
7761  if ( arg3 )
7762  {
7763  for ( i = 0; i < ii3; i++ )
7764  LUA_FREE_ARRAY( arg3[i] );
7765  LUA_FREE_ARRAY( arg3 );
7766  }
7767  }
7768  {
7769  LUA_FREE_ARRAY( arg7 );
7770  }
7771  lua_error(L);
7772  return SWIG_arg;
7773 }
7774 
7775 
7776 static int _wrap_surf3dl(lua_State* L) {
7777  int SWIG_arg = 0;
7778  PLFLT *arg1 = (PLFLT *) 0 ;
7779  PLFLT *arg2 = (PLFLT *) 0 ;
7780  PLFLT **arg3 = (PLFLT **) 0 ;
7781  PLINT arg4 ;
7782  PLINT arg5 ;
7783  PLINT arg6 ;
7784  PLFLT *arg7 = (PLFLT *) 0 ;
7785  PLINT arg8 ;
7786  PLINT arg9 ;
7787  PLINT arg10 ;
7788  PLINT *arg11 = (PLINT *) 0 ;
7789  PLINT *arg12 = (PLINT *) 0 ;
7790  int ii3 ;
7791  int temp12 ;
7792 
7793  SWIG_check_num_args("plsurf3dl",8,8)
7794  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsurf3dl",4,"PLINT");
7795  if(!lua_isnumber(L,6)) SWIG_fail_arg("plsurf3dl",6,"PLINT");
7796  {
7797  int temp;
7798  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
7799  if ( !arg1 )
7800  SWIG_fail;
7801  Xlen = temp;
7802  }
7803  {
7804  int temp;
7805  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
7806  if ( !arg2 )
7807  SWIG_fail;
7808  Ylen = temp;
7809  }
7810  {
7811  int jj;
7812 
7813  arg3 = read_double_Matrix( L, 3, &ii3, &jj );
7814  if ( !arg3 )
7815  SWIG_fail;
7816  arg4 = ii3;
7817  arg5 = jj;
7818  if ( ( arg4 != Xlen ) || ( arg5 != Ylen ) )
7819  {
7820  lua_pushfstring( L, "Vectors must match matrix." );
7821  SWIG_fail;
7822  }
7823  }
7824  arg6 = (PLINT)lua_tonumber(L, 4);
7825  {
7826  int temp;
7827  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp );
7828  if ( !arg7 )
7829  SWIG_fail;
7830  arg8 = Alen = temp;
7831  }
7832  arg9 = (PLINT)lua_tonumber(L, 6);
7833  {
7834  arg11 = (PLINT *) LUA_get_int_num_array_var( L, 7, &arg10 );
7835  if ( !arg11 )
7836  SWIG_fail;
7837  Alen = arg10;
7838  }
7839  {
7840  arg12 = (PLINT *) LUA_get_int_num_array_var( L, 8, &temp12 );
7841  if ( !arg12 )
7842  SWIG_fail;
7843  if ( temp12 != Alen )
7844  {
7845  lua_pushfstring( L, "Tables must be of same length." );
7846  SWIG_fail;
7847  }
7848  }
7849  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);
7850 
7851  {
7852  LUA_FREE_ARRAY( arg1 );
7853  }
7854  {
7855  LUA_FREE_ARRAY( arg2 );
7856  }
7857  {
7858  int i;
7859 
7860  if ( arg3 )
7861  {
7862  for ( i = 0; i < ii3; i++ )
7863  LUA_FREE_ARRAY( arg3[i] );
7864  LUA_FREE_ARRAY( arg3 );
7865  }
7866  }
7867  {
7868  LUA_FREE_ARRAY( arg7 );
7869  }
7870  {
7871  LUA_FREE_ARRAY( arg11 );
7872  }
7873  {
7874  LUA_FREE_ARRAY( arg12 );
7875  }
7876  return SWIG_arg;
7877 
7878  if(0) SWIG_fail;
7879 
7880 fail:
7881  {
7882  LUA_FREE_ARRAY( arg1 );
7883  }
7884  {
7885  LUA_FREE_ARRAY( arg2 );
7886  }
7887  {
7888  int i;
7889 
7890  if ( arg3 )
7891  {
7892  for ( i = 0; i < ii3; i++ )
7893  LUA_FREE_ARRAY( arg3[i] );
7894  LUA_FREE_ARRAY( arg3 );
7895  }
7896  }
7897  {
7898  LUA_FREE_ARRAY( arg7 );
7899  }
7900  {
7901  LUA_FREE_ARRAY( arg11 );
7902  }
7903  {
7904  LUA_FREE_ARRAY( arg12 );
7905  }
7906  lua_error(L);
7907  return SWIG_arg;
7908 }
7909 
7910 
7911 static int _wrap_parseopts(lua_State* L) {
7912  int SWIG_arg = 0;
7913  int *arg1 = (int *) 0 ;
7914  char **arg2 = (char **) 0 ;
7915  PLINT arg3 ;
7916  PLINT result;
7917 
7918  SWIG_check_num_args("plparseopts",2,2)
7919  if(!lua_istable(L,1)) SWIG_fail_arg("plparseopts",1,"int *");
7920  if(!lua_isnumber(L,2)) SWIG_fail_arg("plparseopts",2,"PLINT");
7921  {
7922  int i, n;
7923 
7924  // from lua 5.1 on there is no element "n" anymore,
7925  // so we need to find out the number of command line
7926  // options manually
7927  for ( i = 1;; i++ )
7928  {
7929  lua_rawgeti( L, 1, i );
7930  if ( lua_isnil( L, -1 ) )
7931  {
7932  // ok, this index doesn't exist anymore, we have i-1
7933  // command line options
7934  lua_pop( L, 1 );
7935  break;
7936  }
7937  }
7938  n = i;
7939  arg1 = &n;
7940 
7941  arg2 = LUA_ALLOC_ARRAY( char*, ( n + 1 ) );
7942 
7943  for ( i = 0; i < n; i++ )
7944  {
7945  lua_rawgeti( L, 1, i );
7946  if ( lua_isstring( L, -1 ) )
7947  {
7948  arg2[i] = (char *) lua_tostring( L, -1 );
7949  }
7950  else
7951  {
7952  lua_pop( L, 1 );
7953  lua_pushfstring( L, "List items must be strings" );
7954  SWIG_fail;
7955  // arg2 array is freed after 'fail:'
7956  }
7957  lua_pop( L, 1 );
7958  }
7959  arg2[n] = NULL;
7960  }
7961  arg3 = (PLINT)lua_tonumber(L, 2);
7962  result = (PLINT)plparseopts(arg1,arg2,arg3);
7963  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
7964  {
7965  LUA_FREE_ARRAY( arg2 );
7966  }
7967  return SWIG_arg;
7968 
7969  if(0) SWIG_fail;
7970 
7971 fail:
7972  {
7973  LUA_FREE_ARRAY( arg2 );
7974  }
7975  lua_error(L);
7976  return SWIG_arg;
7977 }
7978 
7979 
7980 static int _wrap_pat(lua_State* L) {
7981  int SWIG_arg = 0;
7982  PLINT arg1 ;
7983  PLINT *arg2 = (PLINT *) 0 ;
7984  PLINT *arg3 = (PLINT *) 0 ;
7985  int temp3 ;
7986 
7987  SWIG_check_num_args("plpat",2,2)
7988  {
7989  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 1, &arg1 );
7990  if ( !arg2 )
7991  SWIG_fail;
7992  Alen = arg1;
7993  }
7994  {
7995  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp3 );
7996  if ( !arg3 )
7997  SWIG_fail;
7998  if ( temp3 != Alen )
7999  {
8000  lua_pushfstring( L, "Tables must be of same length." );
8001  SWIG_fail;
8002  }
8003  }
8004  plpat(arg1,(int const *)arg2,(int const *)arg3);
8005 
8006  {
8007  LUA_FREE_ARRAY( arg2 );
8008  }
8009  {
8010  LUA_FREE_ARRAY( arg3 );
8011  }
8012  return SWIG_arg;
8013 
8014  if(0) SWIG_fail;
8015 
8016 fail:
8017  {
8018  LUA_FREE_ARRAY( arg2 );
8019  }
8020  {
8021  LUA_FREE_ARRAY( arg3 );
8022  }
8023  lua_error(L);
8024  return SWIG_arg;
8025 }
8026 
8027 
8028 static int _wrap_path(lua_State* L) {
8029  int SWIG_arg = 0;
8030  PLINT arg1 ;
8031  PLFLT arg2 ;
8032  PLFLT arg3 ;
8033  PLFLT arg4 ;
8034  PLFLT arg5 ;
8035 
8036  SWIG_check_num_args("plpath",5,5)
8037  if(!lua_isnumber(L,1)) SWIG_fail_arg("plpath",1,"PLINT");
8038  if(!lua_isnumber(L,2)) SWIG_fail_arg("plpath",2,"PLFLT");
8039  if(!lua_isnumber(L,3)) SWIG_fail_arg("plpath",3,"PLFLT");
8040  if(!lua_isnumber(L,4)) SWIG_fail_arg("plpath",4,"PLFLT");
8041  if(!lua_isnumber(L,5)) SWIG_fail_arg("plpath",5,"PLFLT");
8042  arg1 = (PLINT)lua_tonumber(L, 1);
8043  arg2 = (PLFLT)lua_tonumber(L, 2);
8044  arg3 = (PLFLT)lua_tonumber(L, 3);
8045  arg4 = (PLFLT)lua_tonumber(L, 4);
8046  arg5 = (PLFLT)lua_tonumber(L, 5);
8047  plpath(arg1,arg2,arg3,arg4,arg5);
8048 
8049  return SWIG_arg;
8050 
8051  if(0) SWIG_fail;
8052 
8053 fail:
8054  lua_error(L);
8055  return SWIG_arg;
8056 }
8057 
8058 
8059 static int _wrap_poin(lua_State* L) {
8060  int SWIG_arg = 0;
8061  PLINT arg1 ;
8062  PLFLT *arg2 = (PLFLT *) 0 ;
8063  PLFLT *arg3 = (PLFLT *) 0 ;
8064  PLINT arg4 ;
8065  int temp3 ;
8066 
8067  SWIG_check_num_args("plpoin",3,3)
8068  if(!lua_isnumber(L,3)) SWIG_fail_arg("plpoin",3,"PLINT");
8069  {
8070  int temp;
8071  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
8072  if ( !arg2 )
8073  SWIG_fail;
8074  arg1 = Alen = temp;
8075  }
8076  {
8077  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
8078  if ( !arg3 )
8079  SWIG_fail;
8080  if ( temp3 != Alen )
8081  {
8082  lua_pushfstring( L, "Tables must be of same length." );
8083  SWIG_fail;
8084  }
8085  }
8086  arg4 = (PLINT)lua_tonumber(L, 3);
8087  plpoin(arg1,(double const *)arg2,(double const *)arg3,arg4);
8088 
8089  {
8090  LUA_FREE_ARRAY( arg2 );
8091  }
8092  {
8093  LUA_FREE_ARRAY( arg3 );
8094  }
8095  return SWIG_arg;
8096 
8097  if(0) SWIG_fail;
8098 
8099 fail:
8100  {
8101  LUA_FREE_ARRAY( arg2 );
8102  }
8103  {
8104  LUA_FREE_ARRAY( arg3 );
8105  }
8106  lua_error(L);
8107  return SWIG_arg;
8108 }
8109 
8110 
8111 static int _wrap_poin3(lua_State* L) {
8112  int SWIG_arg = 0;
8113  PLINT arg1 ;
8114  PLFLT *arg2 = (PLFLT *) 0 ;
8115  PLFLT *arg3 = (PLFLT *) 0 ;
8116  PLFLT *arg4 = (PLFLT *) 0 ;
8117  PLINT arg5 ;
8118  int temp3 ;
8119  int temp4 ;
8120 
8121  SWIG_check_num_args("plpoin3",4,4)
8122  if(!lua_isnumber(L,4)) SWIG_fail_arg("plpoin3",4,"PLINT");
8123  {
8124  int temp;
8125  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
8126  if ( !arg2 )
8127  SWIG_fail;
8128  arg1 = Alen = temp;
8129  }
8130  {
8131  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
8132  if ( !arg3 )
8133  SWIG_fail;
8134  if ( temp3 != Alen )
8135  {
8136  lua_pushfstring( L, "Tables must be of same length." );
8137  SWIG_fail;
8138  }
8139  }
8140  {
8141  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
8142  if ( !arg4 )
8143  SWIG_fail;
8144  if ( temp4 != Alen )
8145  {
8146  lua_pushfstring( L, "Tables must be of same length." );
8147  SWIG_fail;
8148  }
8149  }
8150  arg5 = (PLINT)lua_tonumber(L, 4);
8151  plpoin3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4,arg5);
8152 
8153  {
8154  LUA_FREE_ARRAY( arg2 );
8155  }
8156  {
8157  LUA_FREE_ARRAY( arg3 );
8158  }
8159  {
8160  LUA_FREE_ARRAY( arg4 );
8161  }
8162  return SWIG_arg;
8163 
8164  if(0) SWIG_fail;
8165 
8166 fail:
8167  {
8168  LUA_FREE_ARRAY( arg2 );
8169  }
8170  {
8171  LUA_FREE_ARRAY( arg3 );
8172  }
8173  {
8174  LUA_FREE_ARRAY( arg4 );
8175  }
8176  lua_error(L);
8177  return SWIG_arg;
8178 }
8179 
8180 
8181 static int _wrap_poly3(lua_State* L) {
8182  int SWIG_arg = 0;
8183  PLINT arg1 ;
8184  PLFLT *arg2 = (PLFLT *) 0 ;
8185  PLFLT *arg3 = (PLFLT *) 0 ;
8186  PLFLT *arg4 = (PLFLT *) 0 ;
8187  PLBOOL *arg5 = (PLBOOL *) 0 ;
8188  PLBOOL arg6 ;
8189  int temp3 ;
8190  int temp4 ;
8191  int temp5 ;
8192 
8193  SWIG_check_num_args("plpoly3",5,5)
8194  if(!lua_isnumber(L,5)) SWIG_fail_arg("plpoly3",5,"PLBOOL");
8195  {
8196  int temp;
8197  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
8198  if ( !arg2 )
8199  SWIG_fail;
8200  arg1 = Alen = temp;
8201  }
8202  {
8203  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
8204  if ( !arg3 )
8205  SWIG_fail;
8206  if ( temp3 != Alen )
8207  {
8208  lua_pushfstring( L, "Tables must be of same length." );
8209  SWIG_fail;
8210  }
8211  }
8212  {
8213  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
8214  if ( !arg4 )
8215  SWIG_fail;
8216  if ( temp4 != Alen )
8217  {
8218  lua_pushfstring( L, "Tables must be of same length." );
8219  SWIG_fail;
8220  }
8221  }
8222  {
8223  arg5 = (PLINT *) LUA_get_int_num_array_var( L, 4, &temp5 );
8224  if ( !arg5 )
8225  SWIG_fail;
8226  if ( temp5 < Alen - 1 )
8227  {
8228  lua_pushfstring( L, "Tables must be at least length of others minus 1." );
8229  SWIG_fail;
8230  }
8231  }
8232  arg6 = (PLBOOL)lua_tonumber(L, 5);
8233  plpoly3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4,(int const *)arg5,arg6);
8234 
8235  {
8236  LUA_FREE_ARRAY( arg2 );
8237  }
8238  {
8239  LUA_FREE_ARRAY( arg3 );
8240  }
8241  {
8242  LUA_FREE_ARRAY( arg4 );
8243  }
8244  {
8245  LUA_FREE_ARRAY( arg5 );
8246  }
8247  return SWIG_arg;
8248 
8249  if(0) SWIG_fail;
8250 
8251 fail:
8252  {
8253  LUA_FREE_ARRAY( arg2 );
8254  }
8255  {
8256  LUA_FREE_ARRAY( arg3 );
8257  }
8258  {
8259  LUA_FREE_ARRAY( arg4 );
8260  }
8261  {
8262  LUA_FREE_ARRAY( arg5 );
8263  }
8264  lua_error(L);
8265  return SWIG_arg;
8266 }
8267 
8268 
8269 static int _wrap_prec(lua_State* L) {
8270  int SWIG_arg = 0;
8271  PLINT arg1 ;
8272  PLINT arg2 ;
8273 
8274  SWIG_check_num_args("plprec",2,2)
8275  if(!lua_isnumber(L,1)) SWIG_fail_arg("plprec",1,"PLINT");
8276  if(!lua_isnumber(L,2)) SWIG_fail_arg("plprec",2,"PLINT");
8277  arg1 = (PLINT)lua_tonumber(L, 1);
8278  arg2 = (PLINT)lua_tonumber(L, 2);
8279  plprec(arg1,arg2);
8280 
8281  return SWIG_arg;
8282 
8283  if(0) SWIG_fail;
8284 
8285 fail:
8286  lua_error(L);
8287  return SWIG_arg;
8288 }
8289 
8290 
8291 static int _wrap_psty(lua_State* L) {
8292  int SWIG_arg = 0;
8293  PLINT arg1 ;
8294 
8295  SWIG_check_num_args("plpsty",1,1)
8296  if(!lua_isnumber(L,1)) SWIG_fail_arg("plpsty",1,"PLINT");
8297  arg1 = (PLINT)lua_tonumber(L, 1);
8298  plpsty(arg1);
8299 
8300  return SWIG_arg;
8301 
8302  if(0) SWIG_fail;
8303 
8304 fail:
8305  lua_error(L);
8306  return SWIG_arg;
8307 }
8308 
8309 
8310 static int _wrap_ptex(lua_State* L) {
8311  int SWIG_arg = 0;
8312  PLFLT arg1 ;
8313  PLFLT arg2 ;
8314  PLFLT arg3 ;
8315  PLFLT arg4 ;
8316  PLFLT arg5 ;
8317  char *arg6 = (char *) 0 ;
8318 
8319  SWIG_check_num_args("plptex",6,6)
8320  if(!lua_isnumber(L,1)) SWIG_fail_arg("plptex",1,"PLFLT");
8321  if(!lua_isnumber(L,2)) SWIG_fail_arg("plptex",2,"PLFLT");
8322  if(!lua_isnumber(L,3)) SWIG_fail_arg("plptex",3,"PLFLT");
8323  if(!lua_isnumber(L,4)) SWIG_fail_arg("plptex",4,"PLFLT");
8324  if(!lua_isnumber(L,5)) SWIG_fail_arg("plptex",5,"PLFLT");
8325  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plptex",6,"char const *");
8326  arg1 = (PLFLT)lua_tonumber(L, 1);
8327  arg2 = (PLFLT)lua_tonumber(L, 2);
8328  arg3 = (PLFLT)lua_tonumber(L, 3);
8329  arg4 = (PLFLT)lua_tonumber(L, 4);
8330  arg5 = (PLFLT)lua_tonumber(L, 5);
8331  arg6 = (char *)lua_tostring(L, 6);
8332  plptex(arg1,arg2,arg3,arg4,arg5,(char const *)arg6);
8333 
8334  return SWIG_arg;
8335 
8336  if(0) SWIG_fail;
8337 
8338 fail:
8339  lua_error(L);
8340  return SWIG_arg;
8341 }
8342 
8343 
8344 static int _wrap_ptex3(lua_State* L) {
8345  int SWIG_arg = 0;
8346  PLFLT arg1 ;
8347  PLFLT arg2 ;
8348  PLFLT arg3 ;
8349  PLFLT arg4 ;
8350  PLFLT arg5 ;
8351  PLFLT arg6 ;
8352  PLFLT arg7 ;
8353  PLFLT arg8 ;
8354  PLFLT arg9 ;
8355  PLFLT arg10 ;
8356  char *arg11 = (char *) 0 ;
8357 
8358  SWIG_check_num_args("plptex3",11,11)
8359  if(!lua_isnumber(L,1)) SWIG_fail_arg("plptex3",1,"PLFLT");
8360  if(!lua_isnumber(L,2)) SWIG_fail_arg("plptex3",2,"PLFLT");
8361  if(!lua_isnumber(L,3)) SWIG_fail_arg("plptex3",3,"PLFLT");
8362  if(!lua_isnumber(L,4)) SWIG_fail_arg("plptex3",4,"PLFLT");
8363  if(!lua_isnumber(L,5)) SWIG_fail_arg("plptex3",5,"PLFLT");
8364  if(!lua_isnumber(L,6)) SWIG_fail_arg("plptex3",6,"PLFLT");
8365  if(!lua_isnumber(L,7)) SWIG_fail_arg("plptex3",7,"PLFLT");
8366  if(!lua_isnumber(L,8)) SWIG_fail_arg("plptex3",8,"PLFLT");
8367  if(!lua_isnumber(L,9)) SWIG_fail_arg("plptex3",9,"PLFLT");
8368  if(!lua_isnumber(L,10)) SWIG_fail_arg("plptex3",10,"PLFLT");
8369  if(!SWIG_lua_isnilstring(L,11)) SWIG_fail_arg("plptex3",11,"char const *");
8370  arg1 = (PLFLT)lua_tonumber(L, 1);
8371  arg2 = (PLFLT)lua_tonumber(L, 2);
8372  arg3 = (PLFLT)lua_tonumber(L, 3);
8373  arg4 = (PLFLT)lua_tonumber(L, 4);
8374  arg5 = (PLFLT)lua_tonumber(L, 5);
8375  arg6 = (PLFLT)lua_tonumber(L, 6);
8376  arg7 = (PLFLT)lua_tonumber(L, 7);
8377  arg8 = (PLFLT)lua_tonumber(L, 8);
8378  arg9 = (PLFLT)lua_tonumber(L, 9);
8379  arg10 = (PLFLT)lua_tonumber(L, 10);
8380  arg11 = (char *)lua_tostring(L, 11);
8381  plptex3(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(char const *)arg11);
8382 
8383  return SWIG_arg;
8384 
8385  if(0) SWIG_fail;
8386 
8387 fail:
8388  lua_error(L);
8389  return SWIG_arg;
8390 }
8391 
8392 
8393 static int _wrap_randd(lua_State* L) {
8394  int SWIG_arg = 0;
8395  PLFLT result;
8396 
8397  SWIG_check_num_args("plrandd",0,0)
8398  result = (PLFLT)plrandd();
8399  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
8400  return SWIG_arg;
8401 
8402  if(0) SWIG_fail;
8403 
8404 fail:
8405  lua_error(L);
8406  return SWIG_arg;
8407 }
8408 
8409 
8410 static int _wrap_replot(lua_State* L) {
8411  int SWIG_arg = 0;
8412 
8413  SWIG_check_num_args("plreplot",0,0)
8414  plreplot();
8415 
8416  return SWIG_arg;
8417 
8418  if(0) SWIG_fail;
8419 
8420 fail:
8421  lua_error(L);
8422  return SWIG_arg;
8423 }
8424 
8425 
8426 static int _wrap_rgbhls(lua_State* L) {
8427  int SWIG_arg = 0;
8428  PLFLT arg1 ;
8429  PLFLT arg2 ;
8430  PLFLT arg3 ;
8431  PLFLT *arg4 = (PLFLT *) 0 ;
8432  PLFLT *arg5 = (PLFLT *) 0 ;
8433  PLFLT *arg6 = (PLFLT *) 0 ;
8434  PLFLT temp4 ;
8435  PLFLT temp5 ;
8436  PLFLT temp6 ;
8437 
8438  arg4 = &temp4;
8439  arg5 = &temp5;
8440  arg6 = &temp6;
8441  SWIG_check_num_args("plrgbhls",3,3)
8442  if(!lua_isnumber(L,1)) SWIG_fail_arg("plrgbhls",1,"PLFLT");
8443  if(!lua_isnumber(L,2)) SWIG_fail_arg("plrgbhls",2,"PLFLT");
8444  if(!lua_isnumber(L,3)) SWIG_fail_arg("plrgbhls",3,"PLFLT");
8445  arg1 = (PLFLT)lua_tonumber(L, 1);
8446  arg2 = (PLFLT)lua_tonumber(L, 2);
8447  arg3 = (PLFLT)lua_tonumber(L, 3);
8448  plrgbhls(arg1,arg2,arg3,arg4,arg5,arg6);
8449 
8450  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
8451  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
8452  lua_pushnumber(L, (lua_Number) *arg6); SWIG_arg++;
8453  return SWIG_arg;
8454 
8455  if(0) SWIG_fail;
8456 
8457 fail:
8458  lua_error(L);
8459  return SWIG_arg;
8460 }
8461 
8462 
8463 static int _wrap_schr(lua_State* L) {
8464  int SWIG_arg = 0;
8465  PLFLT arg1 ;
8466  PLFLT arg2 ;
8467 
8468  SWIG_check_num_args("plschr",2,2)
8469  if(!lua_isnumber(L,1)) SWIG_fail_arg("plschr",1,"PLFLT");
8470  if(!lua_isnumber(L,2)) SWIG_fail_arg("plschr",2,"PLFLT");
8471  arg1 = (PLFLT)lua_tonumber(L, 1);
8472  arg2 = (PLFLT)lua_tonumber(L, 2);
8473  plschr(arg1,arg2);
8474 
8475  return SWIG_arg;
8476 
8477  if(0) SWIG_fail;
8478 
8479 fail:
8480  lua_error(L);
8481  return SWIG_arg;
8482 }
8483 
8484 
8485 static int _wrap_scmap0(lua_State* L) {
8486  int SWIG_arg = 0;
8487  PLINT *arg1 = (PLINT *) 0 ;
8488  PLINT *arg2 = (PLINT *) 0 ;
8489  PLINT *arg3 = (PLINT *) 0 ;
8490  PLINT arg4 ;
8491  int temp1 ;
8492  int temp2 ;
8493  int temp3 ;
8494 
8495  SWIG_check_num_args("plscmap0",3,3)
8496  {
8497  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
8498  if ( !arg1 )
8499  SWIG_fail;
8500  Alen = temp1;
8501  }
8502  {
8503  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
8504  if ( !arg2 )
8505  SWIG_fail;
8506  if ( temp2 != Alen )
8507  {
8508  lua_pushfstring( L, "Tables must be of same length." );
8509  SWIG_fail;
8510  }
8511  }
8512  {
8513  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
8514  if ( !arg3 )
8515  SWIG_fail;
8516  if ( temp3 != Alen )
8517  {
8518  lua_pushfstring( L, "Tables must be of same length." );
8519  SWIG_fail;
8520  }
8521  arg4 = temp3;
8522  }
8523  plscmap0((int const *)arg1,(int const *)arg2,(int const *)arg3,arg4);
8524 
8525  {
8526  LUA_FREE_ARRAY( arg1 );
8527  }
8528  {
8529  LUA_FREE_ARRAY( arg2 );
8530  }
8531  {
8532  LUA_FREE_ARRAY( arg3 );
8533  }
8534  return SWIG_arg;
8535 
8536  if(0) SWIG_fail;
8537 
8538 fail:
8539  {
8540  LUA_FREE_ARRAY( arg1 );
8541  }
8542  {
8543  LUA_FREE_ARRAY( arg2 );
8544  }
8545  {
8546  LUA_FREE_ARRAY( arg3 );
8547  }
8548  lua_error(L);
8549  return SWIG_arg;
8550 }
8551 
8552 
8553 static int _wrap_scmap0a(lua_State* L) {
8554  int SWIG_arg = 0;
8555  PLINT *arg1 = (PLINT *) 0 ;
8556  PLINT *arg2 = (PLINT *) 0 ;
8557  PLINT *arg3 = (PLINT *) 0 ;
8558  PLFLT *arg4 = (PLFLT *) 0 ;
8559  PLINT arg5 ;
8560  int temp1 ;
8561  int temp2 ;
8562  int temp3 ;
8563 
8564  SWIG_check_num_args("plscmap0a",4,4)
8565  {
8566  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
8567  if ( !arg1 )
8568  SWIG_fail;
8569  Alen = temp1;
8570  }
8571  {
8572  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
8573  if ( !arg2 )
8574  SWIG_fail;
8575  if ( temp2 != Alen )
8576  {
8577  lua_pushfstring( L, "Tables must be of same length." );
8578  SWIG_fail;
8579  }
8580  }
8581  {
8582  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
8583  if ( !arg3 )
8584  SWIG_fail;
8585  if ( temp3 != Alen )
8586  {
8587  lua_pushfstring( L, "Tables must be of same length." );
8588  SWIG_fail;
8589  }
8590  }
8591  {
8592  int temp;
8593  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp );
8594  if ( !arg4 )
8595  SWIG_fail;
8596  if ( temp != Alen )
8597  {
8598  lua_pushfstring( L, "Tables must be of same length." );
8599  SWIG_fail;
8600  }
8601  arg5 = temp;
8602  }
8603  plscmap0a((int const *)arg1,(int const *)arg2,(int const *)arg3,(double const *)arg4,arg5);
8604 
8605  {
8606  LUA_FREE_ARRAY( arg1 );
8607  }
8608  {
8609  LUA_FREE_ARRAY( arg2 );
8610  }
8611  {
8612  LUA_FREE_ARRAY( arg3 );
8613  }
8614  {
8615  LUA_FREE_ARRAY( arg4 );
8616  }
8617  return SWIG_arg;
8618 
8619  if(0) SWIG_fail;
8620 
8621 fail:
8622  {
8623  LUA_FREE_ARRAY( arg1 );
8624  }
8625  {
8626  LUA_FREE_ARRAY( arg2 );
8627  }
8628  {
8629  LUA_FREE_ARRAY( arg3 );
8630  }
8631  {
8632  LUA_FREE_ARRAY( arg4 );
8633  }
8634  lua_error(L);
8635  return SWIG_arg;
8636 }
8637 
8638 
8639 static int _wrap_scmap0n(lua_State* L) {
8640  int SWIG_arg = 0;
8641  PLINT arg1 ;
8642 
8643  SWIG_check_num_args("plscmap0n",1,1)
8644  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap0n",1,"PLINT");
8645  arg1 = (PLINT)lua_tonumber(L, 1);
8646  plscmap0n(arg1);
8647 
8648  return SWIG_arg;
8649 
8650  if(0) SWIG_fail;
8651 
8652 fail:
8653  lua_error(L);
8654  return SWIG_arg;
8655 }
8656 
8657 
8658 static int _wrap_scmap1(lua_State* L) {
8659  int SWIG_arg = 0;
8660  PLINT *arg1 = (PLINT *) 0 ;
8661  PLINT *arg2 = (PLINT *) 0 ;
8662  PLINT *arg3 = (PLINT *) 0 ;
8663  PLINT arg4 ;
8664  int temp1 ;
8665  int temp2 ;
8666  int temp3 ;
8667 
8668  SWIG_check_num_args("plscmap1",3,3)
8669  {
8670  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
8671  if ( !arg1 )
8672  SWIG_fail;
8673  Alen = temp1;
8674  }
8675  {
8676  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
8677  if ( !arg2 )
8678  SWIG_fail;
8679  if ( temp2 != Alen )
8680  {
8681  lua_pushfstring( L, "Tables must be of same length." );
8682  SWIG_fail;
8683  }
8684  }
8685  {
8686  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
8687  if ( !arg3 )
8688  SWIG_fail;
8689  if ( temp3 != Alen )
8690  {
8691  lua_pushfstring( L, "Tables must be of same length." );
8692  SWIG_fail;
8693  }
8694  arg4 = temp3;
8695  }
8696  plscmap1((int const *)arg1,(int const *)arg2,(int const *)arg3,arg4);
8697 
8698  {
8699  LUA_FREE_ARRAY( arg1 );
8700  }
8701  {
8702  LUA_FREE_ARRAY( arg2 );
8703  }
8704  {
8705  LUA_FREE_ARRAY( arg3 );
8706  }
8707  return SWIG_arg;
8708 
8709  if(0) SWIG_fail;
8710 
8711 fail:
8712  {
8713  LUA_FREE_ARRAY( arg1 );
8714  }
8715  {
8716  LUA_FREE_ARRAY( arg2 );
8717  }
8718  {
8719  LUA_FREE_ARRAY( arg3 );
8720  }
8721  lua_error(L);
8722  return SWIG_arg;
8723 }
8724 
8725 
8726 static int _wrap_scmap1a(lua_State* L) {
8727  int SWIG_arg = 0;
8728  PLINT *arg1 = (PLINT *) 0 ;
8729  PLINT *arg2 = (PLINT *) 0 ;
8730  PLINT *arg3 = (PLINT *) 0 ;
8731  PLFLT *arg4 = (PLFLT *) 0 ;
8732  PLINT arg5 ;
8733  int temp1 ;
8734  int temp2 ;
8735  int temp3 ;
8736 
8737  SWIG_check_num_args("plscmap1a",4,4)
8738  {
8739  arg1 = (PLINT *) LUA_get_int_num_array_var( L, 1, &temp1 );
8740  if ( !arg1 )
8741  SWIG_fail;
8742  Alen = temp1;
8743  }
8744  {
8745  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp2 );
8746  if ( !arg2 )
8747  SWIG_fail;
8748  if ( temp2 != Alen )
8749  {
8750  lua_pushfstring( L, "Tables must be of same length." );
8751  SWIG_fail;
8752  }
8753  }
8754  {
8755  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 3, &temp3 );
8756  if ( !arg3 )
8757  SWIG_fail;
8758  if ( temp3 != Alen )
8759  {
8760  lua_pushfstring( L, "Tables must be of same length." );
8761  SWIG_fail;
8762  }
8763  }
8764  {
8765  int temp;
8766  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp );
8767  if ( !arg4 )
8768  SWIG_fail;
8769  if ( temp != Alen )
8770  {
8771  lua_pushfstring( L, "Tables must be of same length." );
8772  SWIG_fail;
8773  }
8774  arg5 = temp;
8775  }
8776  plscmap1a((int const *)arg1,(int const *)arg2,(int const *)arg3,(double const *)arg4,arg5);
8777 
8778  {
8779  LUA_FREE_ARRAY( arg1 );
8780  }
8781  {
8782  LUA_FREE_ARRAY( arg2 );
8783  }
8784  {
8785  LUA_FREE_ARRAY( arg3 );
8786  }
8787  {
8788  LUA_FREE_ARRAY( arg4 );
8789  }
8790  return SWIG_arg;
8791 
8792  if(0) SWIG_fail;
8793 
8794 fail:
8795  {
8796  LUA_FREE_ARRAY( arg1 );
8797  }
8798  {
8799  LUA_FREE_ARRAY( arg2 );
8800  }
8801  {
8802  LUA_FREE_ARRAY( arg3 );
8803  }
8804  {
8805  LUA_FREE_ARRAY( arg4 );
8806  }
8807  lua_error(L);
8808  return SWIG_arg;
8809 }
8810 
8811 
8812 static int _wrap_scmap1l(lua_State* L) {
8813  int SWIG_arg = 0;
8814  PLBOOL arg1 ;
8815  PLINT arg2 ;
8816  PLFLT *arg3 = (PLFLT *) 0 ;
8817  PLFLT *arg4 = (PLFLT *) 0 ;
8818  PLFLT *arg5 = (PLFLT *) 0 ;
8819  PLFLT *arg6 = (PLFLT *) 0 ;
8820  PLBOOL *arg7 = (PLBOOL *) 0 ;
8821  int temp4 ;
8822  int temp5 ;
8823  int temp6 ;
8824  int temp7 ;
8825 
8826  {
8827  arg7 = NULL;
8828  }
8829  SWIG_check_num_args("plscmap1l",5,6)
8830  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1l",1,"PLBOOL");
8831  arg1 = (PLBOOL)lua_tonumber(L, 1);
8832  {
8833  int temp;
8834  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
8835  if ( !arg3 )
8836  SWIG_fail;
8837  arg2 = Alen = temp;
8838  }
8839  {
8840  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
8841  if ( !arg4 )
8842  SWIG_fail;
8843  if ( temp4 != Alen )
8844  {
8845  lua_pushfstring( L, "Tables must be of same length." );
8846  SWIG_fail;
8847  }
8848  }
8849  {
8850  arg5 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp5 );
8851  if ( !arg5 )
8852  SWIG_fail;
8853  if ( temp5 != Alen )
8854  {
8855  lua_pushfstring( L, "Tables must be of same length." );
8856  SWIG_fail;
8857  }
8858  }
8859  {
8860  arg6 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp6 );
8861  if ( !arg6 )
8862  SWIG_fail;
8863  if ( temp6 != Alen )
8864  {
8865  lua_pushfstring( L, "Tables must be of same length." );
8866  SWIG_fail;
8867  }
8868  }
8869  if(lua_gettop(L)>=6){
8870  {
8871  if ( lua_isnil( L, 6 ) )
8872  {
8873  arg7 = NULL;
8874  }
8875  else
8876  {
8877  arg7 = (PLINT *) LUA_get_int_num_array_var( L, 6, &temp7 );
8878  if ( !arg7 )
8879  SWIG_fail;
8880  if ( temp7 < Alen - 1 )
8881  {
8882  lua_pushfstring( L, "Tables must be at least length of others minus 1." );
8883  SWIG_fail;
8884  }
8885  }
8886  }
8887  }
8888  plscmap1l(arg1,arg2,(double const *)arg3,(double const *)arg4,(double const *)arg5,(double const *)arg6,(int const *)arg7);
8889 
8890  {
8891  LUA_FREE_ARRAY( arg3 );
8892  }
8893  {
8894  LUA_FREE_ARRAY( arg4 );
8895  }
8896  {
8897  LUA_FREE_ARRAY( arg5 );
8898  }
8899  {
8900  LUA_FREE_ARRAY( arg6 );
8901  }
8902  {
8903  LUA_FREE_ARRAY( arg7 );
8904  }
8905  return SWIG_arg;
8906 
8907  if(0) SWIG_fail;
8908 
8909 fail:
8910  {
8911  LUA_FREE_ARRAY( arg3 );
8912  }
8913  {
8914  LUA_FREE_ARRAY( arg4 );
8915  }
8916  {
8917  LUA_FREE_ARRAY( arg5 );
8918  }
8919  {
8920  LUA_FREE_ARRAY( arg6 );
8921  }
8922  {
8923  LUA_FREE_ARRAY( arg7 );
8924  }
8925  lua_error(L);
8926  return SWIG_arg;
8927 }
8928 
8929 
8930 static int _wrap_scmap1la(lua_State* L) {
8931  int SWIG_arg = 0;
8932  PLBOOL arg1 ;
8933  PLINT arg2 ;
8934  PLFLT *arg3 = (PLFLT *) 0 ;
8935  PLFLT *arg4 = (PLFLT *) 0 ;
8936  PLFLT *arg5 = (PLFLT *) 0 ;
8937  PLFLT *arg6 = (PLFLT *) 0 ;
8938  PLFLT *arg7 = (PLFLT *) 0 ;
8939  PLBOOL *arg8 = (PLBOOL *) 0 ;
8940  int temp4 ;
8941  int temp5 ;
8942  int temp6 ;
8943  int temp7 ;
8944  int temp8 ;
8945 
8946  {
8947  arg8 = NULL;
8948  }
8949  SWIG_check_num_args("plscmap1la",6,7)
8950  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1la",1,"PLBOOL");
8951  arg1 = (PLBOOL)lua_tonumber(L, 1);
8952  {
8953  int temp;
8954  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
8955  if ( !arg3 )
8956  SWIG_fail;
8957  arg2 = Alen = temp;
8958  }
8959  {
8960  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
8961  if ( !arg4 )
8962  SWIG_fail;
8963  if ( temp4 != Alen )
8964  {
8965  lua_pushfstring( L, "Tables must be of same length." );
8966  SWIG_fail;
8967  }
8968  }
8969  {
8970  arg5 = (PLFLT *) LUA_get_double_num_array_var( L, 4, &temp5 );
8971  if ( !arg5 )
8972  SWIG_fail;
8973  if ( temp5 != Alen )
8974  {
8975  lua_pushfstring( L, "Tables must be of same length." );
8976  SWIG_fail;
8977  }
8978  }
8979  {
8980  arg6 = (PLFLT *) LUA_get_double_num_array_var( L, 5, &temp6 );
8981  if ( !arg6 )
8982  SWIG_fail;
8983  if ( temp6 != Alen )
8984  {
8985  lua_pushfstring( L, "Tables must be of same length." );
8986  SWIG_fail;
8987  }
8988  }
8989  {
8990  arg7 = (PLFLT *) LUA_get_double_num_array_var( L, 6, &temp7 );
8991  if ( !arg7 )
8992  SWIG_fail;
8993  if ( temp7 != Alen )
8994  {
8995  lua_pushfstring( L, "Tables must be of same length." );
8996  SWIG_fail;
8997  }
8998  }
8999  if(lua_gettop(L)>=7){
9000  {
9001  if ( lua_isnil( L, 7 ) )
9002  {
9003  arg8 = NULL;
9004  }
9005  else
9006  {
9007  arg8 = (PLINT *) LUA_get_int_num_array_var( L, 7, &temp8 );
9008  if ( !arg8 )
9009  SWIG_fail;
9010  if ( temp8 < Alen - 1 )
9011  {
9012  lua_pushfstring( L, "Tables must be at least length of others minus 1." );
9013  SWIG_fail;
9014  }
9015  }
9016  }
9017  }
9018  plscmap1la(arg1,arg2,(double const *)arg3,(double const *)arg4,(double const *)arg5,(double const *)arg6,(double const *)arg7,(int const *)arg8);
9019 
9020  {
9021  LUA_FREE_ARRAY( arg3 );
9022  }
9023  {
9024  LUA_FREE_ARRAY( arg4 );
9025  }
9026  {
9027  LUA_FREE_ARRAY( arg5 );
9028  }
9029  {
9030  LUA_FREE_ARRAY( arg6 );
9031  }
9032  {
9033  LUA_FREE_ARRAY( arg7 );
9034  }
9035  {
9036  LUA_FREE_ARRAY( arg8 );
9037  }
9038  return SWIG_arg;
9039 
9040  if(0) SWIG_fail;
9041 
9042 fail:
9043  {
9044  LUA_FREE_ARRAY( arg3 );
9045  }
9046  {
9047  LUA_FREE_ARRAY( arg4 );
9048  }
9049  {
9050  LUA_FREE_ARRAY( arg5 );
9051  }
9052  {
9053  LUA_FREE_ARRAY( arg6 );
9054  }
9055  {
9056  LUA_FREE_ARRAY( arg7 );
9057  }
9058  {
9059  LUA_FREE_ARRAY( arg8 );
9060  }
9061  lua_error(L);
9062  return SWIG_arg;
9063 }
9064 
9065 
9066 static int _wrap_scmap1n(lua_State* L) {
9067  int SWIG_arg = 0;
9068  PLINT arg1 ;
9069 
9070  SWIG_check_num_args("plscmap1n",1,1)
9071  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1n",1,"PLINT");
9072  arg1 = (PLINT)lua_tonumber(L, 1);
9073  plscmap1n(arg1);
9074 
9075  return SWIG_arg;
9076 
9077  if(0) SWIG_fail;
9078 
9079 fail:
9080  lua_error(L);
9081  return SWIG_arg;
9082 }
9083 
9084 
9085 static int _wrap_scmap1_range(lua_State* L) {
9086  int SWIG_arg = 0;
9087  PLFLT arg1 ;
9088  PLFLT arg2 ;
9089 
9090  SWIG_check_num_args("plscmap1_range",2,2)
9091  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscmap1_range",1,"PLFLT");
9092  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscmap1_range",2,"PLFLT");
9093  arg1 = (PLFLT)lua_tonumber(L, 1);
9094  arg2 = (PLFLT)lua_tonumber(L, 2);
9095  plscmap1_range(arg1,arg2);
9096 
9097  return SWIG_arg;
9098 
9099  if(0) SWIG_fail;
9100 
9101 fail:
9102  lua_error(L);
9103  return SWIG_arg;
9104 }
9105 
9106 
9107 static int _wrap_gcmap1_range(lua_State* L) {
9108  int SWIG_arg = 0;
9109  PLFLT *arg1 = (PLFLT *) 0 ;
9110  PLFLT *arg2 = (PLFLT *) 0 ;
9111  PLFLT temp1 ;
9112  PLFLT temp2 ;
9113 
9114  arg1 = &temp1;
9115  arg2 = &temp2;
9116  SWIG_check_num_args("plgcmap1_range",0,0)
9117  plgcmap1_range(arg1,arg2);
9118 
9119  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
9120  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
9121  return SWIG_arg;
9122 
9123  if(0) SWIG_fail;
9124 
9125 fail:
9126  lua_error(L);
9127  return SWIG_arg;
9128 }
9129 
9130 
9131 static int _wrap_scol0(lua_State* L) {
9132  int SWIG_arg = 0;
9133  PLINT arg1 ;
9134  PLINT arg2 ;
9135  PLINT arg3 ;
9136  PLINT arg4 ;
9137 
9138  SWIG_check_num_args("plscol0",4,4)
9139  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscol0",1,"PLINT");
9140  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscol0",2,"PLINT");
9141  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscol0",3,"PLINT");
9142  if(!lua_isnumber(L,4)) SWIG_fail_arg("plscol0",4,"PLINT");
9143  arg1 = (PLINT)lua_tonumber(L, 1);
9144  arg2 = (PLINT)lua_tonumber(L, 2);
9145  arg3 = (PLINT)lua_tonumber(L, 3);
9146  arg4 = (PLINT)lua_tonumber(L, 4);
9147  plscol0(arg1,arg2,arg3,arg4);
9148 
9149  return SWIG_arg;
9150 
9151  if(0) SWIG_fail;
9152 
9153 fail:
9154  lua_error(L);
9155  return SWIG_arg;
9156 }
9157 
9158 
9159 static int _wrap_scol0a(lua_State* L) {
9160  int SWIG_arg = 0;
9161  PLINT arg1 ;
9162  PLINT arg2 ;
9163  PLINT arg3 ;
9164  PLINT arg4 ;
9165  PLFLT arg5 ;
9166 
9167  SWIG_check_num_args("plscol0a",5,5)
9168  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscol0a",1,"PLINT");
9169  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscol0a",2,"PLINT");
9170  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscol0a",3,"PLINT");
9171  if(!lua_isnumber(L,4)) SWIG_fail_arg("plscol0a",4,"PLINT");
9172  if(!lua_isnumber(L,5)) SWIG_fail_arg("plscol0a",5,"PLFLT");
9173  arg1 = (PLINT)lua_tonumber(L, 1);
9174  arg2 = (PLINT)lua_tonumber(L, 2);
9175  arg3 = (PLINT)lua_tonumber(L, 3);
9176  arg4 = (PLINT)lua_tonumber(L, 4);
9177  arg5 = (PLFLT)lua_tonumber(L, 5);
9178  plscol0a(arg1,arg2,arg3,arg4,arg5);
9179 
9180  return SWIG_arg;
9181 
9182  if(0) SWIG_fail;
9183 
9184 fail:
9185  lua_error(L);
9186  return SWIG_arg;
9187 }
9188 
9189 
9190 static int _wrap_scolbg(lua_State* L) {
9191  int SWIG_arg = 0;
9192  PLINT arg1 ;
9193  PLINT arg2 ;
9194  PLINT arg3 ;
9195 
9196  SWIG_check_num_args("plscolbg",3,3)
9197  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscolbg",1,"PLINT");
9198  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscolbg",2,"PLINT");
9199  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscolbg",3,"PLINT");
9200  arg1 = (PLINT)lua_tonumber(L, 1);
9201  arg2 = (PLINT)lua_tonumber(L, 2);
9202  arg3 = (PLINT)lua_tonumber(L, 3);
9203  plscolbg(arg1,arg2,arg3);
9204 
9205  return SWIG_arg;
9206 
9207  if(0) SWIG_fail;
9208 
9209 fail:
9210  lua_error(L);
9211  return SWIG_arg;
9212 }
9213 
9214 
9215 static int _wrap_scolbga(lua_State* L) {
9216  int SWIG_arg = 0;
9217  PLINT arg1 ;
9218  PLINT arg2 ;
9219  PLINT arg3 ;
9220  PLFLT arg4 ;
9221 
9222  SWIG_check_num_args("plscolbga",4,4)
9223  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscolbga",1,"PLINT");
9224  if(!lua_isnumber(L,2)) SWIG_fail_arg("plscolbga",2,"PLINT");
9225  if(!lua_isnumber(L,3)) SWIG_fail_arg("plscolbga",3,"PLINT");
9226  if(!lua_isnumber(L,4)) SWIG_fail_arg("plscolbga",4,"PLFLT");
9227  arg1 = (PLINT)lua_tonumber(L, 1);
9228  arg2 = (PLINT)lua_tonumber(L, 2);
9229  arg3 = (PLINT)lua_tonumber(L, 3);
9230  arg4 = (PLFLT)lua_tonumber(L, 4);
9231  plscolbga(arg1,arg2,arg3,arg4);
9232 
9233  return SWIG_arg;
9234 
9235  if(0) SWIG_fail;
9236 
9237 fail:
9238  lua_error(L);
9239  return SWIG_arg;
9240 }
9241 
9242 
9243 static int _wrap_scolor(lua_State* L) {
9244  int SWIG_arg = 0;
9245  PLINT arg1 ;
9246 
9247  SWIG_check_num_args("plscolor",1,1)
9248  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscolor",1,"PLINT");
9249  arg1 = (PLINT)lua_tonumber(L, 1);
9250  plscolor(arg1);
9251 
9252  return SWIG_arg;
9253 
9254  if(0) SWIG_fail;
9255 
9256 fail:
9257  lua_error(L);
9258  return SWIG_arg;
9259 }
9260 
9261 
9262 static int _wrap_scompression(lua_State* L) {
9263  int SWIG_arg = 0;
9264  PLINT arg1 ;
9265 
9266  SWIG_check_num_args("plscompression",1,1)
9267  if(!lua_isnumber(L,1)) SWIG_fail_arg("plscompression",1,"PLINT");
9268  arg1 = (PLINT)lua_tonumber(L, 1);
9269  plscompression(arg1);
9270 
9271  return SWIG_arg;
9272 
9273  if(0) SWIG_fail;
9274 
9275 fail:
9276  lua_error(L);
9277  return SWIG_arg;
9278 }
9279 
9280 
9281 static int _wrap_sdev(lua_State* L) {
9282  int SWIG_arg = 0;
9283  char *arg1 = (char *) 0 ;
9284 
9285  SWIG_check_num_args("plsdev",1,1)
9286  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsdev",1,"char const *");
9287  arg1 = (char *)lua_tostring(L, 1);
9288  plsdev((char const *)arg1);
9289 
9290  return SWIG_arg;
9291 
9292  if(0) SWIG_fail;
9293 
9294 fail:
9295  lua_error(L);
9296  return SWIG_arg;
9297 }
9298 
9299 
9300 static int _wrap_sdidev(lua_State* L) {
9301  int SWIG_arg = 0;
9302  PLFLT arg1 ;
9303  PLFLT arg2 ;
9304  PLFLT arg3 ;
9305  PLFLT arg4 ;
9306 
9307  SWIG_check_num_args("plsdidev",4,4)
9308  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdidev",1,"PLFLT");
9309  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdidev",2,"PLFLT");
9310  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdidev",3,"PLFLT");
9311  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdidev",4,"PLFLT");
9312  arg1 = (PLFLT)lua_tonumber(L, 1);
9313  arg2 = (PLFLT)lua_tonumber(L, 2);
9314  arg3 = (PLFLT)lua_tonumber(L, 3);
9315  arg4 = (PLFLT)lua_tonumber(L, 4);
9316  plsdidev(arg1,arg2,arg3,arg4);
9317 
9318  return SWIG_arg;
9319 
9320  if(0) SWIG_fail;
9321 
9322 fail:
9323  lua_error(L);
9324  return SWIG_arg;
9325 }
9326 
9327 
9328 static int _wrap_sdimap(lua_State* L) {
9329  int SWIG_arg = 0;
9330  PLINT arg1 ;
9331  PLINT arg2 ;
9332  PLINT arg3 ;
9333  PLINT arg4 ;
9334  PLFLT arg5 ;
9335  PLFLT arg6 ;
9336 
9337  SWIG_check_num_args("plsdimap",6,6)
9338  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdimap",1,"PLINT");
9339  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdimap",2,"PLINT");
9340  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdimap",3,"PLINT");
9341  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdimap",4,"PLINT");
9342  if(!lua_isnumber(L,5)) SWIG_fail_arg("plsdimap",5,"PLFLT");
9343  if(!lua_isnumber(L,6)) SWIG_fail_arg("plsdimap",6,"PLFLT");
9344  arg1 = (PLINT)lua_tonumber(L, 1);
9345  arg2 = (PLINT)lua_tonumber(L, 2);
9346  arg3 = (PLINT)lua_tonumber(L, 3);
9347  arg4 = (PLINT)lua_tonumber(L, 4);
9348  arg5 = (PLFLT)lua_tonumber(L, 5);
9349  arg6 = (PLFLT)lua_tonumber(L, 6);
9350  plsdimap(arg1,arg2,arg3,arg4,arg5,arg6);
9351 
9352  return SWIG_arg;
9353 
9354  if(0) SWIG_fail;
9355 
9356 fail:
9357  lua_error(L);
9358  return SWIG_arg;
9359 }
9360 
9361 
9362 static int _wrap_sdiori(lua_State* L) {
9363  int SWIG_arg = 0;
9364  PLFLT arg1 ;
9365 
9366  SWIG_check_num_args("plsdiori",1,1)
9367  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdiori",1,"PLFLT");
9368  arg1 = (PLFLT)lua_tonumber(L, 1);
9369  plsdiori(arg1);
9370 
9371  return SWIG_arg;
9372 
9373  if(0) SWIG_fail;
9374 
9375 fail:
9376  lua_error(L);
9377  return SWIG_arg;
9378 }
9379 
9380 
9381 static int _wrap_sdiplt(lua_State* L) {
9382  int SWIG_arg = 0;
9383  PLFLT arg1 ;
9384  PLFLT arg2 ;
9385  PLFLT arg3 ;
9386  PLFLT arg4 ;
9387 
9388  SWIG_check_num_args("plsdiplt",4,4)
9389  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdiplt",1,"PLFLT");
9390  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdiplt",2,"PLFLT");
9391  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdiplt",3,"PLFLT");
9392  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdiplt",4,"PLFLT");
9393  arg1 = (PLFLT)lua_tonumber(L, 1);
9394  arg2 = (PLFLT)lua_tonumber(L, 2);
9395  arg3 = (PLFLT)lua_tonumber(L, 3);
9396  arg4 = (PLFLT)lua_tonumber(L, 4);
9397  plsdiplt(arg1,arg2,arg3,arg4);
9398 
9399  return SWIG_arg;
9400 
9401  if(0) SWIG_fail;
9402 
9403 fail:
9404  lua_error(L);
9405  return SWIG_arg;
9406 }
9407 
9408 
9409 static int _wrap_sdiplz(lua_State* L) {
9410  int SWIG_arg = 0;
9411  PLFLT arg1 ;
9412  PLFLT arg2 ;
9413  PLFLT arg3 ;
9414  PLFLT arg4 ;
9415 
9416  SWIG_check_num_args("plsdiplz",4,4)
9417  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsdiplz",1,"PLFLT");
9418  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsdiplz",2,"PLFLT");
9419  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsdiplz",3,"PLFLT");
9420  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsdiplz",4,"PLFLT");
9421  arg1 = (PLFLT)lua_tonumber(L, 1);
9422  arg2 = (PLFLT)lua_tonumber(L, 2);
9423  arg3 = (PLFLT)lua_tonumber(L, 3);
9424  arg4 = (PLFLT)lua_tonumber(L, 4);
9425  plsdiplz(arg1,arg2,arg3,arg4);
9426 
9427  return SWIG_arg;
9428 
9429  if(0) SWIG_fail;
9430 
9431 fail:
9432  lua_error(L);
9433  return SWIG_arg;
9434 }
9435 
9436 
9437 static int _wrap_seed(lua_State* L) {
9438  int SWIG_arg = 0;
9439  unsigned int arg1 ;
9440 
9441  SWIG_check_num_args("plseed",1,1)
9442  if(!lua_isnumber(L,1)) SWIG_fail_arg("plseed",1,"unsigned int");
9443  SWIG_contract_assert((lua_tonumber(L,1)>=0),"number must not be negative")
9444  arg1 = (unsigned int)lua_tonumber(L, 1);
9445  plseed(arg1);
9446 
9447  return SWIG_arg;
9448 
9449  if(0) SWIG_fail;
9450 
9451 fail:
9452  lua_error(L);
9453  return SWIG_arg;
9454 }
9455 
9456 
9457 static int _wrap_sesc(lua_State* L) {
9458  int SWIG_arg = 0;
9459  char arg1 ;
9460 
9461  SWIG_check_num_args("plsesc",1,1)
9462  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsesc",1,"char");
9463  arg1 = (lua_tostring(L, 1))[0];
9464  plsesc(arg1);
9465 
9466  return SWIG_arg;
9467 
9468  if(0) SWIG_fail;
9469 
9470 fail:
9471  lua_error(L);
9472  return SWIG_arg;
9473 }
9474 
9475 
9476 static int _wrap_setopt(lua_State* L) {
9477  int SWIG_arg = 0;
9478  char *arg1 = (char *) 0 ;
9479  char *arg2 = (char *) 0 ;
9480  PLINT result;
9481 
9482  SWIG_check_num_args("plsetopt",2,2)
9483  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsetopt",1,"char const *");
9484  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plsetopt",2,"char const *");
9485  arg1 = (char *)lua_tostring(L, 1);
9486  arg2 = (char *)lua_tostring(L, 2);
9487  result = (PLINT)plsetopt((char const *)arg1,(char const *)arg2);
9488  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
9489  return SWIG_arg;
9490 
9491  if(0) SWIG_fail;
9492 
9493 fail:
9494  lua_error(L);
9495  return SWIG_arg;
9496 }
9497 
9498 
9499 static int _wrap_sfam(lua_State* L) {
9500  int SWIG_arg = 0;
9501  PLINT arg1 ;
9502  PLINT arg2 ;
9503  PLINT arg3 ;
9504 
9505  SWIG_check_num_args("plsfam",3,3)
9506  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsfam",1,"PLINT");
9507  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsfam",2,"PLINT");
9508  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsfam",3,"PLINT");
9509  arg1 = (PLINT)lua_tonumber(L, 1);
9510  arg2 = (PLINT)lua_tonumber(L, 2);
9511  arg3 = (PLINT)lua_tonumber(L, 3);
9512  plsfam(arg1,arg2,arg3);
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_sfci(lua_State* L) {
9525  int SWIG_arg = 0;
9526  PLUNICODE arg1 ;
9527 
9528  SWIG_check_num_args("plsfci",1,1)
9529  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsfci",1,"PLUNICODE");
9530  SWIG_contract_assert((lua_tonumber(L,1)>=0),"number must not be negative")
9531  arg1 = (PLUNICODE)lua_tonumber(L, 1);
9532  plsfci(arg1);
9533 
9534  return SWIG_arg;
9535 
9536  if(0) SWIG_fail;
9537 
9538 fail:
9539  lua_error(L);
9540  return SWIG_arg;
9541 }
9542 
9543 
9544 static int _wrap_sfnam(lua_State* L) {
9545  int SWIG_arg = 0;
9546  char *arg1 = (char *) 0 ;
9547 
9548  SWIG_check_num_args("plsfnam",1,1)
9549  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plsfnam",1,"char const *");
9550  arg1 = (char *)lua_tostring(L, 1);
9551  plsfnam((char const *)arg1);
9552 
9553  return SWIG_arg;
9554 
9555  if(0) SWIG_fail;
9556 
9557 fail:
9558  lua_error(L);
9559  return SWIG_arg;
9560 }
9561 
9562 
9563 static int _wrap_sfont(lua_State* L) {
9564  int SWIG_arg = 0;
9565  PLINT arg1 ;
9566  PLINT arg2 ;
9567  PLINT arg3 ;
9568 
9569  SWIG_check_num_args("plsfont",3,3)
9570  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsfont",1,"PLINT");
9571  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsfont",2,"PLINT");
9572  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsfont",3,"PLINT");
9573  arg1 = (PLINT)lua_tonumber(L, 1);
9574  arg2 = (PLINT)lua_tonumber(L, 2);
9575  arg3 = (PLINT)lua_tonumber(L, 3);
9576  plsfont(arg1,arg2,arg3);
9577 
9578  return SWIG_arg;
9579 
9580  if(0) SWIG_fail;
9581 
9582 fail:
9583  lua_error(L);
9584  return SWIG_arg;
9585 }
9586 
9587 
9588 static int _wrap_shades(lua_State* L) {
9589  int SWIG_arg = 0;
9590  PLFLT **arg1 = (PLFLT **) 0 ;
9591  PLINT arg2 ;
9592  PLINT arg3 ;
9593  defined_func arg4 = (defined_func) 0 ;
9594  PLFLT arg5 ;
9595  PLFLT arg6 ;
9596  PLFLT arg7 ;
9597  PLFLT arg8 ;
9598  PLFLT *arg9 = (PLFLT *) 0 ;
9599  PLINT arg10 ;
9600  PLFLT arg11 ;
9601  PLINT arg12 ;
9602  PLFLT arg13 ;
9603  fill_func arg14 = (fill_func) 0 ;
9604  PLBOOL arg15 ;
9605  pltr_func arg16 = (pltr_func) 0 ;
9606  PLPointer arg17 = (PLPointer) 0 ;
9607  int ii1 ;
9608  PLcGrid cgrid117 ;
9609  PLcGrid2 cgrid217 ;
9610 
9611  {
9612  cgrid117.xg = cgrid117.yg = cgrid117.zg = NULL;
9613  cgrid117.nx = cgrid117.ny = cgrid117.nz = 0;
9614  cgrid217.xg = cgrid217.yg = cgrid217.zg = NULL;
9615  cgrid217.nx = cgrid217.ny = 0;
9616  }
9617  {
9618  arg16 = NULL;
9619  }
9620  {
9621  arg17 = NULL;
9622  }
9623  {
9624  arg4 = NULL;
9625  }
9626  {
9627  arg14 = plfill;
9628  }
9629  SWIG_check_num_args("plshades",10,12)
9630  if(!lua_isnumber(L,2)) SWIG_fail_arg("plshades",2,"PLFLT");
9631  if(!lua_isnumber(L,3)) SWIG_fail_arg("plshades",3,"PLFLT");
9632  if(!lua_isnumber(L,4)) SWIG_fail_arg("plshades",4,"PLFLT");
9633  if(!lua_isnumber(L,5)) SWIG_fail_arg("plshades",5,"PLFLT");
9634  if(!lua_isnumber(L,7)) SWIG_fail_arg("plshades",7,"PLFLT");
9635  if(!lua_isnumber(L,8)) SWIG_fail_arg("plshades",8,"PLINT");
9636  if(!lua_isnumber(L,9)) SWIG_fail_arg("plshades",9,"PLFLT");
9637  if(!lua_isnumber(L,10)) SWIG_fail_arg("plshades",10,"PLBOOL");
9638  {
9639  int jj;
9640 
9641  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
9642  if ( !arg1 )
9643  SWIG_fail;
9644  Xlen = arg2 = ii1;
9645  Ylen = arg3 = jj;
9646  }
9647  arg5 = (PLFLT)lua_tonumber(L, 2);
9648  arg6 = (PLFLT)lua_tonumber(L, 3);
9649  arg7 = (PLFLT)lua_tonumber(L, 4);
9650  arg8 = (PLFLT)lua_tonumber(L, 5);
9651  {
9652  int temp;
9653  arg9 = (PLFLT *) LUA_get_double_num_array_var( L, 6, &temp );
9654  if ( !arg9 )
9655  SWIG_fail;
9656  arg10 = Alen = temp;
9657  }
9658  arg11 = (PLFLT)lua_tonumber(L, 7);
9659  arg12 = (PLINT)lua_tonumber(L, 8);
9660  arg13 = (PLFLT)lua_tonumber(L, 9);
9661  arg15 = (PLBOOL)lua_tonumber(L, 10);
9662  if(lua_gettop(L)>=11){
9663  {
9664  arg16 = NULL;
9665  mypltr_funcstr[0] = '\0';
9666 
9667  if ( lua_isstring( L, 11 ) )
9668  {
9669  const char* funcstr = lua_tostring( L, 11 );
9670  if ( strcmp( "pltr0", funcstr ) == 0 )
9671  {
9672  arg16 = pltr0;
9673  }
9674  else if ( strcmp( "pltr1", funcstr ) == 0 )
9675  {
9676  arg16 = pltr1;
9677  }
9678  else if ( strcmp( "pltr2", funcstr ) == 0 )
9679  {
9680  arg16 = pltr2;
9681  }
9682  else
9683  {
9684  arg16 = mypltr;
9685  strncpy( mypltr_funcstr, funcstr, 255 );
9686  myL = L;
9687  }
9688  }
9689  else
9690  SWIG_fail_arg( "shades", 16, "pltr_func" );
9691  }
9692  }
9693  if(lua_gettop(L)>=12){
9694  {
9695  int nx, ny;
9696  int gridmode = 0;
9697 
9698  lua_pushstring( L, "xg" );
9699  lua_gettable( L, 12 );
9700  if ( !lua_istable( L, -1 ) )
9701  {
9702  lua_pop( L, 1 ); // pop "xg"
9703  lua_pushstring( L, "expected a table xg" );
9704  SWIG_fail;
9705  }
9706  lua_rawgeti( L, -1, 1 );
9707  if ( lua_istable( L, -1 ) )
9708  gridmode = 2; // two dimensional array
9709  else if ( lua_isnumber( L, -1 ) )
9710  gridmode = 1; // one dimensional array
9711  else
9712  {
9713  lua_pop( L, 1 ); // pop "1"
9714  lua_pop( L, 1 ); // pop "xg"
9715  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
9716  SWIG_fail;
9717  }
9718  lua_pop( L, 1 ); // pop test element
9719  if ( gridmode == 1 )
9720  {
9721  cgrid117.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
9722  if ( !cgrid117.xg )
9723  {
9724  lua_pop( L, 1 ); // pop "xg"
9725  SWIG_fail;
9726  }
9727  if ( nx != Xlen )
9728  {
9729  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
9730  SWIG_fail;
9731  }
9732  cgrid117.nx = nx;
9733  }
9734  else
9735  {
9736  cgrid217.xg = read_double_Matrix( L, -1, &nx, &ny );
9737  if ( !cgrid217.xg )
9738  {
9739  lua_pop( L, 1 ); // pop "xg"
9740  SWIG_fail;
9741  }
9742  if ( ( nx != Xlen ) || ( ny != Ylen ) )
9743  {
9744  lua_pop( L, 1 ); // pop "xg"
9745  lua_pushfstring( L, "Vectors must match matrix." );
9746  SWIG_fail;
9747  }
9748  cgrid217.nx = nx;
9749  cgrid217.ny = ny;
9750  }
9751  lua_pop( L, 1 ); // pop "xg"
9752 
9753  lua_pushstring( L, "yg" );
9754  lua_gettable( L, 12 );
9755  if ( !lua_istable( L, -1 ) )
9756  {
9757  lua_pop( L, 1 );
9758  lua_pushstring( L, "expected a table yg" );
9759  SWIG_fail;
9760  }
9761  lua_rawgeti( L, -1, 1 );
9762  if ( gridmode == 2 )
9763  {
9764  if ( !lua_istable( L, -1 ) )
9765  {
9766  lua_pop( L, 1 ); // pop "1"
9767  lua_pop( L, 1 ); // pop "yg"
9768  lua_pushstring( L, "expected a two dimensional array/table in yg" );
9769  SWIG_fail;
9770  }
9771  }
9772  else
9773  {
9774  if ( !lua_isnumber( L, -1 ) )
9775  {
9776  lua_pop( L, 1 ); // pop "1"
9777  lua_pop( L, 1 ); // pop "yg"
9778  lua_pushstring( L, "expected a one dimensional array/table in yg" );
9779  SWIG_fail;
9780  }
9781  }
9782  lua_pop( L, 1 ); // pop "1"
9783  if ( gridmode == 1 )
9784  {
9785  cgrid117.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
9786  if ( !cgrid117.yg )
9787  {
9788  lua_pop( L, 1 ); // pop "yg"
9789  SWIG_fail;
9790  }
9791  if ( ny != Ylen )
9792  {
9793  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
9794  SWIG_fail;
9795  }
9796  cgrid117.ny = ny;
9797  }
9798  else
9799  {
9800  cgrid217.yg = read_double_Matrix( L, -1, &nx, &ny );
9801  if ( !cgrid217.yg )
9802  {
9803  lua_pop( L, 1 ); // pop "xg"
9804  SWIG_fail;
9805  }
9806  if ( ( nx != Xlen ) || ( ny != Ylen ) )
9807  {
9808  lua_pop( L, 1 ); // pop "xg"
9809  lua_pushfstring( L, "Vectors must match matrix." );
9810  SWIG_fail;
9811  }
9812  // cgrid217.nx/ny already set
9813  }
9814  lua_pop( L, 1 ); // pop "yg"
9815 
9816  if ( gridmode == 1 )
9817  arg17 = &cgrid117;
9818  else if ( gridmode == 2 )
9819  arg17 = &cgrid217;
9820  }
9821  }
9822  plshades((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,(double const *)arg9,arg10,arg11,arg12,arg13,arg14,arg15,arg16,arg17);
9823 
9824  {
9825  int i;
9826 
9827  if ( arg1 )
9828  {
9829  for ( i = 0; i < ii1; i++ )
9830  LUA_FREE_ARRAY( arg1[i] );
9831  LUA_FREE_ARRAY( arg1 );
9832  }
9833  }
9834  {
9835  LUA_FREE_ARRAY( arg9 );
9836  }
9837  {
9838  mypltr_funcstr[0] = '\0';
9839  }
9840  {
9841  int i;
9842 
9843  LUA_FREE_ARRAY( cgrid117.xg );
9844  LUA_FREE_ARRAY( cgrid117.yg );
9845 
9846  if ( cgrid217.xg )
9847  {
9848  for ( i = 0; i < Xlen; i++ )
9849  LUA_FREE_ARRAY( cgrid217.xg[i] );
9850  LUA_FREE_ARRAY( cgrid217.xg );
9851  }
9852  if ( cgrid217.yg )
9853  {
9854  for ( i = 0; i < Xlen; i++ )
9855  LUA_FREE_ARRAY( cgrid217.yg[i] );
9856  LUA_FREE_ARRAY( cgrid217.yg );
9857  }
9858  }
9859  return SWIG_arg;
9860 
9861  if(0) SWIG_fail;
9862 
9863 fail:
9864  {
9865  int i;
9866 
9867  if ( arg1 )
9868  {
9869  for ( i = 0; i < ii1; i++ )
9870  LUA_FREE_ARRAY( arg1[i] );
9871  LUA_FREE_ARRAY( arg1 );
9872  }
9873  }
9874  {
9875  LUA_FREE_ARRAY( arg9 );
9876  }
9877  {
9878  mypltr_funcstr[0] = '\0';
9879  }
9880  {
9881  int i;
9882 
9883  LUA_FREE_ARRAY( cgrid117.xg );
9884  LUA_FREE_ARRAY( cgrid117.yg );
9885 
9886  if ( cgrid217.xg )
9887  {
9888  for ( i = 0; i < Xlen; i++ )
9889  LUA_FREE_ARRAY( cgrid217.xg[i] );
9890  LUA_FREE_ARRAY( cgrid217.xg );
9891  }
9892  if ( cgrid217.yg )
9893  {
9894  for ( i = 0; i < Xlen; i++ )
9895  LUA_FREE_ARRAY( cgrid217.yg[i] );
9896  LUA_FREE_ARRAY( cgrid217.yg );
9897  }
9898  }
9899  lua_error(L);
9900  return SWIG_arg;
9901 }
9902 
9903 
9904 static int _wrap_shade(lua_State* L) {
9905  int SWIG_arg = 0;
9906  PLFLT **arg1 = (PLFLT **) 0 ;
9907  PLINT arg2 ;
9908  PLINT arg3 ;
9909  defined_func arg4 = (defined_func) 0 ;
9910  PLFLT arg5 ;
9911  PLFLT arg6 ;
9912  PLFLT arg7 ;
9913  PLFLT arg8 ;
9914  PLFLT arg9 ;
9915  PLFLT arg10 ;
9916  PLINT arg11 ;
9917  PLFLT arg12 ;
9918  PLFLT arg13 ;
9919  PLINT arg14 ;
9920  PLFLT arg15 ;
9921  PLINT arg16 ;
9922  PLFLT arg17 ;
9923  fill_func arg18 = (fill_func) 0 ;
9924  PLBOOL arg19 ;
9925  pltr_func arg20 = (pltr_func) 0 ;
9926  PLPointer arg21 = (PLPointer) 0 ;
9927  int ii1 ;
9928  PLcGrid cgrid121 ;
9929  PLcGrid2 cgrid221 ;
9930 
9931  {
9932  cgrid121.xg = cgrid121.yg = cgrid121.zg = NULL;
9933  cgrid121.nx = cgrid121.ny = cgrid121.nz = 0;
9934  cgrid221.xg = cgrid221.yg = cgrid221.zg = NULL;
9935  cgrid221.nx = cgrid221.ny = 0;
9936  }
9937  {
9938  arg20 = NULL;
9939  }
9940  {
9941  arg21 = NULL;
9942  }
9943  {
9944  arg4 = NULL;
9945  }
9946  {
9947  arg18 = plfill;
9948  }
9949  SWIG_check_num_args("plshade",15,17)
9950  if(!lua_isnumber(L,2)) SWIG_fail_arg("plshade",2,"PLFLT");
9951  if(!lua_isnumber(L,3)) SWIG_fail_arg("plshade",3,"PLFLT");
9952  if(!lua_isnumber(L,4)) SWIG_fail_arg("plshade",4,"PLFLT");
9953  if(!lua_isnumber(L,5)) SWIG_fail_arg("plshade",5,"PLFLT");
9954  if(!lua_isnumber(L,6)) SWIG_fail_arg("plshade",6,"PLFLT");
9955  if(!lua_isnumber(L,7)) SWIG_fail_arg("plshade",7,"PLFLT");
9956  if(!lua_isnumber(L,8)) SWIG_fail_arg("plshade",8,"PLINT");
9957  if(!lua_isnumber(L,9)) SWIG_fail_arg("plshade",9,"PLFLT");
9958  if(!lua_isnumber(L,10)) SWIG_fail_arg("plshade",10,"PLFLT");
9959  if(!lua_isnumber(L,11)) SWIG_fail_arg("plshade",11,"PLINT");
9960  if(!lua_isnumber(L,12)) SWIG_fail_arg("plshade",12,"PLFLT");
9961  if(!lua_isnumber(L,13)) SWIG_fail_arg("plshade",13,"PLINT");
9962  if(!lua_isnumber(L,14)) SWIG_fail_arg("plshade",14,"PLFLT");
9963  if(!lua_isnumber(L,15)) SWIG_fail_arg("plshade",15,"PLBOOL");
9964  {
9965  int jj;
9966 
9967  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
9968  if ( !arg1 )
9969  SWIG_fail;
9970  Xlen = arg2 = ii1;
9971  Ylen = arg3 = jj;
9972  }
9973  arg5 = (PLFLT)lua_tonumber(L, 2);
9974  arg6 = (PLFLT)lua_tonumber(L, 3);
9975  arg7 = (PLFLT)lua_tonumber(L, 4);
9976  arg8 = (PLFLT)lua_tonumber(L, 5);
9977  arg9 = (PLFLT)lua_tonumber(L, 6);
9978  arg10 = (PLFLT)lua_tonumber(L, 7);
9979  arg11 = (PLINT)lua_tonumber(L, 8);
9980  arg12 = (PLFLT)lua_tonumber(L, 9);
9981  arg13 = (PLFLT)lua_tonumber(L, 10);
9982  arg14 = (PLINT)lua_tonumber(L, 11);
9983  arg15 = (PLFLT)lua_tonumber(L, 12);
9984  arg16 = (PLINT)lua_tonumber(L, 13);
9985  arg17 = (PLFLT)lua_tonumber(L, 14);
9986  arg19 = (PLBOOL)lua_tonumber(L, 15);
9987  if(lua_gettop(L)>=16){
9988  {
9989  arg20 = NULL;
9990  mypltr_funcstr[0] = '\0';
9991 
9992  if ( lua_isstring( L, 16 ) )
9993  {
9994  const char* funcstr = lua_tostring( L, 16 );
9995  if ( strcmp( "pltr0", funcstr ) == 0 )
9996  {
9997  arg20 = pltr0;
9998  }
9999  else if ( strcmp( "pltr1", funcstr ) == 0 )
10000  {
10001  arg20 = pltr1;
10002  }
10003  else if ( strcmp( "pltr2", funcstr ) == 0 )
10004  {
10005  arg20 = pltr2;
10006  }
10007  else
10008  {
10009  arg20 = mypltr;
10010  strncpy( mypltr_funcstr, funcstr, 255 );
10011  myL = L;
10012  }
10013  }
10014  else
10015  SWIG_fail_arg( "shade", 20, "pltr_func" );
10016  }
10017  }
10018  if(lua_gettop(L)>=17){
10019  {
10020  int nx, ny;
10021  int gridmode = 0;
10022 
10023  lua_pushstring( L, "xg" );
10024  lua_gettable( L, 17 );
10025  if ( !lua_istable( L, -1 ) )
10026  {
10027  lua_pop( L, 1 ); // pop "xg"
10028  lua_pushstring( L, "expected a table xg" );
10029  SWIG_fail;
10030  }
10031  lua_rawgeti( L, -1, 1 );
10032  if ( lua_istable( L, -1 ) )
10033  gridmode = 2; // two dimensional array
10034  else if ( lua_isnumber( L, -1 ) )
10035  gridmode = 1; // one dimensional array
10036  else
10037  {
10038  lua_pop( L, 1 ); // pop "1"
10039  lua_pop( L, 1 ); // pop "xg"
10040  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
10041  SWIG_fail;
10042  }
10043  lua_pop( L, 1 ); // pop test element
10044  if ( gridmode == 1 )
10045  {
10046  cgrid121.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
10047  if ( !cgrid121.xg )
10048  {
10049  lua_pop( L, 1 ); // pop "xg"
10050  SWIG_fail;
10051  }
10052  if ( nx != Xlen )
10053  {
10054  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
10055  SWIG_fail;
10056  }
10057  cgrid121.nx = nx;
10058  }
10059  else
10060  {
10061  cgrid221.xg = read_double_Matrix( L, -1, &nx, &ny );
10062  if ( !cgrid221.xg )
10063  {
10064  lua_pop( L, 1 ); // pop "xg"
10065  SWIG_fail;
10066  }
10067  if ( ( nx != Xlen ) || ( ny != Ylen ) )
10068  {
10069  lua_pop( L, 1 ); // pop "xg"
10070  lua_pushfstring( L, "Vectors must match matrix." );
10071  SWIG_fail;
10072  }
10073  cgrid221.nx = nx;
10074  cgrid221.ny = ny;
10075  }
10076  lua_pop( L, 1 ); // pop "xg"
10077 
10078  lua_pushstring( L, "yg" );
10079  lua_gettable( L, 17 );
10080  if ( !lua_istable( L, -1 ) )
10081  {
10082  lua_pop( L, 1 );
10083  lua_pushstring( L, "expected a table yg" );
10084  SWIG_fail;
10085  }
10086  lua_rawgeti( L, -1, 1 );
10087  if ( gridmode == 2 )
10088  {
10089  if ( !lua_istable( L, -1 ) )
10090  {
10091  lua_pop( L, 1 ); // pop "1"
10092  lua_pop( L, 1 ); // pop "yg"
10093  lua_pushstring( L, "expected a two dimensional array/table in yg" );
10094  SWIG_fail;
10095  }
10096  }
10097  else
10098  {
10099  if ( !lua_isnumber( L, -1 ) )
10100  {
10101  lua_pop( L, 1 ); // pop "1"
10102  lua_pop( L, 1 ); // pop "yg"
10103  lua_pushstring( L, "expected a one dimensional array/table in yg" );
10104  SWIG_fail;
10105  }
10106  }
10107  lua_pop( L, 1 ); // pop "1"
10108  if ( gridmode == 1 )
10109  {
10110  cgrid121.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
10111  if ( !cgrid121.yg )
10112  {
10113  lua_pop( L, 1 ); // pop "yg"
10114  SWIG_fail;
10115  }
10116  if ( ny != Ylen )
10117  {
10118  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
10119  SWIG_fail;
10120  }
10121  cgrid121.ny = ny;
10122  }
10123  else
10124  {
10125  cgrid221.yg = read_double_Matrix( L, -1, &nx, &ny );
10126  if ( !cgrid221.yg )
10127  {
10128  lua_pop( L, 1 ); // pop "xg"
10129  SWIG_fail;
10130  }
10131  if ( ( nx != Xlen ) || ( ny != Ylen ) )
10132  {
10133  lua_pop( L, 1 ); // pop "xg"
10134  lua_pushfstring( L, "Vectors must match matrix." );
10135  SWIG_fail;
10136  }
10137  // cgrid221.nx/ny already set
10138  }
10139  lua_pop( L, 1 ); // pop "yg"
10140 
10141  if ( gridmode == 1 )
10142  arg21 = &cgrid121;
10143  else if ( gridmode == 2 )
10144  arg21 = &cgrid221;
10145  }
10146  }
10147  plshade((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13,arg14,arg15,arg16,arg17,arg18,arg19,arg20,arg21);
10148 
10149  {
10150  int i;
10151 
10152  if ( arg1 )
10153  {
10154  for ( i = 0; i < ii1; i++ )
10155  LUA_FREE_ARRAY( arg1[i] );
10156  LUA_FREE_ARRAY( arg1 );
10157  }
10158  }
10159  {
10160  mypltr_funcstr[0] = '\0';
10161  }
10162  {
10163  int i;
10164 
10165  LUA_FREE_ARRAY( cgrid121.xg );
10166  LUA_FREE_ARRAY( cgrid121.yg );
10167 
10168  if ( cgrid221.xg )
10169  {
10170  for ( i = 0; i < Xlen; i++ )
10171  LUA_FREE_ARRAY( cgrid221.xg[i] );
10172  LUA_FREE_ARRAY( cgrid221.xg );
10173  }
10174  if ( cgrid221.yg )
10175  {
10176  for ( i = 0; i < Xlen; i++ )
10177  LUA_FREE_ARRAY( cgrid221.yg[i] );
10178  LUA_FREE_ARRAY( cgrid221.yg );
10179  }
10180  }
10181  return SWIG_arg;
10182 
10183  if(0) SWIG_fail;
10184 
10185 fail:
10186  {
10187  int i;
10188 
10189  if ( arg1 )
10190  {
10191  for ( i = 0; i < ii1; i++ )
10192  LUA_FREE_ARRAY( arg1[i] );
10193  LUA_FREE_ARRAY( arg1 );
10194  }
10195  }
10196  {
10197  mypltr_funcstr[0] = '\0';
10198  }
10199  {
10200  int i;
10201 
10202  LUA_FREE_ARRAY( cgrid121.xg );
10203  LUA_FREE_ARRAY( cgrid121.yg );
10204 
10205  if ( cgrid221.xg )
10206  {
10207  for ( i = 0; i < Xlen; i++ )
10208  LUA_FREE_ARRAY( cgrid221.xg[i] );
10209  LUA_FREE_ARRAY( cgrid221.xg );
10210  }
10211  if ( cgrid221.yg )
10212  {
10213  for ( i = 0; i < Xlen; i++ )
10214  LUA_FREE_ARRAY( cgrid221.yg[i] );
10215  LUA_FREE_ARRAY( cgrid221.yg );
10216  }
10217  }
10218  lua_error(L);
10219  return SWIG_arg;
10220 }
10221 
10222 
10223 static int _wrap_slabelfunc(lua_State* L) {
10224  int SWIG_arg = 0;
10225  label_func arg1 = (label_func) 0 ;
10226  PLPointer arg2 = (PLPointer) 0 ;
10227 
10228  {
10229  arg2 = NULL;
10230  }
10231  SWIG_check_num_args("plslabelfunc",1,1)
10232  {
10233  arg1 = NULL;
10234  mylabel_funcstr[0] = '\0';
10235 
10236  if ( lua_isnil( L, 1 ) )
10237  {
10238  arg1 = NULL;
10239  }
10240  else if ( lua_isstring( L, 1 ) )
10241  {
10242  arg1 = mylabel;
10243  strncpy( mylabel_funcstr, lua_tostring( L, 1 ), 255 );
10244  myL = L;
10245  }
10246  else
10247  SWIG_fail_arg( "slabelfunc", 1, "label_func" );
10248  }
10249  plslabelfunc(arg1,arg2);
10250 
10251  {
10252 
10253  }
10254  return SWIG_arg;
10255 
10256  if(0) SWIG_fail;
10257 
10258 fail:
10259  {
10260 
10261  }
10262  lua_error(L);
10263  return SWIG_arg;
10264 }
10265 
10266 
10267 static int _wrap_smaj(lua_State* L) {
10268  int SWIG_arg = 0;
10269  PLFLT arg1 ;
10270  PLFLT arg2 ;
10271 
10272  SWIG_check_num_args("plsmaj",2,2)
10273  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsmaj",1,"PLFLT");
10274  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsmaj",2,"PLFLT");
10275  arg1 = (PLFLT)lua_tonumber(L, 1);
10276  arg2 = (PLFLT)lua_tonumber(L, 2);
10277  plsmaj(arg1,arg2);
10278 
10279  return SWIG_arg;
10280 
10281  if(0) SWIG_fail;
10282 
10283 fail:
10284  lua_error(L);
10285  return SWIG_arg;
10286 }
10287 
10288 
10289 static int _wrap_smin(lua_State* L) {
10290  int SWIG_arg = 0;
10291  PLFLT arg1 ;
10292  PLFLT arg2 ;
10293 
10294  SWIG_check_num_args("plsmin",2,2)
10295  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsmin",1,"PLFLT");
10296  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsmin",2,"PLFLT");
10297  arg1 = (PLFLT)lua_tonumber(L, 1);
10298  arg2 = (PLFLT)lua_tonumber(L, 2);
10299  plsmin(arg1,arg2);
10300 
10301  return SWIG_arg;
10302 
10303  if(0) SWIG_fail;
10304 
10305 fail:
10306  lua_error(L);
10307  return SWIG_arg;
10308 }
10309 
10310 
10311 static int _wrap_sori(lua_State* L) {
10312  int SWIG_arg = 0;
10313  PLINT arg1 ;
10314 
10315  SWIG_check_num_args("plsori",1,1)
10316  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsori",1,"PLINT");
10317  arg1 = (PLINT)lua_tonumber(L, 1);
10318  plsori(arg1);
10319 
10320  return SWIG_arg;
10321 
10322  if(0) SWIG_fail;
10323 
10324 fail:
10325  lua_error(L);
10326  return SWIG_arg;
10327 }
10328 
10329 
10330 static int _wrap_spage(lua_State* L) {
10331  int SWIG_arg = 0;
10332  PLFLT arg1 ;
10333  PLFLT arg2 ;
10334  PLINT arg3 ;
10335  PLINT arg4 ;
10336  PLINT arg5 ;
10337  PLINT arg6 ;
10338 
10339  SWIG_check_num_args("plspage",6,6)
10340  if(!lua_isnumber(L,1)) SWIG_fail_arg("plspage",1,"PLFLT");
10341  if(!lua_isnumber(L,2)) SWIG_fail_arg("plspage",2,"PLFLT");
10342  if(!lua_isnumber(L,3)) SWIG_fail_arg("plspage",3,"PLINT");
10343  if(!lua_isnumber(L,4)) SWIG_fail_arg("plspage",4,"PLINT");
10344  if(!lua_isnumber(L,5)) SWIG_fail_arg("plspage",5,"PLINT");
10345  if(!lua_isnumber(L,6)) SWIG_fail_arg("plspage",6,"PLINT");
10346  arg1 = (PLFLT)lua_tonumber(L, 1);
10347  arg2 = (PLFLT)lua_tonumber(L, 2);
10348  arg3 = (PLINT)lua_tonumber(L, 3);
10349  arg4 = (PLINT)lua_tonumber(L, 4);
10350  arg5 = (PLINT)lua_tonumber(L, 5);
10351  arg6 = (PLINT)lua_tonumber(L, 6);
10352  plspage(arg1,arg2,arg3,arg4,arg5,arg6);
10353 
10354  return SWIG_arg;
10355 
10356  if(0) SWIG_fail;
10357 
10358 fail:
10359  lua_error(L);
10360  return SWIG_arg;
10361 }
10362 
10363 
10364 static int _wrap_spal0(lua_State* L) {
10365  int SWIG_arg = 0;
10366  char *arg1 = (char *) 0 ;
10367 
10368  SWIG_check_num_args("plspal0",1,1)
10369  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plspal0",1,"char const *");
10370  arg1 = (char *)lua_tostring(L, 1);
10371  plspal0((char const *)arg1);
10372 
10373  return SWIG_arg;
10374 
10375  if(0) SWIG_fail;
10376 
10377 fail:
10378  lua_error(L);
10379  return SWIG_arg;
10380 }
10381 
10382 
10383 static int _wrap_spal1(lua_State* L) {
10384  int SWIG_arg = 0;
10385  char *arg1 = (char *) 0 ;
10386  PLBOOL arg2 ;
10387 
10388  SWIG_check_num_args("plspal1",2,2)
10389  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plspal1",1,"char const *");
10390  if(!lua_isnumber(L,2)) SWIG_fail_arg("plspal1",2,"PLBOOL");
10391  arg1 = (char *)lua_tostring(L, 1);
10392  arg2 = (PLBOOL)lua_tonumber(L, 2);
10393  plspal1((char const *)arg1,arg2);
10394 
10395  return SWIG_arg;
10396 
10397  if(0) SWIG_fail;
10398 
10399 fail:
10400  lua_error(L);
10401  return SWIG_arg;
10402 }
10403 
10404 
10405 static int _wrap_spause(lua_State* L) {
10406  int SWIG_arg = 0;
10407  PLBOOL arg1 ;
10408 
10409  SWIG_check_num_args("plspause",1,1)
10410  if(!lua_isnumber(L,1)) SWIG_fail_arg("plspause",1,"PLBOOL");
10411  arg1 = (PLBOOL)lua_tonumber(L, 1);
10412  plspause(arg1);
10413 
10414  return SWIG_arg;
10415 
10416  if(0) SWIG_fail;
10417 
10418 fail:
10419  lua_error(L);
10420  return SWIG_arg;
10421 }
10422 
10423 
10424 static int _wrap_sstrm(lua_State* L) {
10425  int SWIG_arg = 0;
10426  PLINT arg1 ;
10427 
10428  SWIG_check_num_args("plsstrm",1,1)
10429  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsstrm",1,"PLINT");
10430  arg1 = (PLINT)lua_tonumber(L, 1);
10431  plsstrm(arg1);
10432 
10433  return SWIG_arg;
10434 
10435  if(0) SWIG_fail;
10436 
10437 fail:
10438  lua_error(L);
10439  return SWIG_arg;
10440 }
10441 
10442 
10443 static int _wrap_ssub(lua_State* L) {
10444  int SWIG_arg = 0;
10445  PLINT arg1 ;
10446  PLINT arg2 ;
10447 
10448  SWIG_check_num_args("plssub",2,2)
10449  if(!lua_isnumber(L,1)) SWIG_fail_arg("plssub",1,"PLINT");
10450  if(!lua_isnumber(L,2)) SWIG_fail_arg("plssub",2,"PLINT");
10451  arg1 = (PLINT)lua_tonumber(L, 1);
10452  arg2 = (PLINT)lua_tonumber(L, 2);
10453  plssub(arg1,arg2);
10454 
10455  return SWIG_arg;
10456 
10457  if(0) SWIG_fail;
10458 
10459 fail:
10460  lua_error(L);
10461  return SWIG_arg;
10462 }
10463 
10464 
10465 static int _wrap_ssym(lua_State* L) {
10466  int SWIG_arg = 0;
10467  PLFLT arg1 ;
10468  PLFLT arg2 ;
10469 
10470  SWIG_check_num_args("plssym",2,2)
10471  if(!lua_isnumber(L,1)) SWIG_fail_arg("plssym",1,"PLFLT");
10472  if(!lua_isnumber(L,2)) SWIG_fail_arg("plssym",2,"PLFLT");
10473  arg1 = (PLFLT)lua_tonumber(L, 1);
10474  arg2 = (PLFLT)lua_tonumber(L, 2);
10475  plssym(arg1,arg2);
10476 
10477  return SWIG_arg;
10478 
10479  if(0) SWIG_fail;
10480 
10481 fail:
10482  lua_error(L);
10483  return SWIG_arg;
10484 }
10485 
10486 
10487 static int _wrap_star(lua_State* L) {
10488  int SWIG_arg = 0;
10489  PLINT arg1 ;
10490  PLINT arg2 ;
10491 
10492  SWIG_check_num_args("plstar",2,2)
10493  if(!lua_isnumber(L,1)) SWIG_fail_arg("plstar",1,"PLINT");
10494  if(!lua_isnumber(L,2)) SWIG_fail_arg("plstar",2,"PLINT");
10495  arg1 = (PLINT)lua_tonumber(L, 1);
10496  arg2 = (PLINT)lua_tonumber(L, 2);
10497  plstar(arg1,arg2);
10498 
10499  return SWIG_arg;
10500 
10501  if(0) SWIG_fail;
10502 
10503 fail:
10504  lua_error(L);
10505  return SWIG_arg;
10506 }
10507 
10508 
10509 static int _wrap_start(lua_State* L) {
10510  int SWIG_arg = 0;
10511  char *arg1 = (char *) 0 ;
10512  PLINT arg2 ;
10513  PLINT arg3 ;
10514 
10515  SWIG_check_num_args("plstart",3,3)
10516  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plstart",1,"char const *");
10517  if(!lua_isnumber(L,2)) SWIG_fail_arg("plstart",2,"PLINT");
10518  if(!lua_isnumber(L,3)) SWIG_fail_arg("plstart",3,"PLINT");
10519  arg1 = (char *)lua_tostring(L, 1);
10520  arg2 = (PLINT)lua_tonumber(L, 2);
10521  arg3 = (PLINT)lua_tonumber(L, 3);
10522  plstart((char const *)arg1,arg2,arg3);
10523 
10524  return SWIG_arg;
10525 
10526  if(0) SWIG_fail;
10527 
10528 fail:
10529  lua_error(L);
10530  return SWIG_arg;
10531 }
10532 
10533 
10534 static int _wrap_stransform(lua_State* L) {
10535  int SWIG_arg = 0;
10536  ct_func arg1 = (ct_func) 0 ;
10537  PLPointer arg2 = (PLPointer) 0 ;
10538 
10539  {
10540  arg1 = NULL;
10541  myct_funcstr[0] = '\0';
10542  }
10543  {
10544  arg2 = NULL;
10545  }
10546  SWIG_check_num_args("plstransform",0,1)
10547  if(lua_gettop(L)>=1){
10548  {
10549  arg1 = NULL;
10550  myct_funcstr[0] = '\0';
10551 
10552  if ( lua_isstring( L, 1 ) )
10553  {
10554  const char* funcstr = lua_tostring( L, 1 );
10555  arg1 = myct;
10556  strncpy( myct_funcstr, funcstr, 255 );
10557  myL = L;
10558  }
10559  else
10560  SWIG_fail_arg( "stransform", 1, "ct_func" );
10561  }
10562  }
10563  plstransform(arg1,arg2);
10564 
10565  return SWIG_arg;
10566 
10567  if(0) SWIG_fail;
10568 
10569 fail:
10570  lua_error(L);
10571  return SWIG_arg;
10572 }
10573 
10574 
10575 static int _wrap_string(lua_State* L) {
10576  int SWIG_arg = 0;
10577  PLINT arg1 ;
10578  PLFLT *arg2 = (PLFLT *) 0 ;
10579  PLFLT *arg3 = (PLFLT *) 0 ;
10580  char *arg4 = (char *) 0 ;
10581  int temp3 ;
10582 
10583  SWIG_check_num_args("plstring",3,3)
10584  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("plstring",3,"char const *");
10585  {
10586  int temp;
10587  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
10588  if ( !arg2 )
10589  SWIG_fail;
10590  arg1 = Alen = temp;
10591  }
10592  {
10593  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
10594  if ( !arg3 )
10595  SWIG_fail;
10596  if ( temp3 != Alen )
10597  {
10598  lua_pushfstring( L, "Tables must be of same length." );
10599  SWIG_fail;
10600  }
10601  }
10602  arg4 = (char *)lua_tostring(L, 3);
10603  plstring(arg1,(double const *)arg2,(double const *)arg3,(char const *)arg4);
10604 
10605  {
10606  LUA_FREE_ARRAY( arg2 );
10607  }
10608  {
10609  LUA_FREE_ARRAY( arg3 );
10610  }
10611  return SWIG_arg;
10612 
10613  if(0) SWIG_fail;
10614 
10615 fail:
10616  {
10617  LUA_FREE_ARRAY( arg2 );
10618  }
10619  {
10620  LUA_FREE_ARRAY( arg3 );
10621  }
10622  lua_error(L);
10623  return SWIG_arg;
10624 }
10625 
10626 
10627 static int _wrap_string3(lua_State* L) {
10628  int SWIG_arg = 0;
10629  PLINT arg1 ;
10630  PLFLT *arg2 = (PLFLT *) 0 ;
10631  PLFLT *arg3 = (PLFLT *) 0 ;
10632  PLFLT *arg4 = (PLFLT *) 0 ;
10633  char *arg5 = (char *) 0 ;
10634  int temp3 ;
10635  int temp4 ;
10636 
10637  SWIG_check_num_args("plstring3",4,4)
10638  if(!SWIG_lua_isnilstring(L,4)) SWIG_fail_arg("plstring3",4,"char const *");
10639  {
10640  int temp;
10641  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
10642  if ( !arg2 )
10643  SWIG_fail;
10644  arg1 = Alen = temp;
10645  }
10646  {
10647  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
10648  if ( !arg3 )
10649  SWIG_fail;
10650  if ( temp3 != Alen )
10651  {
10652  lua_pushfstring( L, "Tables must be of same length." );
10653  SWIG_fail;
10654  }
10655  }
10656  {
10657  arg4 = (PLFLT *) LUA_get_double_num_array_var( L, 3, &temp4 );
10658  if ( !arg4 )
10659  SWIG_fail;
10660  if ( temp4 != Alen )
10661  {
10662  lua_pushfstring( L, "Tables must be of same length." );
10663  SWIG_fail;
10664  }
10665  }
10666  arg5 = (char *)lua_tostring(L, 4);
10667  plstring3(arg1,(double const *)arg2,(double const *)arg3,(double const *)arg4,(char const *)arg5);
10668 
10669  {
10670  LUA_FREE_ARRAY( arg2 );
10671  }
10672  {
10673  LUA_FREE_ARRAY( arg3 );
10674  }
10675  {
10676  LUA_FREE_ARRAY( arg4 );
10677  }
10678  return SWIG_arg;
10679 
10680  if(0) SWIG_fail;
10681 
10682 fail:
10683  {
10684  LUA_FREE_ARRAY( arg2 );
10685  }
10686  {
10687  LUA_FREE_ARRAY( arg3 );
10688  }
10689  {
10690  LUA_FREE_ARRAY( arg4 );
10691  }
10692  lua_error(L);
10693  return SWIG_arg;
10694 }
10695 
10696 
10697 static int _wrap_stripa(lua_State* L) {
10698  int SWIG_arg = 0;
10699  PLINT arg1 ;
10700  PLINT arg2 ;
10701  PLFLT arg3 ;
10702  PLFLT arg4 ;
10703 
10704  SWIG_check_num_args("plstripa",4,4)
10705  if(!lua_isnumber(L,1)) SWIG_fail_arg("plstripa",1,"PLINT");
10706  if(!lua_isnumber(L,2)) SWIG_fail_arg("plstripa",2,"PLINT");
10707  if(!lua_isnumber(L,3)) SWIG_fail_arg("plstripa",3,"PLFLT");
10708  if(!lua_isnumber(L,4)) SWIG_fail_arg("plstripa",4,"PLFLT");
10709  arg1 = (PLINT)lua_tonumber(L, 1);
10710  arg2 = (PLINT)lua_tonumber(L, 2);
10711  arg3 = (PLFLT)lua_tonumber(L, 3);
10712  arg4 = (PLFLT)lua_tonumber(L, 4);
10713  plstripa(arg1,arg2,arg3,arg4);
10714 
10715  return SWIG_arg;
10716 
10717  if(0) SWIG_fail;
10718 
10719 fail:
10720  lua_error(L);
10721  return SWIG_arg;
10722 }
10723 
10724 
10725 static int _wrap_stripc(lua_State* L) {
10726  int SWIG_arg = 0;
10727  PLINT *arg1 = (PLINT *) 0 ;
10728  char *arg2 = (char *) 0 ;
10729  char *arg3 = (char *) 0 ;
10730  PLFLT arg4 ;
10731  PLFLT arg5 ;
10732  PLFLT arg6 ;
10733  PLFLT arg7 ;
10734  PLFLT arg8 ;
10735  PLFLT arg9 ;
10736  PLFLT arg10 ;
10737  PLBOOL arg11 ;
10738  PLBOOL arg12 ;
10739  PLINT arg13 ;
10740  PLINT arg14 ;
10741  PLINT *arg15 = (PLINT *) 0 ;
10742  PLINT *arg16 = (PLINT *) 0 ;
10743  char **arg17 ;
10744  char *arg18 = (char *) 0 ;
10745  char *arg19 = (char *) 0 ;
10746  char *arg20 = (char *) 0 ;
10747  PLINT temp1 ;
10748  int temp15 ;
10749  int temp16 ;
10750 
10751  {
10752  arg17 = NULL;
10753  }
10754  arg1 = &temp1;
10755  SWIG_check_num_args("plstripc",15,19)
10756  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plstripc",1,"char const *");
10757  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plstripc",2,"char const *");
10758  if(!lua_isnumber(L,3)) SWIG_fail_arg("plstripc",3,"PLFLT");
10759  if(!lua_isnumber(L,4)) SWIG_fail_arg("plstripc",4,"PLFLT");
10760  if(!lua_isnumber(L,5)) SWIG_fail_arg("plstripc",5,"PLFLT");
10761  if(!lua_isnumber(L,6)) SWIG_fail_arg("plstripc",6,"PLFLT");
10762  if(!lua_isnumber(L,7)) SWIG_fail_arg("plstripc",7,"PLFLT");
10763  if(!lua_isnumber(L,8)) SWIG_fail_arg("plstripc",8,"PLFLT");
10764  if(!lua_isnumber(L,9)) SWIG_fail_arg("plstripc",9,"PLFLT");
10765  if(!lua_isnumber(L,10)) SWIG_fail_arg("plstripc",10,"PLBOOL");
10766  if(!lua_isnumber(L,11)) SWIG_fail_arg("plstripc",11,"PLBOOL");
10767  if(!lua_isnumber(L,12)) SWIG_fail_arg("plstripc",12,"PLINT");
10768  if(!lua_isnumber(L,13)) SWIG_fail_arg("plstripc",13,"PLINT");
10769  if(lua_gettop(L)>=16 && !lua_istable(L,16)) SWIG_fail_arg("plstripc",16,"char const *[4]");
10770  if(lua_gettop(L)>=17 && !SWIG_lua_isnilstring(L,17)) SWIG_fail_arg("plstripc",17,"char const *");
10771  if(lua_gettop(L)>=18 && !SWIG_lua_isnilstring(L,18)) SWIG_fail_arg("plstripc",18,"char const *");
10772  if(lua_gettop(L)>=19 && !SWIG_lua_isnilstring(L,19)) SWIG_fail_arg("plstripc",19,"char const *");
10773  arg2 = (char *)lua_tostring(L, 1);
10774  arg3 = (char *)lua_tostring(L, 2);
10775  arg4 = (PLFLT)lua_tonumber(L, 3);
10776  arg5 = (PLFLT)lua_tonumber(L, 4);
10777  arg6 = (PLFLT)lua_tonumber(L, 5);
10778  arg7 = (PLFLT)lua_tonumber(L, 6);
10779  arg8 = (PLFLT)lua_tonumber(L, 7);
10780  arg9 = (PLFLT)lua_tonumber(L, 8);
10781  arg10 = (PLFLT)lua_tonumber(L, 9);
10782  arg11 = (PLBOOL)lua_tonumber(L, 10);
10783  arg12 = (PLBOOL)lua_tonumber(L, 11);
10784  arg13 = (PLINT)lua_tonumber(L, 12);
10785  arg14 = (PLINT)lua_tonumber(L, 13);
10786  {
10787  arg15 = (PLINT *) LUA_get_int_num_array_var( L, 14, &temp15 );
10788  if ( !arg15 )
10789  SWIG_fail;
10790  Alen = temp15;
10791  }
10792  {
10793  arg16 = (PLINT *) LUA_get_int_num_array_var( L, 15, &temp16 );
10794  if ( !arg16 )
10795  SWIG_fail;
10796  if ( temp16 != Alen )
10797  {
10798  lua_pushfstring( L, "Tables must be of same length." );
10799  SWIG_fail;
10800  }
10801  }
10802  if(lua_gettop(L)>=16){
10803  {
10804  int i;
10805  arg17 = NULL;
10806 
10807  if ( SWIG_table_size( L, 16 ) != 4 )
10808  {
10809  lua_pushfstring( L, "Requires a sequence of 4 strings." );
10810  SWIG_fail;
10811  }
10812  if ( Alen != 4 )
10813  {
10814  lua_pushfstring( L, "colline and styline args must be length 4." );
10815  SWIG_fail;
10816  }
10817 
10818  arg17 = malloc( sizeof ( char* ) * 4 );
10819  for ( i = 1; i <= 4; i++ )
10820  {
10821  lua_rawgeti( L, 16, i );
10822  if ( lua_isstring( L, -1 ) )
10823  {
10824  arg17[i - 1] = (char *) lua_tostring( L, -1 );
10825  }
10826  else
10827  {
10828  lua_pop( L, 1 );
10829  lua_pushfstring( L, "Requires a sequence of 4 strings." );
10830  SWIG_fail;
10831  // arg17 array is freed after 'fail:'
10832  }
10833  lua_pop( L, 1 );
10834  }
10835  }
10836  }
10837  if(lua_gettop(L)>=17){
10838  arg18 = (char *)lua_tostring(L, 17);
10839  }
10840  if(lua_gettop(L)>=18){
10841  arg19 = (char *)lua_tostring(L, 18);
10842  }
10843  if(lua_gettop(L)>=19){
10844  arg20 = (char *)lua_tostring(L, 19);
10845  }
10846  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);
10847 
10848  lua_pushnumber(L, (lua_Number) *arg1); SWIG_arg++;
10849  {
10850  LUA_FREE_ARRAY( arg15 );
10851  }
10852  {
10853  LUA_FREE_ARRAY( arg16 );
10854  }
10855  {
10856  if ( arg17 )
10857  {
10858  free( arg17 ); arg17 = NULL;
10859  }
10860  }
10861  return SWIG_arg;
10862 
10863  if(0) SWIG_fail;
10864 
10865 fail:
10866  {
10867  LUA_FREE_ARRAY( arg15 );
10868  }
10869  {
10870  LUA_FREE_ARRAY( arg16 );
10871  }
10872  {
10873  if ( arg17 )
10874  {
10875  free( arg17 ); arg17 = NULL;
10876  }
10877  }
10878  lua_error(L);
10879  return SWIG_arg;
10880 }
10881 
10882 
10883 static int _wrap_stripd(lua_State* L) {
10884  int SWIG_arg = 0;
10885  PLINT arg1 ;
10886 
10887  SWIG_check_num_args("plstripd",1,1)
10888  if(!lua_isnumber(L,1)) SWIG_fail_arg("plstripd",1,"PLINT");
10889  arg1 = (PLINT)lua_tonumber(L, 1);
10890  plstripd(arg1);
10891 
10892  return SWIG_arg;
10893 
10894  if(0) SWIG_fail;
10895 
10896 fail:
10897  lua_error(L);
10898  return SWIG_arg;
10899 }
10900 
10901 
10902 static int _wrap_styl(lua_State* L) {
10903  int SWIG_arg = 0;
10904  PLINT arg1 ;
10905  PLINT *arg2 = (PLINT *) 0 ;
10906  PLINT *arg3 = (PLINT *) 0 ;
10907  int temp3 ;
10908 
10909  SWIG_check_num_args("plstyl",2,2)
10910  {
10911  arg2 = (PLINT *) LUA_get_int_num_array_var( L, 1, &arg1 );
10912  if ( !arg2 )
10913  SWIG_fail;
10914  Alen = arg1;
10915  }
10916  {
10917  arg3 = (PLINT *) LUA_get_int_num_array_var( L, 2, &temp3 );
10918  if ( !arg3 )
10919  SWIG_fail;
10920  if ( temp3 != Alen )
10921  {
10922  lua_pushfstring( L, "Tables must be of same length." );
10923  SWIG_fail;
10924  }
10925  }
10926  plstyl(arg1,(int const *)arg2,(int const *)arg3);
10927 
10928  {
10929  LUA_FREE_ARRAY( arg2 );
10930  }
10931  {
10932  LUA_FREE_ARRAY( arg3 );
10933  }
10934  return SWIG_arg;
10935 
10936  if(0) SWIG_fail;
10937 
10938 fail:
10939  {
10940  LUA_FREE_ARRAY( arg2 );
10941  }
10942  {
10943  LUA_FREE_ARRAY( arg3 );
10944  }
10945  lua_error(L);
10946  return SWIG_arg;
10947 }
10948 
10949 
10950 static int _wrap_svect(lua_State* L) {
10951  int SWIG_arg = 0;
10952  PLFLT *arg1 = (PLFLT *) 0 ;
10953  PLFLT *arg2 = (PLFLT *) 0 ;
10954  PLINT arg3 ;
10955  PLBOOL arg4 ;
10956 
10957  {
10958  arg2 = NULL; arg3 = 0;
10959  }
10960  {
10961  arg4 = 0;
10962  }
10963  SWIG_check_num_args("plsvect",1,3)
10964  if(lua_gettop(L)>=3 && !lua_isnumber(L,3)) SWIG_fail_arg("plsvect",3,"PLBOOL");
10965  {
10966  int temp;
10967  if ( lua_isnil( L, 1 ) )
10968  {
10969  arg1 = NULL;
10970  Alen = 0;
10971  }
10972  else
10973  {
10974  arg1 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
10975  if ( !arg1 )
10976  SWIG_fail;
10977  Alen = temp;
10978  }
10979  }
10980  if(lua_gettop(L)>=2){
10981  {
10982  int temp = 0;
10983  if ( lua_isnil( L, 2 ) )
10984  {
10985  arg2 = NULL;
10986  }
10987  else
10988  {
10989  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp );
10990  if ( !arg2 )
10991  SWIG_fail;
10992  if ( temp != Alen )
10993  {
10994  lua_pushfstring( L, "Tables must be of same length." );
10995  SWIG_fail;
10996  }
10997  }
10998  arg3 = temp;
10999  }
11000  }
11001  if(lua_gettop(L)>=3){
11002  arg4 = (PLBOOL)lua_tonumber(L, 3);
11003  }
11004  plsvect((double const *)arg1,(double const *)arg2,arg3,arg4);
11005 
11006  {
11007  LUA_FREE_ARRAY( arg2 );
11008  }
11009  return SWIG_arg;
11010 
11011  if(0) SWIG_fail;
11012 
11013 fail:
11014  {
11015  LUA_FREE_ARRAY( arg2 );
11016  }
11017  lua_error(L);
11018  return SWIG_arg;
11019 }
11020 
11021 
11022 static int _wrap_svpa(lua_State* L) {
11023  int SWIG_arg = 0;
11024  PLFLT arg1 ;
11025  PLFLT arg2 ;
11026  PLFLT arg3 ;
11027  PLFLT arg4 ;
11028 
11029  SWIG_check_num_args("plsvpa",4,4)
11030  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsvpa",1,"PLFLT");
11031  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsvpa",2,"PLFLT");
11032  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsvpa",3,"PLFLT");
11033  if(!lua_isnumber(L,4)) SWIG_fail_arg("plsvpa",4,"PLFLT");
11034  arg1 = (PLFLT)lua_tonumber(L, 1);
11035  arg2 = (PLFLT)lua_tonumber(L, 2);
11036  arg3 = (PLFLT)lua_tonumber(L, 3);
11037  arg4 = (PLFLT)lua_tonumber(L, 4);
11038  plsvpa(arg1,arg2,arg3,arg4);
11039 
11040  return SWIG_arg;
11041 
11042  if(0) SWIG_fail;
11043 
11044 fail:
11045  lua_error(L);
11046  return SWIG_arg;
11047 }
11048 
11049 
11050 static int _wrap_sxax(lua_State* L) {
11051  int SWIG_arg = 0;
11052  PLINT arg1 ;
11053  PLINT arg2 ;
11054 
11055  SWIG_check_num_args("plsxax",2,2)
11056  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsxax",1,"PLINT");
11057  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsxax",2,"PLINT");
11058  arg1 = (PLINT)lua_tonumber(L, 1);
11059  arg2 = (PLINT)lua_tonumber(L, 2);
11060  plsxax(arg1,arg2);
11061 
11062  return SWIG_arg;
11063 
11064  if(0) SWIG_fail;
11065 
11066 fail:
11067  lua_error(L);
11068  return SWIG_arg;
11069 }
11070 
11071 
11072 static int _wrap_syax(lua_State* L) {
11073  int SWIG_arg = 0;
11074  PLINT arg1 ;
11075  PLINT arg2 ;
11076 
11077  SWIG_check_num_args("plsyax",2,2)
11078  if(!lua_isnumber(L,1)) SWIG_fail_arg("plsyax",1,"PLINT");
11079  if(!lua_isnumber(L,2)) SWIG_fail_arg("plsyax",2,"PLINT");
11080  arg1 = (PLINT)lua_tonumber(L, 1);
11081  arg2 = (PLINT)lua_tonumber(L, 2);
11082  plsyax(arg1,arg2);
11083 
11084  return SWIG_arg;
11085 
11086  if(0) SWIG_fail;
11087 
11088 fail:
11089  lua_error(L);
11090  return SWIG_arg;
11091 }
11092 
11093 
11094 static int _wrap_sym(lua_State* L) {
11095  int SWIG_arg = 0;
11096  PLINT arg1 ;
11097  PLFLT *arg2 = (PLFLT *) 0 ;
11098  PLFLT *arg3 = (PLFLT *) 0 ;
11099  PLINT arg4 ;
11100  int temp3 ;
11101 
11102  SWIG_check_num_args("plsym",3,3)
11103  if(!lua_isnumber(L,3)) SWIG_fail_arg("plsym",3,"PLINT");
11104  {
11105  int temp;
11106  arg2 = (PLFLT *) LUA_get_double_num_array_var( L, 1, &temp );
11107  if ( !arg2 )
11108  SWIG_fail;
11109  arg1 = Alen = temp;
11110  }
11111  {
11112  arg3 = (PLFLT *) LUA_get_double_num_array_var( L, 2, &temp3 );
11113  if ( !arg3 )
11114  SWIG_fail;
11115  if ( temp3 != Alen )
11116  {
11117  lua_pushfstring( L, "Tables must be of same length." );
11118  SWIG_fail;
11119  }
11120  }
11121  arg4 = (PLINT)lua_tonumber(L, 3);
11122  plsym(arg1,(double const *)arg2,(double const *)arg3,arg4);
11123 
11124  {
11125  LUA_FREE_ARRAY( arg2 );
11126  }
11127  {
11128  LUA_FREE_ARRAY( arg3 );
11129  }
11130  return SWIG_arg;
11131 
11132  if(0) SWIG_fail;
11133 
11134 fail:
11135  {
11136  LUA_FREE_ARRAY( arg2 );
11137  }
11138  {
11139  LUA_FREE_ARRAY( arg3 );
11140  }
11141  lua_error(L);
11142  return SWIG_arg;
11143 }
11144 
11145 
11146 static int _wrap_szax(lua_State* L) {
11147  int SWIG_arg = 0;
11148  PLINT arg1 ;
11149  PLINT arg2 ;
11150 
11151  SWIG_check_num_args("plszax",2,2)
11152  if(!lua_isnumber(L,1)) SWIG_fail_arg("plszax",1,"PLINT");
11153  if(!lua_isnumber(L,2)) SWIG_fail_arg("plszax",2,"PLINT");
11154  arg1 = (PLINT)lua_tonumber(L, 1);
11155  arg2 = (PLINT)lua_tonumber(L, 2);
11156  plszax(arg1,arg2);
11157 
11158  return SWIG_arg;
11159 
11160  if(0) SWIG_fail;
11161 
11162 fail:
11163  lua_error(L);
11164  return SWIG_arg;
11165 }
11166 
11167 
11168 static int _wrap_text(lua_State* L) {
11169  int SWIG_arg = 0;
11170 
11171  SWIG_check_num_args("pltext",0,0)
11172  pltext();
11173 
11174  return SWIG_arg;
11175 
11176  if(0) SWIG_fail;
11177 
11178 fail:
11179  lua_error(L);
11180  return SWIG_arg;
11181 }
11182 
11183 
11184 static int _wrap_timefmt(lua_State* L) {
11185  int SWIG_arg = 0;
11186  char *arg1 = (char *) 0 ;
11187 
11188  SWIG_check_num_args("pltimefmt",1,1)
11189  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("pltimefmt",1,"char const *");
11190  arg1 = (char *)lua_tostring(L, 1);
11191  pltimefmt((char const *)arg1);
11192 
11193  return SWIG_arg;
11194 
11195  if(0) SWIG_fail;
11196 
11197 fail:
11198  lua_error(L);
11199  return SWIG_arg;
11200 }
11201 
11202 
11203 static int _wrap_vasp(lua_State* L) {
11204  int SWIG_arg = 0;
11205  PLFLT arg1 ;
11206 
11207  SWIG_check_num_args("plvasp",1,1)
11208  if(!lua_isnumber(L,1)) SWIG_fail_arg("plvasp",1,"PLFLT");
11209  arg1 = (PLFLT)lua_tonumber(L, 1);
11210  plvasp(arg1);
11211 
11212  return SWIG_arg;
11213 
11214  if(0) SWIG_fail;
11215 
11216 fail:
11217  lua_error(L);
11218  return SWIG_arg;
11219 }
11220 
11221 
11222 static int _wrap_vect(lua_State* L) {
11223  int SWIG_arg = 0;
11224  PLFLT **arg1 = (PLFLT **) 0 ;
11225  PLFLT **arg2 = (PLFLT **) 0 ;
11226  PLINT arg3 ;
11227  PLINT arg4 ;
11228  PLFLT arg5 ;
11229  pltr_func arg6 = (pltr_func) 0 ;
11230  PLPointer arg7 = (PLPointer) 0 ;
11231  int ii1 ;
11232  int ii2 ;
11233  PLcGrid cgrid17 ;
11234  PLcGrid2 cgrid27 ;
11235 
11236  {
11237  cgrid17.xg = cgrid17.yg = cgrid17.zg = NULL;
11238  cgrid17.nx = cgrid17.ny = cgrid17.nz = 0;
11239  cgrid27.xg = cgrid27.yg = cgrid27.zg = NULL;
11240  cgrid27.nx = cgrid27.ny = 0;
11241  }
11242  {
11243  arg6 = NULL;
11244  }
11245  {
11246  arg7 = NULL;
11247  }
11248  SWIG_check_num_args("plvect",3,5)
11249  if(!lua_isnumber(L,3)) SWIG_fail_arg("plvect",3,"PLFLT");
11250  {
11251  int jj;
11252 
11253  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
11254  if ( !arg1 )
11255  SWIG_fail;
11256  Xlen = ii1;
11257  Ylen = jj;
11258  }
11259  {
11260  int jj;
11261 
11262  arg2 = read_double_Matrix( L, 2, &ii2, &jj );
11263  if ( !arg2 )
11264  SWIG_fail;
11265  arg3 = ii2;
11266  arg4 = jj;
11267  if ( ( arg3 != Xlen ) || ( arg4 != Ylen ) )
11268  {
11269  lua_pushfstring( L, "Vectors must match matrix." );
11270  SWIG_fail;
11271  }
11272  }
11273  arg5 = (PLFLT)lua_tonumber(L, 3);
11274  if(lua_gettop(L)>=4){
11275  {
11276  arg6 = NULL;
11277  mypltr_funcstr[0] = '\0';
11278 
11279  if ( lua_isstring( L, 4 ) )
11280  {
11281  const char* funcstr = lua_tostring( L, 4 );
11282  if ( strcmp( "pltr0", funcstr ) == 0 )
11283  {
11284  arg6 = pltr0;
11285  }
11286  else if ( strcmp( "pltr1", funcstr ) == 0 )
11287  {
11288  arg6 = pltr1;
11289  }
11290  else if ( strcmp( "pltr2", funcstr ) == 0 )
11291  {
11292  arg6 = pltr2;
11293  }
11294  else
11295  {
11296  arg6 = mypltr;
11297  strncpy( mypltr_funcstr, funcstr, 255 );
11298  myL = L;
11299  }
11300  }
11301  else
11302  SWIG_fail_arg( "vect", 6, "pltr_func" );
11303  }
11304  }
11305  if(lua_gettop(L)>=5){
11306  {
11307  int nx, ny;
11308  int gridmode = 0;
11309 
11310  lua_pushstring( L, "xg" );
11311  lua_gettable( L, 5 );
11312  if ( !lua_istable( L, -1 ) )
11313  {
11314  lua_pop( L, 1 ); // pop "xg"
11315  lua_pushstring( L, "expected a table xg" );
11316  SWIG_fail;
11317  }
11318  lua_rawgeti( L, -1, 1 );
11319  if ( lua_istable( L, -1 ) )
11320  gridmode = 2; // two dimensional array
11321  else if ( lua_isnumber( L, -1 ) )
11322  gridmode = 1; // one dimensional array
11323  else
11324  {
11325  lua_pop( L, 1 ); // pop "1"
11326  lua_pop( L, 1 ); // pop "xg"
11327  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
11328  SWIG_fail;
11329  }
11330  lua_pop( L, 1 ); // pop test element
11331  if ( gridmode == 1 )
11332  {
11333  cgrid17.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
11334  if ( !cgrid17.xg )
11335  {
11336  lua_pop( L, 1 ); // pop "xg"
11337  SWIG_fail;
11338  }
11339  if ( nx != Xlen )
11340  {
11341  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
11342  SWIG_fail;
11343  }
11344  cgrid17.nx = nx;
11345  }
11346  else
11347  {
11348  cgrid27.xg = read_double_Matrix( L, -1, &nx, &ny );
11349  if ( !cgrid27.xg )
11350  {
11351  lua_pop( L, 1 ); // pop "xg"
11352  SWIG_fail;
11353  }
11354  if ( ( nx != Xlen ) || ( ny != Ylen ) )
11355  {
11356  lua_pop( L, 1 ); // pop "xg"
11357  lua_pushfstring( L, "Vectors must match matrix." );
11358  SWIG_fail;
11359  }
11360  cgrid27.nx = nx;
11361  cgrid27.ny = ny;
11362  }
11363  lua_pop( L, 1 ); // pop "xg"
11364 
11365  lua_pushstring( L, "yg" );
11366  lua_gettable( L, 5 );
11367  if ( !lua_istable( L, -1 ) )
11368  {
11369  lua_pop( L, 1 );
11370  lua_pushstring( L, "expected a table yg" );
11371  SWIG_fail;
11372  }
11373  lua_rawgeti( L, -1, 1 );
11374  if ( gridmode == 2 )
11375  {
11376  if ( !lua_istable( L, -1 ) )
11377  {
11378  lua_pop( L, 1 ); // pop "1"
11379  lua_pop( L, 1 ); // pop "yg"
11380  lua_pushstring( L, "expected a two dimensional array/table in yg" );
11381  SWIG_fail;
11382  }
11383  }
11384  else
11385  {
11386  if ( !lua_isnumber( L, -1 ) )
11387  {
11388  lua_pop( L, 1 ); // pop "1"
11389  lua_pop( L, 1 ); // pop "yg"
11390  lua_pushstring( L, "expected a one dimensional array/table in yg" );
11391  SWIG_fail;
11392  }
11393  }
11394  lua_pop( L, 1 ); // pop "1"
11395  if ( gridmode == 1 )
11396  {
11397  cgrid17.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
11398  if ( !cgrid17.yg )
11399  {
11400  lua_pop( L, 1 ); // pop "yg"
11401  SWIG_fail;
11402  }
11403  if ( ny != Ylen )
11404  {
11405  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
11406  SWIG_fail;
11407  }
11408  cgrid17.ny = ny;
11409  }
11410  else
11411  {
11412  cgrid27.yg = read_double_Matrix( L, -1, &nx, &ny );
11413  if ( !cgrid27.yg )
11414  {
11415  lua_pop( L, 1 ); // pop "xg"
11416  SWIG_fail;
11417  }
11418  if ( ( nx != Xlen ) || ( ny != Ylen ) )
11419  {
11420  lua_pop( L, 1 ); // pop "xg"
11421  lua_pushfstring( L, "Vectors must match matrix." );
11422  SWIG_fail;
11423  }
11424  // cgrid27.nx/ny already set
11425  }
11426  lua_pop( L, 1 ); // pop "yg"
11427 
11428  if ( gridmode == 1 )
11429  arg7 = &cgrid17;
11430  else if ( gridmode == 2 )
11431  arg7 = &cgrid27;
11432  }
11433  }
11434  plvect((double const **)arg1,(double const **)arg2,arg3,arg4,arg5,arg6,arg7);
11435 
11436  {
11437  int i;
11438 
11439  if ( arg1 )
11440  {
11441  for ( i = 0; i < ii1; i++ )
11442  LUA_FREE_ARRAY( arg1[i] );
11443  LUA_FREE_ARRAY( arg1 );
11444  }
11445  }
11446  {
11447  int i;
11448 
11449  if ( arg2 )
11450  {
11451  for ( i = 0; i < ii2; i++ )
11452  LUA_FREE_ARRAY( arg2[i] );
11453  LUA_FREE_ARRAY( arg2 );
11454  }
11455  }
11456  {
11457  mypltr_funcstr[0] = '\0';
11458  }
11459  {
11460  int i;
11461 
11462  LUA_FREE_ARRAY( cgrid17.xg );
11463  LUA_FREE_ARRAY( cgrid17.yg );
11464 
11465  if ( cgrid27.xg )
11466  {
11467  for ( i = 0; i < Xlen; i++ )
11468  LUA_FREE_ARRAY( cgrid27.xg[i] );
11469  LUA_FREE_ARRAY( cgrid27.xg );
11470  }
11471  if ( cgrid27.yg )
11472  {
11473  for ( i = 0; i < Xlen; i++ )
11474  LUA_FREE_ARRAY( cgrid27.yg[i] );
11475  LUA_FREE_ARRAY( cgrid27.yg );
11476  }
11477  }
11478  return SWIG_arg;
11479 
11480  if(0) SWIG_fail;
11481 
11482 fail:
11483  {
11484  int i;
11485 
11486  if ( arg1 )
11487  {
11488  for ( i = 0; i < ii1; i++ )
11489  LUA_FREE_ARRAY( arg1[i] );
11490  LUA_FREE_ARRAY( arg1 );
11491  }
11492  }
11493  {
11494  int i;
11495 
11496  if ( arg2 )
11497  {
11498  for ( i = 0; i < ii2; i++ )
11499  LUA_FREE_ARRAY( arg2[i] );
11500  LUA_FREE_ARRAY( arg2 );
11501  }
11502  }
11503  {
11504  mypltr_funcstr[0] = '\0';
11505  }
11506  {
11507  int i;
11508 
11509  LUA_FREE_ARRAY( cgrid17.xg );
11510  LUA_FREE_ARRAY( cgrid17.yg );
11511 
11512  if ( cgrid27.xg )
11513  {
11514  for ( i = 0; i < Xlen; i++ )
11515  LUA_FREE_ARRAY( cgrid27.xg[i] );
11516  LUA_FREE_ARRAY( cgrid27.xg );
11517  }
11518  if ( cgrid27.yg )
11519  {
11520  for ( i = 0; i < Xlen; i++ )
11521  LUA_FREE_ARRAY( cgrid27.yg[i] );
11522  LUA_FREE_ARRAY( cgrid27.yg );
11523  }
11524  }
11525  lua_error(L);
11526  return SWIG_arg;
11527 }
11528 
11529 
11530 static int _wrap_vpas(lua_State* L) {
11531  int SWIG_arg = 0;
11532  PLFLT arg1 ;
11533  PLFLT arg2 ;
11534  PLFLT arg3 ;
11535  PLFLT arg4 ;
11536  PLFLT arg5 ;
11537 
11538  SWIG_check_num_args("plvpas",5,5)
11539  if(!lua_isnumber(L,1)) SWIG_fail_arg("plvpas",1,"PLFLT");
11540  if(!lua_isnumber(L,2)) SWIG_fail_arg("plvpas",2,"PLFLT");
11541  if(!lua_isnumber(L,3)) SWIG_fail_arg("plvpas",3,"PLFLT");
11542  if(!lua_isnumber(L,4)) SWIG_fail_arg("plvpas",4,"PLFLT");
11543  if(!lua_isnumber(L,5)) SWIG_fail_arg("plvpas",5,"PLFLT");
11544  arg1 = (PLFLT)lua_tonumber(L, 1);
11545  arg2 = (PLFLT)lua_tonumber(L, 2);
11546  arg3 = (PLFLT)lua_tonumber(L, 3);
11547  arg4 = (PLFLT)lua_tonumber(L, 4);
11548  arg5 = (PLFLT)lua_tonumber(L, 5);
11549  plvpas(arg1,arg2,arg3,arg4,arg5);
11550 
11551  return SWIG_arg;
11552 
11553  if(0) SWIG_fail;
11554 
11555 fail:
11556  lua_error(L);
11557  return SWIG_arg;
11558 }
11559 
11560 
11561 static int _wrap_vpor(lua_State* L) {
11562  int SWIG_arg = 0;
11563  PLFLT arg1 ;
11564  PLFLT arg2 ;
11565  PLFLT arg3 ;
11566  PLFLT arg4 ;
11567 
11568  SWIG_check_num_args("plvpor",4,4)
11569  if(!lua_isnumber(L,1)) SWIG_fail_arg("plvpor",1,"PLFLT");
11570  if(!lua_isnumber(L,2)) SWIG_fail_arg("plvpor",2,"PLFLT");
11571  if(!lua_isnumber(L,3)) SWIG_fail_arg("plvpor",3,"PLFLT");
11572  if(!lua_isnumber(L,4)) SWIG_fail_arg("plvpor",4,"PLFLT");
11573  arg1 = (PLFLT)lua_tonumber(L, 1);
11574  arg2 = (PLFLT)lua_tonumber(L, 2);
11575  arg3 = (PLFLT)lua_tonumber(L, 3);
11576  arg4 = (PLFLT)lua_tonumber(L, 4);
11577  plvpor(arg1,arg2,arg3,arg4);
11578 
11579  return SWIG_arg;
11580 
11581  if(0) SWIG_fail;
11582 
11583 fail:
11584  lua_error(L);
11585  return SWIG_arg;
11586 }
11587 
11588 
11589 static int _wrap_vsta(lua_State* L) {
11590  int SWIG_arg = 0;
11591 
11592  SWIG_check_num_args("plvsta",0,0)
11593  plvsta();
11594 
11595  return SWIG_arg;
11596 
11597  if(0) SWIG_fail;
11598 
11599 fail:
11600  lua_error(L);
11601  return SWIG_arg;
11602 }
11603 
11604 
11605 static int _wrap_w3d(lua_State* L) {
11606  int SWIG_arg = 0;
11607  PLFLT arg1 ;
11608  PLFLT arg2 ;
11609  PLFLT arg3 ;
11610  PLFLT arg4 ;
11611  PLFLT arg5 ;
11612  PLFLT arg6 ;
11613  PLFLT arg7 ;
11614  PLFLT arg8 ;
11615  PLFLT arg9 ;
11616  PLFLT arg10 ;
11617  PLFLT arg11 ;
11618 
11619  SWIG_check_num_args("plw3d",11,11)
11620  if(!lua_isnumber(L,1)) SWIG_fail_arg("plw3d",1,"PLFLT");
11621  if(!lua_isnumber(L,2)) SWIG_fail_arg("plw3d",2,"PLFLT");
11622  if(!lua_isnumber(L,3)) SWIG_fail_arg("plw3d",3,"PLFLT");
11623  if(!lua_isnumber(L,4)) SWIG_fail_arg("plw3d",4,"PLFLT");
11624  if(!lua_isnumber(L,5)) SWIG_fail_arg("plw3d",5,"PLFLT");
11625  if(!lua_isnumber(L,6)) SWIG_fail_arg("plw3d",6,"PLFLT");
11626  if(!lua_isnumber(L,7)) SWIG_fail_arg("plw3d",7,"PLFLT");
11627  if(!lua_isnumber(L,8)) SWIG_fail_arg("plw3d",8,"PLFLT");
11628  if(!lua_isnumber(L,9)) SWIG_fail_arg("plw3d",9,"PLFLT");
11629  if(!lua_isnumber(L,10)) SWIG_fail_arg("plw3d",10,"PLFLT");
11630  if(!lua_isnumber(L,11)) SWIG_fail_arg("plw3d",11,"PLFLT");
11631  arg1 = (PLFLT)lua_tonumber(L, 1);
11632  arg2 = (PLFLT)lua_tonumber(L, 2);
11633  arg3 = (PLFLT)lua_tonumber(L, 3);
11634  arg4 = (PLFLT)lua_tonumber(L, 4);
11635  arg5 = (PLFLT)lua_tonumber(L, 5);
11636  arg6 = (PLFLT)lua_tonumber(L, 6);
11637  arg7 = (PLFLT)lua_tonumber(L, 7);
11638  arg8 = (PLFLT)lua_tonumber(L, 8);
11639  arg9 = (PLFLT)lua_tonumber(L, 9);
11640  arg10 = (PLFLT)lua_tonumber(L, 10);
11641  arg11 = (PLFLT)lua_tonumber(L, 11);
11642  plw3d(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11);
11643 
11644  return SWIG_arg;
11645 
11646  if(0) SWIG_fail;
11647 
11648 fail:
11649  lua_error(L);
11650  return SWIG_arg;
11651 }
11652 
11653 
11654 static int _wrap_width(lua_State* L) {
11655  int SWIG_arg = 0;
11656  PLFLT arg1 ;
11657 
11658  SWIG_check_num_args("plwidth",1,1)
11659  if(!lua_isnumber(L,1)) SWIG_fail_arg("plwidth",1,"PLFLT");
11660  arg1 = (PLFLT)lua_tonumber(L, 1);
11661  plwidth(arg1);
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_wind(lua_State* L) {
11674  int SWIG_arg = 0;
11675  PLFLT arg1 ;
11676  PLFLT arg2 ;
11677  PLFLT arg3 ;
11678  PLFLT arg4 ;
11679 
11680  SWIG_check_num_args("plwind",4,4)
11681  if(!lua_isnumber(L,1)) SWIG_fail_arg("plwind",1,"PLFLT");
11682  if(!lua_isnumber(L,2)) SWIG_fail_arg("plwind",2,"PLFLT");
11683  if(!lua_isnumber(L,3)) SWIG_fail_arg("plwind",3,"PLFLT");
11684  if(!lua_isnumber(L,4)) SWIG_fail_arg("plwind",4,"PLFLT");
11685  arg1 = (PLFLT)lua_tonumber(L, 1);
11686  arg2 = (PLFLT)lua_tonumber(L, 2);
11687  arg3 = (PLFLT)lua_tonumber(L, 3);
11688  arg4 = (PLFLT)lua_tonumber(L, 4);
11689  plwind(arg1,arg2,arg3,arg4);
11690 
11691  return SWIG_arg;
11692 
11693  if(0) SWIG_fail;
11694 
11695 fail:
11696  lua_error(L);
11697  return SWIG_arg;
11698 }
11699 
11700 
11701 static int _wrap_xormod(lua_State* L) {
11702  int SWIG_arg = 0;
11703  PLBOOL arg1 ;
11704  PLBOOL *arg2 = (PLBOOL *) 0 ;
11705  PLBOOL temp2 ;
11706 
11707  arg2 = &temp2;
11708  SWIG_check_num_args("plxormod",1,1)
11709  if(!lua_isnumber(L,1)) SWIG_fail_arg("plxormod",1,"PLBOOL");
11710  arg1 = (PLBOOL)lua_tonumber(L, 1);
11711  plxormod(arg1,arg2);
11712 
11713  lua_pushnumber(L, (lua_Number) *arg2); SWIG_arg++;
11714  return SWIG_arg;
11715 
11716  if(0) SWIG_fail;
11717 
11718 fail:
11719  lua_error(L);
11720  return SWIG_arg;
11721 }
11722 
11723 
11724 static int _wrap_map(lua_State* L) {
11725  int SWIG_arg = 0;
11726  mapform_func arg1 = (mapform_func) 0 ;
11727  char *arg2 = (char *) 0 ;
11728  PLFLT arg3 ;
11729  PLFLT arg4 ;
11730  PLFLT arg5 ;
11731  PLFLT arg6 ;
11732 
11733  SWIG_check_num_args("plmap",6,6)
11734  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmap",2,"char const *");
11735  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmap",3,"PLFLT");
11736  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmap",4,"PLFLT");
11737  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmap",5,"PLFLT");
11738  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmap",6,"PLFLT");
11739  {
11740  arg1 = NULL;
11741  mapform_funcstr[0] = '\0';
11742 
11743  if ( lua_isnil( L, 1 ) )
11744  {
11745  arg1 = NULL;
11746  }
11747  else if ( lua_isstring( L, 1 ) )
11748  {
11749  arg1 = mapform;
11750  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11751  myL = L;
11752  }
11753  else
11754  SWIG_fail_arg( "map", 1, "mapform_func" );
11755  }
11756  arg2 = (char *)lua_tostring(L, 2);
11757  arg3 = (PLFLT)lua_tonumber(L, 3);
11758  arg4 = (PLFLT)lua_tonumber(L, 4);
11759  arg5 = (PLFLT)lua_tonumber(L, 5);
11760  arg6 = (PLFLT)lua_tonumber(L, 6);
11761  plmap(arg1,(char const *)arg2,arg3,arg4,arg5,arg6);
11762 
11763  {
11764  mapform_funcstr[0] = '\0';
11765  }
11766  return SWIG_arg;
11767 
11768  if(0) SWIG_fail;
11769 
11770 fail:
11771  {
11772  mapform_funcstr[0] = '\0';
11773  }
11774  lua_error(L);
11775  return SWIG_arg;
11776 }
11777 
11778 
11779 static int _wrap_mapline(lua_State* L) {
11780  int SWIG_arg = 0;
11781  mapform_func arg1 = (mapform_func) 0 ;
11782  char *arg2 = (char *) 0 ;
11783  PLFLT arg3 ;
11784  PLFLT arg4 ;
11785  PLFLT arg5 ;
11786  PLFLT arg6 ;
11787  PLINT *arg7 = (PLINT *) 0 ;
11788  PLINT arg8 ;
11789  int temp7 ;
11790 
11791  SWIG_check_num_args("plmapline",7,7)
11792  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmapline",2,"char const *");
11793  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmapline",3,"PLFLT");
11794  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmapline",4,"PLFLT");
11795  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmapline",5,"PLFLT");
11796  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmapline",6,"PLFLT");
11797  {
11798  arg1 = NULL;
11799  mapform_funcstr[0] = '\0';
11800 
11801  if ( lua_isnil( L, 1 ) )
11802  {
11803  arg1 = NULL;
11804  }
11805  else if ( lua_isstring( L, 1 ) )
11806  {
11807  arg1 = mapform;
11808  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11809  myL = L;
11810  }
11811  else
11812  SWIG_fail_arg( "mapline", 1, "mapform_func" );
11813  }
11814  arg2 = (char *)lua_tostring(L, 2);
11815  arg3 = (PLFLT)lua_tonumber(L, 3);
11816  arg4 = (PLFLT)lua_tonumber(L, 4);
11817  arg5 = (PLFLT)lua_tonumber(L, 5);
11818  arg6 = (PLFLT)lua_tonumber(L, 6);
11819  {
11820  if ( lua_isnil( L, 7 ) )
11821  {
11822  arg7 = NULL;
11823  arg8 = 0;
11824  }
11825  else
11826  {
11827  arg7 = (PLINT *) LUA_get_int_num_array_var( L, 7, &temp7 );
11828  if ( !arg7 )
11829  SWIG_fail;
11830  arg8 = temp7;
11831  }
11832  }
11833  plmapline(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,(int const *)arg7,arg8);
11834 
11835  {
11836  mapform_funcstr[0] = '\0';
11837  }
11838  {
11839  LUA_FREE_ARRAY( arg7 );
11840  }
11841  return SWIG_arg;
11842 
11843  if(0) SWIG_fail;
11844 
11845 fail:
11846  {
11847  mapform_funcstr[0] = '\0';
11848  }
11849  {
11850  LUA_FREE_ARRAY( arg7 );
11851  }
11852  lua_error(L);
11853  return SWIG_arg;
11854 }
11855 
11856 
11857 static int _wrap_mapstring(lua_State* L) {
11858  int SWIG_arg = 0;
11859  mapform_func arg1 = (mapform_func) 0 ;
11860  char *arg2 = (char *) 0 ;
11861  char *arg3 = (char *) 0 ;
11862  PLFLT arg4 ;
11863  PLFLT arg5 ;
11864  PLFLT arg6 ;
11865  PLFLT arg7 ;
11866  PLINT *arg8 = (PLINT *) 0 ;
11867  PLINT arg9 ;
11868  int temp8 ;
11869 
11870  SWIG_check_num_args("plmapstring",8,8)
11871  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmapstring",2,"char const *");
11872  if(!SWIG_lua_isnilstring(L,3)) SWIG_fail_arg("plmapstring",3,"char const *");
11873  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmapstring",4,"PLFLT");
11874  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmapstring",5,"PLFLT");
11875  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmapstring",6,"PLFLT");
11876  if(!lua_isnumber(L,7)) SWIG_fail_arg("plmapstring",7,"PLFLT");
11877  {
11878  arg1 = NULL;
11879  mapform_funcstr[0] = '\0';
11880 
11881  if ( lua_isnil( L, 1 ) )
11882  {
11883  arg1 = NULL;
11884  }
11885  else if ( lua_isstring( L, 1 ) )
11886  {
11887  arg1 = mapform;
11888  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11889  myL = L;
11890  }
11891  else
11892  SWIG_fail_arg( "mapstring", 1, "mapform_func" );
11893  }
11894  arg2 = (char *)lua_tostring(L, 2);
11895  arg3 = (char *)lua_tostring(L, 3);
11896  arg4 = (PLFLT)lua_tonumber(L, 4);
11897  arg5 = (PLFLT)lua_tonumber(L, 5);
11898  arg6 = (PLFLT)lua_tonumber(L, 6);
11899  arg7 = (PLFLT)lua_tonumber(L, 7);
11900  {
11901  if ( lua_isnil( L, 8 ) )
11902  {
11903  arg8 = NULL;
11904  arg9 = 0;
11905  }
11906  else
11907  {
11908  arg8 = (PLINT *) LUA_get_int_num_array_var( L, 8, &temp8 );
11909  if ( !arg8 )
11910  SWIG_fail;
11911  arg9 = temp8;
11912  }
11913  }
11914  plmapstring(arg1,(char const *)arg2,(char const *)arg3,arg4,arg5,arg6,arg7,(int const *)arg8,arg9);
11915 
11916  {
11917  mapform_funcstr[0] = '\0';
11918  }
11919  {
11920  LUA_FREE_ARRAY( arg8 );
11921  }
11922  return SWIG_arg;
11923 
11924  if(0) SWIG_fail;
11925 
11926 fail:
11927  {
11928  mapform_funcstr[0] = '\0';
11929  }
11930  {
11931  LUA_FREE_ARRAY( arg8 );
11932  }
11933  lua_error(L);
11934  return SWIG_arg;
11935 }
11936 
11937 
11938 static int _wrap_maptex(lua_State* L) {
11939  int SWIG_arg = 0;
11940  mapform_func arg1 = (mapform_func) 0 ;
11941  char *arg2 = (char *) 0 ;
11942  PLFLT arg3 ;
11943  PLFLT arg4 ;
11944  PLFLT arg5 ;
11945  char *arg6 = (char *) 0 ;
11946  PLFLT arg7 ;
11947  PLFLT arg8 ;
11948  PLFLT arg9 ;
11949  PLFLT arg10 ;
11950  PLINT arg11 ;
11951 
11952  SWIG_check_num_args("plmaptex",11,11)
11953  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmaptex",2,"char const *");
11954  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmaptex",3,"PLFLT");
11955  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmaptex",4,"PLFLT");
11956  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmaptex",5,"PLFLT");
11957  if(!SWIG_lua_isnilstring(L,6)) SWIG_fail_arg("plmaptex",6,"char const *");
11958  if(!lua_isnumber(L,7)) SWIG_fail_arg("plmaptex",7,"PLFLT");
11959  if(!lua_isnumber(L,8)) SWIG_fail_arg("plmaptex",8,"PLFLT");
11960  if(!lua_isnumber(L,9)) SWIG_fail_arg("plmaptex",9,"PLFLT");
11961  if(!lua_isnumber(L,10)) SWIG_fail_arg("plmaptex",10,"PLFLT");
11962  if(!lua_isnumber(L,11)) SWIG_fail_arg("plmaptex",11,"PLINT");
11963  {
11964  arg1 = NULL;
11965  mapform_funcstr[0] = '\0';
11966 
11967  if ( lua_isnil( L, 1 ) )
11968  {
11969  arg1 = NULL;
11970  }
11971  else if ( lua_isstring( L, 1 ) )
11972  {
11973  arg1 = mapform;
11974  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
11975  myL = L;
11976  }
11977  else
11978  SWIG_fail_arg( "maptex", 1, "mapform_func" );
11979  }
11980  arg2 = (char *)lua_tostring(L, 2);
11981  arg3 = (PLFLT)lua_tonumber(L, 3);
11982  arg4 = (PLFLT)lua_tonumber(L, 4);
11983  arg5 = (PLFLT)lua_tonumber(L, 5);
11984  arg6 = (char *)lua_tostring(L, 6);
11985  arg7 = (PLFLT)lua_tonumber(L, 7);
11986  arg8 = (PLFLT)lua_tonumber(L, 8);
11987  arg9 = (PLFLT)lua_tonumber(L, 9);
11988  arg10 = (PLFLT)lua_tonumber(L, 10);
11989  arg11 = (PLINT)lua_tonumber(L, 11);
11990  plmaptex(arg1,(char const *)arg2,arg3,arg4,arg5,(char const *)arg6,arg7,arg8,arg9,arg10,arg11);
11991 
11992  {
11993  mapform_funcstr[0] = '\0';
11994  }
11995  return SWIG_arg;
11996 
11997  if(0) SWIG_fail;
11998 
11999 fail:
12000  {
12001  mapform_funcstr[0] = '\0';
12002  }
12003  lua_error(L);
12004  return SWIG_arg;
12005 }
12006 
12007 
12008 static int _wrap_mapfill(lua_State* L) {
12009  int SWIG_arg = 0;
12010  mapform_func arg1 = (mapform_func) 0 ;
12011  char *arg2 = (char *) 0 ;
12012  PLFLT arg3 ;
12013  PLFLT arg4 ;
12014  PLFLT arg5 ;
12015  PLFLT arg6 ;
12016  PLINT *arg7 = (PLINT *) 0 ;
12017  PLINT arg8 ;
12018  int temp7 ;
12019 
12020  SWIG_check_num_args("plmapfill",7,7)
12021  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plmapfill",2,"char const *");
12022  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmapfill",3,"PLFLT");
12023  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmapfill",4,"PLFLT");
12024  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmapfill",5,"PLFLT");
12025  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmapfill",6,"PLFLT");
12026  {
12027  arg1 = NULL;
12028  mapform_funcstr[0] = '\0';
12029 
12030  if ( lua_isnil( L, 1 ) )
12031  {
12032  arg1 = NULL;
12033  }
12034  else if ( lua_isstring( L, 1 ) )
12035  {
12036  arg1 = mapform;
12037  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
12038  myL = L;
12039  }
12040  else
12041  SWIG_fail_arg( "mapfill", 1, "mapform_func" );
12042  }
12043  arg2 = (char *)lua_tostring(L, 2);
12044  arg3 = (PLFLT)lua_tonumber(L, 3);
12045  arg4 = (PLFLT)lua_tonumber(L, 4);
12046  arg5 = (PLFLT)lua_tonumber(L, 5);
12047  arg6 = (PLFLT)lua_tonumber(L, 6);
12048  {
12049  if ( lua_isnil( L, 7 ) )
12050  {
12051  arg7 = NULL;
12052  arg8 = 0;
12053  }
12054  else
12055  {
12056  arg7 = (PLINT *) LUA_get_int_num_array_var( L, 7, &temp7 );
12057  if ( !arg7 )
12058  SWIG_fail;
12059  arg8 = temp7;
12060  }
12061  }
12062  plmapfill(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,(int const *)arg7,arg8);
12063 
12064  {
12065  mapform_funcstr[0] = '\0';
12066  }
12067  {
12068  LUA_FREE_ARRAY( arg7 );
12069  }
12070  return SWIG_arg;
12071 
12072  if(0) SWIG_fail;
12073 
12074 fail:
12075  {
12076  mapform_funcstr[0] = '\0';
12077  }
12078  {
12079  LUA_FREE_ARRAY( arg7 );
12080  }
12081  lua_error(L);
12082  return SWIG_arg;
12083 }
12084 
12085 
12086 static int _wrap_meridians(lua_State* L) {
12087  int SWIG_arg = 0;
12088  mapform_func arg1 = (mapform_func) 0 ;
12089  PLFLT arg2 ;
12090  PLFLT arg3 ;
12091  PLFLT arg4 ;
12092  PLFLT arg5 ;
12093  PLFLT arg6 ;
12094  PLFLT arg7 ;
12095 
12096  SWIG_check_num_args("plmeridians",7,7)
12097  if(!lua_isnumber(L,2)) SWIG_fail_arg("plmeridians",2,"PLFLT");
12098  if(!lua_isnumber(L,3)) SWIG_fail_arg("plmeridians",3,"PLFLT");
12099  if(!lua_isnumber(L,4)) SWIG_fail_arg("plmeridians",4,"PLFLT");
12100  if(!lua_isnumber(L,5)) SWIG_fail_arg("plmeridians",5,"PLFLT");
12101  if(!lua_isnumber(L,6)) SWIG_fail_arg("plmeridians",6,"PLFLT");
12102  if(!lua_isnumber(L,7)) SWIG_fail_arg("plmeridians",7,"PLFLT");
12103  {
12104  arg1 = NULL;
12105  mapform_funcstr[0] = '\0';
12106 
12107  if ( lua_isnil( L, 1 ) )
12108  {
12109  arg1 = NULL;
12110  }
12111  else if ( lua_isstring( L, 1 ) )
12112  {
12113  arg1 = mapform;
12114  strncpy( mapform_funcstr, lua_tostring( L, 1 ), 255 );
12115  myL = L;
12116  }
12117  else
12118  SWIG_fail_arg( "meridians", 1, "mapform_func" );
12119  }
12120  arg2 = (PLFLT)lua_tonumber(L, 2);
12121  arg3 = (PLFLT)lua_tonumber(L, 3);
12122  arg4 = (PLFLT)lua_tonumber(L, 4);
12123  arg5 = (PLFLT)lua_tonumber(L, 5);
12124  arg6 = (PLFLT)lua_tonumber(L, 6);
12125  arg7 = (PLFLT)lua_tonumber(L, 7);
12126  plmeridians(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
12127 
12128  {
12129  mapform_funcstr[0] = '\0';
12130  }
12131  return SWIG_arg;
12132 
12133  if(0) SWIG_fail;
12134 
12135 fail:
12136  {
12137  mapform_funcstr[0] = '\0';
12138  }
12139  lua_error(L);
12140  return SWIG_arg;
12141 }
12142 
12143 
12144 static int _wrap_image(lua_State* L) {
12145  int SWIG_arg = 0;
12146  PLFLT **arg1 = (PLFLT **) 0 ;
12147  PLINT arg2 ;
12148  PLINT arg3 ;
12149  PLFLT arg4 ;
12150  PLFLT arg5 ;
12151  PLFLT arg6 ;
12152  PLFLT arg7 ;
12153  PLFLT arg8 ;
12154  PLFLT arg9 ;
12155  PLFLT arg10 ;
12156  PLFLT arg11 ;
12157  PLFLT arg12 ;
12158  PLFLT arg13 ;
12159  int ii1 ;
12160 
12161  SWIG_check_num_args("plimage",11,11)
12162  if(!lua_isnumber(L,2)) SWIG_fail_arg("plimage",2,"PLFLT");
12163  if(!lua_isnumber(L,3)) SWIG_fail_arg("plimage",3,"PLFLT");
12164  if(!lua_isnumber(L,4)) SWIG_fail_arg("plimage",4,"PLFLT");
12165  if(!lua_isnumber(L,5)) SWIG_fail_arg("plimage",5,"PLFLT");
12166  if(!lua_isnumber(L,6)) SWIG_fail_arg("plimage",6,"PLFLT");
12167  if(!lua_isnumber(L,7)) SWIG_fail_arg("plimage",7,"PLFLT");
12168  if(!lua_isnumber(L,8)) SWIG_fail_arg("plimage",8,"PLFLT");
12169  if(!lua_isnumber(L,9)) SWIG_fail_arg("plimage",9,"PLFLT");
12170  if(!lua_isnumber(L,10)) SWIG_fail_arg("plimage",10,"PLFLT");
12171  if(!lua_isnumber(L,11)) SWIG_fail_arg("plimage",11,"PLFLT");
12172  {
12173  int jj;
12174 
12175  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
12176  if ( !arg1 )
12177  SWIG_fail;
12178  Xlen = arg2 = ii1;
12179  Ylen = arg3 = jj;
12180  }
12181  arg4 = (PLFLT)lua_tonumber(L, 2);
12182  arg5 = (PLFLT)lua_tonumber(L, 3);
12183  arg6 = (PLFLT)lua_tonumber(L, 4);
12184  arg7 = (PLFLT)lua_tonumber(L, 5);
12185  arg8 = (PLFLT)lua_tonumber(L, 6);
12186  arg9 = (PLFLT)lua_tonumber(L, 7);
12187  arg10 = (PLFLT)lua_tonumber(L, 8);
12188  arg11 = (PLFLT)lua_tonumber(L, 9);
12189  arg12 = (PLFLT)lua_tonumber(L, 10);
12190  arg13 = (PLFLT)lua_tonumber(L, 11);
12191  plimage((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13);
12192 
12193  {
12194  int i;
12195 
12196  if ( arg1 )
12197  {
12198  for ( i = 0; i < ii1; i++ )
12199  LUA_FREE_ARRAY( arg1[i] );
12200  LUA_FREE_ARRAY( arg1 );
12201  }
12202  }
12203  return SWIG_arg;
12204 
12205  if(0) SWIG_fail;
12206 
12207 fail:
12208  {
12209  int i;
12210 
12211  if ( arg1 )
12212  {
12213  for ( i = 0; i < ii1; i++ )
12214  LUA_FREE_ARRAY( arg1[i] );
12215  LUA_FREE_ARRAY( arg1 );
12216  }
12217  }
12218  lua_error(L);
12219  return SWIG_arg;
12220 }
12221 
12222 
12223 static int _wrap_imagefr(lua_State* L) {
12224  int SWIG_arg = 0;
12225  PLFLT **arg1 = (PLFLT **) 0 ;
12226  PLINT arg2 ;
12227  PLINT arg3 ;
12228  PLFLT arg4 ;
12229  PLFLT arg5 ;
12230  PLFLT arg6 ;
12231  PLFLT arg7 ;
12232  PLFLT arg8 ;
12233  PLFLT arg9 ;
12234  PLFLT arg10 ;
12235  PLFLT arg11 ;
12236  pltr_func arg12 = (pltr_func) 0 ;
12237  PLPointer arg13 = (PLPointer) 0 ;
12238  int ii1 ;
12239  PLcGrid cgrid113 ;
12240  PLcGrid2 cgrid213 ;
12241 
12242  {
12243  cgrid113.xg = cgrid113.yg = cgrid113.zg = NULL;
12244  cgrid113.nx = cgrid113.ny = cgrid113.nz = 0;
12245  cgrid213.xg = cgrid213.yg = cgrid213.zg = NULL;
12246  cgrid213.nx = cgrid213.ny = 0;
12247  }
12248  {
12249  arg12 = NULL;
12250  }
12251  {
12252  arg13 = NULL;
12253  }
12254  SWIG_check_num_args("plimagefr",9,11)
12255  if(!lua_isnumber(L,2)) SWIG_fail_arg("plimagefr",2,"PLFLT");
12256  if(!lua_isnumber(L,3)) SWIG_fail_arg("plimagefr",3,"PLFLT");
12257  if(!lua_isnumber(L,4)) SWIG_fail_arg("plimagefr",4,"PLFLT");
12258  if(!lua_isnumber(L,5)) SWIG_fail_arg("plimagefr",5,"PLFLT");
12259  if(!lua_isnumber(L,6)) SWIG_fail_arg("plimagefr",6,"PLFLT");
12260  if(!lua_isnumber(L,7)) SWIG_fail_arg("plimagefr",7,"PLFLT");
12261  if(!lua_isnumber(L,8)) SWIG_fail_arg("plimagefr",8,"PLFLT");
12262  if(!lua_isnumber(L,9)) SWIG_fail_arg("plimagefr",9,"PLFLT");
12263  {
12264  int jj;
12265 
12266  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
12267  if ( !arg1 )
12268  SWIG_fail;
12269  Xlen = arg2 = ii1;
12270  Ylen = arg3 = jj;
12271  }
12272  arg4 = (PLFLT)lua_tonumber(L, 2);
12273  arg5 = (PLFLT)lua_tonumber(L, 3);
12274  arg6 = (PLFLT)lua_tonumber(L, 4);
12275  arg7 = (PLFLT)lua_tonumber(L, 5);
12276  arg8 = (PLFLT)lua_tonumber(L, 6);
12277  arg9 = (PLFLT)lua_tonumber(L, 7);
12278  arg10 = (PLFLT)lua_tonumber(L, 8);
12279  arg11 = (PLFLT)lua_tonumber(L, 9);
12280  if(lua_gettop(L)>=10){
12281  {
12282  arg12 = NULL;
12283  mypltr_funcstr[0] = '\0';
12284 
12285  if ( lua_isstring( L, 10 ) )
12286  {
12287  const char* funcstr = lua_tostring( L, 10 );
12288  if ( strcmp( "pltr0", funcstr ) == 0 )
12289  {
12290  arg12 = pltr0;
12291  }
12292  else if ( strcmp( "pltr1", funcstr ) == 0 )
12293  {
12294  arg12 = pltr1;
12295  }
12296  else if ( strcmp( "pltr2", funcstr ) == 0 )
12297  {
12298  arg12 = pltr2;
12299  }
12300  else
12301  {
12302  arg12 = mypltr;
12303  strncpy( mypltr_funcstr, funcstr, 255 );
12304  myL = L;
12305  }
12306  }
12307  else
12308  SWIG_fail_arg( "imagefr", 12, "pltr_func" );
12309  }
12310  }
12311  if(lua_gettop(L)>=11){
12312  {
12313  int nx, ny;
12314  int gridmode = 0;
12315 
12316  lua_pushstring( L, "xg" );
12317  lua_gettable( L, 11 );
12318  if ( !lua_istable( L, -1 ) )
12319  {
12320  lua_pop( L, 1 ); // pop "xg"
12321  lua_pushstring( L, "expected a table xg" );
12322  SWIG_fail;
12323  }
12324  lua_rawgeti( L, -1, 1 );
12325  if ( lua_istable( L, -1 ) )
12326  gridmode = 2; // two dimensional array
12327  else if ( lua_isnumber( L, -1 ) )
12328  gridmode = 1; // one dimensional array
12329  else
12330  {
12331  lua_pop( L, 1 ); // pop "1"
12332  lua_pop( L, 1 ); // pop "xg"
12333  lua_pushstring( L, "expected a one or two dimensional array/table in xg" );
12334  SWIG_fail;
12335  }
12336  lua_pop( L, 1 ); // pop test element
12337  if ( gridmode == 1 )
12338  {
12339  cgrid113.xg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &nx );
12340  if ( !cgrid113.xg )
12341  {
12342  lua_pop( L, 1 ); // pop "xg"
12343  SWIG_fail;
12344  }
12345  if ( nx != Xlen )
12346  {
12347  lua_pushfstring( L, "Table xg must be of length%d.", Xlen );
12348  SWIG_fail;
12349  }
12350  cgrid113.nx = nx;
12351  }
12352  else
12353  {
12354  cgrid213.xg = read_double_Matrix( L, -1, &nx, &ny );
12355  if ( !cgrid213.xg )
12356  {
12357  lua_pop( L, 1 ); // pop "xg"
12358  SWIG_fail;
12359  }
12360  if ( ( nx != Xlen ) || ( ny != Ylen ) )
12361  {
12362  lua_pop( L, 1 ); // pop "xg"
12363  lua_pushfstring( L, "Vectors must match matrix." );
12364  SWIG_fail;
12365  }
12366  cgrid213.nx = nx;
12367  cgrid213.ny = ny;
12368  }
12369  lua_pop( L, 1 ); // pop "xg"
12370 
12371  lua_pushstring( L, "yg" );
12372  lua_gettable( L, 11 );
12373  if ( !lua_istable( L, -1 ) )
12374  {
12375  lua_pop( L, 1 );
12376  lua_pushstring( L, "expected a table yg" );
12377  SWIG_fail;
12378  }
12379  lua_rawgeti( L, -1, 1 );
12380  if ( gridmode == 2 )
12381  {
12382  if ( !lua_istable( L, -1 ) )
12383  {
12384  lua_pop( L, 1 ); // pop "1"
12385  lua_pop( L, 1 ); // pop "yg"
12386  lua_pushstring( L, "expected a two dimensional array/table in yg" );
12387  SWIG_fail;
12388  }
12389  }
12390  else
12391  {
12392  if ( !lua_isnumber( L, -1 ) )
12393  {
12394  lua_pop( L, 1 ); // pop "1"
12395  lua_pop( L, 1 ); // pop "yg"
12396  lua_pushstring( L, "expected a one dimensional array/table in yg" );
12397  SWIG_fail;
12398  }
12399  }
12400  lua_pop( L, 1 ); // pop "1"
12401  if ( gridmode == 1 )
12402  {
12403  cgrid113.yg = (PLFLT *) LUA_get_double_num_array_var( L, -1, &ny );
12404  if ( !cgrid113.yg )
12405  {
12406  lua_pop( L, 1 ); // pop "yg"
12407  SWIG_fail;
12408  }
12409  if ( ny != Ylen )
12410  {
12411  lua_pushfstring( L, "Table yg must be of length%d.", Ylen );
12412  SWIG_fail;
12413  }
12414  cgrid113.ny = ny;
12415  }
12416  else
12417  {
12418  cgrid213.yg = read_double_Matrix( L, -1, &nx, &ny );
12419  if ( !cgrid213.yg )
12420  {
12421  lua_pop( L, 1 ); // pop "xg"
12422  SWIG_fail;
12423  }
12424  if ( ( nx != Xlen ) || ( ny != Ylen ) )
12425  {
12426  lua_pop( L, 1 ); // pop "xg"
12427  lua_pushfstring( L, "Vectors must match matrix." );
12428  SWIG_fail;
12429  }
12430  // cgrid213.nx/ny already set
12431  }
12432  lua_pop( L, 1 ); // pop "yg"
12433 
12434  if ( gridmode == 1 )
12435  arg13 = &cgrid113;
12436  else if ( gridmode == 2 )
12437  arg13 = &cgrid213;
12438  }
12439  }
12440  plimagefr((double const **)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,arg12,arg13);
12441 
12442  {
12443  int i;
12444 
12445  if ( arg1 )
12446  {
12447  for ( i = 0; i < ii1; i++ )
12448  LUA_FREE_ARRAY( arg1[i] );
12449  LUA_FREE_ARRAY( arg1 );
12450  }
12451  }
12452  {
12453  mypltr_funcstr[0] = '\0';
12454  }
12455  {
12456  int i;
12457 
12458  LUA_FREE_ARRAY( cgrid113.xg );
12459  LUA_FREE_ARRAY( cgrid113.yg );
12460 
12461  if ( cgrid213.xg )
12462  {
12463  for ( i = 0; i < Xlen; i++ )
12464  LUA_FREE_ARRAY( cgrid213.xg[i] );
12465  LUA_FREE_ARRAY( cgrid213.xg );
12466  }
12467  if ( cgrid213.yg )
12468  {
12469  for ( i = 0; i < Xlen; i++ )
12470  LUA_FREE_ARRAY( cgrid213.yg[i] );
12471  LUA_FREE_ARRAY( cgrid213.yg );
12472  }
12473  }
12474  return SWIG_arg;
12475 
12476  if(0) SWIG_fail;
12477 
12478 fail:
12479  {
12480  int i;
12481 
12482  if ( arg1 )
12483  {
12484  for ( i = 0; i < ii1; i++ )
12485  LUA_FREE_ARRAY( arg1[i] );
12486  LUA_FREE_ARRAY( arg1 );
12487  }
12488  }
12489  {
12490  mypltr_funcstr[0] = '\0';
12491  }
12492  {
12493  int i;
12494 
12495  LUA_FREE_ARRAY( cgrid113.xg );
12496  LUA_FREE_ARRAY( cgrid113.yg );
12497 
12498  if ( cgrid213.xg )
12499  {
12500  for ( i = 0; i < Xlen; i++ )
12501  LUA_FREE_ARRAY( cgrid213.xg[i] );
12502  LUA_FREE_ARRAY( cgrid213.xg );
12503  }
12504  if ( cgrid213.yg )
12505  {
12506  for ( i = 0; i < Xlen; i++ )
12507  LUA_FREE_ARRAY( cgrid213.yg[i] );
12508  LUA_FREE_ARRAY( cgrid213.yg );
12509  }
12510  }
12511  lua_error(L);
12512  return SWIG_arg;
12513 }
12514 
12515 
12516 static int _wrap_plClearOpts(lua_State* L) {
12517  int SWIG_arg = 0;
12518 
12519  SWIG_check_num_args("plClearOpts",0,0)
12520  plClearOpts();
12521 
12522  return SWIG_arg;
12523 
12524  if(0) SWIG_fail;
12525 
12526 fail:
12527  lua_error(L);
12528  return SWIG_arg;
12529 }
12530 
12531 
12532 static int _wrap_plResetOpts(lua_State* L) {
12533  int SWIG_arg = 0;
12534 
12535  SWIG_check_num_args("plResetOpts",0,0)
12536  plResetOpts();
12537 
12538  return SWIG_arg;
12539 
12540  if(0) SWIG_fail;
12541 
12542 fail:
12543  lua_error(L);
12544  return SWIG_arg;
12545 }
12546 
12547 
12548 static int _wrap_plSetUsage(lua_State* L) {
12549  int SWIG_arg = 0;
12550  char *arg1 = (char *) 0 ;
12551  char *arg2 = (char *) 0 ;
12552 
12553  SWIG_check_num_args("plSetUsage",2,2)
12554  if(!SWIG_lua_isnilstring(L,1)) SWIG_fail_arg("plSetUsage",1,"char const *");
12555  if(!SWIG_lua_isnilstring(L,2)) SWIG_fail_arg("plSetUsage",2,"char const *");
12556  arg1 = (char *)lua_tostring(L, 1);
12557  arg2 = (char *)lua_tostring(L, 2);
12558  plSetUsage((char const *)arg1,(char const *)arg2);
12559 
12560  return SWIG_arg;
12561 
12562  if(0) SWIG_fail;
12563 
12564 fail:
12565  lua_error(L);
12566  return SWIG_arg;
12567 }
12568 
12569 
12570 static int _wrap_plOptUsage(lua_State* L) {
12571  int SWIG_arg = 0;
12572 
12573  SWIG_check_num_args("plOptUsage",0,0)
12574  plOptUsage();
12575 
12576  return SWIG_arg;
12577 
12578  if(0) SWIG_fail;
12579 
12580 fail:
12581  lua_error(L);
12582  return SWIG_arg;
12583 }
12584 
12585 
12586 static int _wrap_MinMax2dGrid(lua_State* L) {
12587  int SWIG_arg = 0;
12588  PLFLT **arg1 = (PLFLT **) 0 ;
12589  PLINT arg2 ;
12590  PLINT arg3 ;
12591  PLFLT *arg4 = (PLFLT *) 0 ;
12592  PLFLT *arg5 = (PLFLT *) 0 ;
12593  int ii1 ;
12594  PLFLT temp4 ;
12595  PLFLT temp5 ;
12596 
12597  arg4 = &temp4;
12598  arg5 = &temp5;
12599  SWIG_check_num_args("plMinMax2dGrid",1,1)
12600  {
12601  int jj;
12602 
12603  arg1 = read_double_Matrix( L, 1, &ii1, &jj );
12604  if ( !arg1 )
12605  SWIG_fail;
12606  Xlen = arg2 = ii1;
12607  Ylen = arg3 = jj;
12608  }
12609  plMinMax2dGrid((double const **)arg1,arg2,arg3,arg4,arg5);
12610 
12611  lua_pushnumber(L, (lua_Number) *arg4); SWIG_arg++;
12612  lua_pushnumber(L, (lua_Number) *arg5); SWIG_arg++;
12613  {
12614  int i;
12615 
12616  if ( arg1 )
12617  {
12618  for ( i = 0; i < ii1; i++ )
12619  LUA_FREE_ARRAY( arg1[i] );
12620  LUA_FREE_ARRAY( arg1 );
12621  }
12622  }
12623  return SWIG_arg;
12624 
12625  if(0) SWIG_fail;
12626 
12627 fail:
12628  {
12629  int i;
12630 
12631  if ( arg1 )
12632  {
12633  for ( i = 0; i < ii1; i++ )
12634  LUA_FREE_ARRAY( arg1[i] );
12635  LUA_FREE_ARRAY( arg1 );
12636  }
12637  }
12638  lua_error(L);
12639  return SWIG_arg;
12640 }
12641 
12642 
12643 static int _wrap_plGetCursor(lua_State* L) {
12644  int SWIG_arg = 0;
12645  PLGraphicsIn *arg1 = (PLGraphicsIn *) 0 ;
12646  PLINT result;
12647 
12648  SWIG_check_num_args("plGetCursor",1,1)
12649  if(!SWIG_isptrtype(L,1)) SWIG_fail_arg("plGetCursor",1,"PLGraphicsIn *");
12650 
12651  if (!SWIG_IsOK(SWIG_ConvertPtr(L,1,(void**)&arg1,SWIGTYPE_p_PLGraphicsIn,0))){
12652  SWIG_fail_ptr("plGetCursor",1,SWIGTYPE_p_PLGraphicsIn);
12653  }
12654 
12655  result = (PLINT)plGetCursor(arg1);
12656  lua_pushnumber(L, (lua_Number) result); SWIG_arg++;
12657  return SWIG_arg;
12658 
12659  if(0) SWIG_fail;
12660 
12661 fail:
12662  lua_error(L);
12663  return SWIG_arg;
12664 }
12665 
12666 
12667 static int _wrap_warn(lua_State* L) {
12668  int SWIG_arg = 0;
12669  char *arg1 = (char *) 0 ;
12670 
12671  SWIG_check_num_args("plwarn",1,1)
12672  if(!lua_isstring(L,1)) SWIG_fail_arg("plwarn",1,"char const *");
12673  {
12674  arg1 = (char *) lua_tostring( L, 1 );
12675  }
12676  plwarn((char const *)arg1);
12677 
12678  return SWIG_arg;
12679 
12680  if(0) SWIG_fail;
12681 
12682 fail:
12683  lua_error(L);
12684  return SWIG_arg;
12685 }
12686 
12687 
12688 static int _wrap_abort(lua_State* L) {
12689  int SWIG_arg = 0;
12690  char *arg1 = (char *) 0 ;
12691 
12692  SWIG_check_num_args("plabort",1,1)
12693  if(!lua_isstring(L,1)) SWIG_fail_arg("plabort",1,"char const *");
12694  {
12695  arg1 = (char *) lua_tostring( L, 1 );
12696  }
12697  plabort((char const *)arg1);
12698 
12699  return SWIG_arg;
12700 
12701  if(0) SWIG_fail;
12702 
12703 fail:
12704  lua_error(L);
12705  return SWIG_arg;
12706 }
12707 
12708 
12710  {0,0,0}
12711 };
12713  {SWIG_LUA_CONSTTAB_INT("PLESC_SET_RGB", 1)},
12714  {SWIG_LUA_CONSTTAB_INT("PLESC_ALLOC_NCOL", 2)},
12715  {SWIG_LUA_CONSTTAB_INT("PLESC_SET_LPB", 3)},
12716  {SWIG_LUA_CONSTTAB_INT("PLESC_EXPOSE", 4)},
12717  {SWIG_LUA_CONSTTAB_INT("PLESC_RESIZE", 5)},
12718  {SWIG_LUA_CONSTTAB_INT("PLESC_REDRAW", 6)},
12719  {SWIG_LUA_CONSTTAB_INT("PLESC_TEXT", 7)},
12720  {SWIG_LUA_CONSTTAB_INT("PLESC_GRAPH", 8)},
12721  {SWIG_LUA_CONSTTAB_INT("PLESC_FILL", 9)},
12722  {SWIG_LUA_CONSTTAB_INT("PLESC_DI", 10)},
12723  {SWIG_LUA_CONSTTAB_INT("PLESC_FLUSH", 11)},
12724  {SWIG_LUA_CONSTTAB_INT("PLESC_EH", 12)},
12725  {SWIG_LUA_CONSTTAB_INT("PLESC_GETC", 13)},
12726  {SWIG_LUA_CONSTTAB_INT("PLESC_SWIN", 14)},
12727  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING", 15)},
12728  {SWIG_LUA_CONSTTAB_INT("PLESC_XORMOD", 16)},
12729  {SWIG_LUA_CONSTTAB_INT("PLESC_SET_COMPRESSION", 17)},
12730  {SWIG_LUA_CONSTTAB_INT("PLESC_CLEAR", 18)},
12731  {SWIG_LUA_CONSTTAB_INT("PLESC_DASH", 19)},
12732  {SWIG_LUA_CONSTTAB_INT("PLESC_HAS_TEXT", 20)},
12733  {SWIG_LUA_CONSTTAB_INT("PLESC_IMAGE", 21)},
12734  {SWIG_LUA_CONSTTAB_INT("PLESC_IMAGEOPS", 22)},
12735  {SWIG_LUA_CONSTTAB_INT("PLESC_PL2DEVCOL", 23)},
12736  {SWIG_LUA_CONSTTAB_INT("PLESC_DEV2PLCOL", 24)},
12737  {SWIG_LUA_CONSTTAB_INT("PLESC_SETBGFG", 25)},
12738  {SWIG_LUA_CONSTTAB_INT("PLESC_DEVINIT", 26)},
12739  {SWIG_LUA_CONSTTAB_INT("PLESC_GETBACKEND", 27)},
12740  {SWIG_LUA_CONSTTAB_INT("PLESC_BEGIN_TEXT", 28)},
12741  {SWIG_LUA_CONSTTAB_INT("PLESC_TEXT_CHAR", 29)},
12742  {SWIG_LUA_CONSTTAB_INT("PLESC_CONTROL_CHAR", 30)},
12743  {SWIG_LUA_CONSTTAB_INT("PLESC_END_TEXT", 31)},
12744  {SWIG_LUA_CONSTTAB_INT("PLESC_START_RASTERIZE", 32)},
12745  {SWIG_LUA_CONSTTAB_INT("PLESC_END_RASTERIZE", 33)},
12746  {SWIG_LUA_CONSTTAB_INT("PLESC_ARC", 34)},
12747  {SWIG_LUA_CONSTTAB_INT("PLESC_GRADIENT", 35)},
12748  {SWIG_LUA_CONSTTAB_INT("PLESC_MODESET", 36)},
12749  {SWIG_LUA_CONSTTAB_INT("PLESC_MODEGET", 37)},
12750  {SWIG_LUA_CONSTTAB_INT("PLESC_FIXASPECT", 38)},
12751  {SWIG_LUA_CONSTTAB_INT("PLESC_IMPORT_BUFFER", 39)},
12752  {SWIG_LUA_CONSTTAB_INT("PLESC_APPEND_BUFFER", 40)},
12753  {SWIG_LUA_CONSTTAB_INT("PLESC_FLUSH_REMAINING_BUFFER", 41)},
12754  {SWIG_LUA_CONSTTAB_INT("PLTEXT_FONTCHANGE", 0)},
12755  {SWIG_LUA_CONSTTAB_INT("PLTEXT_SUPERSCRIPT", 1)},
12756  {SWIG_LUA_CONSTTAB_INT("PLTEXT_SUBSCRIPT", 2)},
12757  {SWIG_LUA_CONSTTAB_INT("PLTEXT_BACKCHAR", 3)},
12758  {SWIG_LUA_CONSTTAB_INT("PLTEXT_OVERLINE", 4)},
12759  {SWIG_LUA_CONSTTAB_INT("PLTEXT_UNDERLINE", 5)},
12760  {SWIG_LUA_CONSTTAB_INT("ZEROW2B", 1)},
12761  {SWIG_LUA_CONSTTAB_INT("ZEROW2D", 2)},
12762  {SWIG_LUA_CONSTTAB_INT("ONEW2B", 3)},
12763  {SWIG_LUA_CONSTTAB_INT("ONEW2D", 4)},
12764  {SWIG_LUA_CONSTTAB_INT("PLSWIN_DEVICE", 1)},
12765  {SWIG_LUA_CONSTTAB_INT("PLSWIN_WORLD", 2)},
12766  {SWIG_LUA_CONSTTAB_INT("PL_X_AXIS", 1)},
12767  {SWIG_LUA_CONSTTAB_INT("PL_Y_AXIS", 2)},
12768  {SWIG_LUA_CONSTTAB_INT("PL_Z_AXIS", 3)},
12769  {SWIG_LUA_CONSTTAB_INT("PL_OPT_ENABLED", 0x0001)},
12770  {SWIG_LUA_CONSTTAB_INT("PL_OPT_ARG", 0x0002)},
12771  {SWIG_LUA_CONSTTAB_INT("PL_OPT_NODELETE", 0x0004)},
12772  {SWIG_LUA_CONSTTAB_INT("PL_OPT_INVISIBLE", 0x0008)},
12773  {SWIG_LUA_CONSTTAB_INT("PL_OPT_DISABLED", 0x0010)},
12774  {SWIG_LUA_CONSTTAB_INT("PL_OPT_FUNC", 0x0100)},
12775  {SWIG_LUA_CONSTTAB_INT("PL_OPT_BOOL", 0x0200)},
12776  {SWIG_LUA_CONSTTAB_INT("PL_OPT_INT", 0x0400)},
12777  {SWIG_LUA_CONSTTAB_INT("PL_OPT_FLOAT", 0x0800)},
12778  {SWIG_LUA_CONSTTAB_INT("PL_OPT_STRING", 0x1000)},
12779  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_PARTIAL", 0x0000)},
12780  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_FULL", 0x0001)},
12781  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_QUIET", 0x0002)},
12782  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_NODELETE", 0x0004)},
12783  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_SHOWALL", 0x0008)},
12784  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_OVERRIDE", 0x0010)},
12785  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_NOPROGRAM", 0x0020)},
12786  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_NODASH", 0x0040)},
12787  {SWIG_LUA_CONSTTAB_INT("PL_PARSE_SKIP", 0x0080)},
12788  {SWIG_LUA_CONSTTAB_INT("PL_FCI_MARK", 0x80000000)},
12789  {SWIG_LUA_CONSTTAB_INT("PL_FCI_IMPOSSIBLE", 0x00000000)},
12790  {SWIG_LUA_CONSTTAB_INT("PL_FCI_HEXDIGIT_MASK", 0xf)},
12791  {SWIG_LUA_CONSTTAB_INT("PL_FCI_HEXPOWER_MASK", 0x7)},
12792  {SWIG_LUA_CONSTTAB_INT("PL_FCI_HEXPOWER_IMPOSSIBLE", 0xf)},
12793  {SWIG_LUA_CONSTTAB_INT("PL_FCI_FAMILY", 0x0)},
12794  {SWIG_LUA_CONSTTAB_INT("PL_FCI_STYLE", 0x1)},
12795  {SWIG_LUA_CONSTTAB_INT("PL_FCI_WEIGHT", 0x2)},
12796  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SANS", 0x0)},
12797  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SERIF", 0x1)},
12798  {SWIG_LUA_CONSTTAB_INT("PL_FCI_MONO", 0x2)},
12799  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SCRIPT", 0x3)},
12800  {SWIG_LUA_CONSTTAB_INT("PL_FCI_SYMBOL", 0x4)},
12801  {SWIG_LUA_CONSTTAB_INT("PL_FCI_UPRIGHT", 0x0)},
12802  {SWIG_LUA_CONSTTAB_INT("PL_FCI_ITALIC", 0x1)},
12803  {SWIG_LUA_CONSTTAB_INT("PL_FCI_OBLIQUE", 0x2)},
12804  {SWIG_LUA_CONSTTAB_INT("PL_FCI_MEDIUM", 0x0)},
12805  {SWIG_LUA_CONSTTAB_INT("PL_FCI_BOLD", 0x1)},
12806  {SWIG_LUA_CONSTTAB_INT("PL_MAXKEY", 16)},
12807  {SWIG_LUA_CONSTTAB_INT("PL_MASK_SHIFT", 0x1)},
12808  {SWIG_LUA_CONSTTAB_INT("PL_MASK_CAPS", 0x2)},
12809  {SWIG_LUA_CONSTTAB_INT("PL_MASK_CONTROL", 0x4)},
12810  {SWIG_LUA_CONSTTAB_INT("PL_MASK_ALT", 0x8)},
12811  {SWIG_LUA_CONSTTAB_INT("PL_MASK_NUM", 0x10)},
12812  {SWIG_LUA_CONSTTAB_INT("PL_MASK_ALTGR", 0x20)},
12813  {SWIG_LUA_CONSTTAB_INT("PL_MASK_WIN", 0x40)},
12814  {SWIG_LUA_CONSTTAB_INT("PL_MASK_SCROLL", 0x80)},
12815  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON1", 0x100)},
12816  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON2", 0x200)},
12817  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON3", 0x400)},
12818  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON4", 0x800)},
12819  {SWIG_LUA_CONSTTAB_INT("PL_MASK_BUTTON5", 0x1000)},
12820  {SWIG_LUA_CONSTTAB_INT("PL_MAXWINDOWS", 64)},
12821  {SWIG_LUA_CONSTTAB_INT("PL_NOTSET", (-42))},
12822  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING_ENABLE", 1)},
12823  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING_DISABLE", 2)},
12824  {SWIG_LUA_CONSTTAB_INT("PLESC_DOUBLEBUFFERING_QUERY", 3)},
12825  {SWIG_LUA_CONSTTAB_INT("PL_BIN_DEFAULT", 0x0)},
12826  {SWIG_LUA_CONSTTAB_INT("PL_BIN_CENTRED", 0x1)},
12827  {SWIG_LUA_CONSTTAB_INT("PL_BIN_NOEXPAND", 0x2)},
12828  {SWIG_LUA_CONSTTAB_INT("PL_BIN_NOEMPTY", 0x4)},
12829  {SWIG_LUA_CONSTTAB_INT("GRID_CSA", 1)},
12830  {SWIG_LUA_CONSTTAB_INT("GRID_DTLI", 2)},
12831  {SWIG_LUA_CONSTTAB_INT("GRID_NNI", 3)},
12832  {SWIG_LUA_CONSTTAB_INT("GRID_NNIDW", 4)},
12833  {SWIG_LUA_CONSTTAB_INT("GRID_NNLI", 5)},
12834  {SWIG_LUA_CONSTTAB_INT("GRID_NNAIDW", 6)},
12835  {SWIG_LUA_CONSTTAB_INT("PL_HIST_DEFAULT", 0x00)},
12836  {SWIG_LUA_CONSTTAB_INT("PL_HIST_NOSCALING", 0x01)},
12837  {SWIG_LUA_CONSTTAB_INT("PL_HIST_IGNORE_OUTLIERS", 0x02)},
12838  {SWIG_LUA_CONSTTAB_INT("PL_HIST_NOEXPAND", 0x08)},
12839  {SWIG_LUA_CONSTTAB_INT("PL_HIST_NOEMPTY", 0x10)},
12840  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_NULL", 0x0)},
12841  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_LEFT", 0x1)},
12842  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_RIGHT", 0x2)},
12843  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_TOP", 0x4)},
12844  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_BOTTOM", 0x8)},
12845  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_INSIDE", 0x10)},
12846  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_OUTSIDE", 0x20)},
12847  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_VIEWPORT", 0x40)},
12848  {SWIG_LUA_CONSTTAB_INT("PL_POSITION_SUBPAGE", 0x80)},
12849  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_NULL", 0x0)},
12850  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_NONE", 0x1)},
12851  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_COLOR_BOX", 0x2)},
12852  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_LINE", 0x4)},
12853  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_SYMBOL", 0x8)},
12854  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_TEXT_LEFT", 0x10)},
12855  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_BACKGROUND", 0x20)},
12856  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_BOUNDING_BOX", 0x40)},
12857  {SWIG_LUA_CONSTTAB_INT("PL_LEGEND_ROW_MAJOR", 0x80)},
12858  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_NULL", 0x0)},
12859  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_LEFT", 0x1)},
12860  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_RIGHT", 0x2)},
12861  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_TOP", 0x4)},
12862  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_LABEL_BOTTOM", 0x8)},
12863  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_IMAGE", 0x10)},
12864  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_SHADE", 0x20)},
12865  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_GRADIENT", 0x40)},
12866  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_CAP_NONE", 0x80)},
12867  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_CAP_LOW", 0x100)},
12868  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_CAP_HIGH", 0x200)},
12869  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_SHADE_LABEL", 0x400)},
12870  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_RIGHT", 0x800)},
12871  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_TOP", 0x1000)},
12872  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_LEFT", 0x2000)},
12873  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_ORIENT_BOTTOM", 0x4000)},
12874  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_BACKGROUND", 0x8000)},
12875  {SWIG_LUA_CONSTTAB_INT("PL_COLORBAR_BOUNDING_BOX", 0x10000)},
12876  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_UNKNOWN", 0x0)},
12877  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_DEFAULT", 0x1)},
12878  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_REPLACE", 0x2)},
12879  {SWIG_LUA_CONSTTAB_INT("PL_DRAWMODE_XOR", 0x4)},
12880  {SWIG_LUA_CONSTTAB_INT("DRAW_LINEX", 0x001)},
12881  {SWIG_LUA_CONSTTAB_INT("DRAW_LINEY", 0x002)},
12882  {SWIG_LUA_CONSTTAB_INT("DRAW_LINEXY", 0x003)},
12883  {SWIG_LUA_CONSTTAB_INT("MAG_COLOR", 0x004)},
12884  {SWIG_LUA_CONSTTAB_INT("BASE_CONT", 0x008)},
12885  {SWIG_LUA_CONSTTAB_INT("TOP_CONT", 0x010)},
12886  {SWIG_LUA_CONSTTAB_INT("SURF_CONT", 0x020)},
12887  {SWIG_LUA_CONSTTAB_INT("DRAW_SIDES", 0x040)},
12888  {SWIG_LUA_CONSTTAB_INT("FACETED", 0x080)},
12889  {SWIG_LUA_CONSTTAB_INT("MESH", 0x100)},
12890  {0,0,0,0,0,0}
12891 };
12893  { "setcontlabelformat", _wrap_setcontlabelformat},
12894  { "setcontlabelparam", _wrap_setcontlabelparam},
12895  { "adv", _wrap_adv},
12896  { "arc", _wrap_arc},
12897  { "axes", _wrap_axes},
12898  { "bin", _wrap_bin},
12899  { "btime", _wrap_btime},
12900  { "bop", _wrap_bop},
12901  { "box", _wrap_box},
12902  { "box3", _wrap_box3},
12903  { "calc_world", _wrap_calc_world},
12904  { "clear", _wrap_clear},
12905  { "col0", _wrap_col0},
12906  { "col1", _wrap_col1},
12907  { "configtime", _wrap_configtime},
12908  { "cont", _wrap_cont},
12909  { "ctime", _wrap_ctime},
12910  { "cpstrm", _wrap_cpstrm},
12911  { "plend", _wrap_plend},
12912  { "plend1", _wrap_plend1},
12913  { "env", _wrap_env},
12914  { "env0", _wrap_env0},
12915  { "eop", _wrap_eop},
12916  { "errx", _wrap_errx},
12917  { "erry", _wrap_erry},
12918  { "famadv", _wrap_famadv},
12919  { "fill", _wrap_fill},
12920  { "fill3", _wrap_fill3},
12921  { "gradient", _wrap_gradient},
12922  { "flush", _wrap_flush},
12923  { "font", _wrap_font},
12924  { "fontld", _wrap_fontld},
12925  { "gchr", _wrap_gchr},
12926  { "gcol0", _wrap_gcol0},
12927  { "gcol0a", _wrap_gcol0a},
12928  { "gcolbg", _wrap_gcolbg},
12929  { "gcolbga", _wrap_gcolbga},
12930  { "gcompression", _wrap_gcompression},
12931  { "gdev", _wrap_gdev},
12932  { "gdidev", _wrap_gdidev},
12933  { "gdiori", _wrap_gdiori},
12934  { "gdiplt", _wrap_gdiplt},
12935  { "gfam", _wrap_gfam},
12936  { "gfci", _wrap_gfci},
12937  { "gfnam", _wrap_gfnam},
12938  { "gfont", _wrap_gfont},
12939  { "glevel", _wrap_glevel},
12940  { "gpage", _wrap_gpage},
12941  { "gra", _wrap_gra},
12942  { "griddata", _wrap_griddata},
12943  { "gspa", _wrap_gspa},
12944  { "gstrm", _wrap_gstrm},
12945  { "gver", _wrap_gver},
12946  { "gvpd", _wrap_gvpd},
12947  { "gvpw", _wrap_gvpw},
12948  { "gxax", _wrap_gxax},
12949  { "gyax", _wrap_gyax},
12950  { "gzax", _wrap_gzax},
12951  { "hist", _wrap_hist},
12952  { "hlsrgb", _wrap_hlsrgb},
12953  { "init", _wrap_init},
12954  { "join", _wrap_join},
12955  { "lab", _wrap_lab},
12956  { "legend", _wrap_legend},
12957  { "colorbar", _wrap_colorbar},
12958  { "lightsource", _wrap_lightsource},
12959  { "line", _wrap_line},
12960  { "line3", _wrap_line3},
12961  { "lsty", _wrap_lsty},
12962  { "mesh", _wrap_mesh},
12963  { "meshc", _wrap_meshc},
12964  { "mkstrm", _wrap_mkstrm},
12965  { "mtex", _wrap_mtex},
12966  { "mtex3", _wrap_mtex3},
12967  { "plot3d", _wrap_plot3d},
12968  { "plot3dc", _wrap_plot3dc},
12969  { "plot3dcl", _wrap_plot3dcl},
12970  { "surf3d", _wrap_surf3d},
12971  { "surf3dl", _wrap_surf3dl},
12972  { "parseopts", _wrap_parseopts},
12973  { "pat", _wrap_pat},
12974  { "path", _wrap_path},
12975  { "poin", _wrap_poin},
12976  { "poin3", _wrap_poin3},
12977  { "poly3", _wrap_poly3},
12978  { "prec", _wrap_prec},
12979  { "psty", _wrap_psty},
12980  { "ptex", _wrap_ptex},
12981  { "ptex3", _wrap_ptex3},
12982  { "randd", _wrap_randd},
12983  { "replot", _wrap_replot},
12984  { "rgbhls", _wrap_rgbhls},
12985  { "schr", _wrap_schr},
12986  { "scmap0", _wrap_scmap0},
12987  { "scmap0a", _wrap_scmap0a},
12988  { "scmap0n", _wrap_scmap0n},
12989  { "scmap1", _wrap_scmap1},
12990  { "scmap1a", _wrap_scmap1a},
12991  { "scmap1l", _wrap_scmap1l},
12992  { "scmap1la", _wrap_scmap1la},
12993  { "scmap1n", _wrap_scmap1n},
12994  { "scmap1_range", _wrap_scmap1_range},
12995  { "gcmap1_range", _wrap_gcmap1_range},
12996  { "scol0", _wrap_scol0},
12997  { "scol0a", _wrap_scol0a},
12998  { "scolbg", _wrap_scolbg},
12999  { "scolbga", _wrap_scolbga},
13000  { "scolor", _wrap_scolor},
13001  { "scompression", _wrap_scompression},
13002  { "sdev", _wrap_sdev},
13003  { "sdidev", _wrap_sdidev},
13004  { "sdimap", _wrap_sdimap},
13005  { "sdiori", _wrap_sdiori},
13006  { "sdiplt", _wrap_sdiplt},
13007  { "sdiplz", _wrap_sdiplz},
13008  { "seed", _wrap_seed},
13009  { "sesc", _wrap_sesc},
13010  { "setopt", _wrap_setopt},
13011  { "sfam", _wrap_sfam},
13012  { "sfci", _wrap_sfci},
13013  { "sfnam", _wrap_sfnam},
13014  { "sfont", _wrap_sfont},
13015  { "shades", _wrap_shades},
13016  { "shade", _wrap_shade},
13017  { "slabelfunc", _wrap_slabelfunc},
13018  { "smaj", _wrap_smaj},
13019  { "smin", _wrap_smin},
13020  { "sori", _wrap_sori},
13021  { "spage", _wrap_spage},
13022  { "spal0", _wrap_spal0},
13023  { "spal1", _wrap_spal1},
13024  { "spause", _wrap_spause},
13025  { "sstrm", _wrap_sstrm},
13026  { "ssub", _wrap_ssub},
13027  { "ssym", _wrap_ssym},
13028  { "star", _wrap_star},
13029  { "start", _wrap_start},
13030  { "stransform", _wrap_stransform},
13031  { "string", _wrap_string},
13032  { "string3", _wrap_string3},
13033  { "stripa", _wrap_stripa},
13034  { "stripc", _wrap_stripc},
13035  { "stripd", _wrap_stripd},
13036  { "styl", _wrap_styl},
13037  { "svect", _wrap_svect},
13038  { "svpa", _wrap_svpa},
13039  { "sxax", _wrap_sxax},
13040  { "syax", _wrap_syax},
13041  { "sym", _wrap_sym},
13042  { "szax", _wrap_szax},
13043  { "text", _wrap_text},
13044  { "timefmt", _wrap_timefmt},
13045  { "vasp", _wrap_vasp},
13046  { "vect", _wrap_vect},
13047  { "vpas", _wrap_vpas},
13048  { "vpor", _wrap_vpor},
13049  { "vsta", _wrap_vsta},
13050  { "w3d", _wrap_w3d},
13051  { "width", _wrap_width},
13052  { "wind", _wrap_wind},
13053  { "xormod", _wrap_xormod},
13054  { "map", _wrap_map},
13055  { "mapline", _wrap_mapline},
13056  { "mapstring", _wrap_mapstring},
13057  { "maptex", _wrap_maptex},
13058  { "mapfill", _wrap_mapfill},
13059  { "meridians", _wrap_meridians},
13060  { "image", _wrap_image},
13061  { "imagefr", _wrap_imagefr},
13062  { "plClearOpts", _wrap_plClearOpts},
13063  { "plResetOpts", _wrap_plResetOpts},
13064  { "plSetUsage", _wrap_plSetUsage},
13065  { "plOptUsage", _wrap_plOptUsage},
13066  { "MinMax2dGrid", _wrap_MinMax2dGrid},
13067  { "plGetCursor", _wrap_plGetCursor},
13068  { "warn", _wrap_warn},
13069  { "abort", _wrap_abort},
13070  {0,0}
13071 };
13074  0
13075 };
13077  0
13078 };
13079 
13081  "plplotluac",
13087 };
13088 #ifdef __cplusplus
13089 }
13090 #endif
13091 
13092 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
13093 
13094 static swig_type_info _swigt__p_PLGraphicsIn = {"_p_PLGraphicsIn", "PLGraphicsIn *", 0, 0, (void*)&_wrap_class_PLGraphicsIn, 0};
13095 static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
13096 static swig_type_info _swigt__p_double = {"_p_double", "double *|PLFLT *", 0, 0, (void*)0, 0};
13097 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};
13098 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};
13099 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};
13100 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};
13101 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};
13102 static swig_type_info _swigt__p_int = {"_p_int", "PLBOOL *|int *|PLINT *", 0, 0, (void*)0, 0};
13103 static swig_type_info _swigt__p_p_char = {"_p_p_char", "char **", 0, 0, (void*)0, 0};
13104 static swig_type_info _swigt__p_p_double = {"_p_p_double", "PLFLT **|double **", 0, 0, (void*)0, 0};
13105 static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "unsigned int *|PLUNICODE *", 0, 0, (void*)0, 0};
13106 
13109  &_swigt__p_char,
13116  &_swigt__p_int,
13120 };
13121 
13122 static swig_cast_info _swigc__p_PLGraphicsIn[] = { {&_swigt__p_PLGraphicsIn, 0, 0, 0},{0, 0, 0, 0}};
13123 static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
13124 static swig_cast_info _swigc__p_double[] = { {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}};
13130 static swig_cast_info _swigc__p_int[] = { {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
13131 static swig_cast_info _swigc__p_p_char[] = { {&_swigt__p_p_char, 0, 0, 0},{0, 0, 0, 0}};
13132 static swig_cast_info _swigc__p_p_double[] = { {&_swigt__p_p_double, 0, 0, 0},{0, 0, 0, 0}};
13133 static swig_cast_info _swigc__p_unsigned_int[] = { {&_swigt__p_unsigned_int, 0, 0, 0},{0, 0, 0, 0}};
13134 
13144  _swigc__p_int,
13148 };
13149 
13150 
13151 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */
13152 
13153 /* -----------------------------------------------------------------------------
13154  * Type initialization:
13155  * This problem is tough by the requirement that no dynamic
13156  * memory is used. Also, since swig_type_info structures store pointers to
13157  * swig_cast_info structures and swig_cast_info structures store pointers back
13158  * to swig_type_info structures, we need some lookup code at initialization.
13159  * The idea is that swig generates all the structures that are needed.
13160  * The runtime then collects these partially filled structures.
13161  * The SWIG_InitializeModule function takes these initial arrays out of
13162  * swig_module, and does all the lookup, filling in the swig_module.types
13163  * array with the correct data and linking the correct swig_cast_info
13164  * structures together.
13165  *
13166  * The generated swig_type_info structures are assigned statically to an initial
13167  * array. We just loop through that array, and handle each type individually.
13168  * First we lookup if this type has been already loaded, and if so, use the
13169  * loaded structure instead of the generated one. Then we have to fill in the
13170  * cast linked list. The cast data is initially stored in something like a
13171  * two-dimensional array. Each row corresponds to a type (there are the same
13172  * number of rows as there are in the swig_type_initial array). Each entry in
13173  * a column is one of the swig_cast_info structures for that type.
13174  * The cast_initial array is actually an array of arrays, because each row has
13175  * a variable number of columns. So to actually build the cast linked list,
13176  * we find the array of casts associated with the type, and loop through it
13177  * adding the casts to the list. The one last trick we need to do is making
13178  * sure the type pointer in the swig_cast_info struct is correct.
13179  *
13180  * First off, we lookup the cast->type name to see if it is already loaded.
13181  * There are three cases to handle:
13182  * 1) If the cast->type has already been loaded AND the type we are adding
13183  * casting info to has not been loaded (it is in this module), THEN we
13184  * replace the cast->type pointer with the type pointer that has already
13185  * been loaded.
13186  * 2) If BOTH types (the one we are adding casting info to, and the
13187  * cast->type) are loaded, THEN the cast info has already been loaded by
13188  * the previous module so we just ignore it.
13189  * 3) Finally, if cast->type has not already been loaded, then we add that
13190  * swig_cast_info to the linked list (because the cast->type) pointer will
13191  * be correct.
13192  * ----------------------------------------------------------------------------- */
13193 
13194 #ifdef __cplusplus
13195 extern "C" {
13196 #if 0
13197 } /* c-mode */
13198 #endif
13199 #endif
13200 
13201 #if 0
13202 #define SWIGRUNTIME_DEBUG
13203 #endif
13204 
13205 
13206 SWIGRUNTIME void
13207 SWIG_InitializeModule(void *clientdata) {
13208  size_t i;
13209  swig_module_info *module_head, *iter;
13210  int init;
13211 
13212  /* check to see if the circular list has been setup, if not, set it up */
13213  if (swig_module.next==0) {
13214  /* Initialize the swig_module */
13218  init = 1;
13219  } else {
13220  init = 0;
13221  }
13222 
13223  /* Try and load any already created modules */
13224  module_head = SWIG_GetModule(clientdata);
13225  if (!module_head) {
13226  /* This is the first module loaded for this interpreter */
13227  /* so set the swig module into the interpreter */
13228  SWIG_SetModule(clientdata, &swig_module);
13229  } else {
13230  /* the interpreter has loaded a SWIG module, but has it loaded this one? */
13231  iter=module_head;
13232  do {
13233  if (iter==&swig_module) {
13234  /* Our module is already in the list, so there's nothing more to do. */
13235  return;
13236  }
13237  iter=iter->next;
13238  } while (iter!= module_head);
13239 
13240  /* otherwise we must add our module into the list */
13241  swig_module.next = module_head->next;
13242  module_head->next = &swig_module;
13243  }
13244 
13245  /* When multiple interpreters are used, a module could have already been initialized in
13246  a different interpreter, but not yet have a pointer in this interpreter.
13247  In this case, we do not want to continue adding types... everything should be
13248  set up already */
13249  if (init == 0) return;
13250 
13251  /* Now work on filling in swig_module.types */
13252 #ifdef SWIGRUNTIME_DEBUG
13253  printf("SWIG_InitializeModule: size %lu\n", (unsigned long)swig_module.size);
13254 #endif
13255  for (i = 0; i < swig_module.size; ++i) {
13256  swig_type_info *type = 0;
13257  swig_type_info *ret;
13258  swig_cast_info *cast;
13259 
13260 #ifdef SWIGRUNTIME_DEBUG
13261  printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
13262 #endif
13263 
13264  /* if there is another module already loaded */
13265  if (swig_module.next != &swig_module) {
13267  }
13268  if (type) {
13269  /* Overwrite clientdata field */
13270 #ifdef SWIGRUNTIME_DEBUG
13271  printf("SWIG_InitializeModule: found type %s\n", type->name);
13272 #endif
13275 #ifdef SWIGRUNTIME_DEBUG
13276  printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
13277 #endif
13278  }
13279  } else {
13280  type = swig_module.type_initial[i];
13281  }
13282 
13283  /* Insert casting types */
13284  cast = swig_module.cast_initial[i];
13285  while (cast->type) {
13286 
13287  /* Don't need to add information already in the list */
13288  ret = 0;
13289 #ifdef SWIGRUNTIME_DEBUG
13290  printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
13291 #endif
13292  if (swig_module.next != &swig_module) {
13294 #ifdef SWIGRUNTIME_DEBUG
13295  if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
13296 #endif
13297  }
13298  if (ret) {
13299  if (type == swig_module.type_initial[i]) {
13300 #ifdef SWIGRUNTIME_DEBUG
13301  printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
13302 #endif
13303  cast->type = ret;
13304  ret = 0;
13305  } else {
13306  /* Check for casting already in the list */
13307  swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
13308 #ifdef SWIGRUNTIME_DEBUG
13309  if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
13310 #endif
13311  if (!ocast) ret = 0;
13312  }
13313  }
13314 
13315  if (!ret) {
13316 #ifdef SWIGRUNTIME_DEBUG
13317  printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
13318 #endif
13319  if (type->cast) {
13320  type->cast->prev = cast;
13321  cast->next = type->cast;
13322  }
13323  type->cast = cast;
13324  }
13325  cast++;
13326  }
13327  /* Set entry in modules->types array equal to the type */
13328  swig_module.types[i] = type;
13329  }
13330  swig_module.types[i] = 0;
13331 
13332 #ifdef SWIGRUNTIME_DEBUG
13333  printf("**** SWIG_InitializeModule: Cast List ******\n");
13334  for (i = 0; i < swig_module.size; ++i) {
13335  int j = 0;
13337  printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
13338  while (cast->type) {
13339  printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
13340  cast++;
13341  ++j;
13342  }
13343  printf("---- Total casts: %d\n",j);
13344  }
13345  printf("**** SWIG_InitializeModule: Cast List ******\n");
13346 #endif
13347 }
13348 
13349 /* This function will propagate the clientdata field of type to
13350 * any new swig_type_info structures that have been added into the list
13351 * of equivalent types. It is like calling
13352 * SWIG_TypeClientData(type, clientdata) a second time.
13353 */
13354 SWIGRUNTIME void
13356  size_t i;
13357  swig_cast_info *equiv;
13358  static int init_run = 0;
13359 
13360  if (init_run) return;
13361  init_run = 1;
13362 
13363  for (i = 0; i < swig_module.size; i++) {
13364  if (swig_module.types[i]->clientdata) {
13365  equiv = swig_module.types[i]->cast;
13366  while (equiv) {
13367  if (!equiv->converter) {
13368  if (equiv->type && !equiv->type->clientdata)
13370  }
13371  equiv = equiv->next;
13372  }
13373  }
13374  }
13375 }
13376 
13377 #ifdef __cplusplus
13378 #if 0
13379 { /* c-mode */
13380 #endif
13381 }
13382 #endif
13383 
13384 
13385 
13386 /* Forward declaration of where the user's %init{} gets inserted */
13387 void SWIG_init_user(lua_State* L );
13388 
13389 #ifdef __cplusplus
13390 extern "C" {
13391 #endif
13392 /* this is the initialization function
13393  added at the very end of the code
13394  the function is always called SWIG_init, but an earlier #define will rename it
13395 */
13396 #if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
13397 LUALIB_API int SWIG_init(lua_State* L)
13398 #else
13399 SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */
13400 #endif
13401 {
13402 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC) /* valid for both Lua and eLua */
13403  int i;
13404  int globalRegister = 0;
13405  /* start with global table */
13406  lua_pushglobaltable (L);
13407  /* SWIG's internal initialisation */
13408  SWIG_InitializeModule((void*)L);
13410 #endif
13411 
13412 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)) || defined(SWIG_LUA_ELUA_EMULATE)
13413  /* add a global fn */
13414  SWIG_Lua_add_function(L,"swig_type",SWIG_Lua_type);
13416 #endif
13417 
13418 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
13419  /* set up base class pointers (the hierarchy) */
13420  for (i = 0; swig_types[i]; i++){
13421  if (swig_types[i]->clientdata){
13422  SWIG_Lua_init_base_class(L,(swig_lua_class*)(swig_types[i]->clientdata));
13423  }
13424  }
13425 #ifdef SWIG_LUA_MODULE_GLOBAL
13426  globalRegister = 1;
13427 #endif
13428 
13429 
13430 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
13431  SWIG_Lua_namespace_register(L,&swig_SwigModule, globalRegister);
13432 #endif
13433 
13434 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
13435  for (i = 0; swig_types[i]; i++){
13436  if (swig_types[i]->clientdata){
13437  SWIG_Lua_elua_class_register_instance(L,(swig_lua_class*)(swig_types[i]->clientdata));
13438  }
13439  }
13440 #endif
13441 
13442 #if defined(SWIG_LUA_ELUA_EMULATE)
13443  lua_newtable(L);
13444  SWIG_Lua_elua_emulate_register(L,swig_SwigModule.ns_methods);
13445  SWIG_Lua_elua_emulate_register_clear(L);
13446  if(globalRegister) {
13447  lua_pushstring(L,swig_SwigModule.name);
13448  lua_pushvalue(L,-2);
13449  lua_rawset(L,-4);
13450  }
13451 #endif
13452 
13453 #endif
13454 
13455 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
13456  /* invoke user-specific initialization */
13457  SWIG_init_user(L);
13458  /* end module */
13459  /* Note: We do not clean up the stack here (Lua will do this for us). At this
13460  point, we have the globals table and out module table on the stack. Returning
13461  one value makes the module table the result of the require command. */
13462  return 1;
13463 #else
13464  return 0;
13465 #endif
13466 }
13467 
13468 #ifdef __cplusplus
13469 }
13470 #endif
13471 
13472 
13473 const char* SWIG_LUACODE=
13474  "\n"
13475  " pl = plplotluac";
13476 
13477 void SWIG_init_user(lua_State* L)
13478 {
13479  /* exec Lua code if applicable */
13481 }
13482 
static int _wrap_bin(lua_State *L)
static swig_lua_namespace swig_SwigModule
swig_lua_method * metatable
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:805
static char myct_funcstr[255]
#define plw3d
Definition: plplot.h:851
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:750
static swig_module_info swig_module
SWIGINTERN void SWIG_Lua_get_class_registry(lua_State *L)
void(* ct_func)(PLFLT, PLFLT, PLFLT *, PLFLT *, PLPointer)
SWIGRUNTIME char * SWIG_PackData(char *c, void *ptr, size_t sz)
static int _wrap_mtex3(lua_State *L)
#define plgxax
Definition: plplot.h:737
#define plsstrm
Definition: plplot.h:824
void(* fill_func)(PLINT, const PLFLT *, const PLFLT *)
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:820
struct swig_lua_class ** ns_classes
static int _wrap_scmap1a(lua_State *L)
#define plvpor
Definition: plplot.h:849
SWIGINTERN void SWIG_write_ptr_array(lua_State *L, void **array, int size, swig_type_info *type, int own)
SWIGINTERN int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class *clss, int metamethod_name_idx, int skip_check)
static int _wrap_sfont(lua_State *L)
static int _wrap_imagefr(lua_State *L)
static int _wrap_gfam(lua_State *L)
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:763
#define plerry
Definition: plplot.h:704
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:841
SWIGINTERN void SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[])
#define plschr
Definition: plplot.h:779
#define plsdev
Definition: plplot.h:795
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:718
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 SWIG_NullReferenceError
#define pllegend
Definition: plplot.h:747
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)
void(* mapform_func)(PLINT, PLFLT *, PLFLT *)
static int _wrap_scmap1la(lua_State *L)
#define plshade
Definition: plplot.h:809
#define plscompression
Definition: plplot.h:794
static int _wrap_scompression(lua_State *L)
#define plarc
Definition: plplot.h:682
PLUINT PLUNICODE
Definition: plplot.h:196
SWIGINTERN void SWIG_Lua_create_class_registry(lua_State *L)
static int _wrap_spause(lua_State *L)
static swig_lua_attribute swig_SwigModule_attributes[]
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:513
#define plot3dc
Definition: plplot.h:765
#define plot3dcl
Definition: plplot.h:766
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:752
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:818
#define plwind
Definition: plplot.h:853
#define plclear
Definition: plplot.h:690
#define plfill
Definition: plplot.h:706
#define plconfigtime
Definition: plplot.h:694
#define plsurf3dl
Definition: plplot.h:837
SWIGINTERN void ** SWIG_get_ptr_array_var(lua_State *L, int index, int *size, swig_type_info *type)
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:594
static int _wrap_scolbg(lua_State *L)
#define plbtime
Definition: plplot.h:688
#define pl_setcontlabelparam
Definition: plplot.h:680
#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)
void plResetOpts(void)
Definition: plargs.c:834
static int _wrap_PLGraphicsIn_pY_set(lua_State *L)
swig_lua_namespace * cls_static
static swig_type_info _swigt__p_p_double
#define plscolbg
Definition: plplot.h:791
void pltr1(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plcont.c:874
swig_dycast_func dcast
static int _wrap_PLGraphicsIn_dX_set(lua_State *L)
struct swig_cast_info * cast
#define plfont
Definition: plplot.h:709
static int _wrap_PLGraphicsIn_type_get(lua_State *L)
#define plstyl
Definition: plplot.h:835
#define plpoly3
Definition: plplot.h:771
#define SWIG_ConvertPtr(L, idx, ptr, type, flags)
swig_type_info ** type
#define plimage
Definition: plplot.h:742
swig_type_info * type
static int _wrap_lightsource(lua_State *L)
SWIGRUNTIME swig_cast_info * SWIG_TypeCheck(const char *c, swig_type_info *ty)
#define plfontld
Definition: plplot.h:710
#define SWIG_RUNTIME_VERSION
static int _wrap_image(lua_State *L)
#define plscolbga
Definition: plplot.h:792
#define SWIGRUNTIMEINLINE
#define plbin
Definition: plplot.h:684
static int _wrap_plot3dcl(lua_State *L)
static int _wrap_setcontlabelformat(lua_State *L)
#define plsdiori
Definition: plplot.h:798
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:708
#define plparseopts
Definition: plplot.h:767
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:639
#define SWIGRUNTIME
#define plsym
Definition: plplot.h:842
static int _wrap_scol0(lua_State *L)
#define plscmap1
Definition: plplot.h:783
static int _wrap_poin3(lua_State *L)
#define plinit
Definition: plplot.h:744
#define lua_rawsetp(L, index, ptr)
#define plctime
Definition: plplot.h:697
#define pltimefmt
Definition: plplot.h:845
SWIGINTERN int SWIG_Lua_class_tostring(lua_State *L)
#define plscmap1n
Definition: plplot.h:787
static int _wrap_gcol0(lua_State *L)
static int _wrap_prec(lua_State *L)
#define plbop
Definition: plplot.h:685
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:1898
static int _wrap_plOptUsage(lua_State *L)
#define plsdiplt
Definition: plplot.h:799
#define plsvect
Definition: plplot.h:838
#define plscmap1a
Definition: plplot.h:784
#define plssub
Definition: plplot.h:825
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:204
#define plspal1
Definition: plplot.h:822
#define plsetopt
Definition: plplot.h:804
static int _wrap_lab(lua_State *L)
#define plmeshc
Definition: plplot.h:760
#define plgcompression
Definition: plplot.h:717
static int _wrap_sesc(lua_State *L)
#define SWIG_DECLARE_TYPEMAP_ARR_FN(NAME, TYPE)
#define SWIG_GetModule(clientdata)
#define plszax
Definition: plplot.h:843
#define plvsta
Definition: plplot.h:850
static int _wrap_map(lua_State *L)
SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L, swig_lua_class *clss)
static swig_type_info _swigt__p_f_int_p_double_p_double__void
static int _wrap_replot(lua_State *L)
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:728
#define plaxes
Definition: plplot.h:683
#define plsori
Definition: plplot.h:819
static char mapform_funcstr[255]
#define plgdiplt
Definition: plplot.h:721
#define plscmap0a
Definition: plplot.h:781
#define lua_rawlen
PLINT ny
Definition: plplot.h:525
static const char * swig_PLGraphicsIn_base_names[]
#define plfamadv
Definition: plplot.h:705
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:698
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)
SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info *SWIGUNUSED swig_type, int first_arg, swig_lua_base_iterator_func func, int *const ret)
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)
SWIGINTERN void SWIG_Lua_populate_inheritable_metamethods(lua_State *L)
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)
PLINT(* defined_func)(PLFLT, PLFLT)
#define SWIGUNUSED
#define plgfont
Definition: plplot.h:726
SWIGINTERN void SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns, int reg)
#define SWIG_init
void plSetUsage(PLCHAR_VECTOR program_string, PLCHAR_VECTOR usage_string)
Definition: plargs.c:1272
static int _wrap_PLGraphicsIn_state_set(lua_State *L)
#define plend1
Definition: plplot.h:699
int PLINT
Definition: plplot.h:176
#define plenv0
Definition: plplot.h:701
static int _wrap_mapstring(lua_State *L)
static int _wrap_sdiori(lua_State *L)
static int _wrap_erry(lua_State *L)
SWIGINTERN void SWIG_Lua_add_variable(lua_State *L, const char *name, lua_CFunction getFn, lua_CFunction setFn)
#define plgdiori
Definition: plplot.h:720
SWIGRUNTIME swig_type_info * SWIG_TypeQueryModule(swig_module_info *start, swig_module_info *end, const char *name)
#define plshades
Definition: plplot.h:813
static int _wrap_scmap1n(lua_State *L)
PLINT PLBOOL
Definition: plplot.h:199
#define SWIG_LUA_FLOAT
#define SWIG_fail_arg(func_name, argnum, type)
#define lua_rawgetp(L, index, ptr)
#define SWIG_FREE_ARRAY(PTR)
static int _wrap_meshc(lua_State *L)
static swig_type_info _swigt__p_PLGraphicsIn
SWIGINTERN void SWIG_Lua_add_class_instance_details(lua_State *L, swig_lua_class *clss)
static int _wrap_PLGraphicsIn_wX_set(lua_State *L)
#define plssym
Definition: plplot.h:826
static int _wrap_smaj(lua_State *L)
PLFLT_NC_MATRIX yg
Definition: plplot.h:524
#define pljoin
Definition: plplot.h:745
#define plgzax
Definition: plplot.h:739
static int _wrap_sori(lua_State *L)
static int _wrap_surf3d(lua_State *L)
static int _wrap_line(lua_State *L)
#define SWIGEXPORT
SWIGINTERN void SWIG_Lua_add_namespace_classes(lua_State *L, swig_lua_namespace *ns)
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:723
PLINT ny
Definition: plplot.h:513
#define plgdidev
Definition: plplot.h:719
static int _wrap_col1(lua_State *L)
static int _wrap_legend(lua_State *L)
#define plstar
Definition: plplot.h:827
static int _wrap_stransform(lua_State *L)
static int _wrap_glevel(lua_State *L)
static swig_cast_info _swigc__p_f_int_p_double_p_double__void[]
#define plcpstrm
Definition: plplot.h:696
#define plimagefr
Definition: plplot.h:743
#define plcalc_world
Definition: plplot.h:689
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:807
swig_type_info * type
#define plhist
Definition: plplot.h:740
static int _wrap_font(lua_State *L)
static int _wrap_scmap1(lua_State *L)
static swig_lua_method swig_PLGraphicsIn_meta[]
SWIGRUNTIME void SWIG_InitializeModule(void *clientdata)
static int _wrap_ssym(lua_State *L)
#define plgchr
Definition: plplot.h:711
struct swig_module_info * next
#define SWIG_ERROR
#define SWIGTYPE_p_PLGraphicsIn
static int _wrap_path(lua_State *L)
#define plsdidev
Definition: plplot.h:796
SWIGRUNTIME void SWIG_Lua_SetModule(lua_State *L, swig_module_info *module)
#define SWIG_SetModule(clientdata, pointer)
#define plspal0
Definition: plplot.h:821
static int _wrap_scmap0n(lua_State *L)
#define plfill3
Definition: plplot.h:707
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 swig_lua_class * swig_PLGraphicsIn_Sf_SwigStatic_classes[]
static swig_lua_const_info swig_SwigModule_constants[]
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:802
static int _wrap_PLGraphicsIn_type_set(lua_State *L)
PLFLT_NC_FE_POINTER yg
Definition: plplot.h:512
#define plstring
Definition: plplot.h:830
#define plstransform
Definition: plplot.h:829
#define plvect
Definition: plplot.h:847
swig_type_info * type
static int _wrap_adv(lua_State *L)
PLFLT_NC_FE_POINTER zg
Definition: plplot.h:512
void mapform(PLINT n, PLFLT *x, PLFLT *y)
static int _wrap_sfam(lua_State *L)
#define plscmap1la
Definition: plplot.h:786
#define plgfnam
Definition: plplot.h:725
static swig_cast_info _swigc__p_f_double_double_p_double_p_double_p_void__void[]
struct swig_lua_namespace swig_lua_namespace
SWIGINTERN int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class *clss, const int metatable_index)
static int _wrap_vasp(lua_State *L)
#define plcont
Definition: plplot.h:695
#define plsxax
Definition: plplot.h:840
#define plstart
Definition: plplot.h:828
#define pleop
Definition: plplot.h:702
static swig_type_info _swigt__p_p_char
#define plmesh
Definition: plplot.h:759
static int _wrap_PLGraphicsIn_button_set(lua_State *L)
static int _wrap_bop(lua_State *L)
#define plhlsrgb
Definition: plplot.h:741
swig_type_info ** types
static int _wrap_cont(lua_State *L)
#define plsmaj
Definition: plplot.h:815
PLINT nx
Definition: plplot.h:525
#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:692
int(* swig_lua_base_iterator_func)(lua_State *, swig_type_info *, int, int *ret)
#define pllab
Definition: plplot.h:746
#define pllightsource
Definition: plplot.h:748
static swig_lua_method swig_PLGraphicsIn_Sf_SwigStatic_methods[]
SWIGINTERN void SWIG_Lua_add_class_static_details(lua_State *L, swig_lua_class *clss)
#define SWIGINTERN
#define plbox
Definition: plplot.h:686
static swig_lua_namespace swig_PLGraphicsIn_Sf_SwigStatic
#define SWIG_init_user
SWIGRUNTIMEINLINE void * SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory)
lua_CFunction constructor
#define pltext
Definition: plplot.h:844
static int _wrap_lsty(lua_State *L)
#define plwidth
Definition: plplot.h:852
#define plgver
Definition: plplot.h:734
static int _wrap_smin(lua_State *L)
static int _wrap_mkstrm(lua_State *L)
#define plscol0a
Definition: plplot.h:790
static swig_cast_info _swigc__p_p_char[]
static int _wrap_wind(lua_State *L)
#define plptex3
Definition: plplot.h:775
static int _wrap_vect(lua_State *L)
static int _wrap_cpstrm(lua_State *L)
static int _proxy__wrap_new_PLGraphicsIn(lua_State *L)
#define plsdiplz
Definition: plplot.h:800
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:823
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:751
static char mypltr_funcstr[255]
#define plstripd
Definition: plplot.h:834
#define plgfci
Definition: plplot.h:724
#define plgspa
Definition: plplot.h:732
#define plgcolbg
Definition: plplot.h:715
SWIGINTERN void SWIG_Lua_AddMetatable(lua_State *L, swig_type_info *type)
#define plstripc
Definition: plplot.h:833
static int _wrap_gpage(lua_State *L)
SWIGRUNTIME void SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata)
#define plstripa
Definition: plplot.h:832
#define SWIG_LUA_STRING
static int _wrap_mapfill(lua_State *L)
static int _wrap_svpa(lua_State *L)
#define plstring3
Definition: plplot.h:831
static PLINT Alen
#define SWIG_NewMemberObj(L, ptr, sz, type)
#define plvpas
Definition: plplot.h:848
void myct(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void *pltr_data)
static swig_type_info _swigt__p_f_int_double_p_char_int_p_void__void
#define plsfont
Definition: plplot.h:808
void plmapfill(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:661
static int _wrap_fill(lua_State *L)
SWIGINTERN int SWIG_table_size(lua_State *L, int index)
static int _wrap_gver(lua_State *L)
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:773
void plOptUsage(void)
Definition: plargs.c:1289
static int _wrap_sym(lua_State *L)
static int _wrap_gyax(lua_State *L)
void pltr0(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer PL_UNUSED(pltr_data))
Definition: plcont.c:858
SWIGRUNTIME void SWIG_TypeClientData(swig_type_info *ti, void *clientdata)
static PLFLT value(double n1, double n2, double hue)
Definition: plctrl.c:1223
SWIGRUNTIME int SWIG_Lua_type(lua_State *L)
void pltr2(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plcont.c:941
SWIGRUNTIME const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz)
#define plgvpd
Definition: plplot.h:735
#define plpoin
Definition: plplot.h:769
#define plgriddata
Definition: plplot.h:731
#define plgvpw
Definition: plplot.h:736
static int _wrap_plResetOpts(lua_State *L)
static int _wrap_PLGraphicsIn_state_get(lua_State *L)
#define SWIG_NewPointerObj(L, ptr, type, owner)
struct swig_lua_namespace ** ns_namespaces
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)
void *(* swig_converter_func)(void *, int *)
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:761
#define PL_UNUSED(x)
Definition: plplot.h:128
static swig_lua_method swig_SwigModule_methods[]
float PLFLT
Definition: plplot.h:158
void mylabel(PLINT axis, PLFLT value, char *label, PLINT length, PLPointer data)
#define plscol0
Definition: plplot.h:789
struct swig_module_info swig_module_info
static int _wrap_warn(lua_State *L)
#define plxormod
Definition: plplot.h:854
static int _wrap_mtex(lua_State *L)
swig_lua_method * methods
static int _wrap_flush(lua_State *L)
#define plflush
Definition: plplot.h:708
#define plerrx
Definition: plplot.h:703
PLFLT_NC_MATRIX zg
Definition: plplot.h:524
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:714
static swig_type_info * swig_types[13]
static int _wrap_sxax(lua_State *L)
SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L)
SWIGINTERN int SWIG_Lua_class_do_set(lua_State *L, swig_type_info *type, int first_arg, int *ret)
SWIGRUNTIME void SWIG_PropagateClientData(void)
#define plgcolbga
Definition: plplot.h:716
static swig_cast_info _swigc__p_f_int_p_q_const__double_p_q_const__double__void[]
#define SWIG_Lua_add_boolean(L, n, b)
static int _wrap_init(lua_State *L)
static int _wrap_shades(lua_State *L)
#define plgyax
Definition: plplot.h:738
#define plsesc
Definition: plplot.h:803
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:700
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
#define SWIG_POINTER_NO_NULL
swig_lua_method * ns_methods
static swig_cast_info _swigc__p_int[]
#define plgcmap1_range
Definition: plplot.h:712
#define plcol0
Definition: plplot.h:691
static int _wrap_PLGraphicsIn_pX_set(lua_State *L)
static int _wrap_gcompression(lua_State *L)
#define plbox3
Definition: plplot.h:687
static int _wrap_ctime(lua_State *L)
struct swig_type_info *(* swig_dycast_func)(void **)
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:693
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:727
PLFLT_NC_FE_POINTER xg
Definition: plplot.h:512
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
SWIGINTERN int SWIG_Lua_class_do_get_item(lua_State *L, swig_type_info *type, int SWIGUNUSED first_arg, int *ret)
static int _wrap_sdev(lua_State *L)
static int _wrap_stripc(lua_State *L)
#define SWIG_LUA_POINTER
#define plpoin3
Definition: plplot.h:770
static int _wrap_PLGraphicsIn_keysym_get(lua_State *L)
static int _wrap_gxax(lua_State *L)
void plwarn(PLCHAR_VECTOR errormsg)
Definition: plctrl.c:1867
static int _wrap_PLGraphicsIn_string_get(lua_State *L)
#define plscmap0n
Definition: plplot.h:782
#define SWIG_AddCast(r)
#define plscolor
Definition: plplot.h:793
#define plsvpa
Definition: plplot.h:839
#define plpat
Definition: plplot.h:768
#define pl_setcontlabelformat
Definition: plplot.h:679
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:788
SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss)
#define SWIG_check_num_args(func_name, a, b)
struct swig_cast_info * prev
#define plgcol0
Definition: plplot.h:713
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:777
swig_cast_info ** cast_initial
void plClearOpts(void)
Definition: plargs.c:821
#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:785
void plmap(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy)
Definition: plmap.c:565
#define plprec
Definition: plplot.h:772
#define lua_absindex(L, i)
#define plptex
Definition: plplot.h:774
#define plline
Definition: plplot.h:749
PLFLT_NC_MATRIX xg
Definition: plplot.h:524
static swig_lua_attribute swig_PLGraphicsIn_Sf_SwigStatic_attributes[]
#define SWIG_contract_assert(expr, msg)
static int _wrap_width(lua_State *L)
SWIGINTERN int SWIG_Lua_class_do_get(lua_State *L, swig_type_info *type, int SWIGUNUSED first_arg, int *ret)
static swig_cast_info _swigc__p_char[]
struct swig_cast_info swig_cast_info
#define plgradient
Definition: plplot.h:730
SWIGRUNTIME const char * SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name)
static int _wrap_shade(lua_State *L)
luaL_Reg swig_lua_method
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:681
#define SWIG_OK
#define SWIGINTERNINLINE
SWIGRUNTIME char * SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz)
const char * fqname
#define plvasp
Definition: plplot.h:846
static int _wrap_line3(lua_State *L)
#define plrandd
Definition: plplot.h:776
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:780
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:616
static int _wrap_sfnam(lua_State *L)
#define plgstrm
Definition: plplot.h:733
void(* pltr_func)(PLFLT, PLFLT, PLFLT *, PLFLT *, PLPointer)
#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:806
static int _wrap_col0(lua_State *L)
SWIGINTERN void SWIG_Lua_get_inheritable_metamethods(lua_State *L)
static int _wrap_svect(lua_State *L)
static int _wrap_styl(lua_State *L)
static int _wrap_gstrm(lua_State *L)
void(* destructor)(void *)
static int _wrap_clear(lua_State *L)
static int _wrap_spage(lua_State *L)
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:762
void plMinMax2dGrid(PLFLT_MATRIX f, PLINT nx, PLINT ny, PLFLT *fnmax, PLFLT *fnmin)
Definition: plmem.c:141
void(* label_func)(PLINT, PLFLT, char *, PLINT, PLPointer)
#define plrgbhls
Definition: plplot.h:778
#define plsurf3d
Definition: plplot.h:836
static swig_lua_class * swig_SwigModule_classes[]
static int _wrap_errx(lua_State *L)
#define plgra
Definition: plplot.h:729
static int _wrap_gcol0a(lua_State *L)
#define plsdimap
Definition: plplot.h:797
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 swig_lua_namespace * swig_SwigModule_namespaces[]
SWIGRUNTIME int SWIG_Lua_class_equal(lua_State *L)
PLFLT(* f2eval_func)(PLINT, PLINT, PLPointer)
static int _wrap_sdiplt(lua_State *L)
static int _wrap_string(lua_State *L)
static swig_lua_const_info swig_PLGraphicsIn_Sf_SwigStatic_constants[]
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:764
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:814
PLINT nx
Definition: plplot.h:513
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)