[FFmpeg-cvslog] mp3enc: remove unneeded static const variables.
Michael Niedermayer
git at videolan.org
Sat May 7 04:07:34 CEST 2011
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Apr 26 03:06:04 2011 +0200| [173c975ead9bd9234956cceb3a9b2ed58dfbe213] | committer: Michael Niedermayer
mp3enc: remove unneeded static const variables.
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=173c975ead9bd9234956cceb3a9b2ed58dfbe213
---
libavformat/mp3enc.c | 11 +++--------
1 files changed, 3 insertions(+), 8 deletions(-)
diff --git a/libavformat/mp3enc.c b/libavformat/mp3enc.c
index 8150b78..731937f 100644
--- a/libavformat/mp3enc.c
+++ b/libavformat/mp3enc.c
@@ -207,11 +207,6 @@ static int id3v2_check_write_tag(AVFormatContext *s, AVMetadataTag *t, const cha
}
static const int64_t xing_offtbl[2][2] = {{32, 17}, {17,9}};
-static const uint32_t XING = MKBETAG('X', 'i', 'n', 'g');
-#ifdef FILTER_VBR_HEADERS
-static const uint32_t INFO = MKBETAG('I', 'n', 'f', 'o');
-static const uint32_t VBRI = MKBETAG('V', 'B', 'R', 'I');
-#endif
/*
* Write an empty XING header and initialize respective data.
@@ -274,7 +269,7 @@ static int mp3_write_xing(AVFormatContext *s)
avio_wb32(s->pb, header);
ffio_fill(s->pb, 0, xing_offset);
- avio_wb32(s->pb, XING);
+ avio_wb32(s->pb, MKBETAG('X', 'i', 'n', 'g'));
avio_wb32(s->pb, 0x01 | 0x02 | 0x04); // frames/size/toc
mp3->xing_header.offset = avio_tell(s->pb);
@@ -430,14 +425,14 @@ static int mp3_write_packet(AVFormatContext *s, AVPacket *pkt)
if (base + 4 <= pkt->size) {
uint32_t v = AV_RB32(pkt->data + base);
- if (XING == v || INFO == v)
+ if (MKBETAG('X','i','n','g') == v || MKBETAG('I','n','f','o') == v)
return 0;
}
/* filter out VBRI headers. */
base = 4 + 32;
- if (base + 4 <= pkt->size && VBRI == AV_RB32(pkt->data + base))
+ if (base + 4 <= pkt->size && MKBETAG('V','B','R','I') == AV_RB32(pkt->data + base))
return 0;
#endif
More information about the ffmpeg-cvslog
mailing list