Making it possible to have two transients in a row for longer frames
This commit is contained in:
parent
2794b63083
commit
4a8c1f11b1
1 changed files with 9 additions and 3 deletions
|
@ -256,7 +256,13 @@ static int transient_analysis(const celt_word32 * restrict in, int len, int C,
|
||||||
|
|
||||||
*transient_time = n;
|
*transient_time = n;
|
||||||
*frame_max = begin[len-overlap];
|
*frame_max = begin[len-overlap];
|
||||||
|
/* Only consider the last 7.5 ms for the next transient */
|
||||||
|
if (len>360+overlap)
|
||||||
|
{
|
||||||
|
*frame_max = 0;
|
||||||
|
for (i=len-360-overlap;i<len;i++)
|
||||||
|
*frame_max = MAX32(*frame_max, ABS32(tmp[i]));
|
||||||
|
}
|
||||||
RESTORE_STACK;
|
RESTORE_STACK;
|
||||||
return ratio > 0;
|
return ratio > 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue