include/SDL.h
author Gabriel Jacobo <gabomdq@gmail.com>
Fri, 16 Nov 2012 09:23:18 -0300
changeset 6674 45a21e50ba5e
parent 6602 533131e24aeb
child 6690 9548c8a58103
permissions -rw-r--r--
Adds CMake build system by Marcus Von Appen (bug #1597)
slouken@0
     1
/*
slouken@5535
     2
  Simple DirectMedia Layer
slouken@6138
     3
  Copyright (C) 1997-2012 Sam Lantinga <slouken@libsdl.org>
slouken@0
     4
slouken@5535
     5
  This software is provided 'as-is', without any express or implied
slouken@5535
     6
  warranty.  In no event will the authors be held liable for any damages
slouken@5535
     7
  arising from the use of this software.
slouken@0
     8
slouken@5535
     9
  Permission is granted to anyone to use this software for any purpose,
slouken@5535
    10
  including commercial applications, and to alter it and redistribute it
slouken@5535
    11
  freely, subject to the following restrictions:
slouken@0
    12
slouken@5535
    13
  1. The origin of this software must not be misrepresented; you must not
slouken@5535
    14
     claim that you wrote the original software. If you use this software
slouken@5535
    15
     in a product, an acknowledgment in the product documentation would be
slouken@5535
    16
     appreciated but is not required.
slouken@5535
    17
  2. Altered source versions must be plainly marked as such, and must not be
slouken@5535
    18
     misrepresented as being the original software.
slouken@5535
    19
  3. This notice may not be removed or altered from any source distribution.
slouken@0
    20
*/
slouken@0
    21
slouken@1895
    22
/**
slouken@3407
    23
 *  \file SDL.h
slouken@3407
    24
 *  
slouken@3407
    25
 *  Main include header for the SDL library
slouken@1895
    26
 */
slouken@3407
    27
slouken@1895
    28
/**
slouken@3407
    29
 *  \mainpage Simple DirectMedia Layer (SDL)
slouken@3407
    30
 *  
slouken@3407
    31
 *  http://www.libsdl.org/
slouken@3407
    32
 *  
slouken@3407
    33
 *  \section intro_sec Introduction
slouken@3407
    34
 *  
slouken@3407
    35
 *  This is the Simple DirectMedia Layer, a general API that provides low
slouken@3407
    36
 *  level access to audio, keyboard, mouse, joystick, 3D hardware via OpenGL,
slouken@3407
    37
 *  and 2D framebuffer across multiple platforms.
slouken@3407
    38
 *  
slouken@3407
    39
 *  SDL is written in C, but works with C++ natively, and has bindings to
slouken@3407
    40
 *  several other languages, including Ada, C#, Eiffel, Erlang, Euphoria,
slouken@3407
    41
 *  Guile, Haskell, Java, Lisp, Lua, ML, Objective C, Pascal, Perl, PHP,
slouken@3407
    42
 *  Pike, Pliant, Python, Ruby, and Smalltalk.
slouken@3407
    43
 *  
slouken@3407
    44
 *  This library is distributed under GNU LGPL version 2, which can be
slouken@3407
    45
 *  found in the file  "COPYING".  This license allows you to use SDL
slouken@3407
    46
 *  freely in commercial programs as long as you link with the dynamic
slouken@3407
    47
 *  library.
slouken@3407
    48
 *  
slouken@3407
    49
 *  The best way to learn how to use SDL is to check out the header files in
slouken@3407
    50
 *  the "include" subdirectory and the programs in the "test" subdirectory.
slouken@3407
    51
 *  The header files and test programs are well commented and always up to date.
slouken@3407
    52
 *  More documentation is available in HTML format in "docs/index.html", and
slouken@3407
    53
 *  a documentation wiki is available online at:
slouken@3407
    54
 *  	http://www.libsdl.org/cgi/docwiki.cgi
slouken@3407
    55
 *  
slouken@3407
    56
 *  The test programs in the "test" subdirectory are in the public domain.
slouken@3407
    57
 *  
slouken@3407
    58
 *  Frequently asked questions are answered online:
slouken@3407
    59
 *  	http://www.libsdl.org/faq.php
slouken@3407
    60
 *  
slouken@3407
    61
 *  If you need help with the library, or just want to discuss SDL related
slouken@3407
    62
 *  issues, you can join the developers mailing list:
slouken@3407
    63
 *  	http://www.libsdl.org/mailing-list.php
slouken@3407
    64
 *  
slouken@3407
    65
 *  Enjoy!
slouken@3407
    66
 *  	Sam Lantinga				(slouken@libsdl.org)
slouken@1895
    67
 */
slouken@0
    68
slouken@0
    69
#ifndef _SDL_H
slouken@0
    70
#define _SDL_H
slouken@0
    71
slouken@1423
    72
#include "SDL_main.h"
slouken@1353
    73
#include "SDL_stdinc.h"
slouken@5347
    74
#include "SDL_assert.h"
slouken@5017
    75
#include "SDL_atomic.h"
slouken@0
    76
#include "SDL_audio.h"
slouken@4493
    77
#include "SDL_clipboard.h"
slouken@1358
    78
#include "SDL_cpuinfo.h"
slouken@1358
    79
#include "SDL_endian.h"
slouken@1358
    80
#include "SDL_error.h"
slouken@0
    81
#include "SDL_events.h"
slouken@5189
    82
#include "SDL_hints.h"
slouken@1358
    83
#include "SDL_loadso.h"
slouken@5221
    84
#include "SDL_log.h"
slouken@6602
    85
#include "SDL_messagebox.h"
slouken@1358
    86
#include "SDL_mutex.h"
icculus@3170
    87
#include "SDL_power.h"
slouken@5145
    88
#include "SDL_render.h"
slouken@1358
    89
#include "SDL_rwops.h"
slouken@6342
    90
#include "SDL_system.h"
slouken@1358
    91
#include "SDL_thread.h"
slouken@1358
    92
#include "SDL_timer.h"
slouken@3647
    93
#include "SDL_version.h"
slouken@0
    94
#include "SDL_video.h"
slouken@0
    95
slouken@0
    96
#include "begin_code.h"
slouken@0
    97
/* Set up for C function definitions, even when using C++ */
slouken@0
    98
#ifdef __cplusplus
slouken@1895
    99
/* *INDENT-OFF* */
slouken@0
   100
extern "C" {
slouken@1895
   101
/* *INDENT-ON* */
slouken@0
   102
#endif
slouken@0
   103
slouken@0
   104
/* As of version 0.5, SDL is loaded dynamically into the application */
slouken@0
   105
slouken@3407
   106
/**
slouken@3407
   107
 *  \name SDL_INIT_*
slouken@3407
   108
 *  
slouken@3407
   109
 *  These are the flags which may be passed to SDL_Init().  You should
slouken@3407
   110
 *  specify the subsystems which you will be using in your application.
slouken@3407
   111
 */
slouken@3407
   112
/*@{*/
slouken@2713
   113
#define SDL_INIT_TIMER          0x00000001
slouken@2713
   114
#define SDL_INIT_AUDIO          0x00000010
slouken@2713
   115
#define SDL_INIT_VIDEO          0x00000020
slouken@2713
   116
#define SDL_INIT_JOYSTICK       0x00000200
slouken@2713
   117
#define SDL_INIT_HAPTIC         0x00001000
slouken@3407
   118
#define SDL_INIT_NOPARACHUTE    0x00100000      /**< Don't catch fatal signals */
slouken@2713
   119
#define SDL_INIT_EVERYTHING     0x0000FFFF
slouken@3407
   120
/*@}*/
slouken@0
   121
slouken@3348
   122
/**
slouken@4863
   123
 *  This function initializes  the subsystems specified by \c flags
slouken@3407
   124
 *  Unless the ::SDL_INIT_NOPARACHUTE flag is set, it will install cleanup
slouken@3407
   125
 *  signal handlers for some commonly ignored fatal signals (like SIGSEGV).
slouken@0
   126
 */
slouken@337
   127
extern DECLSPEC int SDLCALL SDL_Init(Uint32 flags);
slouken@0
   128
slouken@3348
   129
/**
slouken@3407
   130
 *  This function initializes specific SDL subsystems
slouken@3348
   131
 */
slouken@337
   132
extern DECLSPEC int SDLCALL SDL_InitSubSystem(Uint32 flags);
slouken@0
   133
slouken@3407
   134
/**
slouken@3407
   135
 *  This function cleans up specific SDL subsystems
slouken@3407
   136
 */
slouken@337
   137
extern DECLSPEC void SDLCALL SDL_QuitSubSystem(Uint32 flags);
slouken@0
   138
slouken@3348
   139
/**
slouken@4627
   140
 *  This function returns a mask of the specified subsystems which have
slouken@4627
   141
 *  previously been initialized.
slouken@3407
   142
 *  
slouken@3407
   143
 *  If \c flags is 0, it returns a mask of all initialized subsystems.
slouken@3407
   144
 */
slouken@337
   145
extern DECLSPEC Uint32 SDLCALL SDL_WasInit(Uint32 flags);
slouken@0
   146
slouken@3348
   147
/**
slouken@4627
   148
 *  This function cleans up all initialized subsystems. You should
slouken@4627
   149
 *  call it upon all exit conditions.
slouken@0
   150
 */
slouken@337
   151
extern DECLSPEC void SDLCALL SDL_Quit(void);
slouken@0
   152
slouken@0
   153
/* Ends C function definitions when using C++ */
slouken@0
   154
#ifdef __cplusplus
slouken@1895
   155
/* *INDENT-OFF* */
slouken@0
   156
}
slouken@1895
   157
/* *INDENT-ON* */
slouken@0
   158
#endif
slouken@0
   159
#include "close_code.h"
slouken@0
   160
slouken@0
   161
#endif /* _SDL_H */
slouken@1895
   162
slouken@1895
   163
/* vi: set ts=4 sw=4 expandtab: */