changeset 717:c2b9b781f006

Merge from branch "tony_integration"
author Chris Cannam
date Fri, 09 May 2014 17:54:16 +0100
parents 0db5796a41da (current diff) c63a27614970 (diff)
children d333705f6c29
files
diffstat 7 files changed, 118 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/.hgsubstate	Fri Apr 11 23:30:52 2014 -0700
+++ b/.hgsubstate	Fri May 09 17:54:16 2014 +0100
@@ -1,5 +1,5 @@
 236814e07bd07473958c1ff89103124536a0c3c8 dataquay
 3c5adc4a864fa75e5b1e67c260b77541aaa4f1f6 sv-dependency-builds
-46b24009ce7a633a5150592720e192481e5adbb6 svapp
-bc0ff66102a8c52cb2b8b296ce1006207812ad4b svcore
-8b614632568c353c01d2a7e5c48ee9bb98a4ecea svgui
+8d7f39df44edefb923903325ea0e813004953d86 svapp
+c48b07b34cb329e28d342d777164f7eabbccbae5 svcore
+734ee80286c33f445b0584e077344a7e3862e1a2 svgui
--- a/CHANGELOG	Fri Apr 11 23:30:52 2014 -0700
+++ b/CHANGELOG	Fri May 09 17:54:16 2014 +0100
@@ -1,3 +1,32 @@
+
+Changes in Sonic Visualiser 2.4 since the previous release 2.3:
+
+ - Make the octave numbering into a configurable option, and change
+   the default. Previously Sonic Visualiser labelled middle-C as "C3";
+   now it labels middle-C as "C4", a more common standard in the world
+   outside MIDI sequencer software. The previous system available as
+   an option in the Preferences. This affects only the visible labels:
+   there is no change to analysis or to the file format
+
+ - Sonify time-value layers. Any time-value curve whose scale unit is
+   set to Hz will now acquire a playback toggle control; this control
+   is off by default, but if it is switched on, the curve will be
+   played back using a variable-frequency sound generator
+
+ - Add support for playback of note layers with non-MIDI frequencies
+   (formerly the note playback was limited to exact MIDI pitch)
+
+ - Change the default playback sample for note layers from piano to an
+   electric piano with sustain. The piano sample is still available,
+   and any sessions saved using it should continue to use it
+
+ - Shade the start and end of the main audio file, to make them easier
+   to see for files that start or end in silence
+
+ - Speed up rendering and scrolling in time-value layers
+
+ - Make it possible to import CSV files directly into Note layers by
+   adding Pitch as a data type in the CSV file import dialog
 
 
 Changes in Sonic Visualiser 2.3 since the previous release 2.2:
@@ -24,7 +53,7 @@
 
  - Permit installation to non-default location with Windows installer
    build
-	
+
 
 Changes in Sonic Visualiser 2.2 since the previous release 2.1:
 
--- a/main/MainWindow.cpp	Fri Apr 11 23:30:52 2014 -0700
+++ b/main/MainWindow.cpp	Fri May 09 17:54:16 2014 +0100
@@ -145,8 +145,6 @@
     m_rightButtonTransformsMenu(0),
     m_rightButtonPlaybackMenu(0),
     m_soloAction(0),
-    m_soloModified(false),
-    m_prevSolo(false),
     m_rwdStartAction(0),
     m_rwdSimilarAction(0),
     m_rwdAction(0),
@@ -156,6 +154,8 @@
     m_playAction(0),
     m_playSelectionAction(0),
     m_playLoopAction(0),
+    m_soloModified(false),
+    m_prevSolo(false),
     m_playControlsSpacer(0),
     m_playControlsWidth(0),
     m_preferencesDialog(0),
@@ -403,7 +403,7 @@
         m_scrollLeftAction, m_scrollRightAction, m_showPropertyBoxesAction
     };
 
-    for (int i = 0; i < sizeof(acts)/sizeof(acts[0]); ++i) {
+    for (int i = 0; i < int(sizeof(acts)/sizeof(acts[0])); ++i) {
         sc = new QShortcut(acts[i]->shortcut(), ps);
         connect(sc, SIGNAL(activated()), acts[i], SLOT(trigger()));
     }
@@ -454,6 +454,7 @@
     action->setShortcut(tr("Ctrl+O"));
     action->setStatusTip(tr("Open a session file, audio file, or layer"));
     connect(action, SIGNAL(triggered()), this, SLOT(openSomething()));
+    m_keyReference->registerShortcut(action);
     toolbar->addAction(action);
     menu->addAction(action);
 
@@ -946,7 +947,7 @@
     action->setStatusTip(tr("Show times and basic scale"));
     connect(action, SIGNAL(triggered()), this, SLOT(showMinimalOverlays()));
     action->setCheckable(true);
-    action->setChecked(mode == ViewManager::MinimalOverlays);
+    action->setChecked(mode == ViewManager::StandardOverlays);
     overlayGroup->addAction(action);
     m_keyReference->registerShortcut(action);
     menu->addAction(action);
@@ -2070,11 +2071,10 @@
     toolbar = addToolBar(tr("Edit Toolbar"));
     CommandHistory::getInstance()->registerToolbar(toolbar);
 
-    m_keyReference->setCategory(tr("Tool Selection"));
-
     toolbar = addToolBar(tr("Tools Toolbar"));
     QActionGroup *group = new QActionGroup(this);
 
+    m_keyReference->setCategory(tr("Tool Selection"));
     QAction *action = toolbar->addAction(il.load("navigate"),
                                          tr("Navigate"));
     action->setCheckable(true);
@@ -2086,7 +2086,23 @@
     group->addAction(action);
     m_keyReference->registerShortcut(action);
     m_toolActions[ViewManager::NavigateMode] = action;
-
+    
+    m_keyReference->setCategory
+        (tr("Navigate Tool Mouse Actions"));
+    m_keyReference->registerShortcut
+        (tr("Navigate"), tr("Left"), 
+         tr("Click left button and drag to move around"));
+    m_keyReference->registerShortcut
+        (tr("Zoom to Area"), tr("Shift+Left"), 
+         tr("Shift-click left button and drag to zoom to a rectangular area"));
+    m_keyReference->registerShortcut
+        (tr("Relocate"), tr("Double-Click Left"), 
+         tr("Double-click left button to jump to clicked location"));
+    m_keyReference->registerShortcut
+        (tr("Edit"), tr("Double-Click Left"), 
+         tr("Double-click left button on an item to edit it"));
+
+    m_keyReference->setCategory(tr("Tool Selection"));
     action = toolbar->addAction(il.load("select"),
 				tr("Select"));
     action->setCheckable(true);
@@ -2096,7 +2112,26 @@
     group->addAction(action);
     m_keyReference->registerShortcut(action);
     m_toolActions[ViewManager::SelectMode] = action;
-
+        
+    m_keyReference->setCategory
+        (tr("Select Tool Mouse Actions"));
+    m_keyReference->registerShortcut
+        (tr("Select"), tr("Left"), 
+         tr("Click left button and drag to select region; drag region edge to resize"));
+#ifdef Q_OS_MAC
+    m_keyReference->registerShortcut
+        (tr("Multi Select"), tr("Ctrl+Left"), 
+         tr("Cmd-click left button and drag to select an additional region"));
+#else
+    m_keyReference->registerShortcut
+        (tr("Multi Select"), tr("Ctrl+Left"), 
+         tr("Ctrl-click left button and drag to select an additional region"));
+#endif
+    m_keyReference->registerShortcut
+        (tr("Fine Select"), tr("Shift+Left"), 
+        tr("Shift-click left button and drag to select without snapping to items or grid"));
+
+    m_keyReference->setCategory(tr("Tool Selection"));
     action = toolbar->addAction(il.load("move"),
 				tr("Edit"));
     action->setCheckable(true);
@@ -2107,7 +2142,17 @@
     group->addAction(action);
     m_keyReference->registerShortcut(action);
     m_toolActions[ViewManager::EditMode] = action;
-
+    
+    m_keyReference->setCategory
+        (tr("Edit Tool Mouse Actions"));
+    m_keyReference->registerShortcut
+        (tr("Move"), tr("Left"), 
+        tr("Click left button on an item or selected region and drag to move"));
+    m_keyReference->registerShortcut
+        (tr("Edit"), tr("Double-Click Left"), 
+        tr("Double-click left button on an item to edit it"));
+
+    m_keyReference->setCategory(tr("Tool Selection"));
     action = toolbar->addAction(il.load("draw"),
 				tr("Draw"));
     action->setCheckable(true);
@@ -2119,6 +2164,13 @@
     m_keyReference->registerShortcut(action);
     m_toolActions[ViewManager::DrawMode] = action;
 
+    m_keyReference->setCategory
+        (tr("Draw Tool Mouse Actions"));
+    m_keyReference->registerShortcut
+        (tr("Draw"), tr("Left"), 
+        tr("Click left button and drag to create new item"));
+
+    m_keyReference->setCategory(tr("Tool Selection"));
     action = toolbar->addAction(il.load("erase"),
 				tr("Erase"));
     action->setCheckable(true);
@@ -2130,6 +2182,13 @@
     m_keyReference->registerShortcut(action);
     m_toolActions[ViewManager::EraseMode] = action;
 
+    m_keyReference->setCategory
+        (tr("Erase Tool Mouse Actions"));
+    m_keyReference->registerShortcut
+        (tr("Erase"), tr("Left"), 
+        tr("Click left button on an item to remove it from the layer"));
+
+    m_keyReference->setCategory(tr("Tool Selection"));
     action = toolbar->addAction(il.load("measure"), tr("Measure"));
     action->setCheckable(true);
     action->setShortcut(tr("6"));
@@ -2140,6 +2199,18 @@
     m_keyReference->registerShortcut(action);
     m_toolActions[ViewManager::MeasureMode] = action;
 
+    m_keyReference->setCategory
+        (tr("Measure Tool Mouse Actions"));
+    m_keyReference->registerShortcut
+        (tr("Measure Area"), tr("Left"), 
+        tr("Click left button and drag to measure a rectangular area"));
+    m_keyReference->registerShortcut
+        (tr("Measure Item"), tr("Double-Click Left"), 
+        tr("Click left button and drag to measure extents of an item or shape"));
+    m_keyReference->registerShortcut
+        (tr("Zoom to Area"), tr("Shift+Left"), 
+        tr("Shift-click left button and drag to zoom to a rectangular area"));
+
     toolNavigateSelected();
 
     Pane::registerShortcuts(*m_keyReference);
@@ -2650,7 +2721,7 @@
         if (!nm) {
             error = tr("Can't export non-note layers to MIDI");
         } else {
-            MIDIFileWriter writer(path, nm);
+            MIDIFileWriter writer(path, nm, nm->getSampleRate());
             writer.write();
             if (!writer.isOK()) {
                 error = writer.getError();
--- a/main/OSCHandler.cpp	Fri Apr 11 23:30:52 2014 -0700
+++ b/main/OSCHandler.cpp	Fri May 09 17:54:16 2014 +0100
@@ -349,7 +349,7 @@
                 if (value < 0.5) {
                     m_viewManager->setOverlayMode(ViewManager::NoOverlays);
                 } else if (value < 1.5) {
-                    m_viewManager->setOverlayMode(ViewManager::MinimalOverlays);
+                    m_viewManager->setOverlayMode(ViewManager::StandardOverlays);
                 } else {
                     m_viewManager->setOverlayMode(ViewManager::AllOverlays);
                 }                    
--- a/samples/README	Fri Apr 11 23:30:52 2014 -0700
+++ b/samples/README	Fri May 09 17:54:16 2014 +0100
@@ -1,2 +1,3 @@
 Samples from standard Hydrogen drum machine kits, except for piano.wav
-(ancestry unknown) and click.wav (random noise).
+(ancestry unknown), elecpiano.wav (recorded by Matthias Mauch) and
+click.wav (random noise).
Binary file samples/elecpiano.wav has changed
--- a/sonic-visualiser.qrc	Fri Apr 11 23:30:52 2014 -0700
+++ b/sonic-visualiser.qrc	Fri May 09 17:54:16 2014 +0100
@@ -104,6 +104,7 @@
     <file>samples/clap.wav</file>
     <file>samples/click.wav</file>
     <file>samples/cowbell.wav</file>
+    <file>samples/elecpiano.wav</file>
     <file>samples/hihat.wav</file>
     <file>samples/kick.wav</file>
     <file>samples/organ.wav</file>