[FFmpeg-soc] [soc]: r1181 - qcelp/qcelpdec.c

reynaldo subversion at mplayerhq.hu
Sat Aug 25 00:29:23 CEST 2007


Author: reynaldo
Date: Sat Aug 25 00:29:23 2007
New Revision: 1181

Log:
COSMETICS - Some commentary rephrasing

Modified:
   qcelp/qcelpdec.c

Modified: qcelp/qcelpdec.c
==============================================================================
--- qcelp/qcelpdec.c	(original)
+++ qcelp/qcelpdec.c	Sat Aug 25 00:29:23 2007
@@ -720,7 +720,8 @@ static void qcelp_do_formant(float *in, 
 }
 
 /**
- * Detilt filter used in the adaptive postfilter at sample generation stage.
+ * Detilt used in the adaptive postfilter after the formant synthesis
+ * filter.
  *
  * TIA/EIA/IS-733 2.4.8.6-2
  */
@@ -813,7 +814,7 @@ static int qcelp_decode_frame(AVCodecCon
     }
 
     /**
-     * reordering loop
+     * data reordering loop
      */
 
     memset(q->frame->data, 0, 76);
@@ -930,7 +931,14 @@ static int qcelp_decode_frame(AVCodecCon
         memcpy(ppf_vector, cdn_vector, 160*sizeof(float));
 
         /**
-         * pitch pre-filter
+         * Pitch pre-filter
+         *
+         * The specification makes this filter mandatory but one can go
+         * without it with an small degradation of the output perseived
+         * quality.
+         *
+         * WIP: Making this runtime selectable might be a good speed-wise
+         * compromise.
          */
 
         if((is_ifq = qcelp_do_pitchfilter(q->frame, q->pitchp_mem,
@@ -949,29 +957,21 @@ static int qcelp_decode_frame(AVCodecCon
     qcelp_apply_gain_ctrl(0, cdn_vector, ppf_vector);
 
     /**
-     * Apply formant synthesis filter over the pitch pre-filter output.
+     * Interpolate LSP frequencies and apply formant synthesis filter.
      */
 
     for(i=0; i<4; i++)
     {
-        /**
-         * Interpolate lsp freqs
-         */
-
         qcelp_do_interpolate_lspf(q->frame->rate, q->prev_lspf, qtzd_lspf,
                                   interpolated_lspf, i*40, q->frame_num);
-        qcelp_lsp2lpc(interpolated_lspf, lpc);
 
-        /**
-         * Formant
-         */
+        qcelp_lsp2lpc(interpolated_lspf, lpc);
 
         qcelp_do_formant(ppf_vector+i*40, cdn_vector+i*40, lpc, q->formant_mem);
 
         /**
          * WIP Adaptive postfilter should be here
          */
-
     }
 
     /**



More information about the FFmpeg-soc mailing list