]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/wma.c
clarify codec_tag
[ffmpeg] / libavcodec / wma.c
index 31a417ac51491e1bd54c344e8cae795634ba1e2b..76f04def74af4be28d0a24c805db95443de59f08 100644 (file)
@@ -64,7 +64,7 @@ static void init_coef_vlc(VLC *vlc,
 
 int ff_wma_init(AVCodecContext * avctx, int flags2)
 {
-    WMADecodeContext *s = avctx->priv_data;
+    WMACodecContext *s = avctx->priv_data;
     int i;
     float *window;
     float bps1, high_freq;
@@ -108,7 +108,7 @@ int ff_wma_init(AVCodecContext * avctx, int flags2)
         s->nb_block_sizes = 1;
     }
 
-    /* init rate dependant parameters */
+    /* init rate dependent parameters */
     s->use_noise_coding = 1;
     high_freq = s->sample_rate * 0.5;
 
@@ -171,13 +171,13 @@ int ff_wma_init(AVCodecContext * avctx, int flags2)
             high_freq = high_freq * 0.5;
         }
     }
-    dprintf("flags1=0x%x flags2=0x%x\n", flags1, flags2);
-    dprintf("version=%d channels=%d sample_rate=%d bitrate=%d block_align=%d\n",
+    dprintf(s->avctx, "flags2=0x%x\n", flags2);
+    dprintf(s->avctx, "version=%d channels=%d sample_rate=%d bitrate=%d block_align=%d\n",
            s->version, s->nb_channels, s->sample_rate, s->bit_rate,
            s->block_align);
-    dprintf("bps=%f bps1=%f high_freq=%f bitoffset=%d\n",
+    dprintf(s->avctx, "bps=%f bps1=%f high_freq=%f bitoffset=%d\n",
            bps, bps1, high_freq, s->byte_offset_bits);
-    dprintf("use_noise_coding=%d use_exp_vlc=%d nb_block_sizes=%d\n",
+    dprintf(s->avctx, "use_noise_coding=%d use_exp_vlc=%d nb_block_sizes=%d\n",
            s->use_noise_coding, s->use_exp_vlc, s->nb_block_sizes);
 
     /* compute the scale factor band sizes for each MDCT block size */
@@ -268,14 +268,14 @@ int ff_wma_init(AVCodecContext * avctx, int flags2)
             }
             s->exponent_high_sizes[k] = j;
 #if 0
-            tprintf("%5d: coefs_end=%d high_band_start=%d nb_high_bands=%d: ",
+            tprintf(s->avctx, "%5d: coefs_end=%d high_band_start=%d nb_high_bands=%d: ",
                   s->frame_len >> k,
                   s->coefs_end[k],
                   s->high_band_start[k],
                   s->exponent_high_sizes[k]);
             for(j=0;j<s->exponent_high_sizes[k];j++)
-                tprintf(" %d", s->exponent_high_bands[k][j]);
-            tprintf("\n");
+                tprintf(s->avctx, " %d", s->exponent_high_bands[k][j]);
+            tprintf(s->avctx, "\n");
 #endif
         }
     }
@@ -284,12 +284,12 @@ int ff_wma_init(AVCodecContext * avctx, int flags2)
     {
         int i, j;
         for(i = 0; i < s->nb_block_sizes; i++) {
-            tprintf("%5d: n=%2d:",
+            tprintf(s->avctx, "%5d: n=%2d:",
                    s->frame_len >> i,
                    s->exponent_sizes[i]);
             for(j=0;j<s->exponent_sizes[i];j++)
-                tprintf(" %d", s->exponent_bands[i][j]);
-            tprintf("\n");
+                tprintf(s->avctx, " %d", s->exponent_bands[i][j]);
+            tprintf(s->avctx, "\n");
         }
     }
 #endif
@@ -362,7 +362,7 @@ int ff_wma_total_gain_to_bits(int total_gain){
 
 int ff_wma_end(AVCodecContext *avctx)
 {
-    WMADecodeContext *s = avctx->priv_data;
+    WMACodecContext *s = avctx->priv_data;
     int i;
 
     for(i = 0; i < s->nb_block_sizes; i++)