src/video/win32/SDL_win32video.h
author Edgar Simo <bobbens@gmail.com>
Sun, 06 Jul 2008 17:06:37 +0000
branchgsoc2008_force_feedback
changeset 2498 ab567bd667bf
parent 2308 514f7c1651fc
child 2724 0e2b65f32298
permissions -rw-r--r--
Fixed various mistakes in the doxygen.
     1 /*
     2     SDL - Simple DirectMedia Layer
     3     Copyright (C) 1997-2006 Sam Lantinga
     4 
     5     This library is free software; you can redistribute it and/or
     6     modify it under the terms of the GNU Lesser General Public
     7     License as published by the Free Software Foundation; either
     8     version 2.1 of the License, or (at your option) any later version.
     9 
    10     This library is distributed in the hope that it will be useful,
    11     but WITHOUT ANY WARRANTY; without even the implied warranty of
    12     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    13     Lesser General Public License for more details.
    14 
    15     You should have received a copy of the GNU Lesser General Public
    16     License along with this library; if not, write to the Free Software
    17     Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
    18 
    19     Sam Lantinga
    20     slouken@libsdl.org
    21 */
    22 #include "SDL_config.h"
    23 
    24 #ifndef _SDL_win32video_h
    25 #define _SDL_win32video_h
    26 
    27 #include "../SDL_sysvideo.h"
    28 
    29 #define WIN32_LEAN_AND_MEAN
    30 #define UNICODE
    31 #define WINVER  0x500           /* Need 0x410 for AlphaBlend() and 0x500 for EnumDisplayDevices() */
    32 #include <windows.h>
    33 
    34 #if SDL_VIDEO_RENDER_D3D
    35 //#include <d3d9.h>
    36 #define D3D_DEBUG_INFO
    37 #include "d3d9.h"
    38 #endif
    39 
    40 #include "SDL_win32events.h"
    41 #include "SDL_win32gamma.h"
    42 #include "SDL_win32keyboard.h"
    43 #include "SDL_win32modes.h"
    44 #include "SDL_win32mouse.h"
    45 #include "SDL_win32opengl.h"
    46 #include "SDL_win32window.h"
    47 
    48 #ifdef UNICODE
    49 #define WIN_StringToUTF8(S) SDL_iconv_string("UTF-8", "UCS-2", (char *)S, (SDL_wcslen(S)+1)*sizeof(WCHAR))
    50 #define WIN_UTF8ToString(S) (WCHAR *)SDL_iconv_string("UCS-2", "UTF-8", (char *)S, SDL_strlen(S)+1)
    51 #else
    52 #define WIN_StringToUTF8(S) SDL_iconv_string("UTF-8", "ASCII", (char *)S, (SDL_strlen(S)+1))
    53 #define WIN_UTF8ToString(S) SDL_iconv_string("ASCII", "UTF-8", (char *)S, SDL_strlen(S)+1)
    54 #endif
    55 
    56 /* Private display data */
    57 
    58 typedef struct SDL_VideoData
    59 {
    60 #if SDL_VIDEO_RENDER_D3D
    61     HANDLE d3dDLL;
    62     IDirect3D9 *d3d;
    63 #endif
    64     int mouse;
    65     int keyboard;
    66     SDL_scancode *key_layout;
    67 } SDL_VideoData;
    68 
    69 #endif /* _SDL_win32video_h */
    70 
    71 /* vi: set ts=4 sw=4 expandtab: */