# Lua-SDL2 rc1 available for testing!

**URL:** <https://discourse.libsdl.org/t/lua-sdl2-rc1-available-for-testing/20625>\
**Category:** SDL Development\
**Created:** [April 26, 2014, 10:36am UTC](https://discourse.libsdl.org/t/lua-sdl2-rc1-available-for-testing/20625 "2014-04-26T10:36:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![David\_Demelier](https://discourse.libsdl.org/user_avatar/discourse.libsdl.org/david_demelier/32/2164_2.png) [@David\_Demelier](https://discourse.libsdl.org/u/David_Demelier)\
**Post date:** [April 26, 2014, 10:36am UTC](https://discourse.libsdl.org/t/lua-sdl2-rc1-available-for-testing/20625/1 "2014-04-26T10:36:51Z")

</div>

Hi there,

I’m very happy to announce the first release candidate of Lua-SDL2  
[1]. As I already announced a few  
months ago, Lua-SDL2 is a pure C binding against SDL 2.0.3.

It is designed to be as close as possible to the official SDL C API  
but with object orientation and  
functions overload where possible. For instance, SDL\_Window is mapped  
to a Lua userdata object.

The Lua-SDL2 binding was currently tested on Windows 7 and FreeBSD. It  
should compile on major  
platforms which support C and SDL. Prebuilt binaries are available for Windows.

The SDL API is covered around 95% (of what can be implemented, DSO and  
such are not counted), its API  
is completely documented [2].

However, Lua-SDL2 now needs _your_ help, by:

- Testing as much as possible, a lot of examples are available in the  
examples/ and tutorials/  
directories.

- A few functions are not implemented, it’s the case of Texture:lock  
for instance which is terribly  
hard to implement from Lua because the C side expect to cast the  
pixel pointer to the underlyling  
sized array which in Lua is impossible to do. Please provide me  
feedback on how you want it to  
be implemented.

- Feedback, provide me some enhancement you may find obvious or  
better. In the code or in the documentation :-).

Currently, Lua-SDL2 only supports Lua 5.2 and higher, I will add some  
portability code for Lua 5.1 in the  
next few days.

Enjoy this binding :-).

PS: Can anyone with the Wiki rights can add a link to this binding on  
the SDL Bindings [3] page?

Kind regards,  
David.

[1] [https://redmine.malikania.fr/projects/luasdl2/wiki#Download](https://redmine.malikania.fr/projects/luasdl2/wiki#Download)  
[2] [https://redmine.malikania.fr/projects/luasdl2/wiki#Documentation](https://redmine.malikania.fr/projects/luasdl2/wiki#Documentation)  
[3] [http://libsdl.org/languages.php](http://libsdl.org/languages.php)

---

<div class="post-metadata">

**Author:** ![slouken](https://discourse.libsdl.org/letter_avatar_proxy/v4/letter/s/ec9cab/32.png) [@slouken](https://discourse.libsdl.org/u/slouken)\
**Post date:** [April 26, 2014, 7:27pm UTC](https://discourse.libsdl.org/t/lua-sdl2-rc1-available-for-testing/20625/2 "2014-04-26T19:27:39Z")

</div>

Very cool! I’ve added this to the bindings page.

Cheers,On Sat, Apr 26, 2014 at 3:36 AM, David Demelier \<demelier.david at [gmail.com](http://gmail.com)\>wrote:

> Hi there,
> 
> I’m very happy to announce the first release candidate of Lua-SDL2  
> [1]. As I already announced a few  
> months ago, Lua-SDL2 is a pure C binding against SDL 2.0.3.
> 
> It is designed to be as close as possible to the official SDL C API  
> but with object orientation and  
> functions overload where possible. For instance, SDL\_Window is mapped  
> to a Lua userdata object.
> 
> The Lua-SDL2 binding was currently tested on Windows 7 and FreeBSD. It  
> should compile on major  
> platforms which support C and SDL. Prebuilt binaries are available for  
> Windows.
> 
> The SDL API is covered around 95% (of what can be implemented, DSO and  
> such are not counted), its API  
> is completely documented [2].
> 
> However, Lua-SDL2 now needs _your_ help, by:
> 
> - Testing as much as possible, a lot of examples are available in the  
> examples/ and tutorials/  
> directories.
> 
> - A few functions are not implemented, it’s the case of Texture:lock  
> for instance which is terribly  
> hard to implement from Lua because the C side expect to cast the  
> pixel pointer to the underlyling  
> sized array which in Lua is impossible to do. Please provide me  
> feedback on how you want it to  
> be implemented.
> 
> - Feedback, provide me some enhancement you may find obvious or  
> better. In the code or in the documentation :-).
> 
> Currently, Lua-SDL2 only supports Lua 5.2 and higher, I will add some  
> portability code for Lua 5.1 in the  
> next few days.
> 
> Enjoy this binding :-).
> 
> PS: Can anyone with the Wiki rights can add a link to this binding on  
> the SDL Bindings [3] page?
> 
> Kind regards,  
> David.
> 
> [1] [https://redmine.malikania.fr/projects/luasdl2/wiki#Download](https://redmine.malikania.fr/projects/luasdl2/wiki#Download)  
> [2] [https://redmine.malikania.fr/projects/luasdl2/wiki#Documentation](https://redmine.malikania.fr/projects/luasdl2/wiki#Documentation)  
> [3] [Simple DirectMedia Layer - Language Bindings](http://libsdl.org/languages.php)
> 
> * * *
> 
> SDL mailing list  
> SDL at [lists.libsdl.org](http://lists.libsdl.org)  
> [http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org](http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org)
