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.c (1954B)


      1 /* Generated from glu.ffi */
      2 
      3 #include "../pico.h"
      4 
      5 #include "GL/glut.h"
      6 #include "GL/glu.h"
      7 #include "GL/gl.h"
      8 
      9 any cfun_gluDeleteQuadric(any ex) {
     10    any x = ex, y;
     11    x = cdr(x);
     12    y = EVAL(car(x));
     13    NeedNum(ex, y);
     14    GLUquadric* b1 = (GLUquadric*) unBox(y);
     15    gluDeleteQuadric(b1);
     16    return Nil;
     17 }
     18 
     19 any cfun_gluDisk(any ex) {
     20    any x = ex, y;
     21    x = cdr(x);
     22    y = EVAL(car(x));
     23    NeedNum(ex, y);
     24    GLUquadric* b1 = (GLUquadric*) unBox(y);
     25    x = cdr(x);
     26    y = EVAL(car(x));
     27    NeedNum(ex, y);
     28    double b2 = (double) unBox(y) / 10000;
     29    x = cdr(x);
     30    y = EVAL(car(x));
     31    NeedNum(ex, y);
     32    double b3 = (double) unBox(y) / 10000;
     33    x = cdr(x);
     34    y = EVAL(car(x));
     35    NeedNum(ex, y);
     36    int b4 = (int) unBox(y);
     37    x = cdr(x);
     38    y = EVAL(car(x));
     39    NeedNum(ex, y);
     40    int b5 = (int) unBox(y);
     41    gluDisk(b1, b2, b3, b4, b5);
     42    return Nil;
     43 }
     44 
     45 any cfun_gluNewQuadric(any ex __attribute__((unused))) {
     46    GLUquadric* z = gluNewQuadric();
     47    return box(z);
     48 }
     49 
     50 any cfun_gluOrtho2D(any ex) {
     51    any x = ex, y;
     52    x = cdr(x);
     53    y = EVAL(car(x));
     54    NeedNum(ex, y);
     55    double b1 = (double) unBox(y) / 10000;
     56    x = cdr(x);
     57    y = EVAL(car(x));
     58    NeedNum(ex, y);
     59    double b2 = (double) unBox(y) / 10000;
     60    x = cdr(x);
     61    y = EVAL(car(x));
     62    NeedNum(ex, y);
     63    double b3 = (double) unBox(y) / 10000;
     64    x = cdr(x);
     65    y = EVAL(car(x));
     66    NeedNum(ex, y);
     67    double b4 = (double) unBox(y) / 10000;
     68    gluOrtho2D(b1, b2, b3, b4);
     69    return Nil;
     70 }
     71 
     72 any cfun_gluPerspective(any ex) {
     73    any x = ex, y;
     74    x = cdr(x);
     75    y = EVAL(car(x));
     76    NeedNum(ex, y);
     77    double b1 = (double) unBox(y) / 10000;
     78    x = cdr(x);
     79    y = EVAL(car(x));
     80    NeedNum(ex, y);
     81    double b2 = (double) unBox(y) / 10000;
     82    x = cdr(x);
     83    y = EVAL(car(x));
     84    NeedNum(ex, y);
     85    double b3 = (double) unBox(y) / 10000;
     86    x = cdr(x);
     87    y = EVAL(car(x));
     88    NeedNum(ex, y);
     89    double b4 = (double) unBox(y) / 10000;
     90    gluPerspective(b1, b2, b3, b4);
     91    return Nil;
     92 }