Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
7e98da9c
Commit
7e98da9c
authored
Jun 22, 2017
by
Rostislav Pehlivanov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
opus_celt: do not use double precision exp2
Signed-off-by:
Rostislav Pehlivanov
<
atomnuker@gmail.com
>
parent
505cb8e3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
opus_celt.c
libavcodec/opus_celt.c
+2
-2
No files found.
libavcodec/opus_celt.c
View file @
7e98da9c
...
@@ -485,7 +485,7 @@ static void celt_denormalize(CeltFrame *f, CeltBlock *block, float *data)
...
@@ -485,7 +485,7 @@ static void celt_denormalize(CeltFrame *f, CeltBlock *block, float *data)
for
(
i
=
f
->
start_band
;
i
<
f
->
end_band
;
i
++
)
{
for
(
i
=
f
->
start_band
;
i
<
f
->
end_band
;
i
++
)
{
float
*
dst
=
data
+
(
ff_celt_freq_bands
[
i
]
<<
f
->
size
);
float
*
dst
=
data
+
(
ff_celt_freq_bands
[
i
]
<<
f
->
size
);
float
norm
=
exp2
(
block
->
energy
[
i
]
+
ff_celt_mean_energy
[
i
]);
float
norm
=
exp2
f
(
block
->
energy
[
i
]
+
ff_celt_mean_energy
[
i
]);
for
(
j
=
0
;
j
<
ff_celt_freq_range
[
i
]
<<
f
->
size
;
j
++
)
for
(
j
=
0
;
j
<
ff_celt_freq_range
[
i
]
<<
f
->
size
;
j
++
)
dst
[
j
]
*=
norm
;
dst
[
j
]
*=
norm
;
...
@@ -664,7 +664,7 @@ static void process_anticollapse(CeltFrame *f, CeltBlock *block, float *X)
...
@@ -664,7 +664,7 @@ static void process_anticollapse(CeltFrame *f, CeltBlock *block, float *X)
/* r needs to be multiplied by 2 or 2*sqrt(2) depending on LM because
/* r needs to be multiplied by 2 or 2*sqrt(2) depending on LM because
short blocks don't have the same energy as long */
short blocks don't have the same energy as long */
r
=
exp2
(
1
-
Ediff
);
r
=
exp2
f
(
1
-
Ediff
);
if
(
f
->
size
==
3
)
if
(
f
->
size
==
3
)
r
*=
M_SQRT2
;
r
*=
M_SQRT2
;
r
=
FFMIN
(
thresh
,
r
)
*
sqrt_1
;
r
=
FFMIN
(
thresh
,
r
)
*
sqrt_1
;
...
...
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