1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-21 06:40:08 +02:00

308 Commits

Author SHA1 Message Date
david avery
0319f6ea51 merging wx3 changes 2015-04-12 23:52:32 -06:00
Paul-Licameli
7d6de21e3a Enh809 - Add persistency of spectral selections, including those in labels 2015-04-10 15:20:50 -04:00
Paul-Licameli
5d19887da6 Bug812 - Vertical scrollbar position should be persistent too, as is horizontal
Effective but perhaps inelegant fix.
2015-04-10 15:20:32 -04:00
Leland Lucius
2457579091 Bug 765 - Delays using Edit commands and Draw Tool in long projects
A 4hr track used to take about 20s to cut a few samples. This is now significantly improved, to around 3s. Leland did this by

(a) moving the size calculation to when we examine the undo history, so it isn't slowing down the edits.
(b) in size calculation, using sizes that are cached rather than going to disk to find the sizes.
(c) writing the autosave file which is to an FFIle to a string first, i.e. using XMLStringWriter as a buffer for XMLFileWriter.

Step (c) may also make autosave marginally safer, as the risk of a partially updated autosave file is reduced.
2015-04-07 12:20:50 +01:00
Paul Licameli
e9537fccb8 Bug897 - Time ruler is not redrawn for zoom or horizontal scroll when play region is locked
Added a Refresh() to fix this.
2015-04-05 22:27:35 +01:00
lllucius
f60afbb8da Fix disk space checking to prevent error message
The error message only happens in debug builds, but the cause of
the message still happens in release builds.  Basically, the temporary
project directory may not yet be created if the person is only monitoring.
2015-01-06 16:16:01 +00:00
stevethefiddle@gmail.com
c8cabab88b Better fix for bug 802. 2015-01-05 11:07:55 +00:00
lllucius
f5f3c5135f Make sure display refreshes after audio I/O stops
What looked simple in r13811 was not so simple apparently.
(We REALLY need a gAudioIO->IsCapturing())
2014-12-29 22:28:32 +00:00
lllucius
204aa37716 Only push state if recording, not when monitoring 2014-12-29 20:26:07 +00:00
lllucius
c305724561 Fix for bug #806
This was my bad.  I'd reset the number of capture channels
in AudioIO when the stream was stopped.  Unfortunately, two
methods depended on it being valid AFTER the stream had
stopped.

Those methods, TrackPanel::OnTimer and AudacityProjecT::OnCloseWindow,
were using it as an indicator if recording had been taking place
before they stopped the stream.  They then flushed the tracks, pushed
the state onto the undo stack and did some other post-recording tasks.

Turns out that the tracks are already flushed as part of the normal
AudioIO::StopStream processing, so that was redundant.

And, instead of duplicating the process, I've relocated most of each
methods processing to AudacityProject::OnAudioIOStopRecording.
2014-12-28 08:53:57 +00:00
lllucius
9bbc261321 Attempt #2 at taming the meter toolbars
It corrects several "multiple project" problems with the
meter toolbars and meters.

In addition, there was a "multiple project" issue where
the transport buttons didn't disable properly in the
non-active project.
2014-12-19 16:38:56 +00:00
lllucius
fe42e881a5 First stab at taming the meter toolbars
This should correct at least a couple of the reported
issues.  And it also has some fixes in for multiple
project support.
2014-12-17 19:16:08 +00:00
lllucius
a0370e8faa Fix for startup crash on Windows 8
Don't know why it didn't crash on w7...should have...
2014-12-08 14:32:56 +00:00
lllucius
6539d693b3 Fix for bug #783
This should correct the crash and will also correct
the problem where one project's playback/capture was
being metered in another project if multiple projects
were open.
2014-12-08 04:53:53 +00:00
lllucius
4b756ce7d6 Give the keyboard user the ability to move among all modeless windows
With realtime preview, the keyboard user will need this to get
back and forth between the effect and the project window.  Actualy,
the "problem" existed before this since the keyboard user couldn't
switch between project and Plot Spectrum windows.

The normal flags-based keyboard handling would not work since it
depends on the state of the project and requires a project window
to have the current focus.

In this new case, a modeless dialog may actually have the focus and
using the "switch window" key combo may happen in nearly any mode, like
while playing.

