summaryrefslogtreecommitdiff
path: root/apps/codecs/libspeex/sb_celp.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/codecs/libspeex/sb_celp.c')
-rw-r--r--apps/codecs/libspeex/sb_celp.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/codecs/libspeex/sb_celp.c b/apps/codecs/libspeex/sb_celp.c
index b12ca71f4b..424d590b89 100644
--- a/apps/codecs/libspeex/sb_celp.c
+++ b/apps/codecs/libspeex/sb_celp.c
@@ -844,6 +844,7 @@ void sb_decoder_destroy(void *state)
844*/ 844*/
845} 845}
846 846
847#ifndef ROCKBOX_VOICE_CODEC
847static void sb_decode_lost(SBDecState *st, spx_word16_t *out, int dtx, char *stack) 848static void sb_decode_lost(SBDecState *st, spx_word16_t *out, int dtx, char *stack)
848{ 849{
849 int i; 850 int i;
@@ -881,6 +882,7 @@ static void sb_decode_lost(SBDecState *st, spx_word16_t *out, int dtx, char *sta
881 882
882 return; 883 return;
883} 884}
885#endif
884 886
885int sb_decode(void *state, SpeexBits *bits, void *vout) 887int sb_decode(void *state, SpeexBits *bits, void *vout)
886{ 888{
@@ -917,11 +919,13 @@ int sb_decode(void *state, SpeexBits *bits, void *vout)
917 return ret; 919 return ret;
918 } 920 }
919 921
922#ifndef ROCKBOX_VOICE_CODEC
920 if (!bits) 923 if (!bits)
921 { 924 {
922 sb_decode_lost(st, out, dtx, stack); 925 sb_decode_lost(st, out, dtx, stack);
923 return 0; 926 return 0;
924 } 927 }
928#endif
925 929
926 if (st->encode_submode) 930 if (st->encode_submode)
927 { 931 {
@@ -951,11 +955,13 @@ int sb_decode(void *state, SpeexBits *bits, void *vout)
951 /* If null mode (no transmission), just set a couple things to zero*/ 955 /* If null mode (no transmission), just set a couple things to zero*/
952 if (st->submodes[st->submodeID] == NULL) 956 if (st->submodes[st->submodeID] == NULL)
953 { 957 {
958#ifndef ROCKBOX_VOICE_CODEC
954 if (dtx) 959 if (dtx)
955 { 960 {
956 sb_decode_lost(st, out, 1, stack); 961 sb_decode_lost(st, out, 1, stack);
957 return 0; 962 return 0;
958 } 963 }
964#endif
959 965
960 for (i=0;i<st->frame_size;i++) 966 for (i=0;i<st->frame_size;i++)
961 out[st->frame_size+i]=VERY_SMALL; 967 out[st->frame_size+i]=VERY_SMALL;