src/video/x11/SDL_x11modes.h
author Sam Lantinga <slouken@libsdl.org>
Tue, 15 Dec 2009 08:11:06 +0000
changeset 3565 f43c8f688f77
parent 3521 76f9b76ddf0f
child 3697 f7b03b6838cb
permissions -rw-r--r--
Fixed bug #906

Added better error reporting for OpenGL context creation failing.
slouken@1950
     1
/*
slouken@1950
     2
    SDL - Simple DirectMedia Layer
slouken@2859
     3
    Copyright (C) 1997-2009 Sam Lantinga
slouken@1950
     4
slouken@1950
     5
    This library is free software; you can redistribute it and/or
slouken@1950
     6
    modify it under the terms of the GNU Lesser General Public
slouken@1950
     7
    License as published by the Free Software Foundation; either
slouken@1950
     8
    version 2.1 of the License, or (at your option) any later version.
slouken@1950
     9
slouken@1950
    10
    This library is distributed in the hope that it will be useful,
slouken@1950
    11
    but WITHOUT ANY WARRANTY; without even the implied warranty of
slouken@1950
    12
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
slouken@1950
    13
    Lesser General Public License for more details.
slouken@1950
    14
slouken@1950
    15
    You should have received a copy of the GNU Lesser General Public
slouken@1950
    16
    License along with this library; if not, write to the Free Software
slouken@1950
    17
    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
slouken@1950
    18
slouken@1950
    19
    Sam Lantinga
slouken@1950
    20
    slouken@libsdl.org
slouken@1950
    21
*/
slouken@1950
    22
#include "SDL_config.h"
slouken@1950
    23
slouken@1950
    24
#ifndef _SDL_x11modes_h
slouken@1950
    25
#define _SDL_x11modes_h
slouken@1950
    26
slouken@1950
    27
typedef struct
slouken@1950
    28
{
slouken@1950
    29
    int screen;
slouken@1950
    30
    Visual *visual;
slouken@1951
    31
    int depth;
slouken@2916
    32
    int scanline_pad;
slouken@2873
    33
slouken@2873
    34
    int use_xinerama;
slouken@2873
    35
    int use_xrandr;
slouken@2873
    36
    int use_vidmode;
slouken@2873
    37
slouken@2873
    38
#if SDL_VIDEO_DRIVER_X11_XINERAMA
slouken@2874
    39
      SDL_NAME(XineramaScreenInfo) xinerama_info;
slouken@2873
    40
#endif
slouken@2873
    41
#if SDL_VIDEO_DRIVER_X11_XRANDR
slouken@2873
    42
    XRRScreenConfiguration *screen_config;
slouken@2873
    43
    int saved_size;
slouken@2873
    44
    Rotation saved_rotation;
slouken@2873
    45
    short saved_rate;
slouken@2873
    46
#endif
slouken@2873
    47
#if SDL_VIDEO_DRIVER_X11_VIDMODE
slouken@2874
    48
      SDL_NAME(XF86VidModeModeInfo) saved_mode;
slouken@2874
    49
    struct
slouken@2874
    50
    {
slouken@2873
    51
        int x, y;
slouken@2873
    52
    } saved_view;
slouken@2873
    53
#endif
slouken@2873
    54
slouken@1950
    55
} SDL_DisplayData;
slouken@1950
    56
slouken@3521
    57
extern int X11_InitModes(_THIS);
slouken@3500
    58
extern void X11_GetDisplayModes(_THIS, SDL_VideoDisplay * display);
slouken@3500
    59
extern int X11_SetDisplayMode(_THIS, SDL_VideoDisplay * display, SDL_DisplayMode * mode);
slouken@1950
    60
extern void X11_QuitModes(_THIS);
slouken@1950
    61
slouken@1950
    62
#endif /* _SDL_x11modes_h */
slouken@1950
    63
slouken@1950
    64
/* vi: set ts=4 sw=4 expandtab: */