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
a30af2ba
Commit
a30af2ba
authored
Apr 05, 2019
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lib/chromaprint/DecoderClient: replace method PrintResult()
parent
9f1c23e2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
5 deletions
+8
-5
DecoderClient.cxx
src/lib/chromaprint/DecoderClient.cxx
+1
-3
DecoderClient.hxx
src/lib/chromaprint/DecoderClient.hxx
+5
-1
RunChromaprint.cxx
test/RunChromaprint.cxx
+2
-1
No files found.
src/lib/chromaprint/DecoderClient.cxx
View file @
a30af2ba
...
...
@@ -26,7 +26,7 @@ ChromaprintDecoderClient::ChromaprintDecoderClient() = default;
ChromaprintDecoderClient
::~
ChromaprintDecoderClient
()
noexcept
=
default
;
void
ChromaprintDecoderClient
::
PrintResult
()
ChromaprintDecoderClient
::
Finish
()
{
if
(
!
ready
)
throw
std
::
runtime_error
(
"Decoding failed"
);
...
...
@@ -38,8 +38,6 @@ ChromaprintDecoderClient::PrintResult()
}
chromaprint
.
Finish
();
printf
(
"%s
\n
"
,
chromaprint
.
GetFingerprint
().
c_str
());
}
void
...
...
src/lib/chromaprint/DecoderClient.hxx
View file @
a30af2ba
...
...
@@ -45,7 +45,11 @@ public:
ChromaprintDecoderClient
();
~
ChromaprintDecoderClient
()
noexcept
;
void
PrintResult
();
void
Finish
();
std
::
string
GetFingerprint
()
const
{
return
chromaprint
.
GetFingerprint
();
}
/* virtual methods from DecoderClient */
void
Ready
(
AudioFormat
audio_format
,
...
...
test/RunChromaprint.cxx
View file @
a30af2ba
...
...
@@ -135,7 +135,8 @@ try {
return
EXIT_FAILURE
;
}
client
.
PrintResult
();
client
.
Finish
();
printf
(
"%s
\n
"
,
client
.
GetFingerprint
().
c_str
());
return
EXIT_SUCCESS
;
}
catch
(...)
{
PrintException
(
std
::
current_exception
());
...
...
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