Mercurial > mplayer.hg
annotate libvo/vo_syncfb.c @ 22483:662e7f56ec7f
Include <string.h> explicitly.
(it was already present through other headers)
author | uau |
---|---|
date | Fri, 09 Mar 2007 14:04:07 +0000 |
parents | cea0eb833758 |
children | a124f3abc1ec |
rev | line source |
---|---|
1 | 1 |
2 // How many MegaBytes of RAM is on your G200/G400 card? | |
3 #define RAM_SIZE 16 | |
4 | |
5 /* | |
6 * video_out_syncfb.c | |
7 * | |
8 * Copyright (C) Aaron Holtzman - Aug 1999 | |
9 * | |
10 * This file is part of mpeg2dec, a free MPEG-2 video stream decoder. | |
11 * | |
12 * mpeg2dec is free software; you can redistribute it and/or modify | |
13 * it under the terms of the GNU General Public License as published by | |
14 * the Free Software Foundation; either version 2, or (at your option) | |
15 * any later version. | |
16 * | |
17 * mpeg2dec is distributed in the hope that it will be useful, | |
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
20 * GNU General Public License for more details. | |
21 * | |
22 * You should have received a copy of the GNU General Public License | |
21977
cea0eb833758
Fix FSF address and otherwise broken license headers.
diego
parents:
18234
diff
changeset
|
23 * along with mpeg2dec; if not, write to the Free Software |
cea0eb833758
Fix FSF address and otherwise broken license headers.
diego
parents:
18234
diff
changeset
|
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
1 | 25 */ |
26 | |
27 #include <stdio.h> | |
28 #include <stdlib.h> | |
29 #include <string.h> | |
4737
32e1f5042f65
I don't like such reports: '-vo dga:vidix or -vo x11:vidix works fine for me'
nick
parents:
4596
diff
changeset
|
30 #include <errno.h> |
1 | 31 |
32 #include "config.h" | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
33 #include "mp_msg.h" |
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
34 #include "help_mp.h" |
1 | 35 #include "video_out.h" |
36 #include "video_out_internal.h" | |
37 | |
38 #include <sys/ioctl.h> | |
39 #include <unistd.h> | |
40 #include <fcntl.h> | |
41 #include <sys/mman.h> | |
42 #include <linux/videodev.h> | |
43 | |
44 #include "drivers/syncfb/syncfb.h" | |
45 | |
354 | 46 #include "fastmemcpy.h" |
350 | 47 |
8148
5b39e79af5fe
removed get_info, using the same sheme as in libmpcodecs instead
alex
parents:
7124
diff
changeset
|
48 static vo_info_t info = |
1 | 49 { |
50 "Matrox G200/G400 Synchronous framebuffer (/dev/syncfb)", | |
51 "syncfb", | |
52 "Matthias Oelmann <mao@well.com>", | |
53 "" | |
54 }; | |
55 | |
8148
5b39e79af5fe
removed get_info, using the same sheme as in libmpcodecs instead
alex
parents:
7124
diff
changeset
|
56 LIBVO_EXTERN(syncfb) |
5b39e79af5fe
removed get_info, using the same sheme as in libmpcodecs instead
alex
parents:
7124
diff
changeset
|
57 |
1 | 58 /* deinterlacing on? looks only good in 50 Hz(PAL) or 60 Hz(NTSC) modes */ |
59 static int vo_conf_deinterlace = 0; | |
60 | |
61 /* 72/75 Hz Monitor frequency for progressive output */ | |
62 static int vo_conf_cinemode = 0; | |
63 | |
64 | |
4433 | 65 static syncfb_config_t _config; |
1 | 66 static syncfb_capability_t sfb_caps; |
67 | |
68 static syncfb_buffer_info_t bufinfo; | |
69 | |
70 static uint_8 *vid_data; | |
71 static uint_8 *frame_mem; | |
72 | |
73 static int debug_skip_first = 250; | |
74 static int dbg_singleframe = 0; | |
75 | |
76 static int conf_palette; | |
77 | |
78 static int f; | |
79 | |
80 | |
81 | |
82 /* | |
83 it seems that mpeg2dec never calls | |
84 draw_frame, so i could not test it.... | |
85 */ | |
86 | |
87 static void | |
88 write_frame_YUV422(uint_8 *y,uint_8 *cr, uint_8 *cb) | |
89 { | |
90 uint_8 *crp, *cbp; | |
91 uint_32 *dest32; | |
92 uint_32 bespitch,h,w; | |
93 | |
94 | |
4433 | 95 bespitch = _config.src_pitch; |
1 | 96 dest32 = (uint_32 *)vid_data; |
97 | |
4433 | 98 for(h=0; h < _config.src_height/2; h++) |
1 | 99 { |
100 cbp = cb; | |
101 crp = cr; | |
4433 | 102 for(w=0; w < _config.src_width/2; w++) |
1 | 103 { |
104 *dest32++ = (*y) + ((*cr)<<8) + ((*(y+1))<<16) + ((*cb)<<24); | |
105 y++; y++; cb++; cr++; | |
106 } | |
4433 | 107 dest32 += (bespitch - _config.src_width) / 2; |
1 | 108 |
4433 | 109 for(w=0; w < _config.src_width/2; w++) |
1 | 110 { |
111 *dest32++ = (*y) + ((*crp)<<8) + ((*(y+1))<<16) + ((*cbp)<<24); | |
112 y++; y++; cbp++; crp++; | |
113 } | |
4433 | 114 dest32 += (bespitch - _config.src_width) / 2; |
1 | 115 } |
116 } | |
117 | |
118 | |
119 static void | |
120 write_frame_YUV420P2(uint_8 *y,uint_8 *cr, uint_8 *cb) | |
121 { | |
122 uint_8 *dest, *tmp; | |
123 uint_32 bespitch,h,w; | |
124 | |
4433 | 125 bespitch = _config.src_pitch; |
1 | 126 dest = frame_mem + bufinfo.offset; |
127 | |
4433 | 128 for(h=0; h < _config.src_height; h++) |
1 | 129 { |
4433 | 130 memcpy(dest, y, _config.src_width); |
131 y += _config.src_width; | |
1 | 132 dest += bespitch; |
133 } | |
134 | |
135 dest = frame_mem + bufinfo.offset_p2; | |
4433 | 136 for(h=0; h < _config.src_height/2; h++) |
1 | 137 { |
138 tmp = dest; | |
4433 | 139 for(w=0; w < _config.src_width/2; w++) |
1 | 140 { |
141 *tmp++ = *cr++; | |
142 *tmp++ = *cb++; | |
143 } | |
144 dest += bespitch; | |
145 } | |
146 } | |
147 | |
148 static void | |
149 write_frame_YUV420P3(uint_8 *y,uint_8 *cr, uint_8 *cb) | |
150 { | |
151 } | |
152 | |
153 static void | |
154 write_slice_YUV420P2(uint_8 *y,uint_8 *cr, uint_8 *cb,uint_32 slice_num) | |
155 { | |
156 uint_8 *dest, *tmp; | |
157 uint_32 bespitch,h,w; | |
158 | |
4433 | 159 bespitch = _config.src_pitch; |
1 | 160 dest = frame_mem + bufinfo.offset + (bespitch * 16 * slice_num); |
161 | |
162 for(h=0; h < 16; h++) | |
163 { | |
4433 | 164 memcpy(dest, y, _config.src_width); |
165 y += _config.src_width; | |
1 | 166 dest += bespitch; |
167 } | |
168 | |
169 dest = frame_mem + bufinfo.offset_p2 + (bespitch * 16 * slice_num) /2; | |
170 for(h=0; h < 8; h++) | |
171 { | |
172 tmp = dest; | |
4433 | 173 for(w=0; w < _config.src_width/2; w++) |
1 | 174 { |
175 *tmp++ = *cr++; | |
176 *tmp++ = *cb++; | |
177 } | |
178 dest += bespitch; | |
179 } | |
180 } | |
181 | |
182 static void | |
183 write_slice_YUV420P3(uint_8 *y,uint_8 *cr, uint_8 *cb,int stride[],uint_32 ypos,uint_32 xsize,uint_32 ysize) | |
184 { | |
185 uint_8 *dest; | |
186 uint_32 bespitch,h; | |
187 | |
4433 | 188 bespitch = _config.src_pitch; |
1 | 189 |
190 dest = frame_mem + bufinfo.offset + (bespitch * ypos); | |
191 for(h=0; h < ysize; h++) | |
192 { | |
193 memcpy(dest, y, xsize); | |
194 y += stride[0]; | |
195 dest += bespitch; | |
196 } | |
197 | |
198 xsize/=2; | |
199 ysize/=2; | |
200 | |
201 dest = frame_mem + bufinfo.offset_p2 + (bespitch * ypos)/4; | |
202 for(h=0; h < ysize; h++) | |
203 { | |
204 memcpy(dest, cr, xsize); | |
205 cr += stride[1]; | |
206 dest += bespitch/2; | |
207 } | |
208 | |
209 dest = frame_mem + bufinfo.offset_p3 + (bespitch * ypos)/4; | |
210 for(h=0; h < ysize; h++) | |
211 { | |
212 memcpy(dest, cb, xsize); | |
213 cb += stride[2]; | |
214 dest += bespitch/2; | |
215 } | |
216 | |
217 | |
218 } | |
219 | |
220 | |
221 static void | |
222 write_slice_YUV422(uint_8 *y,uint_8 *cr, uint_8 *cb,uint_32 slice_num) | |
223 { | |
224 uint_8 *crp, *cbp; | |
225 uint_32 *dest32; | |
226 uint_32 bespitch,h,w; | |
227 | |
228 | |
4433 | 229 bespitch = _config.src_pitch; |
1 | 230 dest32 = (uint_32 *)(vid_data + (bespitch * 16 * slice_num) * 2); |
231 | |
232 for(h=0; h < 8; h++) | |
233 { | |
234 cbp = cb; | |
235 crp = cr; | |
4433 | 236 for(w=0; w < _config.src_width/2; w++) |
1 | 237 { |
238 *dest32++ = (*y) + ((*cr)<<8) + ((*(y+1))<<16) + ((*cb)<<24); | |
239 y++; y++; cb++; cr++; | |
240 } | |
4433 | 241 dest32 += (bespitch - _config.src_width) / 2; |
1 | 242 |
4433 | 243 for(w=0; w < _config.src_width/2; w++) |
1 | 244 { |
245 *dest32++ = (*y) + ((*crp)<<8) + ((*(y+1))<<16) + ((*cbp)<<24); | |
246 y++; y++; cbp++; crp++; | |
247 } | |
4433 | 248 dest32 += (bespitch - _config.src_width) / 2; |
1 | 249 } |
250 } | |
251 | |
252 //static uint32_t draw_slice(uint8_t *src[], uint32_t slice_num) | |
16171
fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
ivo
parents:
15212
diff
changeset
|
253 static int |
1 | 254 draw_slice(uint8_t *src[], int stride[], int w,int h,int x,int y) |
255 { | |
256 | |
257 if ( vid_data == NULL ) return 0; | |
258 | |
259 write_slice_YUV420P3(src[0],src[1], src[2],stride,y,w,h); | |
260 | |
261 //printf("sorry, not syncfb/draw_slice() implemented yet...\n"); | |
262 | |
263 #if 0 | |
264 | |
265 if ( conf_palette == VIDEO_PALETTE_YUV422 ) { | |
266 write_slice_YUV422(src[0],src[1], src[2],slice_num); | |
267 } else if ( conf_palette == VIDEO_PALETTE_YUV420P2 ) { | |
268 write_slice_YUV420P2(src[0],src[1], src[2],slice_num); | |
269 } else if ( conf_palette == VIDEO_PALETTE_YUV420P3 ) { | |
270 write_slice_YUV420P3(src[0],src[1], src[2],slice_num); | |
271 } | |
272 #endif | |
273 | |
274 return 0; | |
275 } | |
276 | |
1501
d40f2b686846
changes according to -utf8 option, draw_osd() function added
atlka
parents:
614
diff
changeset
|
277 static void draw_osd(void) |
d40f2b686846
changes according to -utf8 option, draw_osd() function added
atlka
parents:
614
diff
changeset
|
278 { |
d40f2b686846
changes according to -utf8 option, draw_osd() function added
atlka
parents:
614
diff
changeset
|
279 } |
1 | 280 |
281 static void | |
282 flip_page(void) | |
283 { | |
284 | |
4433 | 285 // memset(frame_mem + bufinfo.offset_p2, 0x80, _config.src_width*config.src_height); |
1 | 286 ioctl(f,SYNCFB_COMMIT_BUFFER,&bufinfo); |
287 | |
288 if ( dbg_singleframe ) { | |
289 if ( debug_skip_first == 0 ) { | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
290 mp_msg(MSGT_VO,MSGL_INFO, "Press 'anykey' for field 1\n" ); |
1 | 291 getchar(); |
292 ioctl(f,SYNCFB_VBI,0); | |
293 } | |
294 | |
295 if ( debug_skip_first > 0 ) { | |
296 debug_skip_first--; | |
297 // debug_skip_first = 0; | |
298 if ( debug_skip_first == 0 ) { | |
299 ioctl(f,SYNCFB_VBI,0); | |
300 ioctl(f,SYNCFB_VBI,0); | |
301 ioctl(f,SYNCFB_VBI,0); | |
302 } | |
303 } | |
304 | |
305 if ( debug_skip_first == 0 ) { | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
306 mp_msg(MSGT_VO,MSGL_INFO, "Press 'anykey' for field 2\n" ); |
1 | 307 getchar(); |
308 ioctl(f,SYNCFB_VBI,0); | |
309 } | |
310 } | |
311 | |
312 ioctl(f,SYNCFB_REQUEST_BUFFER,&bufinfo); | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
313 if ( bufinfo.id == -1 ) mp_msg(MSGT_VO,MSGL_INFO, "Got buffer #%d\n", bufinfo.id ); |
1 | 314 |
315 vid_data = (uint_8 *)(frame_mem + bufinfo.offset); | |
316 if ( bufinfo.id == -1 ) { | |
317 //vid_data = frame_mem; | |
318 vid_data = NULL; | |
319 } | |
320 // printf("Flip %d\n", bufinfo.offset); | |
321 | |
322 } | |
323 | |
16171
fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
ivo
parents:
15212
diff
changeset
|
324 static int draw_frame(uint8_t *src[]) |
1 | 325 { |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
326 mp_msg(MSGT_VO,MSGL_INFO, "DRAW FRAME!!!\n"); |
1 | 327 if ( conf_palette == VIDEO_PALETTE_YUV422 ) { |
328 write_frame_YUV422(src[0],src[1], src[2]); | |
329 } else if ( conf_palette == VIDEO_PALETTE_YUV420P2 ) { | |
330 write_frame_YUV420P2(src[0],src[1], src[2]); | |
331 } else if ( conf_palette == VIDEO_PALETTE_YUV420P3 ) { | |
332 write_frame_YUV420P3(src[0],src[1], src[2]); | |
333 } | |
334 | |
335 flip_page(); | |
336 return 0; | |
337 } | |
338 | |
16171
fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
ivo
parents:
15212
diff
changeset
|
339 static int |
1 | 340 query_format(uint32_t format) |
341 { | |
342 switch(format){ | |
343 case IMGFMT_YV12: | |
344 // case IMGFMT_RGB|24: | |
345 // case IMGFMT_BGR|24: | |
15212
05aa13cdf92f
replace VO and VF numeric flags with #defined identifiers
henry
parents:
8148
diff
changeset
|
346 return VFCAP_CSP_SUPPORTED; |
1 | 347 } |
348 return 0; | |
349 } | |
350 | |
16171
fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
ivo
parents:
15212
diff
changeset
|
351 static int config(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) |
1 | 352 { |
353 uint_32 frame_size; | |
354 | |
355 f = open("/dev/syncfb",O_RDWR); | |
356 | |
357 if(f == -1) | |
358 { | |
359 f = open("/dev/mga_vid",O_RDWR); | |
360 if(f == -1) | |
361 { | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
362 mp_msg(MSGT_VO,MSGL_ERR, MSGTR_LIBVO_SYNCFB_CouldntOpen); |
1 | 363 return(-1); |
364 } | |
365 } | |
366 | |
367 if (ioctl(f,SYNCFB_GET_CAPS,&sfb_caps)) perror("Error in mga_vid_config ioctl"); | |
368 if (ioctl(f,SYNCFB_GET_CONFIG,&config)) perror("Error in mga_vid_config ioctl"); | |
369 | |
370 if (sfb_caps.palettes & (1<<VIDEO_PALETTE_YUV420P3) ) { | |
4433 | 371 _config.src_palette= VIDEO_PALETTE_YUV420P3; |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
372 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_UsingPaletteYuv420p3); |
1 | 373 }else if ( sfb_caps.palettes & (1<<VIDEO_PALETTE_YUV420P2) ) { |
4433 | 374 _config.src_palette= VIDEO_PALETTE_YUV420P2; |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
375 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_UsingPaletteYuv420p2); |
1 | 376 } else if ( sfb_caps.palettes & (1<<VIDEO_PALETTE_YUV422) ) { |
4433 | 377 _config.src_palette= VIDEO_PALETTE_YUV422; |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
378 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_UsingPaletteYuv420); |
1 | 379 } else { |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
380 mp_msg(MSGT_VO,MSGL_ERR, MSGTR_LIBVO_SYNCFB_NoSupportedPaletteFound); |
1633 | 381 return -1; |
1 | 382 } |
383 | |
4433 | 384 // _config.src_palette= VIDEO_PALETTE_YUV422; |
1 | 385 |
386 if ( vo_conf_cinemode ) { | |
4433 | 387 _config.default_repeat = 3; |
1 | 388 } else { |
4433 | 389 _config.default_repeat = 2; |
1 | 390 } |
391 | |
4433 | 392 conf_palette = _config.src_palette; |
1 | 393 if ( vo_conf_deinterlace ) { |
4433 | 394 _config.syncfb_mode = SYNCFB_FEATURE_SCALE | SYNCFB_FEATURE_BLOCK_REQUEST | SYNCFB_FEATURE_DEINTERLACE; |
395 _config.default_repeat = 1; | |
1 | 396 } else { |
4433 | 397 _config.syncfb_mode = SYNCFB_FEATURE_SCALE | SYNCFB_FEATURE_BLOCK_REQUEST; |
1 | 398 } |
399 | |
4433 | 400 _config.fb_screen_size = (RAM_SIZE-4)*0x100000; //(1280 * 1024 * 32) / 8; |
401 _config.src_width = width; | |
402 _config.src_height= height; | |
1 | 403 |
4433 | 404 _config.image_width = d_width; |
405 _config.image_height= d_height; | |
406 //_config.image_width = 1024; | |
407 //_config.image_height= 576; | |
1 | 408 |
4433 | 409 _config.image_xorg= 0; |
410 _config.image_yorg= 0; | |
1 | 411 |
412 | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
413 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_BesSourcerSize, width, height); |
1 | 414 |
415 ioctl(f,SYNCFB_ON,0); | |
4433 | 416 if (ioctl(f,SYNCFB_SET_CONFIG,&_config)) perror("Error in mga_vid_config ioctl"); |
1 | 417 |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
418 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_FramebufferMemory, sfb_caps.memory_size, _config.buffers); |
1 | 419 |
420 frame_size = ((width + 31) & ~31) * height + (((width + 31) & ~31) * height) / 2; | |
421 frame_mem = (uint_8*)mmap(0,sfb_caps.memory_size,PROT_WRITE,MAP_SHARED,f,0); | |
422 | |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
423 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_RequestingFirstBuffer, bufinfo.id ); |
1 | 424 ioctl(f,SYNCFB_REQUEST_BUFFER,&bufinfo); |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
425 mp_msg(MSGT_VO,MSGL_INFO, MSGTR_LIBVO_SYNCFB_GotFirstBuffer, bufinfo.id ); |
1 | 426 |
427 | |
428 vid_data = (uint_8 *)(frame_mem + bufinfo.offset); | |
429 | |
430 //clear the buffer | |
431 // memset(frame_mem,0x80,frame_size*2); | |
432 return 0; | |
433 } | |
434 | |
435 | |
436 static void | |
437 uninit(void) | |
438 { | |
439 if (ioctl(f,SYNCFB_OFF,0)) perror("Error in OFF ioctl"); | |
440 | |
441 } | |
442 | |
31 | 443 static void check_events(void) |
444 { | |
445 } | |
1 | 446 |
16171
fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
ivo
parents:
15212
diff
changeset
|
447 static int preinit(const char *arg) |
4352 | 448 { |
4737
32e1f5042f65
I don't like such reports: '-vo dga:vidix or -vo x11:vidix works fine for me'
nick
parents:
4596
diff
changeset
|
449 if(arg) |
32e1f5042f65
I don't like such reports: '-vo dga:vidix or -vo x11:vidix works fine for me'
nick
parents:
4596
diff
changeset
|
450 { |
18234
a107276371a8
Part 5 and final of otvos attila's oattila AT chello-hu mp_msg changes, with lots of corrections
reynaldo
parents:
16171
diff
changeset
|
451 mp_msg(MSGT_VO,MSGL_ERR, MSGTR_LIBVO_SYNCFB_UnknownSubdevice,arg); |
4737
32e1f5042f65
I don't like such reports: '-vo dga:vidix or -vo x11:vidix works fine for me'
nick
parents:
4596
diff
changeset
|
452 return ENOSYS; |
32e1f5042f65
I don't like such reports: '-vo dga:vidix or -vo x11:vidix works fine for me'
nick
parents:
4596
diff
changeset
|
453 } |
32e1f5042f65
I don't like such reports: '-vo dga:vidix or -vo x11:vidix works fine for me'
nick
parents:
4596
diff
changeset
|
454 return 0; |
4352 | 455 } |
456 | |
16171
fd51fd1ff231
Fix the return types of all (six) libvo API functions. Used to be uint32_t, but
ivo
parents:
15212
diff
changeset
|
457 static int control(uint32_t request, void *data, ...) |
4352 | 458 { |
4592
5fbfd8545c3b
query_ stuff replaced by new control() - patch by David Holm
arpi
parents:
4433
diff
changeset
|
459 switch (request) { |
5fbfd8545c3b
query_ stuff replaced by new control() - patch by David Holm
arpi
parents:
4433
diff
changeset
|
460 case VOCTRL_QUERY_FORMAT: |
5fbfd8545c3b
query_ stuff replaced by new control() - patch by David Holm
arpi
parents:
4433
diff
changeset
|
461 return query_format(*((uint32_t*)data)); |
5fbfd8545c3b
query_ stuff replaced by new control() - patch by David Holm
arpi
parents:
4433
diff
changeset
|
462 } |
5fbfd8545c3b
query_ stuff replaced by new control() - patch by David Holm
arpi
parents:
4433
diff
changeset
|
463 return VO_NOTIMPL; |
4352 | 464 } |