Mercurial > hg > svapp
changeset 340:c11701af6bb4 tony_integration
Merge from branch tonioni
author | Chris Cannam |
---|---|
date | Wed, 02 Apr 2014 08:51:51 +0100 |
parents | b2ca08d16293 (diff) dd07d48d7d4f (current diff) |
children | a4b8f0864835 |
files | |
diffstat | 4 files changed, 28 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/audioio/PlaySpeedRangeMapper.cpp Tue Apr 01 13:27:44 2014 +0100 +++ b/audioio/PlaySpeedRangeMapper.cpp Wed Apr 02 08:51:51 2014 +0100 @@ -34,6 +34,13 @@ } int +PlaySpeedRangeMapper::getPositionForValueUnclamped(float value) const +{ + // We don't really provide this + return getPositionForValue(value); +} + +int PlaySpeedRangeMapper::getPositionForFactor(float factor) const { bool slow = (factor > 1.0); @@ -65,6 +72,13 @@ } float +PlaySpeedRangeMapper::getValueForPositionUnclamped(int position) const +{ + // We don't really provide this + return getValueForPosition(position); +} + +float PlaySpeedRangeMapper::getValueForFactor(float factor) const { float pc;
--- a/audioio/PlaySpeedRangeMapper.h Tue Apr 01 13:27:44 2014 +0100 +++ b/audioio/PlaySpeedRangeMapper.h Wed Apr 02 08:51:51 2014 +0100 @@ -24,7 +24,10 @@ PlaySpeedRangeMapper(int minpos, int maxpos); virtual int getPositionForValue(float value) const; + virtual int getPositionForValueUnclamped(float value) const; + virtual float getValueForPosition(int position) const; + virtual float getValueForPositionUnclamped(int position) const; int getPositionForFactor(float factor) const; float getValueForFactor(float factor) const;
--- a/framework/MainWindowBase.cpp Tue Apr 01 13:27:44 2014 +0100 +++ b/framework/MainWindowBase.cpp Wed Apr 02 08:51:51 2014 +0100 @@ -133,7 +133,6 @@ #endif MainWindowBase::MainWindowBase(bool withAudioOutput, - bool withOSCSupport, bool withMIDIInput) : m_document(0), m_paneStack(0), @@ -254,12 +253,6 @@ if (withMIDIInput) { m_midiInput = new MIDIInput(QApplication::applicationName(), this); } - - if (withOSCSupport) { - m_oscQueueStarter = new OSCQueueStarter(this); - connect(m_oscQueueStarter, SIGNAL(finished()), this, SLOT(oscReady())); - m_oscQueueStarter->start(); - } } MainWindowBase::~MainWindowBase() @@ -270,6 +263,7 @@ delete m_playSource; delete m_viewManager; delete m_oscQueue; + delete m_oscQueueStarter; delete m_midiInput; Profiles::getInstance()->dump(); } @@ -285,6 +279,14 @@ } void +MainWindowBase::startOSCQueue() +{ + m_oscQueueStarter = new OSCQueueStarter(this); + connect(m_oscQueueStarter, SIGNAL(finished()), this, SLOT(oscReady())); + m_oscQueueStarter->start(); +} + +void MainWindowBase::oscReady() { if (m_oscQueue && m_oscQueue->isOK()) {
--- a/framework/MainWindowBase.h Tue Apr 01 13:27:44 2014 +0100 +++ b/framework/MainWindowBase.h Wed Apr 02 08:51:51 2014 +0100 @@ -75,7 +75,7 @@ Q_OBJECT public: - MainWindowBase(bool withAudioOutput, bool withOSCSupport, bool withMIDIInput); + MainWindowBase(bool withAudioOutput, bool withMIDIInput); virtual ~MainWindowBase(); enum AudioFileOpenMode { @@ -309,6 +309,7 @@ OSCQueue *m_oscQueue; OSCQueueStarter *m_oscQueueStarter; + void startOSCQueue(); MIDIInput *m_midiInput;