Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFmpeg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
libremedia
Tethys
FFmpeg
Commits
d961a79e
Commit
d961a79e
authored
11 years ago
by
Janne Grunau
Browse files
Options
Downloads
Patches
Plain Diff
sbrdsp: move #if to disable all educational code
Avoids a warning of the unused function 'autocorrelate'.
parent
c829b35c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libavcodec/sbrdsp.c
+8
-4
8 additions, 4 deletions
libavcodec/sbrdsp.c
with
8 additions
and
4 deletions
libavcodec/sbrdsp.c
+
8
−
4
View file @
d961a79e
...
@@ -109,6 +109,11 @@ static void sbr_qmf_deint_bfly_c(float *v, const float *src0, const float *src1)
...
@@ -109,6 +109,11 @@ static void sbr_qmf_deint_bfly_c(float *v, const float *src0, const float *src1)
}
}
}
}
#if 0
/* This code is slower because it multiplies memory accesses.
* It is left for educational purposes and because it may offer
* a better reference for writing arch-specific DSP functions. */
static av_always_inline void autocorrelate(const float x[40][2],
static av_always_inline void autocorrelate(const float x[40][2],
float phi[3][2][2], int lag)
float phi[3][2][2], int lag)
{
{
...
@@ -137,14 +142,13 @@ static av_always_inline void autocorrelate(const float x[40][2],
...
@@ -137,14 +142,13 @@ static av_always_inline void autocorrelate(const float x[40][2],
static void sbr_autocorrelate_c(const float x[40][2], float phi[3][2][2])
static void sbr_autocorrelate_c(const float x[40][2], float phi[3][2][2])
{
{
#if 0
/* This code is slower because it multiplies memory accesses.
* It is left for educational purposes and because it may offer
* a better reference for writing arch-specific DSP functions. */
autocorrelate(x, phi, 0);
autocorrelate(x, phi, 0);
autocorrelate(x, phi, 1);
autocorrelate(x, phi, 1);
autocorrelate(x, phi, 2);
autocorrelate(x, phi, 2);
}
#else
#else
static
void
sbr_autocorrelate_c
(
const
float
x
[
40
][
2
],
float
phi
[
3
][
2
][
2
])
{
float
real_sum2
=
x
[
0
][
0
]
*
x
[
2
][
0
]
+
x
[
0
][
1
]
*
x
[
2
][
1
];
float
real_sum2
=
x
[
0
][
0
]
*
x
[
2
][
0
]
+
x
[
0
][
1
]
*
x
[
2
][
1
];
float
imag_sum2
=
x
[
0
][
0
]
*
x
[
2
][
1
]
-
x
[
0
][
1
]
*
x
[
2
][
0
];
float
imag_sum2
=
x
[
0
][
0
]
*
x
[
2
][
1
]
-
x
[
0
][
1
]
*
x
[
2
][
0
];
float
real_sum1
=
0
.
0
f
,
imag_sum1
=
0
.
0
f
,
real_sum0
=
0
.
0
f
;
float
real_sum1
=
0
.
0
f
,
imag_sum1
=
0
.
0
f
,
real_sum0
=
0
.
0
f
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment