Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
496f8865
Commit
496f8865
authored
Sep 13, 2019
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ReplayGainInfo: add static method Undefined()
parent
5ef645df
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
0 deletions
+11
-0
ReplayGainInfo.hxx
src/ReplayGainInfo.hxx
+11
-0
No files found.
src/ReplayGainInfo.hxx
View file @
496f8865
...
...
@@ -38,6 +38,10 @@ struct ReplayGainTuple {
return
gain
>
-
100
;
}
static
constexpr
ReplayGainTuple
Undefined
()
noexcept
{
return
{
-
200.0
f
,
0.0
f
};
}
gcc_pure
float
CalculateScale
(
const
ReplayGainConfig
&
config
)
const
noexcept
;
};
...
...
@@ -49,6 +53,13 @@ struct ReplayGainInfo {
return
track
.
IsDefined
()
||
album
.
IsDefined
();
}
static
constexpr
ReplayGainInfo
Undefined
()
noexcept
{
return
{
ReplayGainTuple
::
Undefined
(),
ReplayGainTuple
::
Undefined
(),
};
}
const
ReplayGainTuple
&
Get
(
ReplayGainMode
mode
)
const
noexcept
{
return
mode
==
ReplayGainMode
::
ALBUM
?
(
album
.
IsDefined
()
?
album
:
track
)
...
...
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