Mercurial > mplayer.hg
annotate libmpcodecs/vf_format.c @ 30421:bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
| author | diego |
|---|---|
| date | Sat, 30 Jan 2010 16:57:40 +0000 |
| parents | 391e683541a7 |
| children | a7b908875c14 |
| rev | line source |
|---|---|
|
30421
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
1 /* |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
2 * This file is part of MPlayer. |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
3 * |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
4 * MPlayer is free software; you can redistribute it and/or modify |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
5 * it under the terms of the GNU General Public License as published by |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
6 * the Free Software Foundation; either version 2 of the License, or |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
7 * (at your option) any later version. |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
8 * |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
9 * MPlayer is distributed in the hope that it will be useful, |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
12 * GNU General Public License for more details. |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
13 * |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
14 * You should have received a copy of the GNU General Public License along |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
15 * with MPlayer; if not, write to the Free Software Foundation, Inc., |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
17 */ |
|
bbb6ebec87a0
Add missing license headers to all files in the libmpcodecs directory.
diego
parents:
29903
diff
changeset
|
18 |
| 5539 | 19 #include <stdio.h> |
| 20 #include <stdlib.h> | |
| 21 #include <string.h> | |
| 22 #include <inttypes.h> | |
| 23 | |
| 17012 | 24 #include "config.h" |
| 25 #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
|
26 #include "help_mp.h" |
| 5539 | 27 |
| 5607 | 28 #include "img_format.h" |
| 29 #include "mp_image.h" | |
| 5539 | 30 #include "vf.h" |
| 31 | |
| 9601 | 32 #include "m_option.h" |
| 33 #include "m_struct.h" | |
| 34 | |
| 35 static struct vf_priv_s { | |
| 5539 | 36 unsigned int fmt; |
| 22027 | 37 } const vf_priv_dflt = { |
| 9601 | 38 IMGFMT_YUY2 |
| 5539 | 39 }; |
| 40 | |
| 41 //===========================================================================// | |
| 42 | |
| 43 static int query_format(struct vf_instance_s* vf, unsigned int fmt){ | |
| 44 if(fmt==vf->priv->fmt) | |
| 45 return vf_next_query_format(vf,fmt); | |
| 46 return 0; | |
| 47 } | |
| 48 | |
| 49 static int open(vf_instance_t *vf, char* args){ | |
| 50 vf->query_format=query_format; | |
| 6001 | 51 vf->default_caps=0; |
| 5539 | 52 return 1; |
| 53 } | |
| 54 | |
| 9601 | 55 #define ST_OFF(f) M_ST_OFF(struct vf_priv_s,f) |
| 56 static m_option_t vf_opts_fields[] = { | |
| 57 {"fmt", ST_OFF(fmt), CONF_TYPE_IMGFMT, 0,0 ,0, NULL}, | |
| 58 { NULL, NULL, 0, 0, 0, 0, NULL } | |
| 59 }; | |
| 60 | |
| 61 static m_struct_t vf_opts = { | |
| 62 "format", | |
| 63 sizeof(struct vf_priv_s), | |
| 64 &vf_priv_dflt, | |
| 65 vf_opts_fields | |
| 66 }; | |
| 67 | |
| 25221 | 68 const vf_info_t vf_info_format = { |
| 5539 | 69 "force output format", |
| 70 "format", | |
| 71 "A'rpi", | |
|
5565
0b301fec999a
capabilities support -> automatic insertion of scale, expand, pp
arpi
parents:
5539
diff
changeset
|
72 "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
|
73 open, |
| 9601 | 74 &vf_opts |
| 5539 | 75 }; |
| 76 | |
| 77 //===========================================================================// |
