1 /***********************************************************
2 Copyright 1991-1995 by Stichting Mathematisch Centrum, Amsterdam,
7 Permission to use, copy, modify, and distribute this software and its
8 documentation for any purpose and without fee is hereby granted,
9 provided that the above copyright notice appear in all copies and that
10 both that copyright notice and this permission notice appear in
11 supporting documentation, and that the names of Stichting Mathematisch
12 Centrum or CWI or Corporation for National Research Initiatives or
13 CNRI not be used in advertising or publicity pertaining to
14 distribution of the software without specific, written prior
17 While CWI is the initial source for this software, a modified version
18 is made available by the Corporation for National Research Initiatives
19 (CNRI) at the Internet address ftp://ftp.python.org.
21 STICHTING MATHEMATISCH CENTRUM AND CNRI DISCLAIM ALL WARRANTIES WITH
22 REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF
23 MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH
24 CENTRUM OR CNRI BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
25 DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
26 PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
27 TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
28 PERFORMANCE OF THIS SOFTWARE.
30 ******************************************************************/
33 Input used to generate the Python module "glmodule.c".
34 The stub generator is a Python script called "cgen.py".
36 Each definition must be contained on one line:
38 <returntype> <name> <type> <arg> <type> <arg>
40 <returntype> can be: void, short, long (XXX maybe others?)
42 <type> can be: char, string, short, float, long, or double
43 string indicates a null terminated string;
44 if <type> is char and <arg> begins with a *, the * is stripped
45 and <type> is changed into string
47 <arg> has the form <mode> or <mode>[<subscript>]
50 r: arg is received (arg is a pointer)
51 and <subscript> can be (N and I are numbers):
58 In the case where the subscript consists of two parts
59 separated by *, the first part is the width of the matrix, and
60 the second part is the length of the matrix. This order is
61 opposite from the order used in C to declare a two-dimensional
66 * An attempt has been made to make this module switch threads on qread
67 * calls. It is far from safe, though.
75 extern int textwritemask();
76 extern int pagewritemask();
82 #include "cgensupport.h"
85 Some stubs are too complicated for the stub generator.
86 We can include manually written versions of them here.
87 A line starting with '%' gives the name of the function so the stub
88 generator can include it in the table of functions.
100 Py_BEGIN_ALLOW_THREADS
101 retval = qread( & arg1 );
103 { PyObject *v = PyTuple_New( 2 );
104 if (v == NULL) return NULL;
105 PyTuple_SetItem(v, 0, mknewlongobject(retval));
106 PyTuple_SetItem(v, 1, mknewshortobject(arg1));
113 varray -- an array of v.. calls.
114 The argument is an array (maybe list or tuple) of points.
115 Each point must be a tuple or list of coordinates (x, y, z).
116 The points may be 2- or 3-dimensional but must all have the
117 same dimension. Float and int values may be mixed however.
118 The points are always converted to 3D double precision points
119 by assuming z=0.0 if necessary (as indicated in the man page),
120 and for each point v3d() is called.
126 gl_varray(self, args)
130 PyObject *v, *w=NULL;
133 PyObject * (*getitem) Py_FPROTO((PyObject *, int));
135 if (!PyArg_GetObject(args, 1, 0, &v))
138 if (PyList_Check(v)) {
140 getitem = PyList_GetItem;
142 else if (PyTuple_Check(v)) {
144 getitem = PyTuple_GetItem;
156 w = (*getitem)(v, 0);
161 else if (PyList_Check(w)) {
162 width = PyList_Size(w);
164 else if (PyTuple_Check(w)) {
165 width = PyTuple_Size(w);
179 for (i = 0; i < n; i++) {
180 w = (*getitem)(v, i);
181 if (!PyArg_GetDoubleArray(w, 1, 0, width, vec))
191 vnarray, nvarray -- an array of n3f and v3f calls.
192 The argument is an array (list or tuple) of pairs of points and normals.
193 Each pair is a tuple (NOT a list) of a point and a normal for that point.
194 Each point or normal must be a tuple (NOT a list) of coordinates (x, y, z).
195 Three coordinates must be given. Float and int values may be mixed.
196 For each pair, n3f() is called for the normal, and then v3f() is called
199 vnarray and nvarray differ only in the order of the vector and normal in
200 the pair: vnarray expects (v, n) while nvarray expects (n, v).
203 static PyObject *gen_nvarray(); /* Forward */
208 gl_nvarray(self, args)
212 return gen_nvarray(args, 0);
218 gl_vnarray(self, args)
222 return gen_nvarray(args, 1);
225 /* Generic, internal version of {nv,nv}array: inorm indicates the
226 argument order, 0: normal first, 1: vector first. */
229 gen_nvarray(args, inorm)
233 PyObject *v, *w, *wnorm, *wvec;
235 float norm[3], vec[3];
236 PyObject * (*getitem) Py_FPROTO((PyObject *, int));
238 if (!PyArg_GetObject(args, 1, 0, &v))
241 if (PyList_Check(v)) {
243 getitem = PyList_GetItem;
245 else if (PyTuple_Check(v)) {
247 getitem = PyTuple_GetItem;
254 for (i = 0; i < n; i++) {
255 w = (*getitem)(v, i);
256 if (!PyTuple_Check(w) || PyTuple_Size(w) != 2) {
260 wnorm = PyTuple_GetItem(w, inorm);
261 wvec = PyTuple_GetItem(w, 1 - inorm);
262 if (!PyArg_GetFloatArray(wnorm, 1, 0, 3, norm) ||
263 !PyArg_GetFloatArray(wvec, 1, 0, 3, vec))
273 /* nurbssurface(s_knots[], t_knots[], ctl[][], s_order, t_order, type).
274 The dimensions of ctl[] are computed as follows:
275 [len(s_knots) - s_order], [len(t_knots) - t_order]
281 gl_nurbssurface(self, args)
294 long s_byte_stride, t_byte_stride;
297 PyObject *v, *w, *pt;
299 if (!PyArg_GetLongArraySize(args, 6, 0, &arg1))
301 if ((arg2 = PyMem_NEW(double, arg1 )) == NULL) {
302 return PyErr_NoMemory();
304 if (!PyArg_GetDoubleArray(args, 6, 0, arg1 , arg2))
306 if (!PyArg_GetLongArraySize(args, 6, 1, &arg3))
308 if ((arg4 = PyMem_NEW(double, arg3 )) == NULL) {
309 return PyErr_NoMemory();
311 if (!PyArg_GetDoubleArray(args, 6, 1, arg3 , arg4))
313 if (!PyArg_GetLong(args, 6, 3, &arg6))
315 if (!PyArg_GetLong(args, 6, 4, &arg7))
317 if (!PyArg_GetLong(args, 6, 5, &arg8))
321 else if (arg8 == N_XYZW)
327 s_nctl = arg1 - arg6;
328 t_nctl = arg3 - arg7;
329 if (!PyArg_GetObject(args, 6, 2, &v))
331 if (!PyList_Check(v) || PyList_Size(v) != s_nctl) {
335 if ((arg5 = PyMem_NEW(double, s_nctl*t_nctl*ncoords )) == NULL) {
336 return PyErr_NoMemory();
339 for (s = 0; s < s_nctl; s++) {
340 w = PyList_GetItem(v, s);
341 if (w == NULL || !PyList_Check(w) ||
342 PyList_Size(w) != t_nctl) {
346 for (t = 0; t < t_nctl; t++) {
347 pt = PyList_GetItem(w, t);
348 if (!PyArg_GetDoubleArray(pt, 1, 0, ncoords, pnext))
353 s_byte_stride = sizeof(double) * ncoords;
354 t_byte_stride = s_byte_stride * s_nctl;
355 nurbssurface( arg1 , arg2 , arg3 , arg4 ,
356 s_byte_stride , t_byte_stride , arg5 , arg6 , arg7 , arg8 );
364 /* nurbscurve(knots, ctlpoints, order, type).
365 The length of ctlpoints is len(knots)-order. */
370 gl_nurbscurve(self, args)
380 int ncoords, npoints;
384 if (!PyArg_GetLongArraySize(args, 4, 0, &arg1))
386 if ((arg2 = PyMem_NEW(double, arg1 )) == NULL) {
387 return PyErr_NoMemory();
389 if (!PyArg_GetDoubleArray(args, 4, 0, arg1 , arg2))
391 if (!PyArg_GetLong(args, 4, 2, &arg5))
393 if (!PyArg_GetLong(args, 4, 3, &arg6))
397 else if (arg6 == N_STW)
403 npoints = arg1 - arg5;
404 if (!PyArg_GetObject(args, 4, 1, &v))
406 if (!PyList_Check(v) || PyList_Size(v) != npoints) {
410 if ((arg4 = PyMem_NEW(double, npoints*ncoords )) == NULL) {
411 return PyErr_NoMemory();
414 for (i = 0; i < npoints; i++) {
415 if (!PyArg_GetDoubleArray(PyList_GetItem(v, i), 1, 0, ncoords, pnext))
419 arg3 = (sizeof(double)) * ncoords;
420 nurbscurve( arg1 , arg2 , arg3 , arg4 , arg5 , arg6 );
427 /* pwlcurve(points, type).
428 Points is a list of points. Type must be N_ST. */
433 gl_pwlcurve(self, args)
439 double *data, *pnext;
440 long npoints, ncoords;
442 if (!PyArg_GetObject(args, 2, 0, &v))
444 if (!PyArg_GetLong(args, 2, 1, &type))
446 if (!PyList_Check(v)) {
450 npoints = PyList_Size(v);
457 if ((data = PyMem_NEW(double, npoints*ncoords)) == NULL) {
458 return PyErr_NoMemory();
461 for (i = 0; i < npoints; i++) {
462 if (!PyArg_GetDoubleArray(PyList_GetItem(v, i), 1, 0, ncoords, pnext))
466 pwlcurve(npoints, data, sizeof(double)*ncoords, type);
473 /* Picking and Selecting */
475 static short *pickbuffer = NULL;
476 static long pickbuffersize;
479 pick_select(args, func)
483 if (!PyArg_GetLong(args, 1, 0, &pickbuffersize))
485 if (pickbuffer != NULL) {
486 PyErr_SetString(PyExc_RuntimeError,
487 "pick/gselect: already picking/selecting");
490 if ((pickbuffer = PyMem_NEW(short, pickbuffersize)) == NULL) {
491 return PyErr_NoMemory();
493 (*func)(pickbuffer, pickbuffersize);
499 endpick_select(args, func)
505 if (!PyArg_NoArgs(args))
507 if (pickbuffer == NULL) {
508 PyErr_SetString(PyExc_RuntimeError,
509 "endpick/endselect: not in pick/select mode");
512 nhits = (*func)(pickbuffer);
514 nhits = -nhits; /* How to report buffer overflow otherwise? */
516 /* Scan the buffer to see how many integers */
518 for (; nhits > 0; nhits--) {
519 n += 1 + pickbuffer[n];
524 /* XXX Could do it nicer and interpret the data structure here,
525 returning a list of lists. But this can be done in Python... */
526 for (i = 0; i < n; i++) {
527 w = PyInt_FromLong((long)pickbuffer[i]);
532 PyList_SetItem(v, i, w);
534 PyMem_DEL(pickbuffer);
539 extern void pick(), gselect();
540 extern long endpick(), endselect();
543 static PyObject *gl_pick(self, args) PyObject *self, *args; {
544 return pick_select(args, pick);
548 static PyObject *gl_endpick(self, args) PyObject *self, *args; {
549 return endpick_select(args, endpick);
553 static PyObject *gl_gselect(self, args) PyObject *self, *args; {
554 return pick_select(args, gselect);
558 static PyObject *gl_endselect(self, args) PyObject *self, *args; {
559 return endpick_select(args, endselect);
563 /* XXX The generator botches this one. Here's a quick hack to fix it. */
565 /* XXX The generator botches this one. Here's a quick hack to fix it. */
567 % getmatrix float r[16]
570 gl_getmatrix(self, args)
580 return PyErr_NoMemory();
582 for (i = 0; i < 4; i++) for (j = 0; j < 4; j++) {
583 w = mknewfloatobject(arg1[i][j]);
588 PyList_SetItem(v, i*4+j, w);
593 /* Here's an alternate version that returns a 4x4 matrix instead of
594 a vector. Unfortunately it is incompatible with loadmatrix and
597 % altgetmatrix float r[4][4]
600 gl_altgetmatrix(self, args)
612 for (i = 0; i < 4; i++) {
618 PyList_SetItem(v, i, w);
620 for (i = 0; i < 4; i++) {
621 for (j = 0; j < 4; j++) {
622 w = mknewfloatobject(arg1[i][j]);
627 PyList_SetItem(PyList_GetItem(v, i), j, w);
636 gl_lrectwrite(self, args)
649 if (!PyArg_GetShort(args, 5, 0, &x1))
651 if (!PyArg_GetShort(args, 5, 1, &y1))
653 if (!PyArg_GetShort(args, 5, 2, &x2))
655 if (!PyArg_GetShort(args, 5, 3, &y2))
657 if (!PyArg_GetString(args, 5, 4, &parray))
659 if (!PyArg_GetObject(args, 5, 4, &s))
662 /* Don't check this, it breaks experiments with pixmode(PM_SIZE, ...) */
663 pixcount = (long)(x2+1-x1) * (long)(y2+1-y1);
664 if (!PyString_Check(s) || PyString_Size(s) != pixcount*sizeof(long)) {
665 PyErr_SetString(PyExc_RuntimeError,
666 "string arg to lrectwrite has wrong size");
670 lrectwrite( x1 , y1 , x2 , y2 , (unsigned long *) parray );
678 gl_lrectread(self, args)
688 if (!PyArg_GetShort(args, 4, 0, &x1))
690 if (!PyArg_GetShort(args, 4, 1, &y1))
692 if (!PyArg_GetShort(args, 4, 2, &x2))
694 if (!PyArg_GetShort(args, 4, 3, &y2))
696 pixcount = (long)(x2+1-x1) * (long)(y2+1-y1);
697 parray = PyString_FromStringAndSize((char *)NULL, pixcount*sizeof(long));
699 return NULL; /* No memory */
700 lrectread(x1, y1, x2, y2, (unsigned long *) PyString_AsString(parray));
707 gl_readdisplay(self, args)
711 short x1, y1, x2, y2;
712 unsigned long *parray, hints;
716 if ( !PyArg_Parse(args, "hhhhl", &x1, &y1, &x2, &y2, &hints) )
718 size = (long)(x2+1-x1) * (long)(y2+1-y1);
719 rv = PyString_FromStringAndSize((char *)NULL, size*sizeof(long));
722 parray = (unsigned long *)PyString_AsString(rv);
723 size_ret = readdisplay(x1, y1, x2, y2, parray, hints);
724 if ( size_ret != size ) {
725 printf("gl_readdisplay: got %ld pixels, expected %ld\n",
727 PyErr_SetString(PyExc_RuntimeError, "readdisplay returned unexpected length");
733 /* Desperately needed, here are tools to compress and decompress
734 the data manipulated by lrectread/lrectwrite.
736 gl.packrect(width, height, packfactor, bigdata) --> smalldata
737 makes 'bigdata' 4*(packfactor**2) times smaller by:
738 - turning it into B/W (a factor 4)
739 - replacing squares of size pacfactor by one
742 gl.unpackrect(width, height, packfactor, smalldata) --> bigdata
743 is the inverse; the numeric arguments must be *the same*.
745 Both work best if width and height are multiples of packfactor
746 (in fact unpackrect will leave garbage bytes).
752 gl_packrect(self, args)
756 long width, height, packfactor;
758 PyObject *unpacked, *packed;
759 int pixcount, packedcount, x, y, r, g, b;
762 unsigned long *parray;
763 if (!PyArg_GetLong(args, 4, 0, &width))
765 if (!PyArg_GetLong(args, 4, 1, &height))
767 if (!PyArg_GetLong(args, 4, 2, &packfactor))
769 if (!PyArg_GetString(args, 4, 3, &s)) /* For type checking only */
771 if (!PyArg_GetObject(args, 4, 3, &unpacked))
773 if (width <= 0 || height <= 0 || packfactor <= 0) {
774 PyErr_SetString(PyExc_RuntimeError, "packrect args must be > 0");
777 pixcount = width*height;
778 packedcount = ((width+packfactor-1)/packfactor) *
779 ((height+packfactor-1)/packfactor);
780 if (PyString_Size(unpacked) != pixcount*sizeof(long)) {
781 PyErr_SetString(PyExc_RuntimeError,
782 "string arg to packrect has wrong size");
785 packed = PyString_FromStringAndSize((char *)NULL, packedcount);
788 parray = (unsigned long *) PyString_AsString(unpacked);
789 p = (unsigned char *) PyString_AsString(packed);
790 for (y = 0; y < height; y += packfactor, parray += packfactor*width) {
791 for (x = 0; x < width; x += packfactor) {
794 g = (pixel >> 8) & 0xff;
795 b = (pixel >> 16) & 0xff;
796 *p++ = (30*r+59*g+11*b) / 100;
804 static unsigned long unpacktab[256];
805 static int unpacktab_inited = 0;
808 gl_unpackrect(self, args)
812 long width, height, packfactor;
814 PyObject *unpacked, *packed;
815 int pixcount, packedcount;
816 register unsigned char *p;
817 register unsigned long *parray;
818 if (!unpacktab_inited) {
820 for (white = 256; --white >= 0; )
821 unpacktab[white] = white * 0x010101L;
824 if (!PyArg_GetLong(args, 4, 0, &width))
826 if (!PyArg_GetLong(args, 4, 1, &height))
828 if (!PyArg_GetLong(args, 4, 2, &packfactor))
830 if (!PyArg_GetString(args, 4, 3, &s)) /* For type checking only */
832 if (!PyArg_GetObject(args, 4, 3, &packed))
834 if (width <= 0 || height <= 0 || packfactor <= 0) {
835 PyErr_SetString(PyExc_RuntimeError, "packrect args must be > 0");
838 pixcount = width*height;
839 packedcount = ((width+packfactor-1)/packfactor) *
840 ((height+packfactor-1)/packfactor);
841 if (PyString_Size(packed) != packedcount) {
842 PyErr_SetString(PyExc_RuntimeError,
843 "string arg to unpackrect has wrong size");
846 unpacked = PyString_FromStringAndSize((char *)NULL, pixcount*sizeof(long));
847 if (unpacked == NULL)
849 parray = (unsigned long *) PyString_AsString(unpacked);
850 p = (unsigned char *) PyString_AsString(packed);
851 if (packfactor == 1 && width*height > 0) {
852 /* Just expand bytes to longs */
853 register int x = width * height;
855 *parray++ = unpacktab[*p++];
860 for (y = 0; y < height-packfactor+1;
861 y += packfactor, parray += packfactor*width) {
863 for (x = 0; x < width-packfactor+1; x += packfactor) {
864 register unsigned long pixel = unpacktab[*p++];
866 for (i = packfactor*width; (i-=width) >= 0;) {
868 for (j = packfactor; --j >= 0; )
869 parray[i+x+j] = pixel;
879 gl_gversion(self, args)
885 return PyString_FromString(buf);
889 /* void clear - Manual because of clash with termcap */
901 /* End of manually written stubs */
906 if !solaris void devport short s long s
907 void rdr2i long s long s
908 void rectfs short s short s short s short s
909 void rects short s short s short s short s
910 void rmv2i long s long s
946 if !solaris void spclos
954 if !solaris void endpupmode
956 if !solaris void pupmode
958 void pagecolor short s
959 void textcolor short s
963 void linewidth short s
964 void setlinestyle short s
966 void swapinterval short s
967 void writemask short s
968 if !solaris void textwritemask short s
970 void unqdevice short s
971 void curvebasis short s
972 void curveprecision short s
973 void loadname short s
974 void passthrough short s
975 void pushname short s
976 void setmonitor short s
977 if !solaris void setshade short s
978 void setpattern short s
979 if !solaris void pagewritemask short s
986 void chunksize long s
987 void compactify long s
990 void objinsert long s
991 void objreplace long s
993 void blanktime long s
995 # This is not in the library!?
996 ###void pupcolor long s
998 void backbuffer long s
999 void frontbuffer long s
1000 if !solaris void lsbackup long s
1005 void blankscreen long s
1006 void depthcue long s
1008 void backface long s
1010 void cmov2i long s long s
1011 void draw2i long s long s
1012 void move2i long s long s
1013 void pnt2i long s long s
1014 void patchbasis long s long s
1015 void patchprecision long s long s
1016 void pdr2i long s long s
1017 void pmv2i long s long s
1018 void rpdr2i long s long s
1019 void rpmv2i long s long s
1020 void xfpt2i long s long s
1021 void objdelete long s long s
1022 void patchcurves long s long s
1023 void minsize long s long s
1024 void maxsize long s long s
1025 void keepaspect long s long s
1026 void prefsize long s long s
1027 void stepunit long s long s
1028 void fudge long s long s
1029 void winmove long s long s
1031 void attachcursor short s short s
1032 void deflinestyle short s short s
1033 void noise short s short s
1034 void picksize short s short s
1035 void qenter short s short s
1036 void setdepth short s short s
1037 void cmov2s short s short s
1038 void draw2s short s short s
1039 void move2s short s short s
1040 void pdr2s short s short s
1041 void pmv2s short s short s
1042 void pnt2s short s short s
1043 void rdr2s short s short s
1044 void rmv2s short s short s
1045 void rpdr2s short s short s
1046 void rpmv2s short s short s
1047 void xfpt2s short s short s
1049 void cmov2 float s float s
1050 void draw2 float s float s
1051 void move2 float s float s
1052 void pnt2 float s float s
1053 void pdr2 float s float s
1054 void pmv2 float s float s
1055 void rdr2 float s float s
1056 void rmv2 float s float s
1057 void rpdr2 float s float s
1058 void rpmv2 float s float s
1059 void xfpt2 float s float s
1061 void loadmatrix float s[4*4]
1063 void multmatrix float s[4*4]
1065 void crv float s[3*4]
1067 void rcrv float s[4*4]
1070 # Methods that have strings.
1072 void addtopup long s char *s long s
1073 void charstr char *s
1074 void getport char *s
1075 long strwidth char *s
1076 long winopen char *s
1077 void wintitle char *s
1079 # Methods that have 1 long (# of elements) and an array
1081 void polf long s float s[3*arg1]
1082 void polf2 long s float s[2*arg1]
1083 void poly long s float s[3*arg1]
1084 void poly2 long s float s[2*arg1]
1085 void crvn long s float s[3*arg1]
1086 void rcrvn long s float s[4*arg1]
1088 void polf2i long s long s[2*arg1]
1089 void polfi long s long s[3*arg1]
1090 void poly2i long s long s[2*arg1]
1091 void polyi long s long s[3*arg1]
1093 void polf2s long s short s[2*arg1]
1094 void polfs long s short s[3*arg1]
1095 void polys long s short s[3*arg1]
1096 void poly2s long s short s[2*arg1]
1098 void defcursor short s u_short s[128]
1100 void writepixels short s u_short s[arg1]
1101 # Should be unsigned short...
1102 void defbasis long s float s[4*4]
1103 if !solaris void gewrite short s short s[arg1]
1105 void rotate short s char s
1106 # This is not in the library!?
1107 ###void setbutton short s char s
1108 void rot float s char s
1110 void circfi long s long s long s
1111 void circi long s long s long s
1112 void cmovi long s long s long s
1113 void drawi long s long s long s
1114 void movei long s long s long s
1115 void pnti long s long s long s
1116 void newtag long s long s long s
1117 void pdri long s long s long s
1118 void pmvi long s long s long s
1119 void rdri long s long s long s
1120 void rmvi long s long s long s
1121 void rpdri long s long s long s
1122 void rpmvi long s long s long s
1123 void xfpti long s long s long s
1125 void circ float s float s float s
1126 void circf float s float s float s
1127 void cmov float s float s float s
1128 void draw float s float s float s
1129 void move float s float s float s
1130 void pnt float s float s float s
1131 void scale float s float s float s
1132 void translate float s float s float s
1133 void pdr float s float s float s
1134 void pmv float s float s float s
1135 void rdr float s float s float s
1136 void rmv float s float s float s
1137 void rpdr float s float s float s
1138 void rpmv float s float s float s
1139 void xfpt float s float s float s
1141 void RGBcolor short s short s short s
1142 void RGBwritemask short s short s short s
1143 void setcursor short s short s short s
1144 void tie short s short s short s
1145 void circfs short s short s short s
1146 void circs short s short s short s
1147 void cmovs short s short s short s
1148 void draws short s short s short s
1149 void moves short s short s short s
1150 void pdrs short s short s short s
1151 void pmvs short s short s short s
1152 void pnts short s short s short s
1153 void rdrs short s short s short s
1154 void rmvs short s short s short s
1155 void rpdrs short s short s short s
1156 void rpmvs short s short s short s
1157 void xfpts short s short s short s
1158 void curorigin short s short s short s
1159 void cyclemap short s short s short s
1161 void patch float s[4*4] float s[4*4] float s[4*4]
1162 void splf long s float s[3*arg1] u_short s[arg1]
1163 void splf2 long s float s[2*arg1] u_short s[arg1]
1164 void splfi long s long s[3*arg1] u_short s[arg1]
1165 void splf2i long s long s[2*arg1] u_short s[arg1]
1166 void splfs long s short s[3*arg1] u_short s[arg1]
1167 void splf2s long s short s[2*arg1] u_short s[arg1]
1168 ###void defpattern short s short s u_short s[arg2*arg2/16]
1170 void rpatch float s[4*4] float s[4*4] float s[4*4] float s[4*4]
1172 # routines that send 4 floats
1174 void ortho2 float s float s float s float s
1175 void rect float s float s float s float s
1176 void rectf float s float s float s float s
1177 void xfpt4 float s float s float s float s
1179 void textport short s short s short s short s
1180 void mapcolor short s short s short s short s
1181 void scrmask short s short s short s short s
1182 void setvaluator short s short s short s short s
1183 void viewport short s short s short s short s
1184 void shaderange short s short s short s short s
1185 void xfpt4s short s short s short s short s
1186 void rectfi long s long s long s long s
1187 void recti long s long s long s long s
1188 void xfpt4i long s long s long s long s
1189 void prefposition long s long s long s long s
1191 void arc float s float s float s short s short s
1192 void arcf float s float s float s short s short s
1193 void arcfi long s long s long s short s short s
1194 void arci long s long s long s short s short s
1196 void bbox2 short s short s float s float s float s float s
1197 void bbox2i short s short s long s long s long s long s
1198 void bbox2s short s short s short s short s short s short s
1199 void blink short s short s short s short s short s
1200 void ortho float s float s float s float s float s float s
1201 void window float s float s float s float s float s float s
1202 void lookat float s float s float s float s float s float s short s
1204 void perspective short s float s float s float s
1205 void polarview float s short s short s short s
1206 # XXX getichararray not supported
1207 #void writeRGB short s char s[arg1] char s[arg1] char s[arg1]
1209 void arcfs short s short s short s short s short s
1210 void arcs short s short s short s short s short s
1211 void rectcopy short s short s short s short s short s short s
1212 if !solaris void RGBcursor short s short s short s short s short s short s short s
1214 long getbutton short s
1222 long isqueued short s
1245 long getothermonitor
1248 long getvaluator short s
1251 void getdepth short r short r
1252 void getcpos short r short r
1253 void getsize long r long r
1254 void getorigin long r long r
1255 void getviewport short r short r short r short r
1256 if !solaris void gettp short r short r short r short r
1257 void getgpos float r float r float r float r
1258 void winposition long s long s long s long s
1259 void gRGBcolor short r short r short r
1260 void gRGBmask short r short r short r
1261 void getscrmask short r short r short r short r
1262 ###void gRGBcursor short r short r short r short r short r short r short r short r
1263 void getmcolor short s short r short r short r
1264 void mapw long s short s short s float r float r float r float r float r float r
1265 void mapw2 long s short s short s float r float r
1266 ###void defrasterfont short s short s short s Fontchar s[arg3] short s short s[4*arg5]
1267 ###long qread short r
1268 void getcursor short r u_short r u_short r long r
1270 # For these we receive arrays of stuff
1272 ###void getdev long s short s[arg1] short r[arg1]
1273 #XXX not generated correctly yet
1274 #void getmatrix float r[16]
1275 ###long readpixels short s short r[retval]
1276 ###long readRGB short s char r[retval] char r[retval] char r[retval]
1277 ###long blkqread short s short r[arg1]
1283 void curstype long s
1284 void drawmode long s
1285 void gammaramp short s[256] short s[256] short s[256]
1291 long getvideo long s
1292 void imakebackground
1293 void lmbind short s short s
1294 void lmdef long s long s long s float s[arg3]
1296 void normal float s[3]
1298 void RGBrange short s short s short s short s short s short s short s short s
1299 if !solaris void setvideo long s long s
1300 void shademodel long s
1301 void underlay long s
1303 # New Personal Iris/GT Routines
1319 void blendfunction long s long s
1328 void czclear long s long s
1329 void dglclose long s
1330 long dglopen char *s long s
1331 long getgdesc long s
1332 void getnurbsproperty long s float r
1333 void glcompat long s long s
1334 void iconsize long s long s
1335 void icontitle char *s
1336 void lRGBrange short s short s short s short s short s short s long s long s
1337 void linesmooth long s
1340 ###long lrectread short s short s short s short s long r[retval]
1341 ###void lrectwrite short s short s short s short s long s[(arg2-arg1+1)*(arg4-arg3+1)]
1342 ### Now manual, with string last arg
1343 ###long rectread short s short s short s short s short r[retval]
1344 ###void rectwrite short s short s short s short s short s[(arg2-arg1+1)*(arg4-arg3+1)]
1345 void lsetdepth long s long s
1346 void lshaderange short s short s long s long s
1349 void pntsmooth long s
1350 void readsource long s
1351 void rectzoom float s float s
1352 void sbox float s float s float s float s
1353 void sboxi long s long s long s long s
1354 void sboxs short s short s short s short s
1355 void sboxf float s float s float s float s
1356 void sboxfi long s long s long s long s
1357 void sboxfs short s short s short s short s
1358 void setnurbsproperty long s float s
1359 void setpup long s long s long s
1360 void smoothline long s
1361 void subpixel long s
1363 long swinopen long s
1373 void videocmd long s
1374 long windepth long s
1377 void zfunction long s
1379 void zwritemask long s
1383 void v2d double s[2]
1384 void v3d double s[3]
1385 void v4d double s[4]
1387 # Why isn't this here?
1389 void pixmode long s long s