Shadowed some foreign type definitions that may clash with CL package.
[cl-glfw/jecs.git] / README
blobd582ef5850be0afab1312894e18964e334e3ca7b
1 cl-glfw: The glfw wrapper for Common Lisp.
3 A public domain set of CFFI bindings and convenience macros for the GLFW, GLU and OpenGL
4 libraries.
6 The OpenGL bindings are automatically generated from the (supposedly) canonical spec-files from 
7 http://www.opengl.org/registry/
9 The GLU binding was hand-coerced from a tidied up header file, through swig, so it's pretty
10 much a direct mapping onto the API.
12 GLFW threading WILL PROBABLY BREAK YOUR LISP. I would advise seeking other avenues if you
13 require threading in your applications. The bindings remain in cl-glfw, but, I should emphasise
14 once again, that they probably are going to mess up things like garbage collection in your lisp,
15 and apparently some things to do with stacks and allocations aswell.
18 NAME MANGLING STYLE
20 All function/constant names are 'lispified', that is dash-separated, instead of camel-case. 
21 Suffixes and acronyms are kept together as one word. Library prefixes are expressed as their
22 package. Constants are surrounded by the '+' characters as lisp convention dictates.
23 Some examples:
25 glfwOpenWindow -> glfw:open-window
26 glVertex3fv -> gl:vertex-3fv
27 gluBuild2DMipmaps -> glu:build-2d-mipmaps
28 GL_FOG_INDEX -> gl:+fog-index+
29 GL_LIGHT0 -> gl:+light-0+
31 Functions that take a predictable c-array input or return an output have automatic-translators
32 for lisp-sequences. However, this will require an extra allocation. cffi:pointer types will
33 be passed straight through. Eg. (gl:vertex-3fv #(1.0 0.0 1.0)) will work as expected.
36 Platforms tested on:
37     SBCL Linux x86
38     SBCL Linux amd64
39     Others: Let me know.
42 Links:
43     http://repo.or.cz/w/cl-glfw.git
44     http://glfw.sf.net/
45     http://common-lisp.net/project/cffi/
46     http://www.sbcl.org/
47     http://www.opengl.org/
50 Enjoy.
51 Bill
52 airbaggins@users.sourceforge.net