comparison src/video/ps2gs/SDL_gsvideo.h @ 70:f590dd383b5d

Added Linux PlayStation 2 Graphics Synthesizer support
author Sam Lantinga <slouken@lokigames.com>
date Sat, 16 Jun 2001 03:17:45 +0000
parents
children 717f739d6ec1
comparison
equal deleted inserted replaced
69:280ff3af2ecc 70:f590dd383b5d
1 /*
2 SDL - Simple DirectMedia Layer
3 Copyright (C) 1997, 1998, 1999, 2000 Sam Lantinga
4
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 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 Library General Public License for more details.
14
15 You should have received a copy of the GNU Library General Public
16 License along with this library; if not, write to the Free
17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18
19 Sam Lantinga
20 slouken@devolution.com
21 */
22
23 #ifdef SAVE_RCSID
24 static char rcsid =
25 "@(#) $Id$";
26 #endif
27
28 #ifndef _SDL_gsvideo_h
29 #define _SDL_gsvideo_h
30
31 #include <sys/types.h>
32 #include <termios.h>
33 #include <linux/ps2/dev.h>
34 #include <linux/ps2/gs.h>
35
36 #include "SDL_mouse.h"
37 #include "SDL_mutex.h"
38 #include "SDL_sysvideo.h"
39
40 /* Hidden "this" pointer for the video functions */
41 #define _THIS SDL_VideoDevice *this
42
43
44 /* Private display data */
45 struct SDL_PrivateVideoData {
46 /* Gotta love that simple PS2 graphics interface. :) */
47 int console_fd;
48 int memory_fd;
49 struct ps2_screeninfo saved_vinfo;
50
51 /* Ye olde linux keyboard code */
52 int current_vt;
53 int saved_vt;
54 int keyboard_fd;
55 int saved_kbd_mode;
56 struct termios saved_kbd_termios;
57
58 /* Ye olde linux mouse code */
59 int mouse_fd;
60 int cursor_drawn;
61
62 /* The memory mapped DMA area and associated variables */
63 caddr_t mapped_mem;
64 int pixels_len;
65 int mapped_len;
66 struct ps2_image screen_image;
67 int screen_image_size;
68 unsigned long long *head_tags_mem;
69 unsigned long long *image_tags_mem;
70 int dma_pending;
71 };
72 /* Old variable names */
73 #define console_fd (this->hidden->console_fd)
74 #define memory_fd (this->hidden->memory_fd)
75 #define saved_vinfo (this->hidden->saved_vinfo)
76 #define current_vt (this->hidden->current_vt)
77 #define saved_vt (this->hidden->saved_vt)
78 #define keyboard_fd (this->hidden->keyboard_fd)
79 #define saved_kbd_mode (this->hidden->saved_kbd_mode)
80 #define saved_kbd_termios (this->hidden->saved_kbd_termios)
81 #define mouse_fd (this->hidden->mouse_fd)
82 #define cursor_drawn (this->hidden->cursor_drawn)
83 #define mapped_mem (this->hidden->mapped_mem)
84 #define pixels_len (this->hidden->pixels_len)
85 #define mapped_len (this->hidden->mapped_len)
86 #define screen_image (this->hidden->screen_image)
87 #define screen_image_size (this->hidden->screen_image_size)
88 #define head_tags_mem (this->hidden->head_tags_mem)
89 #define image_tags_mem (this->hidden->image_tags_mem)
90 #define dma_pending (this->hidden->dma_pending)
91
92 #endif /* _SDL_gsvideo_h */