Rev 2340 | Rev 2344 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2340 | Rev 2342 | ||
---|---|---|---|
Line 10... | Line 10... | ||
10 | #include |
10 | #include |
11 | #include |
11 | #include |
12 | #include |
12 | #include |
13 | #include |
13 | #include |
Line 14... | Line 14... | ||
14 | 14 | ||
Line 15... | Line 15... | ||
15 | typedef struct bitmap bitmap_t; |
15 | #include "bitmap.h" |
16 | 16 | ||
17 | void parse_cmdline(char *cmdline, char *log); |
17 | void parse_cmdline(char *cmdline, char *log); |
Line 18... | Line 18... | ||
18 | int _stdcall display_handler(ioctl_t *io); |
18 | int _stdcall display_handler(ioctl_t *io); |
19 | int init_agp(void); |
- | |
20 | 19 | int init_agp(void); |
|
21 | int create_video(int width, int height, u32_t *outp); |
20 | |
Line 22... | Line 21... | ||
22 | int create_bitmap(bitmap_t **pbitmap, int width, int height); |
21 | int create_video(int width, int height, u32_t *outp); |
Line 50... | Line 49... | ||
50 | { |
49 | { |
51 | printf("Can't open %s\nExit\n", log); |
50 | printf("Can't open %s\nExit\n", log); |
52 | return 0; |
51 | return 0; |
53 | }; |
52 | }; |
54 | } |
53 | } |
55 | dbgprintf("i915_early_preview second edition\n cmdline: %s\n", cmdline); |
54 | dbgprintf("i915 blitter preview\n cmdline: %s\n", cmdline); |
Line 56... | Line 55... | ||
56 | 55 | ||
Line 57... | Line 56... | ||
57 | enum_pci_devices(); |
56 | enum_pci_devices(); |
Line 76... | Line 75... | ||
76 | 75 | ||
77 | #define SRV_GETVERSION 0 |
76 | #define SRV_GETVERSION 0 |
78 | #define SRV_ENUM_MODES 1 |
77 | #define SRV_ENUM_MODES 1 |
Line 79... | Line 78... | ||
79 | #define SRV_SET_MODE 2 |
78 | #define SRV_SET_MODE 2 |
- | 79 | ||
80 | 80 | #define SRV_CREATE_BITMAP 10 |
|
81 | #define SRV_CREATE_VIDEO 9 |
- | |
Line 82... | Line 81... | ||
82 | #define SRV_BLIT_VIDEO 10 |
81 | |
83 | #define SRV_CREATE_BITMAP 11 |
82 | #define SRV_BLIT_VIDEO 20 |
84 | 83 | ||
Line 122... | Line 121... | ||
122 | check_input(sizeof(videomode_t)); |
121 | check_input(sizeof(videomode_t)); |
123 | if( i915_modeset ) |
122 | if( i915_modeset ) |
124 | retval = set_user_mode((videomode_t*)inp); |
123 | retval = set_user_mode((videomode_t*)inp); |
125 | break; |
124 | break; |
Line 126... | Line 125... | ||
126 | 125 | ||
127 | case SRV_CREATE_VIDEO: |
126 | case SRV_CREATE_BITMAP: |
128 | check_input(2); |
- | |
129 | check_output(4); |
127 | check_input(5); |
130 | retval = create_video(inp[0], inp[1], outp); |
128 | retval = create_bitmap((struct ubitmap*)inp); |
Line -... | Line 129... | ||
- | 129 | break; |
|
131 | break; |
130 | |
132 | 131 | ||
133 | case SRV_BLIT_VIDEO: |
132 | case SRV_BLIT_VIDEO: |
Line 134... | Line 133... | ||
134 | video_blit( ((uint64_t*)inp)[0], inp[2], inp[3], |
133 | blit_video( inp[0], inp[1], inp[2], |
135 | inp[4], inp[5], inp[6]); |
134 | inp[3], inp[4], inp[5], inp[6]); |
136 | - | ||
137 | retval = 0; |
- | |
138 | break; |
- | |
139 | - | ||
140 | case SRV_CREATE_BITMAP: |
- | |
141 | check_input(8); |
- | |
142 | check_output(4); |
- | |
143 | retval = create_bitmap((bitmap_t**)outp, inp[0], inp[1]); |
135 | |
Line 144... | Line 136... | ||
144 | break; |
136 | retval = 0; |
145 | 137 | break; |