Commit 222b7775 authored by Max Kellermann's avatar Max Kellermann

tag/ApeReplayGain: add overload with InputStream& parameter

parent b5c206d3
......@@ -48,6 +48,23 @@ replay_gain_ape_callback(unsigned long flags, const char *key,
}
bool
replay_gain_ape_read(InputStream &is, ReplayGainInfo &info)
{
bool found = false;
auto callback = [&info, &found]
(unsigned long flags, const char *key,
StringView value) {
found |= replay_gain_ape_callback(flags, key,
value,
info);
return true;
};
return tag_ape_scan(is, callback) && found;
}
bool
replay_gain_ape_read(Path path_fs, ReplayGainInfo &info)
{
bool found = false;
......
......@@ -22,10 +22,14 @@
#include "check.h"
class InputStream;
class Path;
struct ReplayGainInfo;
bool
replay_gain_ape_read(InputStream &is, ReplayGainInfo &info);
bool
replay_gain_ape_read(Path path_fs, ReplayGainInfo &info);
#endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment