I want to use gluUnProject in order to do things on-screen when the user clicks with the mouse.  I'm using Ubuntu, and it seems that the opengl libraries that come with it do not come with the glu(Un)Project methods defined.  However, after poking around a bit in the source, it looks pretty straight-forward to create the lisp methods from the c methods, so I added the following to my glu.lisp file:

(def-foreign-routine ("gluProject" project) void
  (obj-x gl:double)
  (obj-y gl:double)
  (obj-z gl:double)
  (modelview (* gl:double)
  (projection (* gl:double)
  (viewport (* gl:int))
  (win-x (* gl:double)
  (win-y (* gl:double)
  (win-z (* gl:double)))))))
 
(def-foreign-routine ("gluUnProject" unproject) void
  (win-x gl:double)
  (win-y gl:double)
  (win-z gl:double)
  (modelview (* gl:double)
  (projection (* gl:double)
  (viewport (* gl:int))
  (obj-x (* gl:double)
  (obj-y (* gl:double)
  (obj-z (* gl:double)))))))

These are purely based off of looking around at how the other glu methods were defined.

Are these definitions correct?  I'm unable to really try them out because I don't understand how to pass double pointers to these methods.  I'm just getting started with CL, and loving it so far, but the application I'm currently working on has definitely hit a roadblock.

Can somone point me in the right direction as far as whether how I'm defining these methods is correct, and if so, how I pass pointer-style vars to the method calls to get the results?

Thanks!