Mercurial > mplayer.hg
annotate libmpcodecs/vf_format.c @ 30383:0bc34f21039e
Merge two "if (flags & SWS_PRINT_INFO) { ... }" blocks.
author | stefano |
---|---|
date | Sun, 24 Jan 2010 17:44:43 +0000 |
parents | 391e683541a7 |
children | bbb6ebec87a0 |
rev | line source |
---|---|
5539 | 1 #include <stdio.h> |
2 #include <stdlib.h> | |
3 #include <string.h> | |
4 #include <inttypes.h> | |
5 | |
17012 | 6 #include "config.h" |
7 #include "mp_msg.h" | |
18004
bcd805923554
Part2 of several printf2mp_msg changes in patch from Otvos Attila oattila AT chello DOT hu with LOTS of modifications by me
reynaldo
parents:
17012
diff
changeset
|
8 #include "help_mp.h" |
5539 | 9 |
5607 | 10 #include "img_format.h" |
11 #include "mp_image.h" | |
5539 | 12 #include "vf.h" |
13 | |
9601 | 14 #include "m_option.h" |
15 #include "m_struct.h" | |
16 | |
17 static struct vf_priv_s { | |
5539 | 18 unsigned int fmt; |
22027 | 19 } const vf_priv_dflt = { |
9601 | 20 IMGFMT_YUY2 |
5539 | 21 }; |
22 | |
23 //===========================================================================// | |
24 | |
25 static int query_format(struct vf_instance_s* vf, unsigned int fmt){ | |
26 if(fmt==vf->priv->fmt) | |
27 return vf_next_query_format(vf,fmt); | |
28 return 0; | |
29 } | |
30 | |
31 static int open(vf_instance_t *vf, char* args){ | |
32 vf->query_format=query_format; | |
6001 | 33 vf->default_caps=0; |
5539 | 34 return 1; |
35 } | |
36 | |
9601 | 37 #define ST_OFF(f) M_ST_OFF(struct vf_priv_s,f) |
38 static m_option_t vf_opts_fields[] = { | |
39 {"fmt", ST_OFF(fmt), CONF_TYPE_IMGFMT, 0,0 ,0, NULL}, | |
40 { NULL, NULL, 0, 0, 0, 0, NULL } | |
41 }; | |
42 | |
43 static m_struct_t vf_opts = { | |
44 "format", | |
45 sizeof(struct vf_priv_s), | |
46 &vf_priv_dflt, | |
47 vf_opts_fields | |
48 }; | |
49 | |
25221 | 50 const vf_info_t vf_info_format = { |
5539 | 51 "force output format", |
52 "format", | |
53 "A'rpi", | |
5565
0b301fec999a
capabilities support -> automatic insertion of scale, expand, pp
arpi
parents:
5539
diff
changeset
|
54 "FIXME! get_image()/put_image()", |
9593
e9a2af584986
Add the new -vf option wich is the same as vop in reverse order.
albeu
parents:
9171
diff
changeset
|
55 open, |
9601 | 56 &vf_opts |
5539 | 57 }; |
58 | |
59 //===========================================================================// |