Mercurial > hg > sonic-visualiser
changeset 1056:25e1cc4f34eb recording
Add audio record mode (option to replace session) and support for browsing to record directory
author | Chris Cannam |
---|---|
date | Tue, 15 Sep 2015 16:34:08 +0100 |
parents | 7cda09a99a79 |
children | 65d3025e9544 |
files | .hgsubstate main/MainWindow.cpp main/MainWindow.h |
diffstat | 3 files changed, 25 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/.hgsubstate Thu Aug 20 12:22:17 2015 +0100 +++ b/.hgsubstate Tue Sep 15 16:34:08 2015 +0100 @@ -3,6 +3,6 @@ 94b6ebd5e8ab897e5b294fd77b4113e8d6d78b13 bqvec d16f0fd6db6104d87882bc43788a3bb1b0f8c528 dataquay 55ece8862b6d3a54aad271a53f9c1615e5d3bcf8 sv-dependency-builds -1d4cb8befcfd5212006da0fd455dbd79d8dfdcd2 svapp +493f2af85497469f6682a80c172942493e5fb527 svapp 133747edd76c133fb3f0afd8524a9890c898a368 svcore 7dcd035176851a9f13539d852ccec828a37d2863 svgui
--- a/main/MainWindow.cpp Thu Aug 20 12:22:17 2015 +0100 +++ b/main/MainWindow.cpp Tue Sep 15 16:34:08 2015 +0100 @@ -303,6 +303,8 @@ m_activityLog->hide(); m_unitConverter->hide(); + + setAudioRecordMode(RecordCreateAdditionalModel); newSession(); @@ -589,6 +591,13 @@ menu->addSeparator(); + action = new QAction(tr("Browse Recorded Audio Folder"), this); + action->setStatusTip(tr("Open the Recorded Audio folder in the system file browser")); + connect(action, SIGNAL(triggered()), this, SLOT(browseRecordedAudio())); + menu->addAction(action); + + menu->addSeparator(); + QString templatesMenuLabel = tr("Apply Session Template"); m_templatesMenu = menu->addMenu(templatesMenuLabel); m_templatesMenu->setTearOffEnabled(true); @@ -2048,6 +2057,7 @@ } m_keyReference->registerShortcut(m_playAction); + m_keyReference->registerShortcut(m_recordAction); m_keyReference->registerShortcut(m_playSelectionAction); m_keyReference->registerShortcut(m_playLoopAction); m_keyReference->registerShortcut(m_soloAction); @@ -2060,6 +2070,7 @@ m_keyReference->registerShortcut(m_ffwdEndAction); menu->addAction(m_playAction); + menu->addAction(m_recordAction); menu->addAction(m_playSelectionAction); menu->addAction(m_playLoopAction); menu->addAction(m_soloAction); @@ -2076,6 +2087,7 @@ menu->addSeparator(); m_rightButtonPlaybackMenu->addAction(m_playAction); + m_rightButtonPlaybackMenu->addAction(m_recordAction); m_rightButtonPlaybackMenu->addAction(m_playSelectionAction); m_rightButtonPlaybackMenu->addAction(m_playLoopAction); m_rightButtonPlaybackMenu->addAction(m_soloAction); @@ -2895,6 +2907,17 @@ } void +MainWindow::browseRecordedAudio() +{ + if (!m_recordTarget) return; + + QString path = m_recordTarget->getRecordFolder(); + if (path == "") return; + + openLocalFolder(path); +} + +void MainWindow::newSession() { if (!checkSaveModified()) return;
--- a/main/MainWindow.h Thu Aug 20 12:22:17 2015 +0100 +++ b/main/MainWindow.h Tue Sep 15 16:34:08 2015 +0100 @@ -59,6 +59,7 @@ virtual void importLayer(); virtual void exportLayer(); virtual void exportImage(); + virtual void browseRecordedAudio(); virtual void saveSession(); virtual void saveSessionAs(); virtual void newSession();