mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-05-13 21:26:33 +02:00
avcodec/lpc: zero the middle odd sample in the output
Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
parent
c8c4a162fc
commit
0627e6d74c
@ -53,6 +53,7 @@ static void lpc_apply_welch_window_c(const int32_t *data, ptrdiff_t len,
|
|||||||
w_data[i] = data[i] * w;
|
w_data[i] = data[i] * w;
|
||||||
w_data[len-1-i] = data[len-1-i] * w;
|
w_data[len-1-i] = data[len-1-i] * w;
|
||||||
}
|
}
|
||||||
|
w_data[n2] = 0.0;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ SECTION .text
|
|||||||
%macro APPLY_WELCH_FN 0
|
%macro APPLY_WELCH_FN 0
|
||||||
cglobal lpc_apply_welch_window, 3, 5, 8, data, len, out, off1, off2
|
cglobal lpc_apply_welch_window, 3, 5, 8, data, len, out, off1, off2
|
||||||
cmp lenq, 0
|
cmp lenq, 0
|
||||||
je .end
|
je .end_e
|
||||||
cmp lenq, 2
|
cmp lenq, 2
|
||||||
je .two
|
je .two
|
||||||
cmp lenq, 1
|
cmp lenq, 1
|
||||||
@ -104,7 +104,7 @@ cglobal lpc_apply_welch_window, 3, 5, 8, data, len, out, off1, off2
|
|||||||
|
|
||||||
add lend, (mmsize/4 - 1)
|
add lend, (mmsize/4 - 1)
|
||||||
cmp lend, 0
|
cmp lend, 0
|
||||||
je .end
|
je .end_o
|
||||||
sub lenq, (mmsize/4 - 1)
|
sub lenq, (mmsize/4 - 1)
|
||||||
|
|
||||||
.scalar_o:
|
.scalar_o:
|
||||||
@ -135,6 +135,10 @@ cglobal lpc_apply_welch_window, 3, 5, 8, data, len, out, off1, off2
|
|||||||
|
|
||||||
sub lenq, 2
|
sub lenq, 2
|
||||||
jg .loop_o_scalar
|
jg .loop_o_scalar
|
||||||
|
|
||||||
|
.end_o:
|
||||||
|
xorpd xm3, xm3
|
||||||
|
movlpd [outq + off1q*2], xm3
|
||||||
RET
|
RET
|
||||||
|
|
||||||
.even:
|
.even:
|
||||||
@ -233,7 +237,7 @@ cglobal lpc_apply_welch_window, 3, 5, 8, data, len, out, off1, off2
|
|||||||
.one:
|
.one:
|
||||||
xorpd xm0, xm0
|
xorpd xm0, xm0
|
||||||
movhpd [outq], xm0
|
movhpd [outq], xm0
|
||||||
.end:
|
.end_e:
|
||||||
RET
|
RET
|
||||||
%endmacro
|
%endmacro
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user