[FFmpeg-devel] Suggestion for a centralized language-tag facility in libavformat

cyril comparon cyril.comparon
Wed Apr 29 10:42:19 CEST 2009


> [...]
> 6 bytes is enough considering stream_languages isnt larger
> [...]
> can be merged and id make it a int or unsigned int but thats just me
> [...]
> id make that unsigned int too, we dont need a variable of exact size
> here
> [...]

Modifications done.

> [...]
>> + ? ? ? ?hpos = put_header(pb, &ff_asf_ext_stream_header);
>> + ? ? ? ?put_le64(pb, 0); // starttime (optional so zero to ignore it)
>> + ? ? ? ?put_le64(pb, 0); // endtime (optional so zero to ignore it)
>> + ? ? ? ?put_le32(pb, s->streams[n]->codec->bit_rate); // leak-datarate
>> + ? ? ? ?put_le32(pb, BUFFER_SIZE_IN_MS); // bucket-datasize
>> + ? ? ? ?put_le32(pb, 0); // init-bucket-fullness
>> + ? ? ? ?put_le32(pb, s->streams[n]->codec->bit_rate); // alt-leak-datarate
>> + ? ? ? ?put_le32(pb, BUFFER_SIZE_IN_MS); // alt-bucket-datasize in milliseconds
>
> I do not belive you can set these values randomly
> I suspect they might be calculatable from the VBV parameters of the streams
> and in their absence you will have to analyze all packets their sizes and
> timestamps before this can be written

I did my best to put values as relevant as possible, however I am
afraid what you're raising now is beyond my abilities. By chance, all
tests I made produced asf files I could read with usual players with
no errors. Is there someone out there who could have a look and do
these corrections eventually?

Latest patch as attachment.
Cyril
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 2_asf_languages-f.patch
Type: application/octet-stream
Size: 10135 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090429/7671ea70/attachment.obj>



More information about the ffmpeg-devel mailing list