SDL Framework RSS
NAVIGATION >>
HOME API TOOLS FORUM REPORT BUGS
:. SDL Framework (SDLFW)
SDLFW-app
SDLFW is a cross-platform framework from the powerful SDL library to create your own 2D games with the Lua programming language.
It's easy-to-use, open-source, and works on Windows, Linux and PSP.

SDLFW is licensed under the zLib license. That means you can use it freely for any purpose - including commercial purposes with no limitations.

:. Main Features
  • Fast application development through Lua scripting language
  • Support for multiple image formats
  • TrueType font rendering support
  • Provides input from the keyboard, mouse, and joystick
  • Provides a simple API to query the capabilities of the sound card
  • Complex audio functions, mainly for sound mixing
  • Provides a clean, simple, and reliable time and timer API
  • Provides an API for reading and playing tracks on a CDROM
  • Networking support
  • Provides a thread API that looks like a simplified version of pthreads
  • Is small, portable, and reliable
:. What's New in This Version?
  • Lua binding optimized, now should be a little more faster
  • Bugs fixed in more functions
  • Now SONY PlayStation Portable (PSP) platform is supported
  • Update samples to work fine on PSP
  • Improvements on error messages
:. Example
main.lua
local function main()
  -- Initialize SDL video   if ( SDL_Init(SDL_INIT_VIDEO) < 0 ) then     print( "Couldn't initialize SDL: " .. SDL_GetError() )     return 1   end
  -- Set the window caption   SDL_WM_SetCaption( "SDLFW - Hello World", nil )
  -- Create a new window   local screen = SDL_SetVideoMode( 512, 384, 16, SDL_SWSURFACE )   if ( screen == nil ) then     print( "Unable to set the video mode: " .. SDL_GetError() )     SDL_Quit()     return 1   end
  -- Get the global event   local event = SDLFW_GetGlobalEvent()
  -- While the user hasn't quit   local done = false   while ( done == false ) do     -- While there's an event to handle     if ( SDL_PollEvent(event) ) then       -- If the user has X out the window       if ( event.type == SDL_QUIT ) then done = true end     end
    -- Swaps screen buffers     SDL_Flip( screen )
    -- Wait a specified number of milliseconds before returning     SDL_Delay( 1 )   end
  -- Make sure SDL cleans up before exit   SDL_Quit()
  return 0 end
main()
:: CURRENT VERSION

1.7.1

Dec / 2017
:: PLATFORMS SUPPORTED
WINDOWS LINUX PSP
:: DOWNLOAD
DOWNLOAD Deps
:: DONATE
SDLFW needs your support, please donate 1 dollar or more to make this project better.
:: POWERED BY
SDL
Lua
:: VISITORS
:: CONTACT AND FEEDBACK
Developer
CorEduard@Programmer.net
SourceForge.net
SDLFW.sf.net Except where otherwise noted, content on this site is
licensed under a Creative Commons Attribution 3.0 License.