So, I "created" the concept of "meta" commands...ones that do not have
the restrictions mentioned above.  The should be used sparingly and
you must be careful about what happens within their handlers.
2014-11-26 18:17:38 +00:00
james.k.crook@gmail.com
703fafacb2 Frequency-selection aware noise reduction, plus small adjustments to toolbar and effect. (patch from Paul Licameli)
1. Change in project.cpp fixes misbehavior of spectral selection toolbar,
when you try to enter numbers in the low or high frequency boxes and one of
the frequencies was undefined.

2. Changes in NoiseReduction.cpp now take the spectral selection into
account in step 2, so that noise is reduced (or isolated) only in the
selected range of frequencies.  No effect on statistics gathered in step 1.

3. Other noise reduction changes:  avoid an assertion in case of certain
incompatible settings, and end all messages in message boxes consistently
with a period.
2014-11-11 18:02:31 +00:00
james.k.crook@gmail.com
65a75fafb4 Project window height tweak, following feedback. 2014-11-09 10:38:41 +00:00
james.k.crook@gmail.com
0d34f0835d Taller window to go with window being wider.
We're agreed we want a wider window by default.  Some experimenting still to do with what to show by default, how much space to use, and in what order.
2014-11-08 23:32:33 +00:00
james.k.crook@gmail.com
d9d193a1ea Wider Audacity and wider meters, now that we are agreed 1000px is fine for a minimum width.
This entailed rearranging the toolbar order.  I've set the width to 940px, but am tempted to take it all the way to 1000.
2014-11-08 18:51:00 +00:00
james.k.crook@gmail.com
67d2b274e2 Frequency Selection toolbar from Paul Licameli.
Linux/Mac will need new files adding to project, SpectralSelectionBar.cpp, NumericTextCtrl.cpp.
2014-11-08 15:18:43 +00:00
lllucius
1eeb4d979a The fabled realtime effects...
I've made it where you can enable and disable via experimentals:

EXPERIMENTAL_REALTIME_EFFECTS
EXPERIMENTAL_EFFECTS_RACK

You will notice that, as of now, the only effects currently set up for
realtime are VSTs.  Now that this is in, I will start converting the
rest.

As I start to convert the effects, the astute of you may notice that
they no longer directly access tracks or any "internal" Audacity
objects.  This isolates the effects from changes in Audacity and makes
it much easier to add new ones.

Anyway, all 3 platforms can now display VST effects in graphical mode.
Yes, that means Linux too.  There are quite a few VSTs for Linux if
you search for them.

The so-called "rack" definitely needs some discussion, work, and attention
from someone much better at graphics than me.  I'm not really sure it should
stay in as-is.  I'd originally planned for it to be simply a utility window
where you can store your (preconfigured) favorite effects.  It should probably
revert back to that idea.

You may notice that this DOES include the API work I did.  The realtime effects
were too tied to it and I didn't want to redo the whole thing.  As I mentioned
elsewhere, the API stuff may or may not be very future proof.

