On 23/08/13 14:37, Diego Biurrun wrote:
> On Fri, Aug 23, 2013 at 06:01:10AM +0200, Luca Barbato wrote:
>> --- a/libavformat/mov.c
>> +++ b/libavformat/mov.c
>> @@ -1370,6 +1370,29 @@ static int mov_finalize_stsd_codec(MOVContext *c,
>> AVIOContext *pb,
>> +static int mov_skip_multiple_stsd(MOVContext *c, AVIOContext *pb,
>> + int codec_tag, int format,
>> + int size)
>> +{
>> + int video_codec_id = ff_codec_get_id(ff_codec_movvideo_tags, format);
>> +
>> + if (codec_tag &&
>> + (codec_tag == AV_RL32("avc1") ||
>> + (codec_tag != format &&
>> + (c->fc->video_codec_id ? video_codec_id != c->fc->video_codec_id
>> + : codec_tag != MKTAG('j','p','e','g'))))) {
>> + /* Multiple fourcc, we skip JPEG. This is not correct, we should
>> + * export it as a separate AVStream but this needs a few changes
>> + * in the MOV demuxer, patch welcome. */
>> +
>> + av_log(c->fc, AV_LOG_WARNING, "multiple fourcc not supported\n");
>
> Drop this empty line.
The result is less readable IMHO.
>
>> @@ -1401,22 +1424,10 @@ int ff_mov_read_stsd_entries(MOVContext *c,
>> AVIOContext *pb, int entries)
>> + if (mov_skip_multiple_stsd(c, pb, st->codec->codec_tag, format,
>> + size - (avio_tell(pb) - start_pos)))
>> continue;
>> +
>> sc->pseudo_stream_id = st->codec->codec_tag ? -1 : pseudo_stream_id;
>> sc->dref_id= dref_id;
>
> What is the if-statement supposed to accomplish?
>
Skip to the next (as the code previously did using a goto and two
branches...
lu
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel