Browse Source

lavf/img2: Add svg and svgz to allow reading image sequences.

Increase the return value for svg_probe() to make it != AVPROBE_SCORE_EXTENSION.
tags/n3.4
Carl Eugen Hoyos 8 years ago
parent
commit
7f60dc03a0
2 changed files with 3 additions and 1 deletions
  1. +2
    -0
      libavformat/img2.c
  2. +1
    -1
      libavformat/img2dec.c

+ 2
- 0
libavformat/img2.c View File

@@ -65,6 +65,8 @@ const IdStrMap ff_img_tags[] = {
{ AV_CODEC_ID_SUNRAST, "im24" },
{ AV_CODEC_ID_SUNRAST, "im32" },
{ AV_CODEC_ID_SUNRAST, "sunras" },
{ AV_CODEC_ID_SVG, "svg" },
{ AV_CODEC_ID_SVG, "svgz" },
{ AV_CODEC_ID_JPEG2000, "j2c" },
{ AV_CODEC_ID_JPEG2000, "jp2" },
{ AV_CODEC_ID_JPEG2000, "jpc" },


+ 1
- 1
libavformat/img2dec.c View File

@@ -876,7 +876,7 @@ static int sunrast_probe(AVProbeData *p)
static int svg_probe(AVProbeData *p)
{
if (av_match_ext(p->filename, "svg") || av_match_ext(p->filename, "svgz"))
return AVPROBE_SCORE_EXTENSION;
return AVPROBE_SCORE_EXTENSION + 1;
return 0;
}



Loading…
Cancel
Save