Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
audiowmark
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
audiowmark
Commits
22267ef1
Commit
22267ef1
authored
Nov 28, 2019
by
Stefan Westerfeld
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Better name for log10_approx: fast_log10.
Signed-off-by:
Stefan Westerfeld
<
stefan@space.twc.de
>
parent
0a2c6006
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
audiowmark.cc
src/audiowmark.cc
+2
-2
No files found.
src/audiowmark.cc
View file @
22267ef1
...
...
@@ -228,7 +228,7 @@ window_hamming (double x) /* sharp (rectangle) cutoffs at boundaries */
* glibc log2f is a lot faster than glibc log10
*/
inline
double
log10_approx
(
double
l
)
fast_log10
(
double
l
)
{
constexpr
double
log2_log10_factor
=
0.3010299956639811952
;
// 1 / log2 (10)
...
...
@@ -240,7 +240,7 @@ db_from_factor (double factor, double min_dB)
{
if
(
factor
>
0
)
{
double
dB
=
log10_approx
(
factor
);
/* Bell */
double
dB
=
fast_log10
(
factor
);
/* Bell */
dB
*=
20
;
return
dB
;
}
...
...
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