[plt-scheme] opengl binding

From: Hans Oesterholt (hdnews at gawab.com)
Date: Sun Sep 18 16:06:37 EDT 2005

Got it working with glVertex2f, however I'd rather have it working like:

(define point (make-vector (<calculate x>) (<calulate y>) ))
(glVertex2fv point)

instead of having to do

(define point (make-vector (<calculate x>) (<calulate y>) ))
(glVertex2f (vector-ref point 0) (vector-ref point 1))

My own opengl binding takes care of this implicitly. It even
accepts lists of numbers there.

BTW. I needed to include opengl-enum.scm from my own
binding to get the right enumerations.

I personally like


better then


Would it be an option to adopt the constants from opengl-enum.scm?

Best whishes,

Scott Owens schreef:

> The sgl collection relies only on the foreign-function interface (as  
> of v299.28), and can be used with either mred/DrScheme or mzscheme.   
> sgl only provides access to the functions documented in the GL (1.5)  
> and GLU specs, and not to the functions of glx, or whatever OS X or  
> MS Windows use to manage GL drawing contexts.  mred provides this  
> functionality, but sgl itself is agnostic about how the GL contexts  
> are managed (as is the OpenGL spec itself).
> -Scott
> On Sep 18, 2005, at 12:39 PM, Hans Oesterholt wrote:
>> Scott Owens schreef:
>>> I'm curious if you are unaware of the GL binding that comes with  
>>> PLT  Scheme, or if you found it deficient.
>>> -Scott
>> I didn't try it yet. It is part of drscheme, not mzscheme isn't it?
>> Can I install it seperately from drscheme? I'll give it
>> a try sometime soon. It's not that I don't want to use it.
>> Some months ago, when I created mzopengl, wasn'tt aware
>> of the existence of sgl. As I am about to release the first
>> alpha of mzgtk2, I needan opengl binding working
>> with mzgtk2 released.
>> Hans

Posted on the users mailing list.