Menu

Tree [dbd8ce] master esdl-1.3.1 /
 History

HTTPS access


File Date Author Commit
 api_gen 2007-12-21 Andrzej Giniewicz Andrzej Giniewicz [4fff99] removed depreceated calls to erlang:fault in fa...
 c_src 2013-04-08 Dan Gudmundsson Dan Gudmundsson [f73091] Update with Windows gcc x86 info
 doc 2010-10-12 Dan Gudmundsson Dan Gudmundsson [67a38f] More cleanup moved GL to SDL MACROS with same d...
 ebin 2009-05-05 Bjorn Gustavsson Bjorn Gustavsson [d42fd9] Ignore build results and create ebin and priv d...
 include 2011-01-23 Dan Gudmundsson Dan Gudmundsson [326a25] More fixes, configure, more functions moved to ...
 priv 2009-05-05 Bjorn Gustavsson Bjorn Gustavsson [d42fd9] Ignore build results and create ebin and priv d...
 src 2013-04-08 Dan Gudmundsson Dan Gudmundsson [f73091] Update with Windows gcc x86 info
 test 2013-02-27 Dan Gudmundsson Dan Gudmundsson [f3d752] Remove Makefiles and configure scripts and mino...
 woggle 2009-05-16 Dan Gudmundsson Dan Gudmundsson [821c92] Git converted windows <CR><NL> <NL>
 .gitignore 2009-05-05 Bjorn Gustavsson Bjorn Gustavsson [d42fd9] Ignore build results and create ebin and priv d...
 README-SDL.txt 2004-03-30 Bjorn Gustavsson Bjorn Gustavsson [4cc035] Initial revision.
 Readme 2013-08-05 Björn Gustavsson Björn Gustavsson [1298aa] Fix building on Mac OS X
 esdl.pub 2004-03-30 Bjorn Gustavsson Bjorn Gustavsson [4cc035] Initial revision.
 license.terms 2004-03-30 Dan Gudmundsson Dan Gudmundsson [b666d1] We missed some files and dirs
 rebar.config 2013-08-06 Björn Gustavsson Björn Gustavsson [31defe] Mac OS X: Ensure that SDL can be found when emb...
 rebar.config.script 2013-05-17 Dan Gudmundsson Dan Gudmundsson [2372a1] Fix the previous fix, sigh
 vsn.mk 2013-08-06 Dan Gudmundsson Dan Gudmundsson [dbd8ce] Update version

Read Me

ESDL by Dan Gudmundsson 
Currently located at http://esdl.sourceforge.net

What is it?
===========
Esdl is library for accessing SDL (Simple DirectMedia Layer)
and OpenGL through Erlang.

Simple DirectMedia Layer is a cross-platform multimedia library
designed to provide fast access to the graphics framebuffer and audio
device. It also do event handling from mouse, keyboards and joysticks.
It is also possible to use TrueType fonts through SDL_ttf
(www.libsdl.org/projects/SDL_ttf/) and images through SDL_image
(www.libsdl.org/projects/SDL_image/). More information can be
found at libsdl.org

OpenGL is a cross-platform standard for 3D rendering and
3D hardware acceleration. More information can be found at
www.opengl.org

News
========= 
1.3.1:
   Throw away Makefiles and use rebar for building

1.3:
   Builds with otp-r15b

1.2:
   I have removed the opengl specific part from esdl, now esdl
   requires that wx is available for opengl usage.
   
   This means that this release is not backwards compatible 
   with the old release, some gl functions have been changed in wx gl.

   This is done to only have one gl.erl in your (erlang) system,
   and it also more up to date with the standard.
   Actually only wx/ebin/gl.beam wx/ebin/glu.beam and wx/priv/OS/erl_gl.[so|dll]
   is required.

   Also using wx's opengl allowed me to create an opengl thread,
   if the erlang emulator is multithreaded. So now sdl with opengl
   works for both smp and single threaded erlang.
   
 
Compilation and Installation
=============================

You need erlang (www.erlang.org). This release has only been
tested on R16B, it requires R14B version for opengl to work.

You need libsdl (www.libsdl.org) (the development package) version > 1.2.5
For windows grab SDL-devel-1.2.15-VC.zip 
    (which work with both gcc and cl and contains both x86 and x64 libs)

On Mac OS X, you also must install XQuartz from:

   http://xquartz.macosforge.org

(Needed for the X11 header files.)

And optionally you'll need:
* SDL_ttf (www.libsdl.org/projects/SDL_ttf/) version > 2.0.7
* SDL_image (www.libsdl.org/projects/SDL_image/) version > 1.2.4

You need rebar, see: github.com/rebar/rebar

Build with: 
rebar compile

On windows:
===========
SDL_DIR=/opt/local rebar compile (requires Microsoft's SDK)
or 
CC=gcc SDL_DIR=/opt/local rebar compile (requires mingw)
also copy SDL.dll to esdl/priv dir or put SDL.dll somewhere in your path.

Note: for x64 and mingw-gcc you (currently) can not link against libraries build with 
MCL so you will need to recreate the dependency libs,
see http://sourceforge.net/apps/trac/mingw-w64/wiki/Answer%2064%20bit%20MSVC-generated%20x64%20.lib

::This is currently not supported::

Optionally you'll also need SDL_ttf for the font support 
and SDL_image for the image support.

    Note: SDL_ttf and SDL_image are disabled by default, since they
          depend on libraries not in the plain vanilla SDL packages.
          By making them optional one can compile and run esdl without
          having to bother about getting hold of the SDL_ttf and
          SDL_image libraries.  Enable them in the Makefile:

              ENABLE_SDL_TTF = yes
              ENABLE_SDL_IMAGE = yes


Testing esdl can be done by building the tests in the test directory and 
running the test programs, example:
cd test
erl +S1 -pa ../ebin   (werl on windows) 
Erlang (BEAM) emulator version 5.1.1 [threads:0]
Eshell V5.1.1  (abort with ^G)
1> testsprite:go().    %% Escape quits
2> testgl:go().  
3> erldemo:go().
4> testaudio:go(). 
5> testjoy:go().
6> test_ttf:go("/usr/share/fonts/truetype/freefont/FreeSerif.ttf", 20).
7> test_glfont:go("/usr/share/fonts/truetype/freefont/FreeSans.ttf").
8> test_glimg:go().


Regards 
/Dan (d g u d @ users.sf.net)
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.