summaryrefslogtreecommitdiffstats
path: root/libmpdemux
diff options
context:
space:
mode:
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/mp3_hdr.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/libmpdemux/mp3_hdr.c b/libmpdemux/mp3_hdr.c
index b2ac948b5b..78ed2fc0a1 100644
--- a/libmpdemux/mp3_hdr.c
+++ b/libmpdemux/mp3_hdr.c
@@ -16,6 +16,18 @@ static int tabsel_123[2][3][16] = {
};
static long freqs[9] = { 44100, 48000, 32000, 22050, 24000, 16000 , 11025 , 12000 , 8000 };
+int mp_mp3_get_lsf(unsigned char* hbuf){
+ unsigned long newhead =
+ hbuf[0] << 24 |
+ hbuf[1] << 16 |
+ hbuf[2] << 8 |
+ hbuf[3];
+ if( newhead & ((long)1<<20) ) {
+ return (newhead & ((long)1<<19)) ? 0x0 : 0x1;
+ }
+ return 1;
+}
+
/*
* return frame size or -1 (bad frame)
*/