summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBe <be@mixxx.org>2021-03-15 21:47:51 -0500
committerBe <be@mixxx.org>2021-03-16 12:47:09 -0500
commitf2ecd5380be154861c9542a4d69b664c70e8f0a5 (patch)
treed33afbc19b8b16abf77def86fe0f6ba3a2311ce5
parent8c306045df0727c1c7a9ce6c9fc1e4183105004b (diff)
SoundManager: remove erroneous warning and add debug assertion
Vinyl control inputs are registered twice, once for timecode and once for passthrough, each with different outputs.
-rw-r--r--src/soundio/soundmanager.cpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/soundio/soundmanager.cpp b/src/soundio/soundmanager.cpp
index eb204e883e..3aa42f2f07 100644
--- a/src/soundio/soundmanager.cpp
+++ b/src/soundio/soundmanager.cpp
@@ -623,20 +623,17 @@ void SoundManager::readProcess() const {
}
void SoundManager::registerOutput(const AudioOutput& output, AudioSource* src) {
- if (m_registeredSources.contains(output)) {
- qDebug() << "WARNING: AudioOutput already registered!";
+ VERIFY_OR_DEBUG_ASSERT(!m_registeredSources.contains(output)) {
+ return;
}
m_registeredSources.insert(output, src);
emit outputRegistered(output, src);
}
void SoundManager::registerInput(const AudioInput& input, AudioDestination* dest) {
- if (m_registeredDestinations.contains(input)) {
- // note that this can be totally ok if we just want a certain
- // AudioInput to be going to a different AudioDest -bkgood
- qDebug() << "WARNING: AudioInput already registered!";
- }
-
+ // Vinyl control inputs are registered twice, once for timecode and once for
+ // passthrough, each with different outputs. So unlike outputs, do not assert
+ // that the input has not been registered yet.
m_registeredDestinations.insert(input, dest);
emit inputRegistered(input, dest);