Mercurial > mplayer.hg
changeset 35245:6055467828a4
Add flag "dummy" for null and black decoder
author | upsuper |
---|---|
date | Sat, 03 Nov 2012 12:59:57 +0000 |
parents | 222713e4d79f |
children | db605820eef9 |
files | codec-cfg.c codec-cfg.h etc/codecs.conf |
diffstat | 3 files changed, 7 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/codec-cfg.c Fri Nov 02 05:42:48 2012 +0000 +++ b/codec-cfg.c Sat Nov 03 12:59:57 2012 +0000 @@ -752,6 +752,9 @@ if (!strcmp(token[0], "align16")) codec->flags |= CODECS_FLAG_ALIGN16; else + if (!strcmp(token[0], "dummy")) + codec->flags |= CODECS_FLAG_DUMMY; + else goto err_out_parse_error; } else if (!strcmp(token[0], "status")) { if (get_token(1, 1) < 0) @@ -870,8 +873,7 @@ for (/* NOTHING */; i--; c++) { if(start && c<=start) continue; for (j = 0; j < CODECS_MAX_FOURCC; j++) { - // FIXME: do NOT hardwire 'null' and 'black' here: - if (c->fourcc[j]==fourcc || !strcmp(c->drv,"null") || !strcmp(c->drv,"black")) { + if (c->fourcc[j]==fourcc || c->flags & CODECS_FLAG_DUMMY) { if (fourccmap) *fourccmap = c->fourccmap[j]; return c;
--- a/codec-cfg.h Fri Nov 02 05:42:48 2012 +0000 +++ b/codec-cfg.h Sat Nov 03 12:59:57 2012 +0000 @@ -26,6 +26,7 @@ // Global flags: #define CODECS_FLAG_SEEKABLE (1<<0) #define CODECS_FLAG_ALIGN16 (1<<1) +#define CODECS_FLAG_DUMMY (1<<2) // Outfmt flags: #define CODECS_FLAG_FLIP (1<<0)
--- a/etc/codecs.conf Fri Nov 02 05:42:48 2012 +0000 +++ b/etc/codecs.conf Sat Nov 03 12:59:57 2012 +0000 @@ -4218,6 +4218,7 @@ status crashing comment "for unknown/unsupported codecs or testing" driver null + flags dummy out YV12 out I420 out YUY2 @@ -4230,6 +4231,7 @@ status crashing comment "for unknown/unsupported codecs or testing" driver black + flags dummy out YV12 out I420 out YUY2