mplisp

miniPicoLisp with FFI and modules for Buddy BDD library, OpenGL, Gtk and GMP
git clone https://logand.com/git/mplisp.git/
Log | Files | Refs

glu.ffi (669B)


      1 # -*- picolisp -*-
      2 
      3 (load "@src/mod/ffi.l")
      4 
      5 (module 'glu '((X) (pack "glu:" (cdddr (chop X)))))
      6 
      7 (if (= *OS "Darwin")
      8     (include "GLUT/glut.h" "OpenGL/glu.h" "OpenGL/gl.h")
      9     (include "GL/glut.h" "GL/glu.h" "GL/gl.h"))
     10 
     11 (put 'cwrap 'GLUquadric* (get 'cwrap 'void*))
     12 
     13 (put 'cbody 'GLUquadric* (get 'cbody 'void*))
     14 
     15 # define SCL 10000.0
     16 
     17 (cfun void gluDeleteQuadric GLUquadric*)
     18 (cfun void gluDisk GLUquadric* (double inner) (double outer) (int slices) (int loops))
     19 (cfun GLUquadric* gluNewQuadric)
     20 (cfun void gluOrtho2D (double left) (double right) (double bottom) (double top))
     21 (cfun void gluPerspective (double fovy) (double aspect) (double zNear) (double zFar))