[FFmpeg-devel] [PATCH ]FLV Metadata
Josh Allmann
joshua.allmann
Thu Sep 9 19:38:51 CEST 2010
On 3 September 2010 08:26, Tom?s Touceda <chiiph at gentoo.org> wrote:
> 2010/9/3 Tom?s Touceda <chiiph at gentoo.org>:
>> 2010/9/3 Anton Khirnov <anton at khirnov.net>:
>>>
>>>> diff -Naur ffmpeg-9999.old/libavformat/flvenc.c ffmpeg-9999/libavformat/flvenc.c
>>>> --- ffmpeg-9999.old/libavformat/flvenc.c ? ? ?2010-08-07 10:21:58.000000000 -0300
>>>> +++ ffmpeg-9999/libavformat/flvenc.c ?2010-09-02 17:19:21.000000000 -0300
>>>> @@ -22,6 +22,7 @@
>>>> ?#include "flv.h"
>>>> ?#include "internal.h"
>>>> ?#include "avc.h"
>>>> +#include "metadata.h"
>>>>
>>>> ?#undef NDEBUG
>>>> ?#include <assert.h>
>>>> @@ -257,6 +258,12 @@
>>>> ? ? ? ? ?put_amf_double(pb, audio_enc->codec_tag);
>>>> ? ? ?}
>>>>
>>>> + ? ?while ((tag = av_metadata_get(m, "", tag, AV_METADATA_IGNORE_SUFFIX))) {
>>>> + ? ? ? ?put_amf_string(pb, tag.key);
>>>> + ? ? ? ?put_byte(pb, AMF_DATA_TYPE_STRING);
>>>> + ? ? ? ?put_amf_string(pb, tag.value);
>>>> + ? ?}
>>>> +
>>>> ? ? ?put_amf_string(pb, "filesize");
>>>> ? ? ?flv->filesize_offset= url_ftell(pb);
>>>> ? ? ?put_amf_double(pb, 0); // delayed write
>>>
>>> This doesn't build -- 'tag' and 'm' are not declared, besides
>>> av_metadata_get returns a pointer, so tag.key and tag.value are wrong.
>>> Why did you change all this? It was correct in your last patch.
>>
>
> There it is... Sorry for all the noise...
>
Ping, there is quite a bit of interest in this patch.
BTW:
+ while((tag = av_metadata_get(s->metadata, "", tag,
AV_METADATA_IGNORE_SUFFIX))) {
while (
but that's a nit; if all else is OK otherwise, can whoever applies
just make the change?
More information about the ffmpeg-devel
mailing list