avformat: add xbm_pipe demuxer

This commit is contained in:
Paul B Mahol 2021-02-03 13:52:00 +01:00
parent 7dfa98665c
commit 84d5df5446
5 changed files with 12 additions and 1 deletions

View File

@ -66,6 +66,7 @@ version <next>:
- colorcorrect filter
- binka demuxer
- XBM parser
- xbm_pipe demuxer
version 4.3:

View File

@ -277,6 +277,7 @@ OBJS-$(CONFIG_IMAGE_SVG_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_IMAGE_SUNRAST_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_IMAGE_TIFF_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_IMAGE_WEBP_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_IMAGE_XBM_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_IMAGE_XPM_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_IMAGE_XWD_PIPE_DEMUXER) += img2dec.o img2.o
OBJS-$(CONFIG_INGENIENT_DEMUXER) += ingenientdec.o rawdec.o

View File

@ -518,6 +518,7 @@ extern AVInputFormat ff_image_svg_pipe_demuxer;
extern AVInputFormat ff_image_sunrast_pipe_demuxer;
extern AVInputFormat ff_image_tiff_pipe_demuxer;
extern AVInputFormat ff_image_webp_pipe_demuxer;
extern AVInputFormat ff_image_xbm_pipe_demuxer;
extern AVInputFormat ff_image_xpm_pipe_demuxer;
extern AVInputFormat ff_image_xwd_pipe_demuxer;

View File

@ -1031,6 +1031,13 @@ static int pam_probe(const AVProbeData *p)
return pnm_magic_check(p, 7) ? pnm_probe(p) : 0;
}
static int xbm_probe(const AVProbeData *p)
{
if (!memcmp(p->buf, "#define", 7))
return AVPROBE_SCORE_MAX - 1;
return 0;
}
static int xpm_probe(const AVProbeData *p)
{
const uint8_t *b = p->buf;
@ -1139,5 +1146,6 @@ IMAGEAUTO_DEMUXER(sunrast, AV_CODEC_ID_SUNRAST)
IMAGEAUTO_DEMUXER(svg, AV_CODEC_ID_SVG)
IMAGEAUTO_DEMUXER(tiff, AV_CODEC_ID_TIFF)
IMAGEAUTO_DEMUXER(webp, AV_CODEC_ID_WEBP)
IMAGEAUTO_DEMUXER(xbm, AV_CODEC_ID_XBM)
IMAGEAUTO_DEMUXER(xpm, AV_CODEC_ID_XPM)
IMAGEAUTO_DEMUXER(xwd, AV_CODEC_ID_XWD)

View File

@ -32,7 +32,7 @@
// Major bumping may affect Ticket5467, 5421, 5451(compatibility with Chromium)
// Also please add any ticket numbers that you believe might be affected here
#define LIBAVFORMAT_VERSION_MAJOR 58
#define LIBAVFORMAT_VERSION_MINOR 66
#define LIBAVFORMAT_VERSION_MINOR 67
#define LIBAVFORMAT_VERSION_MICRO 100
#define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \