Module Sdl


module Sdl: sig .. end
This module contains functions for initializing/quitting the library

exception SDL_init_exception of string
Exception for reporting errors during initialization

Main functions


type subsystem = [ `AUDIO | `CDROM | `JOYSTICK | `TIMER | `VIDEO ] 
Initialization flag type
val init : ?auto_clean:bool ->
[< `AUDIO
| `CDROM
| `EVENTTHREAD
| `EVERYTHING
| `JOYSTICK
| `NOPARACHUTE
| `TIMER
| `VIDEO ]
list -> unit
Initialize the SDL library. This should be called before all other SDL functions. The flags parameter specifies what part(s) of SDL to initialize.
val init_subsystem : subsystem list -> unit
val was_init : unit -> subsystem list
val quit : unit -> unit
quit shuts down all SDL subsystems and frees the resources allocated to them. This should always be called before you exit.
val quit_subsystem : subsystem list -> unit

Versioning information



type version = {
   major : int;
   minor : int;
   patch : int;
}
val version : unit -> version
version of the SDL library
val string_of_version : version -> string

Environment variables


val getenv : string -> string
val putenv : string -> string -> unit