-rw-r--r-- | core/applets/vmemo/adpcm.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/applets/vmemo/adpcm.c b/core/applets/vmemo/adpcm.c index c4dfa50..a123249 100644 --- a/core/applets/vmemo/adpcm.c +++ b/core/applets/vmemo/adpcm.c | |||
@@ -81,18 +81,18 @@ adpcm_coder(indata, outdata, len, state) | |||
81 | int val; /* Current input sample value */ | 81 | int val; /* Current input sample value */ |
82 | int sign; /* Current adpcm sign bit */ | 82 | int sign; /* Current adpcm sign bit */ |
83 | int delta; /* Current adpcm output value */ | 83 | int delta; /* Current adpcm output value */ |
84 | int diff; /* Difference between val and valprev */ | 84 | int diff; /* Difference between val and valprev */ |
85 | int step; /* Stepsize */ | 85 | int step; /* Stepsize */ |
86 | int valpred; /* Predicted output value */ | 86 | int valpred; /* Predicted output value */ |
87 | int vpdiff; /* Current change to valpred */ | 87 | int vpdiff; /* Current change to valpred */ |
88 | int index; /* Current step change index */ | 88 | int index; /* Current step change index */ |
89 | int outputbuffer; /* place to keep previous 4-bit value */ | 89 | int outputbuffer = 0; /* place to keep previous 4-bit value */ |
90 | int bufferstep; /* toggle between outputbuffer/output */ | 90 | int bufferstep = 0; /* toggle between outputbuffer/output */ |
91 | 91 | ||
92 | outp = (signed char *)outdata; | 92 | outp = (signed char *)outdata; |
93 | inp = indata; | 93 | inp = indata; |
94 | 94 | ||
95 | valpred = state->valprev; | 95 | valpred = state->valprev; |
96 | index = state->index; | 96 | index = state->index; |
97 | step = stepsizeTable[index]; | 97 | step = stepsizeTable[index]; |
98 | 98 | ||
@@ -182,18 +182,18 @@ adpcm_decoder(indata, outdata, len, state) | |||
182 | signed char *inp; /* Input buffer pointer */ | 182 | signed char *inp; /* Input buffer pointer */ |
183 | short *outp; /* output buffer pointer */ | 183 | short *outp; /* output buffer pointer */ |
184 | int sign; /* Current adpcm sign bit */ | 184 | int sign; /* Current adpcm sign bit */ |
185 | int delta; /* Current adpcm output value */ | 185 | int delta; /* Current adpcm output value */ |
186 | int step; /* Stepsize */ | 186 | int step; /* Stepsize */ |
187 | int valpred; /* Predicted value */ | 187 | int valpred; /* Predicted value */ |
188 | int vpdiff; /* Current change to valpred */ | 188 | int vpdiff; /* Current change to valpred */ |
189 | int index; /* Current step change index */ | 189 | int index; /* Current step change index */ |
190 | int inputbuffer; /* place to keep next 4-bit value */ | 190 | int inputbuffer = 0; /* place to keep next 4-bit value */ |
191 | int bufferstep; /* toggle between inputbuffer/input */ | 191 | int bufferstep = 0; /* toggle between inputbuffer/input */ |
192 | 192 | ||
193 | outp = outdata; | 193 | outp = outdata; |
194 | inp = (signed char *)indata; | 194 | inp = (signed char *)indata; |
195 | 195 | ||
196 | valpred = state->valprev; | 196 | valpred = state->valprev; |
197 | index = state->index; | 197 | index = state->index; |
198 | step = stepsizeTable[index]; | 198 | step = stepsizeTable[index]; |
199 | 199 | ||