So, let the critter complaints commence.  I absolute KNOW there will be some.
(I know I'll be hearing from the Linux peeps pretty darn quickly.  ;-))
2014-10-26 03:24:10 +00:00
james.k.crook@gmail.com
7508f10f64 Fixed some memory leaks. 2014-10-24 16:52:17 +00:00
james.k.crook@gmail.com
37608c2290 Paul Licameli's Spectral Editing Patch.
This relies on three new nyquist scripts to actually do the editing.  The peak-snapping code in FrequencyWindow has been extracted into a new class, SpectrumAnalyst, to provide peak-snapping in spectrogram too.
2014-10-18 14:19:38 +00:00
lllucius
c512822138 Additional changes for wx3
These are mostly for getting it to build on Linux, but I've
also created new configs in Visual Studio to make it easier
to switch between wx2 and wx3.

For Linux, you have to tell configure where to find the wx3
version of the wx-config script and, since some distros build
wxWidgets v3 against GTK+ v3, you may also need to enable
gtk3 with something like:

./configure --enable-gtk3 WX_CONFIG=/usr/bin/wx-config-3.0

On Windows, I've added "wx3-Debug" and "wx3-Release" to the
existing "Debug" and "Release" configurations.

They depend on you having your WXWIN environment variable
pointing to your wx2 directory and a new WXWIN3 environment
variable pointing to your wx3 directory.  For instance, I
have:

WXWIN=C:\Users\yam\Documents\wxWidgets-2.8.13
WXWIN3=C:\Users\yam\Documents\wxWidgets-3.0.2

Doing this allows you to switch freely among the 4 configurations
without having to get out of Visual Studio and monkey around with
the environment.

The project files will also add the location of the wxWidgets DLLs
to the PATH when running Audacity from within Visual Studio.  They
add %WXWIN%\lib\vc_dll or %WXWIN3%\lib\vc_dll at the beginning
of the PATH variable as appropriate.

I expect that once we convert to wx3 we'll just drop back down to
the normal Debug and Release configurations, but this should make
switching between wx2 and wx3 much easier during the transition.
2014-10-16 16:18:04 +00:00
lllucius
bdcefb4850 Preliminary changes for wxWidgets 3.0.1
We can't go to 3.0.1 yet as there are still build issues on
Linux and OSX.  You can get Windows to build, but there's
still some display issues.

These changes should work with wxWidgets 2.8.12 as well, so
we can take our time to get things working properly before
switching over.
2014-10-06 08:10:50 +00:00
james.k.crook@gmail.com
f5e593cc4c Paul L's new SelectedRegion class replacing use of t0 and t1. Also LabelTrack.h no longer in TrackPanel.h includes.
This change is believed to be a direct refactoring that does not change functionality.  It paves the way for more complex kinds of selection, such as selections involving frequency as well as time.  It also reduces risk of left and right edges being swapped in future code using SelectedRegion, as the default is to swap on assignment if needed.
2014-10-05 17:10:09 +00:00
james.k.crook@gmail.com
b19c1fbeb5 Applied Paul L's patch for save/restore (and compiler warning). Fix for http://bugzilla.audacityteam.org/show_bug.cgi?id=283 2014-08-17 16:32:57 +00:00
v.audacity
c39269bf4a Austin Boyle's patch for Bug 473 - Track can be in "Solo" mode when there is no solo button 2014-08-01 18:59:07 +00:00
RichardAsh1981@gmail.com
59b8cdeaa8 separate out Help system functions into their own source file (pending some extra ones) and change the required includes to accomodate this. As a result, some error class definitions have to move from .cpp file to .h file. 2014-06-06 21:34:36 +00:00
benjamin.drung@gmail.com
277932dccb Remove trailing spaces. 2014-06-03 20:30:19 +00:00
james.k.crook@gmail.com
6fc830c0b6 Added Steve Parry's patch that adds the Open and SaveAs commands to scripting. 2014-01-13 22:12:20 +00:00
martynshaw99
65e4f56126 Norm's patch to improve selection speed on large projects by reducing the number of unnecessary auto-saves. Maybe vertical zooming should also not trigger an auto-save? 2013-12-30 00:41:18 +00:00
v.audacity
3b124e902d Leland's patch for http://bugzilla.audacityteam.org/show_bug.cgi?id=275, " Snap-To status/quantisation are global, leading to incorrect indications in multiple projects". 2013-12-18 22:54:57 +00:00
v.audacity
568ceeb47f bug fix patch from Eric Lubin: "...where a check accidentally does not dereference a pointer to a bool, instead checking whether or not the pointer is non-null." from "Fixed bug in Project.cpp Where Bool Isn't Dereferenced Properly" thread on -devel. 2013-12-13 01:15:12 +00:00
v.audacity
bf2bc01b64 Steve's patch for http://bugzilla.audacityteam.org/show_bug.cgi?id=687
Changes in AudacityProject::SaveAs() warning dialogs, per 'Save Project warning' discussion on audacity-quality, plus some further changes of my own.

Similar changes for 'Save Compressed Project'.

Added Cancel button to both warnings, so user can opt out immediately, rather than have to wait another dialog. 


Added wxMessageBox's best 'warning' icon to our WarningDialog constructor, so it shows in title bar. It's low-rez (32x32), but all that's available with wxWidgets 2.8.12. Easy to remove if too ugly.
2013-11-25 04:59:07 +00:00
lllucius
ce00d5b507 [Bug 647] Snap-To clicks find nearest snap point, not nearest previous.
Convert SnapTo from on/off to a choice of off/nearest/prior.
2013-11-01 14:13:39 +00:00
lllucius
edbb189bf8 Bug 275 - Snap-To status/quantisation are global, leading to incorrect indications in multiple projects
Missed a portion of the patch (when splitting bigger patch into 3)
2013-10-27 02:07:32 +00:00
lllucius
3d95126e0e Bug 275 - Snap-To status/quantisation are global, leading to incorrect indications in multiple projects
This adds (I believe) project specific selection format.
2013-10-27 01:58:35 +00:00
lllucius
3ec8989265 Bug 510 - undo can change which tracks are selected, and focus
Must more extensive review of saving state

Try this one David.  I reviewed all actions in Menus.cpp and have added state
saving where it seemed to be missing.  I had no idea it would be so many (22). 
And that was only reviewing Menus.cpp.  I believe that will get them all since
all keyboard actions are tied to a menu or command action and they all go
through Menus.cpp. (I still have a few to review in TrackPanel.cpp though)
2013-10-23 20:14:09 +00:00
lllucius
5c8baf9c16 Bug 406 - Label creation/other non-dialogue editing and keyboard selection hang on long projects
This is part 2...

Improve performance of selection via Selection bar

This provides a similar type of speed up when selecting with the keyboard via
the Selection toolbar.
2013-10-23 18:06:49 +00:00
lllucius
03f5088b6a Bug 406 - Label creation/other non-dialogue editing and keyboard selection hang on long projects
This is part 1...

Provides some relief to the selection "hang"

This patch adds the ability for the keyboard based commands (like cursor left,
extend selection right, etc.) to know when the key has been released.

When the patch is applied the current state is saved only when the key is
released and not every time it repeats.

Here's an example of the difference it makes.

This video show the selection "hang", but also watch the CPU usage.  All I'm
doing is pressing SHIFT+RIGHT ARROW.

http://youtu.be/tdMntDwGSkM

This one is the same thing bug with the patch applied.  Notice that the
selection "hang" no longer occurs and look at the CPU usage!

http://youtu.be/EpXNsQ4Cky0
2013-10-23 18:01:14 +00:00
lllucius
0bee195b0e Bug 275 - Snap-To status/quantisation are global, leading to incorrect indications in multiple projects
Make Snap To project specific

This makes the Snap To setting in the selection bar project specific.  Changing
it will no longer affect other open projects.

The state is saved to audacity.cfg when the checkbox is changed.  This means
that the next project window to open will start with the new value.  (As it
should be).
2013-10-23 17:47:00 +00:00
lllucius
1fab1cdb21 Bug 337 - New logger class allows log to be initialized immediately without crashing Mac empty project windows
This is an older one...originally from 2011.  Bug says it all, but basically it allows logging
to begin immediately upon startup for all platforms.  And it has multithreading protection, so
it should now be safe to log from the non-GUI threads.
2013-10-23 17:00:28 +00:00
lllucius
f1bd685c55 Fixes bug #370
http://bugzilla.audacityteam.org/show_bug.cgi?id=370
2013-10-08 19:40:45 +00:00
RichardAsh1981@gmail.com
07a9789ec5 make functions which do not require access to class member variables static so they can be called without an object to do so with. Based on part of a patch by Campbell Barton 2013-09-21 19:34:12 +00:00
RichardAsh1981@gmail.com
61de872bf2 Make a large number of global variables static so they only have file scope when that is all they need. Part of a patch by Campbell Barton 2013-09-21 19:30:00 +00:00
RichardAsh1981@gmail.com
2952017541 Delete a quantity of unused variables, based on a patch supplied by Campbell Barton 2013-09-12 16:48:55 +00:00
v.audacity
cc876ce7be just some cleanups on FIXMEs and unused method parameters 2013-08-31 05:57:48 +00:00
james.k.crook@gmail.com
dba81b3f1c Cleanup: Fixed lots of trivial MSVC warnings. 2013-08-25 21:51:26 +00:00
v.audacity
c7daafede2 In off-list discussion, Steve mentioned that kdevelop / kate highlighting recognizes "FIXME", but not "FIX-ME", which has been the Audacity convention. This commit changes Audacity code to use the "FIXME" convention (though I've never known it as convention and MSVC doesn't recognize it).
Also, minor change in WaveTrack.cpp in the effort on bug 641. Should have no functional difference.
2013-08-24 20:30:47 +00:00