summaryrefslogtreecommitdiff
path: root/apps/codecs/libspeex/modes.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/codecs/libspeex/modes.c')
-rw-r--r--apps/codecs/libspeex/modes.c111
1 files changed, 0 insertions, 111 deletions
diff --git a/apps/codecs/libspeex/modes.c b/apps/codecs/libspeex/modes.c
index 0478f978d1..cf4ef3246c 100644
--- a/apps/codecs/libspeex/modes.c
+++ b/apps/codecs/libspeex/modes.c
@@ -441,9 +441,6 @@ static const SpeexNBMode nb_mode = {
441#endif 441#endif
442 .012, /*lag_factor*/ 442 .012, /*lag_factor*/
443 QCONST16(.0002,15), /*lpc_floor*/ 443 QCONST16(.0002,15), /*lpc_floor*/
444#ifdef EPIC_48K
445 0,
446#endif
447 {NULL, &nb_submode1, &nb_submode2, &nb_submode3, &nb_submode4, &nb_submode5, &nb_submode6, &nb_submode7, 444 {NULL, &nb_submode1, &nb_submode2, &nb_submode3, &nb_submode4, &nb_submode5, &nb_submode6, &nb_submode7,
448 &nb_submode8, NULL, NULL, NULL, NULL, NULL, NULL, NULL}, 445 &nb_submode8, NULL, NULL, NULL, NULL, NULL, NULL, NULL},
449 5, 446 5,
@@ -480,114 +477,6 @@ const SpeexMode speex_nb_mode = {
480}; 477};
481 478
482 479
483/* Wideband part */
484
485
486#ifdef EPIC_48K
487
488extern const signed char gain_cdbk_ulbr[];
489extern const signed char exc_12_32_table[];
490
491/* Parameters for Long-Term Prediction (LTP)*/
492static const ltp_params ltp_params_48k = {
493 gain_cdbk_ulbr,
494 3,
495 0
496};
497
498static const split_cb_params split_cb_nb_48k = {
499 12, /*subvect_size*/
500 4, /*nb_subvect*/
501 exc_12_32_table, /*shape_cb*/
502 5, /*shape_bits*/
503 0,
504};
505
506
507/* 4.8 kbps very low bit-rate mode */
508static const SpeexSubmode nb_48k_submode = {
509 0,
510 0,
511 0,
512 0,
513#ifndef SPEEX_DISABLE_ENCODER
514 /*LSP quantization*/
515 lsp_quant_48k,
516 lsp_unquant_48k,
517 /*No pitch quantization*/
518 pitch_search_3tap,
519 pitch_unquant_3tap,
520 &ltp_params_48k,
521 /*Innovation quantization*/
522 split_cb_search_shape_sign,
523 split_cb_shape_sign_unquant,
524 &split_cb_nb_48k,
525#else
526 /*LSP quantization*/
527 NULL,
528 lsp_unquant_48k,
529 /*No pitch quantization*/
530 NULL,
531 pitch_unquant_3tap,
532 &ltp_params_48k,
533 /*Innovation quantization*/
534 NULL,
535 split_cb_shape_sign_unquant,
536 &split_cb_nb_48k,
537#endif
538 QCONST16(.7,15),
539 144
540};
541
542
543/* Special, non-standard 4.8 kbps mode */
544static const SpeexNBMode nb_48k_mode = {
545 240, /*frameSize*/
546 48, /*subframeSize*/
547 10, /*lpcSize*/
548 17, /*pitchStart*/
549 144, /*pitchEnd*/
550 0.9, /*gamma1*/
551 0.6, /*gamma2*/
552 .01, /*lag_factor*/
553 QCONST16(.0003,15), /*lpc_floor*/
554 1,
555 {NULL, NULL, &nb_48k_submode, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL},
556 2,
557 {2,2,2,2,2,2,2,2,2,2,2}
558};
559
560
561/* Default mode for narrowband */
562const SpeexMode speex_nb_48k_mode = {
563 &nb_48k_mode,
564 nb_mode_query,
565 "narrowband 4.8 kbps",
566 1000,
567 4,
568#ifndef SPEEX_DISABLE_ENCODER
569 &nb_encoder_init,
570 &nb_encoder_destroy,
571 &nb_encode,
572 &nb_decoder_init,
573 &nb_decoder_destroy,
574 &nb_decode,
575 &nb_encoder_ctl,
576 &nb_decoder_ctl,
577#else
578 NULL,
579 NULL,
580 NULL,
581 &nb_decoder_init,
582 &nb_decoder_destroy,
583 &nb_decode,
584 NULL,
585 &nb_decoder_ctl,
586#endif
587};
588
589
590#endif
591 480
592int speex_mode_query(const SpeexMode *mode, int request, void *ptr) 481int speex_mode_query(const SpeexMode *mode, int request, void *ptr)
593{ 482{