Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
24c01336
Commit
24c01336
authored
Aug 13, 2023
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/af_asdr: remove wrong scaling from sdr, and fix sisdr formula
parent
10110a30
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
af_asdr.c
libavfilter/af_asdr.c
+2
-2
No files found.
libavfilter/af_asdr.c
View file @
24c01336
...
...
@@ -225,11 +225,11 @@ static av_cold void uninit(AVFilterContext *ctx)
if
(
!
strcmp
(
ctx
->
filter
->
name
,
"asdr"
))
{
for
(
int
ch
=
0
;
ch
<
s
->
channels
;
ch
++
)
av_log
(
ctx
,
AV_LOG_INFO
,
"SDR ch%d: %g dB
\n
"
,
ch
,
2
0
.
*
log10
(
s
->
chs
[
ch
].
u
/
s
->
chs
[
ch
].
uv
));
av_log
(
ctx
,
AV_LOG_INFO
,
"SDR ch%d: %g dB
\n
"
,
ch
,
1
0
.
*
log10
(
s
->
chs
[
ch
].
u
/
s
->
chs
[
ch
].
uv
));
}
else
if
(
!
strcmp
(
ctx
->
filter
->
name
,
"asisdr"
))
{
for
(
int
ch
=
0
;
ch
<
s
->
channels
;
ch
++
)
{
double
scale
=
s
->
chs
[
ch
].
uv
/
s
->
chs
[
ch
].
v
;
double
sisdr
=
s
->
chs
[
ch
].
u
/
fmax
(
0
.,
s
->
chs
[
ch
].
u
+
scale
*
scale
*
s
->
chs
[
ch
].
v
-
2
.
0
*
scale
*
s
->
chs
[
ch
].
uv
);
double
sisdr
=
s
cale
*
scale
*
s
->
chs
[
ch
].
v
/
fmax
(
0
.,
s
->
chs
[
ch
].
u
+
scale
*
scale
*
s
->
chs
[
ch
].
v
-
2
.
0
*
scale
*
s
->
chs
[
ch
].
uv
);
av_log
(
ctx
,
AV_LOG_INFO
,
"SI-SDR ch%d: %g dB
\n
"
,
ch
,
10
.
*
log10
(
sisdr
));
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment