Lisp HUG Maillist Archive

LWM: Extending the undocumented CoreGraphics FFI?

Greetings,

I'm using LispWorks 4.4 under Mac OS X 10.3.8 and would like to use the 
native CoreGraphics API (Quartz 2D) instead of using CAPI to do some 
drawing.

I noticed that LispWorks already contains a "CORE-GRAPHICS" package 
with a substantial number of external symbols corresponding to various 
CoreGraphics functions. Unfortunately several of the functions that I'm 
interested in are not available which leads me to several questions:

(1) Is there any chance the CoreGraphics FFI source can be released 
(like the editor) so that it can be enhanced/made complete?

(2) Why do some of the external symbols of "CORE-PACKAGE" not have 
function values? Where they removed when the LispWorks image was 
delivered? For example:

CL-USER> (describe 'core-graphics:cg-context-draw-shading)

CORE-GRAPHICS:CG-CONTEXT-DRAW-SHADING is a SYMBOL
NAME          "CG-CONTEXT-DRAW-SHADING"
VALUE         #<unbound value>
FUNCTION      #<unbound function>
PLIST         NIL
PACKAGE       #<The CORE-GRAPHICS package, 135/256 internal, 259/512 
external>
; No value

CL-USER> (describe 'core-graphics:cg-context-restore-gstate)

CORE-GRAPHICS:CG-CONTEXT-RESTORE-GSTATE is a SYMBOL
NAME          "CG-CONTEXT-RESTORE-GSTATE"
VALUE         #<unbound value>
FUNCTION      #<Function CORE-GRAPHICS:CG-CONTEXT-RESTORE-GSTATE>
PLIST         (FLI::DEFINE-FOREIGN-FUNCTION-P T)
PACKAGE       #<The CORE-GRAPHICS package, 135/256 internal, 259/512 
external>
; No value


(3) If I were to write/generate a complete FFI for CoreGraphics (in a 
different package) would it conflict with the internal LispWorks FFI?


Thanks in advance for any help you might be able to provide.

Btw if there are LispWorks on Mac users out there that might be 
interested in FFIs for MacTypes.h, all of CoreFoundation, and CoreMIDI 
let me know. I hope to polish what I have now and make the source 
available.

-greg

_______________________________________________________
Greg Wuller                             greg@wuller.com
_______________________________________________________


Re: LWM: Extending the undocumented CoreGraphics FFI?

On Feb 20, 2005, at 9:56 PM, Greg Wuller wrote:

> Btw if there are LispWorks on Mac users out there that might be 
> interested in FFIs for MacTypes.h, all of CoreFoundation, and CoreMIDI 
> let me know. I hope to polish what I have now and make the source 
> available.

I for one would definitely be interested in what you have done so for.

regards,
Ralph

Raffael Cavallaro, Ph.D.
raffaelcavallaro@mac.com

Updated at: 2020-12-10 08:53 UTC