* [ANN] FFI bindings for SDL2
@ 2015-10-07 3:05 David Thompson
0 siblings, 0 replies; only message in thread
From: David Thompson @ 2015-10-07 3:05 UTC (permalink / raw)
To: guile-user
Hello Guilers,
SDL is a handy library for taking care of low-level window management
and keyboard/mouse input for video games. Version 2 was released quite
some time ago, but guile-sdl only works with SDL 1.x because SDL2 is
essentially an entirely different library. Furthermore, guile-sdl is
written in C and uses a complicated build system, making it hard to
hack. It also fails to build on OS X. So, I have begun the guile-sdl2
project to create pure Scheme bindings for SDL2. I plan to use this
library for Sly when all the needed functions have been wrapped.
So far I've only wrapped a handful of functions, but the autotools build
system is in place to make it easy for others to build and contribute
patches. Still need to set up the Texinfo manual, though. For Guix
users, there is a 'guix.scm' file that can be used with 'guix
environment', 'guix build', and/or 'guix package'.
There are lots of functions to wrap, so I would love some help if anyone
else out there is interested in SDL2! Patches are very much welcome.
Currently, the only thing you can really do is open and manipulate
windows, like so:
(use-modules (sdl2) (sdl2 video))
(sdl-init)
(define window
(make-sdl-window #:size '(800 600)
#:title "Hello, Guilers!"
#:opengl? #t))
(set-sdl-window-title! window "Goodbye, Guilers!)
(close-sdl-window! window)
The Git repository can be browsed on-line:
https://git.dthompson.us/guile-sdl2.git
And here's how to clone the repo:
git clone git://dthompson.us/guile-sdl2.git
Happy hacking!
--
David Thompson
GPG Key: 0FF1D807
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2015-10-07 3:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-07 3:05 [ANN] FFI bindings for SDL2 David Thompson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).