X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pages%2FSDL.html-inc;h=bb561e5541c6b0089f0f548a1d38c66963dd7522;hb=3065276381925b3e87e7851f9a52df76064b9916;hp=530e24cffcd4fb0e04ac8c48774f7c4751c001be;hpb=449a007bd9879e7a37f21137c044f2af6f99f87c;p=sdlgit%2FSDL-Site.git diff --git a/pages/SDL.html-inc b/pages/SDL.html-inc index 530e24c..bb561e5 100644 --- a/pages/SDL.html-inc +++ b/pages/SDL.html-inc @@ -2,7 +2,10 @@

Index

-

NAME

Top

-

SDL_perl - Simple DirectMedia Layer for Perl

+

SDL - Simple DirectMedia Layer for Perl

+ +
+

CATEGORY

+
+

Core

SYNOPSIS

Top

@@ -130,23 +139,31 @@ per class basis.

init(flags)

As with the C language API, SDL_perl initializes the SDL environment through -the SDL::init subroutine. This routine takes a mode flag constructed through -the bitwise OR product of the following constants:

+the SDL::init subroutine. This routine takes a mode flag constructed through +the bitwise OR product of the SDL_INIT_* constants.

+

The constants are not exported by default. You can export them into your namespace by doing:

+
 use SDL ':all';
+
+
+

or access them directly:

+
 SDL::SDL_INIT_AUDIO;
+
+
* -INIT_AUDIO
+SDL_INIT_AUDIO
* -INIT_VIDEO
+SDL_INIT_VIDEO
* -INIT_CDROM
+SDL_INIT_CDROM
* -INIT_EVERYTHING
+SDL_INIT_EVERYTHING
* -INIT_NOPARACHUTE
+SDL_INIT_NOPARACHUTE
* -INIT_JOYSTICK
+SDL_INIT_JOYSTICK
* -INIT_TIMER
+SDL_INIT_TIMER

SDL::Init returns 0 on success, or -1 on error.

@@ -167,7 +184,8 @@ The flags tells SDL::quit_subSystem which subsystems to shut down, it uses the s

quit

-

Shuts down all SDL subsystems, unloads the dynamically linked library and frees the allocated resources. This should always be called before you exit.

+

Shuts down all SDL subsystems, unloads the dynamically linked library and frees the allocated resources.

+

Note: This will be called automatically when perl exits. You don't need to call this, except you want to initialize SDL after this again.

SDL::quit doesn't returns any value.

@@ -188,8 +206,8 @@ If 'flags' is 0 or SDL_INIT_EVERYTHING, it returns a mask of all initialized sub SDL::get_error, which returns a scalar containing the text of the message if any.

-

set_error(error) *need to be coded

-
+

set_error_real(error, @values)

+

SDL::get_error sets the SDL error to a printf style formatted string. it doesn't returns any values.

@@ -232,10 +250,6 @@ it doesn't returns any values.

Unknown SDL error

- - - -

Note 1: SDL_LASTERROR marks the highest numbered predefined error. Note 2: SDL also defines SDL_OutOfMemory() and SDL_Unsupported() for internal use which are equivalent to SDL_Error(SDL_ENOMEM) and SDL_Error(SDL_UNSUPPORTED) respectively.

@@ -246,8 +260,8 @@ which are equivalent to SDL_Error(SDL_ENOMEM) and SDL_Error(SDL_UNSUPPORTED) res
-

clear_error() * need to be coded

-
+

clear_error()

+

SDL::clear_error deletes all information about the last internal SDL error. Useful if the error has been handled by the program. it doesn't returns any value.

@@ -298,6 +312,12 @@ than the specified depending on the underlying OS.

+
+

AUTHORS

Top

+
+

magnet, kthakore

+ +