[Ffmpeg-devel] [PATCH] FLV common header.
Allan Hsu
allan
Tue Dec 5 23:15:31 CET 2006
On Dec 5, 2006, at 10:04 AM, Michael Niedermayer wrote:
[...]
>> st->codec->codec_type = CODEC_TYPE_VIDEO;
>> - switch(flags & 0xF){
>> - case 2: st->codec->codec_id = CODEC_ID_FLV1; break;
>> - case 3: st->codec->codec_id = CODEC_ID_FLASHSV; break;
>> - case 4:
>> + switch(flags & FLV_VIDEO_CODECID_MASK){
>> + case FLV_CODECID_H263: st->codec->codec_id =
>> CODEC_ID_FLV1; break;
>> + case FLV_CODECID_SCREEN: st->codec->codec_id =
>> CODEC_ID_FLASHSV; break;
>
> please align these like:
>
> case FLV_CODECID_H263 : st->codec->codec_id =
> CODEC_ID_FLV1 ; break;
> case FLV_CODECID_SCREEN: st->codec->codec_id =
> CODEC_ID_FLASHSV; break;
>
> same for the other similar code
>
>
> [...]
>
>> +enum {
>> + FLV_CODECID_PCM_BE = 0,
>> + FLV_CODECID_ADPCM = 1 << FLV_AUDIO_CODECID_OFFSET,
>> + FLV_CODECID_MP3 = 2 << FLV_AUDIO_CODECID_OFFSET,
>> + FLV_CODECID_PCM_LE = 3 << FLV_AUDIO_CODECID_OFFSET,
>> + FLV_CODECID_NELLYMOSER_8HZ_MONO = 5 << FLV_AUDIO_CODECID_OFFSET,
>> + FLV_CODECID_NELLYMOSER = 6 << FLV_AUDIO_CODECID_OFFSET
>
> please align these like:
>
> FLV_CODECID_ADPCM = 1 << FLV_AUDIO_CODECID_OFFSET,
> FLV_CODECID_MP3 = 2 << FLV_AUDIO_CODECID_OFFSET,
> FLV_CODECID_PCM_LE = 3 << FLV_AUDIO_CODECID_OFFSET,
> FLV_CODECID_NELLYMOSER_8HZ_MONO = 5 << FLV_AUDIO_CODECID_OFFSET,
> FLV_CODECID_NELLYMOSER = 6 << FLV_AUDIO_CODECID_OFFSET
>
> makes them look much nicer, same for all the others
>
>
> except these the patch is ok
[...]
Here's the patch with your suggested alignment changes, as well as a
few more replacements of hardcoded values with values from the common
header that I missed in previous patches.
-Allan
--
Allan Hsu <allan at counterpop dot net>
1E64 E20F 34D9 CBA7 1300 1457 AC37 CBBB 0E92 C779
-------------- next part --------------
A non-text attachment was scrubbed...
Name: flv_commonheader.patch
Type: application/octet-stream
Size: 13955 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20061205/4347cbf6/attachment.obj>
-------------- next part --------------
More information about the ffmpeg-devel
mailing list