>>>>> "Andrew" == Andrew Simms <[EMAIL PROTECTED]> writes:
Andrew> I've been working on some code to port a Lisp based software system
from
Andrew> AllegroCL to CMUCL. Part of this project involves making calls to
OpenGL
Andrew> calls via functions like this one:
Andrew> NAME
Andrew> glXQueryExtension - indicate whether the GLX extension is
Andrew> supported
Andrew> C SPECIFICATION
Andrew> Bool glXQueryExtension( Display *dpy,
Andrew> int *errorBase,
Andrew> int *eventBase )
Andrew> The Lisp code does not ever try to build things like the *dpy
parameter from
Andrew> scratch. Instead it gets these from calling other GL functions
which return
Andrew> a pointer to a properly constructed struct of type Display.
Andrew> The problem I see is that I'm not sure how to do this with
Andrew> def-alien-routine:
Andrew> (alien:def-alien-routine ( glxqueryextension "glXQueryExtension" )
Andrew> c-call:unsigned-int
Andrew> ( dpy c-call:integer :out ) ;; try to wedge in a generic
integer
Andrew> pointer, doesn't work
Andrew> ( errorBase c-call:integer :out )
Andrew> ( errorBase c-call:integer :out )
Andrew> And using something like '(alien:* T) is not compatible with :out
style
Andrew> arguments.
I think an (alien:* t) is the right type. But for glXQueryExtension,
don't you want just plain :in style argument? You are passing an
alien pointer into the function. The function is free to modify the
memory contents pointed to by the pointer.
I'm guessing though.
Ray