diff options
| -rw-r--r-- | src/plugins/General/CMakeLists.txt | 2 | ||||
| -rw-r--r-- | src/plugins/General/General.pro | 4 | ||||
| -rw-r--r-- | src/plugins/Input/cue/decoder_cue.cpp | 2 | ||||
| -rw-r--r-- | src/plugins/Input/mad/decodermadfactory.cpp | 2 | ||||
| -rw-r--r-- | src/plugins/Input/vorbis/decodervorbisfactory.cpp | 2 | ||||
| -rw-r--r-- | src/qmmp/decoder.cpp | 9 | ||||
| -rw-r--r-- | src/qmmp/decoder.h | 9 | ||||
| -rw-r--r-- | src/qmmp/qmmpaudioengine.cpp | 6 |
8 files changed, 11 insertions, 25 deletions
diff --git a/src/plugins/General/CMakeLists.txt b/src/plugins/General/CMakeLists.txt index 3eb64595b..1b02b2d19 100644 --- a/src/plugins/General/CMakeLists.txt +++ b/src/plugins/General/CMakeLists.txt @@ -71,7 +71,7 @@ add_subdirectory(converter) ENDIF(USE_CONVERTER AND TAGLIB_FOUND) IF(USE_RGSCAN AND TAGLIB_FOUND) -add_subdirectory(rgscan) +#add_subdirectory(rgscan) ENDIF(USE_RGSCAN AND TAGLIB_FOUND) IF(USE_SB) diff --git a/src/plugins/General/General.pro b/src/plugins/General/General.pro index 9484a4b3d..c503b9db4 100644 --- a/src/plugins/General/General.pro +++ b/src/plugins/General/General.pro @@ -9,8 +9,8 @@ SUBDIRS += statusicon \ streambrowser \ trackchange \ hotkey \ - copypaste \ - rgscan + copypaste +# rgscan unix:SUBDIRS += mpris \ kdenotify \ converter \ diff --git a/src/plugins/Input/cue/decoder_cue.cpp b/src/plugins/Input/cue/decoder_cue.cpp index ddb308e69..141317fb4 100644 --- a/src/plugins/Input/cue/decoder_cue.cpp +++ b/src/plugins/Input/cue/decoder_cue.cpp @@ -99,7 +99,7 @@ bool DecoderCUE::initialize() configure(m_decoder->audioParameters().sampleRate(), m_decoder->audioParameters().channelMap(), m_decoder->audioParameters().format()); - setReplayGainInfo(m_parser->replayGain(m_track), m_decoder->hasHeadroom()); + setReplayGainInfo(m_parser->replayGain(m_track)); length_in_bytes = audioParameters().sampleRate() * audioParameters().channels() * audioParameters().sampleSize() * m_length/1000; diff --git a/src/plugins/Input/mad/decodermadfactory.cpp b/src/plugins/Input/mad/decodermadfactory.cpp index 91214f6fb..cc508f221 100644 --- a/src/plugins/Input/mad/decodermadfactory.cpp +++ b/src/plugins/Input/mad/decodermadfactory.cpp @@ -117,7 +117,7 @@ Decoder *DecoderMADFactory::create(const QString &url, QIODevice *input) if(!url.contains("://")) //local file { ReplayGainReader rg(url); - d->setReplayGainInfo(rg.replayGainInfo(), true); + d->setReplayGainInfo(rg.replayGainInfo()); } return d; } diff --git a/src/plugins/Input/vorbis/decodervorbisfactory.cpp b/src/plugins/Input/vorbis/decodervorbisfactory.cpp index 248e25a06..794850c52 100644 --- a/src/plugins/Input/vorbis/decodervorbisfactory.cpp +++ b/src/plugins/Input/vorbis/decodervorbisfactory.cpp @@ -67,7 +67,7 @@ Decoder *DecoderVorbisFactory::create(const QString &url, QIODevice *input) if(!url.contains("://")) //local file { ReplayGainReader rg(url); - d->setReplayGainInfo(rg.replayGainInfo(), true); + d->setReplayGainInfo(rg.replayGainInfo()); } return d; } diff --git a/src/qmmp/decoder.cpp b/src/qmmp/decoder.cpp index 1ef5c672a..702031551 100644 --- a/src/qmmp/decoder.cpp +++ b/src/qmmp/decoder.cpp @@ -21,16 +21,14 @@ extern "C" Decoder::Decoder(QIODevice *input) : m_input(input) { m_hasMetaData = false; - m_hasHeadroom = false; } Decoder::~Decoder() {} -void Decoder::setReplayGainInfo(const QMap<Qmmp::ReplayGainKey, double> &rg, bool headroom) +void Decoder::setReplayGainInfo(const QMap<Qmmp::ReplayGainKey, double> &rg) { m_rg = rg; - m_hasHeadroom = headroom; } void Decoder::configure(quint32 srate, const ChannelMap &map, Qmmp::AudioFormat format) @@ -86,11 +84,6 @@ bool Decoder::hasMetaData() const return m_hasMetaData; } -bool Decoder::hasHeadroom() const -{ - return m_hasHeadroom; -} - QMap<Qmmp::MetaData, QString> Decoder::takeMetaData() { m_hasMetaData = false; diff --git a/src/qmmp/decoder.h b/src/qmmp/decoder.h index 1dc8411ae..799c8d2da 100644 --- a/src/qmmp/decoder.h +++ b/src/qmmp/decoder.h @@ -95,10 +95,8 @@ public: /*! * Sets ReplayGain information. Use this function before playback. * @param rg ReplayGain information - * @param headroom Indicates that decoder allows peak overflow. - * In this case the decoder should support float output. */ - void setReplayGainInfo(const QMap<Qmmp::ReplayGainKey,double> &rg, bool headroom = false); + void setReplayGainInfo(const QMap<Qmmp::ReplayGainKey,double> &rg); /*! * Returns QIODevice-based input source assigned for this decoder. */ @@ -114,10 +112,6 @@ public: */ bool hasMetaData() const; /*! - * Returns \b true if a decoder allows peak overflow, otherwise returns \b false. - */ - bool hasHeadroom() const; - /*! * Takes metadata out of decoder and returns it. * Attention: hasMetaData() should return \b true before use of this fuction. */ @@ -195,7 +189,6 @@ private: AudioParameters m_parameters; QIODevice *m_input; bool m_hasMetaData; - bool m_hasHeadroom; QMap<Qmmp::MetaData, QString> m_metaData; QMap <Qmmp::ReplayGainKey, double> m_rg; //replay gain information }; diff --git a/src/qmmp/qmmpaudioengine.cpp b/src/qmmp/qmmpaudioengine.cpp index 089a64891..74fcce793 100644 --- a/src/qmmp/qmmpaudioengine.cpp +++ b/src/qmmp/qmmpaudioengine.cpp @@ -360,7 +360,7 @@ void QmmpAudioEngine::run() } m_decoder = m_decoders.dequeue(); addOffset(); //offset - m_replayGain->setReplayGainInfo(m_decoder->replayGainInfo(), m_decoder->hasHeadroom()); + //m_replayGain->setReplayGainInfo(m_decoder->replayGainInfo(), m_decoder->hasHeadroom()); mutex()->unlock(); m_output->start(); StateHandler::instance()->dispatch(Qmmp::Buffering); @@ -432,7 +432,7 @@ void QmmpAudioEngine::run() StateHandler::instance()->dispatch(Qmmp::Buffering); m_decoder->next(); StateHandler::instance()->dispatch(m_decoder->totalTime()); - m_replayGain->setReplayGainInfo(m_decoder->replayGainInfo(), m_decoder->hasHeadroom()); + //m_replayGain->setReplayGainInfo(m_decoder->replayGainInfo(), m_decoder->hasHeadroom()); m_output->mutex()->lock(); m_output->seek(0); //reset counter m_output->mutex()->unlock(); @@ -447,7 +447,7 @@ void QmmpAudioEngine::run() delete m_decoder; m_decoder = m_decoders.dequeue(); //m_seekTime = m_inputs.value(m_decoder)->offset(); - m_replayGain->setReplayGainInfo(m_decoder->replayGainInfo(), m_decoder->hasHeadroom()); + //m_replayGain->setReplayGainInfo(m_decoder->replayGainInfo(), m_decoder->hasHeadroom()); //use current output if possible prepareEffects(m_decoder); if(m_ap == m_output->audioParameters()) |
