Commit Graph

64 Commits

Author SHA1 Message Date
Paul Licameli 4ca3e7096f
Track factory cleanup (#646)
* Don't need TrackFactory to make LabelTrack

* Don't need TrackFactory to make NoteTrack

* Don't need TrackFactory to make TimeTrack, or ZoomInfo in the factory

* Remove some forward declarations

* Rename TrackFactory as WaveTrackFactory, move it out of Track.cpp
2020-08-22 18:44:49 -05:00
Paul Licameli 83d5c81578 Change a function return from wxString to TranslatableString 2020-05-26 12:04:11 -04:00
Paul Licameli 37d730edfe Break dependency cycle of Effect and EffectManager 2020-03-08 16:21:28 -04:00
James Crook 95bbe617b8 Bug 2343 - Presets: Effect Ids not the same in Presets as for Macros 2020-03-05 22:14:17 +00:00
Paul Licameli bb26b2f2c4 Require a ProjectWindow as ancestor of effect dialog...
... by passing parent as reference, not pointer, and testing in the dialog
factory function.

This is important so that we know the lifetime of an effect dialog, even when
it is non-modal, is bounded by the lifetime of the associated project.
2020-01-06 11:30:47 -05:00
Paul Licameli 91c45dd32a Move static EffectManager::DoEffect into new namespace 2020-01-05 16:11:55 -05:00
Paul Licameli 23a0206d2a Remove CreateUI; pass dialog factory to effect client instead 2020-01-05 16:11:55 -05:00
Paul Licameli 129c9deb99 Remove GetActiveProject from EffectRack...
... and make one EffectRack window per project
2020-01-04 16:36:55 -05:00
Paul Licameli 1f86a77569 TranslatableString for effect command names and descriptions 2019-12-16 10:58:05 -05:00
Paul Licameli aac50ae36e EffectManager returns TranslatableString for family and vendor 2019-12-12 15:30:36 -05:00
Paul Licameli 33f3d4b82d Heavyweight version of SelectedRegion stored in ViewInfo emits events 2019-07-17 12:43:39 -04:00
Paul Licameli ff2cf496cd Move DoEffect out of PluginMenus 2019-06-25 00:14:52 -04:00
Paul Licameli 1c588fa014 Move enum into EffectManager...
... tying Effect into a cycle of 3 with EffectManager and EffectRack, which is
only revealing the true dependencies
2019-06-25 00:12:45 -04:00
Paul Licameli ab5a98003a Free EffectManager and EffectRack from the big s.c.c. ...
... though in a small cycle with each other, by moving RealtimeEffectManager to
new files, which remain in the big component.

Net loss of 1, the big component now has 27 files
2019-06-24 00:49:12 -04:00
Paul Licameli 04a3ed9d04 Separate class RealtimeEffectManager 2019-06-24 00:37:02 -04:00
Paul Licameli 9935b035c5 Remove Effect.h from EffectManager.h and EffectRack.h 2019-06-24 00:36:59 -04:00
Paul Licameli 2e05d2d884 Remove wx/{radiobut,ownerdrw,menuitem,menu,listbox}.h from *.h 2019-03-30 12:15:53 -04:00
Paul Licameli d28ae40399 Remove wx/dialog.h from headers 2019-03-30 12:01:39 -04:00
Paul Licameli 803d8b9559 Remove wx/filename.h, wx/choice.h, wxFileNameWrapper.h from headers 2019-03-28 03:12:42 -04:00
Paul Licameli c3aad2e026 Remove wx/event.h from headers 2019-03-27 04:36:51 -04:00
Paul Licameli 1d0247607a Remove wx/string.h from headers 2019-03-26 11:33:55 -04:00
Paul Licameli 71036bed01 Remove PluginManager.h from other headers 2019-03-17 15:05:19 -04:00
Paul Licameli 5fd6965925 Use type aliases CommandID, CommandIDs...
... for identifiers of menu commands and macros, and for vectors thereof
2019-03-15 15:18:11 -04:00
James Crook 466e9c179e Create ComponentInterface
It combines the old IdentInterface with the ParamsInterface, providing an identifier and parameters (if needed).
The main purpose of the change is to make the class hierarchy (as viewed via doxygen) much easier to follow.
2018-11-02 17:04:43 +00:00
Paul Licameli 7a0475e39f Remove most uses of AUDACITY_OLD_STD 2018-05-10 00:56:36 -04:00
Paul Licameli 11d217076a Remove PluginManager::GetTranslatedVendor()...
... Instead, use the IdentInterfaceSymbol for vendor reported by the effect
2018-04-11 11:13:41 -04:00
Paul Licameli e3c54a769e Use IdentInterfaceSymbol in PluginDescriptor 2018-04-11 11:13:40 -04:00
Paul Licameli 4bfd8abc2b Fix more missed translations 2018-03-08 22:53:00 -05:00
James Crook 1551a5a073 Include tips in command list. 2018-02-24 14:20:25 -05:00
James Crook 1d9477a455 SetClip, SetLabel, SetProject added
- SetTrack also updated with more options.
2018-02-24 14:20:24 -05:00
James Crook ca5dac59ff Support: JSON, Lispy or Other formats 2018-02-24 14:20:23 -05:00
James Crook 1c988b4e3a Automation: AudacityCommand
This is a squash of 50 commits.

This merges the capabilities of BatchCommands and Effects using a new
AudacityCommand class.  AudacityCommand provides one function to specify the
parameters, and then we leverage that one function in automation, whether by chains,
mod-script-pipe or (future) Nyquist.

- Now have AudacityCommand which is using the same mechanism as Effect
- Has configurable parameters
- Has data-entry GUI (built using shuttle GUI)
- Registers with PluginManager.
- Menu commands now provided in chains, and to python batch.
   - Tested with Zoom Toggle.

- ShuttleParams now can set, get, set defaults, validate and specify
the parameters.
- Bugfix: Don't overwrite values with defaults first time out.
- Add DefineParams function for all built-in effects.
- Extend CommandContext to carry output channels for results.

We abuse EffectsManager.  It handles both Effects and
AudacityCommands now.  In time an Effect should become a special case of
AudacityCommand and we'll split and rename the EffectManager class.

- Don't use 'default' as a parameter name.
- Massive renaming for CommandDefinitionInterface
- EffectIdentInterface becomes EffectDefinitionInterface
- EffectAutomationParameters becomes CommandAutomationParameters
- PluginType is now a bit field.

This way we can search for related types at the same time.

- Most old batch commands made into AudacityCommands.
The ones that weren't are for a reason.  They are used by mod-script-pipe
to carry commands and responses across from a non-GUI thread to the GUI
thread.

- Major tidy up of ScreenshotCommand
- Reworking of SelectCommand
- GetPreferenceCommand and SetPreferenceCommand
- GetTrackInfo and SetTrackInfo
- GetInfoCommand
- Help, Open, Save, Import and Export commands.
- Removed obsolete commands ExecMenu, GetProjectInfo and SetProjectInfo
  which are now better handled by other commands.

- JSONify "GetInfo: Commands" output, i.e. commas in the right places.

- General work on better Doxygen.
    - Lyrics -> LyricsPanel
    - Meter -> MeterPanel
- Updated Linux makefile.
- Scripting commands added into Extra menu.
- Distinct names for previously duplicated find-clipping parameters.
- Fixed longstanding error with erroneous status field number which
  previously caused an ASSERT in debug.
- Sensible formatting of numbers in Chains, 0.1 not 0.1000000000137
2018-02-24 14:20:22 -05:00
Paul Licameli 575070e9ae Remove PluginDescriptor::GetTranslatedEffectFamily...
... and instead look it up by ID, and find the effect's family name

Simplifying what was done at 4628d6afa7
2018-02-21 21:43:02 -05:00
Paul Licameli 8be1e8fdad Remove wxArray(Int|Long|Double) except where wxWidgets fns need it 2018-02-21 19:33:31 -05:00
Paul Licameli cb403954fa Use std::[tr1::]unordered_(set|map), not the wxWidgets container macros 2018-01-08 18:22:51 -05:00
Paul Licameli ddf236993f Bug1502: VST and AU plug-ins should show correct rates and spectra 2017-07-24 14:20:54 -04:00
Paul Licameli 464828d88f Exception safety in: batch processing 2017-03-21 14:11:21 -04:00
Paul Licameli a4c7d37d3e Remove naked new[] in: effects framework 2017-03-17 17:52:48 -04:00
Paul Licameli ad04187a41 Change sampleCount arguments, variables, return values to size_t...
... whenever they really describe the size of a buffer that fits in memory, or
of a block file (which is never now more than a megabyte and so could be fit in
memory all at once), or a part thereof.
2016-09-15 21:03:17 -04:00
Paul Licameli 67cec5ad83 Make many counts of tracks and channels unsigned...
... And in some places where a library uses signed types, assert that
the reported number is not negative.

What led me to this, is that there are many places where a size_t value for
an allocation is the product of a number of channels and some other number.
2016-09-07 10:11:41 -04:00
Paul Licameli 942c62b6f6 Remove some naked new amd delete in: various 2016-08-08 07:51:24 -04:00
Steve Daulton 1d6d08c47d Don't push effects that can't be undone onto the Undo Stack 2016-01-21 02:07:28 +00:00
Paul Licameli ca9928d533 Add missing critical inclusions of Experimental.h to other headers 2015-08-31 17:21:50 -04:00
Leland Lucius 0ef7ccb1d1 Fix permissions...not sure why this was happening though 2015-05-29 19:49:28 -05:00
Leland Lucius b8ce7f6125 Fix for bug #981 2015-05-28 09:57:59 -05:00
Leland Lucius a7203c5d3f Fix crash when certain effects are open and a new project window is created
This affected VST, LADSPA, LV2, and Audio Unit effects.
2015-05-16 22:14:07 -05:00
Leland Lucius 7407243e25 Save/restore effect state during batch processing 2015-04-27 09:22:47 -05:00
Leland Lucius e41db0e4b4 Preload the "Select Preset" with current setting
Also, loads the command parameters box with the default preset if
the selected effect doesn't expose any automation parameters.
2015-04-27 05:02:56 -05:00
Leland Lucius 4f4acffad1 Allow chains to use current/factory presets/settings
Also gives builtin effects a mean to determine if batch processing
is active, IsBatchProcessing() returns true if so.
2015-04-26 16:41:05 -05:00
Leland Lucius 8fbfa460c4 Migrating the remaining effects
This brings the builtin, LV2, and VAMP effects inline with the
Audio Units, LADSPA, and VST effects.  All effects now share
a common UI.

This gives all effects (though not implemented for all):

User and factory preset capability
Preset import/export capability
Shared or private configuration options

Builtin effects can now be migrated to RTP, depending on algorithm.
LV2 effects now support graphical interfaces if the plugin supplies one.
Nyquist prompt enhanced to provide some features of the Nyquist Workbench.

It may not look like it, but this was a LOT of work, so trust me, there
WILL be problems and everything effect related should be suspect.  Keep
a sharp eye (or two) open.
2015-04-16 23:36:28 -05:00