[Speex-dev] [patch] speex_preprocess_ctl
Jean-Marc Valin
jean-marc.valin at usherbrooke.ca
Mon Nov 5 14:21:07 PST 2007
Mihai Balea a écrit :
> I checked it against the latest code in the git repository and it wasn't
> there.
> Mihai
Sorry about that. Had forgotten about the patch. It's applied now.
Thanks for remind me.
> PS: if JM wants a @hates.ms address, I could prolly hook him up.
> Especially if he throws in some VAD code that's not "a hack" :)
I don't actually hate MS, just Windows, its compilers, Office and IE. I
haven't actually been exposed to its other products.
Jean-Marc
> On Nov 5, 2007, at 2:08 PM, Tom Grandgent wrote:
>
>> Did you check it against the trunk in SVN?
>>
>> If it's not applied, and you can hook Jean-Marc up with an email
>> address like yours, I'm sure he will get right on it. :)
>>
>> Tom
>>
>> Mihai Balea <mihai at hates.ms> wrote:
>>>
>>> Hi all,
>>>
>>> Did anything happen to this patch?
>>> It seems to me that it fixes a valid issue, but I'm not an expert.
>>> Anyways, I didn't see and follow-up or reply...
>>>
>>> Cheers,
>>> Mihai
>>>
>>> On Oct 29, 2007, at 7:14 PM, Mikael Magnusson wrote:
>>>
>>>> There is a problem in speex_preprocess_ctl. Both speech_prob_start
>>>> and speech_prob_continue are set to 327.67 for all input values
>>>> except 0 which results in 0. This is in floating point mode.
>>>>
>>>> I think the included patch fixes the problem.
>>>>
>>>> Mikael
>>>> Index: libspeex/preprocess.c
>>>> ===================================================================
>>>> --- libspeex/preprocess.c (revision 13983)
>>>> +++ libspeex/preprocess.c (arbetskopia)
>>>> @@ -1126,16 +1126,16 @@
>>>> break;
>>>>
>>>> case SPEEX_PREPROCESS_SET_PROB_START:
>>>> - *(spx_int32_t*)ptr = MIN32(Q15_ONE,MAX32(0, *(spx_int32_t*)
>>>> ptr));
>>>> - st->speech_prob_start = DIV32_16(MULT16_16(32767,*
>>>> (spx_int32_t*)ptr), 100);
>>>> + *(spx_int32_t*)ptr = MIN32(100,MAX32(0, *(spx_int32_t*)ptr));
>>>> + st->speech_prob_start = DIV32_16(MULT16_16(Q15ONE,*
>>>> (spx_int32_t*)ptr), 100);
>>>> break;
>>>> case SPEEX_PREPROCESS_GET_PROB_START:
>>>> (*(spx_int32_t*)ptr) = MULT16_16_Q15(st->speech_prob_start,
>>>> 100);
>>>> break;
>>>>
>>>> case SPEEX_PREPROCESS_SET_PROB_CONTINUE:
>>>> - *(spx_int32_t*)ptr = MIN32(Q15_ONE,MAX32(0, *(spx_int32_t*)
>>>> ptr));
>>>> - st->speech_prob_continue = DIV32_16(MULT16_16(32767,*
>>>> (spx_int32_t*)ptr), 100);
>>>> + *(spx_int32_t*)ptr = MIN32(100,MAX32(0, *(spx_int32_t*)ptr));
>>>> + st->speech_prob_continue = DIV32_16(MULT16_16(Q15ONE,*
>>>> (spx_int32_t*)ptr), 100);
>>>> break;
>>>> case SPEEX_PREPROCESS_GET_PROB_CONTINUE:
>>>> (*(spx_int32_t*)ptr) = MULT16_16_Q15(st-
>>>>> speech_prob_continue, 100);
>>>> _______________________________________________
>>>> Speex-dev mailing list
>>>> Speex-dev at xiph.org
>>>> http://lists.xiph.org/mailman/listinfo/speex-dev
>>
>>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Speex-dev mailing list
> Speex-dev at xiph.org
> http://lists.xiph.org/mailman/listinfo/speex-dev
More information about the Speex-dev
mailing list