aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClément Bœsch <clement@stupeflix.com>2016-06-29 11:43:57 +0200
committerClément Bœsch <clement@stupeflix.com>2016-06-29 11:43:57 +0200
commitf8beca6f108141a017dfce882bfe31ef93a35193 (patch)
tree931086d45c64abd6cce93663635603ce69340ad8
parent9afa64dfdffdf2ce80fc9e7d1e3e0091d0c2eb3b (diff)
parent6d8fd614ff957af242efcd8a6a0619874382f3a4 (diff)
downloadffmpeg-f8beca6f108141a017dfce882bfe31ef93a35193.tar.gz
Merge commit '6d8fd614ff957af242efcd8a6a0619874382f3a4'
* commit '6d8fd614ff957af242efcd8a6a0619874382f3a4': vorbis: Kill some pointless debug code Merged-by: Clément Bœsch <clement@stupeflix.com>
-rw-r--r--libavcodec/vorbis.c26
1 files changed, 2 insertions, 24 deletions
diff --git a/libavcodec/vorbis.c b/libavcodec/vorbis.c
index a8324248db..399020eec5 100644
--- a/libavcodec/vorbis.c
+++ b/libavcodec/vorbis.c
@@ -26,9 +26,9 @@
* @author Denes Balatoni ( dbalatoni programozo hu )
*/
-#define BITSTREAM_READER_LE
+#include "libavutil/common.h"
+
#include "avcodec.h"
-#include "get_bits.h"
#include "vorbis.h"
@@ -56,13 +56,8 @@ unsigned int ff_vorbis_nth_root(unsigned int x, unsigned int n)
int ff_vorbis_len2vlc(uint8_t *bits, uint32_t *codes, unsigned num)
{
uint32_t exit_at_level[33] = { 404 };
-
unsigned i, j, p, code;
-#ifdef DEBUG
- GetBitContext gb;
-#endif
-
for (p = 0; (bits[p] == 0) && (p < num); ++p)
;
if (p == num)
@@ -74,14 +69,6 @@ int ff_vorbis_len2vlc(uint8_t *bits, uint32_t *codes, unsigned num)
for (i = 0; i < bits[p]; ++i)
exit_at_level[i+1] = 1 << i;
-#ifdef DEBUG
- av_log(NULL, AV_LOG_INFO, " %u. of %u code len %d code %d - ", p, num, bits[p], codes[p]);
- init_get_bits(&gb, (uint8_t *)&codes[p], bits[p]);
- for (i = 0; i < bits[p]; ++i)
- av_log(NULL, AV_LOG_INFO, "%s", get_bits1(&gb) ? "1" : "0");
- av_log(NULL, AV_LOG_INFO, "\n");
-#endif
-
++p;
for (i = p; (bits[i] == 0) && (i < num); ++i)
@@ -106,15 +93,6 @@ int ff_vorbis_len2vlc(uint8_t *bits, uint32_t *codes, unsigned num)
for (j = i + 1 ;j <= bits[p]; ++j)
exit_at_level[j] = code + (1 << (j - 1));
codes[p] = code;
-
-#ifdef DEBUG
- av_log(NULL, AV_LOG_INFO, " %d. code len %d code %d - ", p, bits[p], codes[p]);
- init_get_bits(&gb, (uint8_t *)&codes[p], bits[p]);
- for (i = 0; i < bits[p]; ++i)
- av_log(NULL, AV_LOG_INFO, "%s", get_bits1(&gb) ? "1" : "0");
- av_log(NULL, AV_LOG_INFO, "\n");
-#endif
-
}
//no exits should be left (underspecified tree - ie. unused valid vlcs - not allowed by SPEC)