Remove WaveTrack.h from other headers
This commit is contained in:
parent
b89c2a130c
commit
d39eaa4e65
105
src/AudioIO.cpp
105
src/AudioIO.cpp
|
@ -265,8 +265,9 @@ writing audio.
|
|||
*//*******************************************************************/
|
||||
|
||||
#include "Audacity.h"
|
||||
#include "float_cast.h"
|
||||
#include "Experimental.h"
|
||||
#include "AudioIO.h"
|
||||
#include "float_cast.h"
|
||||
|
||||
#include <math.h>
|
||||
#include <stdlib.h>
|
||||
|
@ -294,7 +295,6 @@ writing audio.
|
|||
#include <wx/txtstrm.h>
|
||||
|
||||
#include "AudacityApp.h"
|
||||
#include "AudioIO.h"
|
||||
#include "Mix.h"
|
||||
#include "MixerBoard.h"
|
||||
#include "Resample.h"
|
||||
|
@ -856,6 +856,8 @@ bool AudioIO::ValidateDeviceNames(wxString play, wxString rec)
|
|||
|
||||
AudioIO::AudioIO()
|
||||
{
|
||||
mCaptureTracks = mPlaybackTracks = NULL;
|
||||
|
||||
mAudioThreadShouldCallFillBuffersOnce = false;
|
||||
mAudioThreadFillBuffersLoopRunning = false;
|
||||
mAudioThreadFillBuffersLoopActive = false;
|
||||
|
@ -992,6 +994,9 @@ AudioIO::~AudioIO()
|
|||
#ifdef EXPERIMENTAL_SCRUBBING_SUPPORT
|
||||
delete mScrubQueue;
|
||||
#endif
|
||||
|
||||
delete mCaptureTracks;
|
||||
delete mPlaybackTracks;
|
||||
}
|
||||
|
||||
void AudioIO::SetMixer(int inputSource)
|
||||
|
@ -1542,8 +1547,8 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
mTime = t0;
|
||||
mSeek = 0;
|
||||
mLastRecordingOffset = 0;
|
||||
mPlaybackTracks = playbackTracks;
|
||||
mCaptureTracks = captureTracks;
|
||||
mPlaybackTracks = new WaveTrackArray(playbackTracks);
|
||||
mCaptureTracks = new WaveTrackArray(captureTracks);
|
||||
#ifdef EXPERIMENTAL_MIDI_OUT
|
||||
mMidiPlaybackTracks = midiPlaybackTracks;
|
||||
#endif
|
||||
|
@ -1563,7 +1568,7 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
double minScrubStutter = options.minScrubStutter;
|
||||
if (scrubbing)
|
||||
{
|
||||
if (mCaptureTracks.GetCount() > 0 ||
|
||||
if (mCaptureTracks->GetCount() > 0 ||
|
||||
mPlayMode == PLAY_LOOPED ||
|
||||
mTimeTrack != NULL ||
|
||||
options.maxScrubSpeed < GetMinScrubSpeed())
|
||||
|
@ -1625,8 +1630,8 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
// Capacity of the playback buffer.
|
||||
mPlaybackRingBufferSecs = 10.0;
|
||||
|
||||
mCaptureRingBufferSecs = 4.5 + 0.5 * std::min(size_t(16), mCaptureTracks.GetCount());
|
||||
mMinCaptureSecsToCopy = 0.2 + 0.2 * std::min(size_t(16), mCaptureTracks.GetCount());
|
||||
mCaptureRingBufferSecs = 4.5 + 0.5 * std::min(size_t(16), mCaptureTracks->GetCount());
|
||||
mMinCaptureSecsToCopy = 0.2 + 0.2 * std::min(size_t(16), mCaptureTracks->GetCount());
|
||||
|
||||
unsigned int playbackChannels = 0;
|
||||
unsigned int captureChannels = 0;
|
||||
|
@ -1641,7 +1646,7 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
if( captureTracks.GetCount() > 0 )
|
||||
{
|
||||
// For capture, every input channel gets its own track
|
||||
captureChannels = mCaptureTracks.GetCount();
|
||||
captureChannels = mCaptureTracks->GetCount();
|
||||
// I don't deal with the possibility of the capture tracks
|
||||
// having different sample formats, since it will never happen
|
||||
// with the current code. This code wouldn't *break* if this
|
||||
|
@ -1650,7 +1655,7 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
// we would set the sound card to capture in 16 bits and the second
|
||||
// track wouldn't get the benefit of all 24 bits the card is capable
|
||||
// of.
|
||||
captureFormat = mCaptureTracks[0]->GetSampleFormat();
|
||||
captureFormat = (*mCaptureTracks)[0]->GetSampleFormat();
|
||||
|
||||
// Tell project that we are about to start recording
|
||||
if (mListener)
|
||||
|
@ -1711,12 +1716,12 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
return 0;
|
||||
}
|
||||
|
||||
mPlaybackBuffers = new RingBuffer* [mPlaybackTracks.GetCount()];
|
||||
mPlaybackMixers = new Mixer* [mPlaybackTracks.GetCount()];
|
||||
mPlaybackBuffers = new RingBuffer* [mPlaybackTracks->GetCount()];
|
||||
mPlaybackMixers = new Mixer* [mPlaybackTracks->GetCount()];
|
||||
|
||||
// Set everything to zero in case we have to delete these due to a memory exception.
|
||||
memset(mPlaybackBuffers, 0, sizeof(RingBuffer*)*mPlaybackTracks.GetCount());
|
||||
memset(mPlaybackMixers, 0, sizeof(Mixer*)*mPlaybackTracks.GetCount());
|
||||
memset(mPlaybackBuffers, 0, sizeof(RingBuffer*)*mPlaybackTracks->GetCount());
|
||||
memset(mPlaybackMixers, 0, sizeof(Mixer*)*mPlaybackTracks->GetCount());
|
||||
|
||||
const Mixer::WarpOptions &warpOptions =
|
||||
#ifdef EXPERIMENTAL_SCRUBBING_SUPPORT
|
||||
|
@ -1724,12 +1729,12 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
#endif
|
||||
Mixer::WarpOptions(mTimeTrack);
|
||||
|
||||
for (unsigned int i = 0; i < mPlaybackTracks.GetCount(); i++)
|
||||
for (unsigned int i = 0; i < mPlaybackTracks->GetCount(); i++)
|
||||
{
|
||||
mPlaybackBuffers[i] = new RingBuffer(floatSample, playbackBufferSize);
|
||||
|
||||
// MB: use normal time for the end time, not warped time!
|
||||
mPlaybackMixers[i] = new Mixer(1, &mPlaybackTracks[i],
|
||||
mPlaybackMixers[i] = new Mixer(1, &(*mPlaybackTracks)[i],
|
||||
warpOptions,
|
||||
mT0, mT1, 1,
|
||||
playbackMixBufferSize, false,
|
||||
|
@ -1753,17 +1758,17 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
return 0;
|
||||
}
|
||||
|
||||
mCaptureBuffers = new RingBuffer* [mCaptureTracks.GetCount()];
|
||||
mResample = new Resample* [mCaptureTracks.GetCount()];
|
||||
mCaptureBuffers = new RingBuffer* [mCaptureTracks->GetCount()];
|
||||
mResample = new Resample* [mCaptureTracks->GetCount()];
|
||||
mFactor = sampleRate / mRate;
|
||||
|
||||
// Set everything to zero in case we have to delete these due to a memory exception.
|
||||
memset(mCaptureBuffers, 0, sizeof(RingBuffer*)*mCaptureTracks.GetCount());
|
||||
memset(mResample, 0, sizeof(Resample*)*mCaptureTracks.GetCount());
|
||||
memset(mCaptureBuffers, 0, sizeof(RingBuffer*)*mCaptureTracks->GetCount());
|
||||
memset(mResample, 0, sizeof(Resample*)*mCaptureTracks->GetCount());
|
||||
|
||||
for( unsigned int i = 0; i < mCaptureTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mCaptureTracks->GetCount(); i++ )
|
||||
{
|
||||
mCaptureBuffers[i] = new RingBuffer( mCaptureTracks[i]->GetSampleFormat(),
|
||||
mCaptureBuffers[i] = new RingBuffer( (*mCaptureTracks)[i]->GetSampleFormat(),
|
||||
captureBufferSize );
|
||||
mResample[i] = new Resample(true, mFactor, mFactor); // constant rate resampling
|
||||
}
|
||||
|
@ -1791,9 +1796,9 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
// group determination should mimic what is done in audacityAudioCallback()
|
||||
// when calling RealtimeProcess().
|
||||
int group = 0;
|
||||
for (size_t i = 0, cnt = mPlaybackTracks.GetCount(); i < cnt; i++)
|
||||
for (size_t i = 0, cnt = mPlaybackTracks->GetCount(); i < cnt; i++)
|
||||
{
|
||||
WaveTrack *vt = gAudioIO->mPlaybackTracks[i];
|
||||
WaveTrack *vt = (*gAudioIO->mPlaybackTracks)[i];
|
||||
|
||||
int chanCnt = 1;
|
||||
if (vt->GetLinked())
|
||||
|
@ -1815,7 +1820,7 @@ int AudioIO::StartStream(WaveTrackArray playbackTracks,
|
|||
// Calculate the new time position
|
||||
mTime = std::max(mT0, std::min(mT1, *options.pStartTime));
|
||||
// Reset mixer positions for all playback tracks
|
||||
unsigned numMixers = mPlaybackTracks.GetCount();
|
||||
unsigned numMixers = mPlaybackTracks->GetCount();
|
||||
for (unsigned ii = 0; ii < numMixers; ++ii)
|
||||
mPlaybackMixers[ii]->Reposition(mTime);
|
||||
if(mTimeTrack)
|
||||
|
@ -1919,7 +1924,7 @@ void AudioIO::StartStreamCleanup(bool bOnlyBuffers)
|
|||
|
||||
if(mPlaybackBuffers)
|
||||
{
|
||||
for( unsigned int i = 0; i < mPlaybackTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mPlaybackTracks->GetCount(); i++ )
|
||||
delete mPlaybackBuffers[i];
|
||||
delete [] mPlaybackBuffers;
|
||||
mPlaybackBuffers = NULL;
|
||||
|
@ -1927,7 +1932,7 @@ void AudioIO::StartStreamCleanup(bool bOnlyBuffers)
|
|||
|
||||
if(mPlaybackMixers)
|
||||
{
|
||||
for( unsigned int i = 0; i < mPlaybackTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mPlaybackTracks->GetCount(); i++ )
|
||||
delete mPlaybackMixers[i];
|
||||
delete [] mPlaybackMixers;
|
||||
mPlaybackMixers = NULL;
|
||||
|
@ -1935,7 +1940,7 @@ void AudioIO::StartStreamCleanup(bool bOnlyBuffers)
|
|||
|
||||
if(mCaptureBuffers)
|
||||
{
|
||||
for( unsigned int i = 0; i < mCaptureTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mCaptureTracks->GetCount(); i++ )
|
||||
delete mCaptureBuffers[i];
|
||||
delete [] mCaptureBuffers;
|
||||
mCaptureBuffers = NULL;
|
||||
|
@ -1943,7 +1948,7 @@ void AudioIO::StartStreamCleanup(bool bOnlyBuffers)
|
|||
|
||||
if(mResample)
|
||||
{
|
||||
for( unsigned int i = 0; i < mCaptureTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mCaptureTracks->GetCount(); i++ )
|
||||
delete mResample[i];
|
||||
delete [] mResample;
|
||||
mResample = NULL;
|
||||
|
@ -2268,9 +2273,9 @@ void AudioIO::StopStream()
|
|||
// we allocated in StartStream()
|
||||
//
|
||||
|
||||
if( mPlaybackTracks.GetCount() > 0 )
|
||||
if( mPlaybackTracks->GetCount() > 0 )
|
||||
{
|
||||
for( unsigned int i = 0; i < mPlaybackTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mPlaybackTracks->GetCount(); i++ )
|
||||
{
|
||||
delete mPlaybackBuffers[i];
|
||||
delete mPlaybackMixers[i];
|
||||
|
@ -2283,7 +2288,7 @@ void AudioIO::StopStream()
|
|||
//
|
||||
// Offset all recorded tracks to account for latency
|
||||
//
|
||||
if( mCaptureTracks.GetCount() > 0 )
|
||||
if( mCaptureTracks->GetCount() > 0 )
|
||||
{
|
||||
//
|
||||
// We only apply latency correction when we actually played back
|
||||
|
@ -2298,15 +2303,15 @@ void AudioIO::StopStream()
|
|||
double recordingOffset =
|
||||
mLastRecordingOffset + latencyCorrection / 1000.0;
|
||||
|
||||
for( unsigned int i = 0; i < mCaptureTracks.GetCount(); i++ )
|
||||
for( unsigned int i = 0; i < mCaptureTracks->GetCount(); i++ )
|
||||
{
|
||||
delete mCaptureBuffers[i];
|
||||
delete mResample[i];
|
||||
|
||||
WaveTrack* track = mCaptureTracks[i];
|
||||
WaveTrack* track = (*mCaptureTracks)[i];
|
||||
track->Flush();
|
||||
|
||||
if (mPlaybackTracks.GetCount() > 0)
|
||||
if (mPlaybackTracks->GetCount() > 0)
|
||||
{ // only do latency correction if some tracks are being played back
|
||||
WaveTrackArray playbackTracks;
|
||||
AudacityProject *p = GetActiveProject();
|
||||
|
@ -2873,7 +2878,7 @@ int AudioIO::GetCommonlyAvailPlayback()
|
|||
int commonlyAvail = mPlaybackBuffers[0]->AvailForPut();
|
||||
unsigned int i;
|
||||
|
||||
for( i = 1; i < mPlaybackTracks.GetCount(); i++ )
|
||||
for( i = 1; i < mPlaybackTracks->GetCount(); i++ )
|
||||
{
|
||||
int thisBlockAvail = mPlaybackBuffers[i]->AvailForPut();
|
||||
|
||||
|
@ -2889,7 +2894,7 @@ int AudioIO::GetCommonlyAvailCapture()
|
|||
int commonlyAvail = mCaptureBuffers[0]->AvailForGet();
|
||||
unsigned int i;
|
||||
|
||||
for( i = 1; i < mCaptureTracks.GetCount(); i++ )
|
||||
for( i = 1; i < mCaptureTracks->GetCount(); i++ )
|
||||
{
|
||||
int avail = mCaptureBuffers[i]->AvailForGet();
|
||||
if( avail < commonlyAvail )
|
||||
|
@ -3266,7 +3271,7 @@ void AudioIO::FillBuffers()
|
|||
{
|
||||
unsigned int i;
|
||||
|
||||
if( mPlaybackTracks.GetCount() > 0 )
|
||||
if( mPlaybackTracks->GetCount() > 0 )
|
||||
{
|
||||
// Though extremely unlikely, it is possible that some buffers
|
||||
// will have more samples available than others. This could happen
|
||||
|
@ -3323,7 +3328,7 @@ void AudioIO::FillBuffers()
|
|||
mWarpedTime += deltat;
|
||||
}
|
||||
|
||||
for( i = 0; i < mPlaybackTracks.GetCount(); i++ )
|
||||
for( i = 0; i < mPlaybackTracks->GetCount(); i++ )
|
||||
{
|
||||
// The mixer here isn't actually mixing: it's just doing
|
||||
// resampling, format conversion, and possibly time track
|
||||
|
@ -3400,7 +3405,7 @@ void AudioIO::FillBuffers()
|
|||
startTime = startSample / mRate;
|
||||
endTime = endSample / mRate;
|
||||
speed = double(abs(endSample - startSample)) / mScrubDuration;
|
||||
for (i = 0; i < mPlaybackTracks.GetCount(); i++)
|
||||
for (i = 0; i < mPlaybackTracks->GetCount(); i++)
|
||||
mPlaybackMixers[i]->SetTimesAndSpeed(startTime, endTime, speed);
|
||||
}
|
||||
}
|
||||
|
@ -3415,7 +3420,7 @@ void AudioIO::FillBuffers()
|
|||
// and if yes, restart from the beginning.
|
||||
if (mWarpedTime >= mWarpedLength)
|
||||
{
|
||||
for (i = 0; i < mPlaybackTracks.GetCount(); i++)
|
||||
for (i = 0; i < mPlaybackTracks->GetCount(); i++)
|
||||
mPlaybackMixers[i]->Restart();
|
||||
mWarpedTime = 0.0;
|
||||
}
|
||||
|
@ -3429,7 +3434,7 @@ void AudioIO::FillBuffers()
|
|||
}
|
||||
} // end of playback buffering
|
||||
|
||||
if( mCaptureTracks.GetCount() > 0 ) // start record buffering
|
||||
if( mCaptureTracks->GetCount() > 0 ) // start record buffering
|
||||
{
|
||||
int commonlyAvail = GetCommonlyAvailCapture();
|
||||
|
||||
|
@ -3444,12 +3449,12 @@ void AudioIO::FillBuffers()
|
|||
// Append captured samples to the end of the WaveTracks.
|
||||
// The WaveTracks have their own buffering for efficiency.
|
||||
AutoSaveFile blockFileLog;
|
||||
int numChannels = mCaptureTracks.GetCount();
|
||||
int numChannels = mCaptureTracks->GetCount();
|
||||
|
||||
for( i = 0; (int)i < numChannels; i++ )
|
||||
{
|
||||
int avail = commonlyAvail;
|
||||
sampleFormat trackFormat = mCaptureTracks[i]->GetSampleFormat();
|
||||
sampleFormat trackFormat = (*mCaptureTracks)[i]->GetSampleFormat();
|
||||
|
||||
AutoSaveFile appendLog;
|
||||
|
||||
|
@ -3457,7 +3462,7 @@ void AudioIO::FillBuffers()
|
|||
{
|
||||
samplePtr temp = NewSamples(avail, trackFormat);
|
||||
mCaptureBuffers[i]->Get (temp, trackFormat, avail);
|
||||
mCaptureTracks[i]-> Append(temp, trackFormat, avail, 1,
|
||||
(*mCaptureTracks)[i]-> Append(temp, trackFormat, avail, 1,
|
||||
&appendLog);
|
||||
DeleteSamples(temp);
|
||||
}
|
||||
|
@ -3473,7 +3478,7 @@ void AudioIO::FillBuffers()
|
|||
*/
|
||||
size = mResample[i]->Process(mFactor, (float *)temp1, avail, !IsStreamActive(),
|
||||
&size, (float *)temp2, size);
|
||||
mCaptureTracks[i]-> Append(temp2, floatSample, size, 1,
|
||||
(*mCaptureTracks)[i]-> Append(temp2, floatSample, size, 1,
|
||||
&appendLog);
|
||||
DeleteSamples(temp1);
|
||||
DeleteSamples(temp2);
|
||||
|
@ -3482,7 +3487,7 @@ void AudioIO::FillBuffers()
|
|||
if (!appendLog.IsEmpty())
|
||||
{
|
||||
blockFileLog.StartTag(wxT("recordingrecovery"));
|
||||
blockFileLog.WriteAttr(wxT("id"), mCaptureTracks[i]->GetAutoSaveIdent());
|
||||
blockFileLog.WriteAttr(wxT("id"), (*mCaptureTracks)[i]->GetAutoSaveIdent());
|
||||
blockFileLog.WriteAttr(wxT("channel"), (int)i);
|
||||
blockFileLog.WriteAttr(wxT("numchannels"), numChannels);
|
||||
blockFileLog.WriteSubTree(appendLog);
|
||||
|
@ -3675,7 +3680,7 @@ bool AudioIO::SetHasSolo(bool hasSolo)
|
|||
void AudioIO::FillMidiBuffers()
|
||||
{
|
||||
bool hasSolo = false;
|
||||
int numPlaybackTracks = gAudioIO->mPlaybackTracks.GetCount();
|
||||
int numPlaybackTracks = gAudioIO->mPlaybackTracks->GetCount();
|
||||
int t;
|
||||
for(t = 0; t < numPlaybackTracks; t++ )
|
||||
if( gAudioIO->mPlaybackTracks[t]->GetSolo() ) {
|
||||
|
@ -3956,7 +3961,7 @@ int audacityAudioCallback(const void *inputBuffer, void *outputBuffer,
|
|||
const PaStreamCallbackFlags WXUNUSED(statusFlags), void * WXUNUSED(userData) )
|
||||
{
|
||||
int numPlaybackChannels = gAudioIO->mNumPlaybackChannels;
|
||||
int numPlaybackTracks = gAudioIO->mPlaybackTracks.GetCount();
|
||||
int numPlaybackTracks = gAudioIO->mPlaybackTracks->GetCount();
|
||||
int numCaptureChannels = gAudioIO->mNumCaptureChannels;
|
||||
int callbackReturn = paContinue;
|
||||
void *tempBuffer = alloca(framesPerBuffer*sizeof(float)*
|
||||
|
@ -4137,7 +4142,7 @@ int audacityAudioCallback(const void *inputBuffer, void *outputBuffer,
|
|||
|
||||
int numSolo = 0;
|
||||
for( t = 0; t < numPlaybackTracks; t++ )
|
||||
if( gAudioIO->mPlaybackTracks[t]->GetSolo() )
|
||||
if( (*gAudioIO->mPlaybackTracks)[t]->GetSolo() )
|
||||
numSolo++;
|
||||
#ifdef EXPERIMENTAL_MIDI_OUT
|
||||
int numMidiPlaybackTracks = gAudioIO->mMidiPlaybackTracks.GetCount();
|
||||
|
@ -4162,7 +4167,7 @@ int audacityAudioCallback(const void *inputBuffer, void *outputBuffer,
|
|||
int maxLen = 0;
|
||||
for (t = 0; t < numPlaybackTracks; t++)
|
||||
{
|
||||
WaveTrack *vt = gAudioIO->mPlaybackTracks[t];
|
||||
WaveTrack *vt = (*gAudioIO->mPlaybackTracks)[t];
|
||||
|
||||
chans[chanCnt] = vt;
|
||||
|
||||
|
|
|
@ -29,10 +29,10 @@
|
|||
#include "portmixer.h"
|
||||
#endif
|
||||
|
||||
#include <wx/event.h>
|
||||
#include <wx/string.h>
|
||||
#include <wx/thread.h>
|
||||
|
||||
#include "WaveTrack.h"
|
||||
#include "SampleFormat.h"
|
||||
|
||||
class AudioIO;
|
||||
|
@ -46,6 +46,9 @@ class SelectedRegion;
|
|||
class TimeTrack;
|
||||
class wxDialog;
|
||||
|
||||
class AudacityProject;
|
||||
class WaveTrackArray;
|
||||
|
||||
extern AUDACITY_DLL_API AudioIO *gAudioIO;
|
||||
|
||||
void InitAudioIO();
|
||||
|
@ -571,9 +574,9 @@ private:
|
|||
#endif
|
||||
Resample **mResample;
|
||||
RingBuffer **mCaptureBuffers;
|
||||
WaveTrackArray mCaptureTracks;
|
||||
WaveTrackArray *mCaptureTracks;
|
||||
RingBuffer **mPlaybackBuffers;
|
||||
WaveTrackArray mPlaybackTracks;
|
||||
WaveTrackArray *mPlaybackTracks;
|
||||
|
||||
Mixer **mPlaybackMixers;
|
||||
volatile int mStreamToken;
|
||||
|
|
|
@ -27,6 +27,8 @@ recover previous Audacity projects that were closed incorrectly.
|
|||
#include <wx/dialog.h>
|
||||
#include <wx/app.h>
|
||||
|
||||
#include "WaveTrack.h"
|
||||
|
||||
enum {
|
||||
ID_RECOVER_ALL = 10000,
|
||||
ID_RECOVER_NONE,
|
||||
|
|
|
@ -17,6 +17,7 @@ See also BatchCommandDialog and BatchProcessDialog.
|
|||
|
||||
|
||||
#include "Audacity.h"
|
||||
#include "BatchCommands.h"
|
||||
|
||||
#include <wx/defs.h>
|
||||
#include <wx/dir.h>
|
||||
|
@ -25,7 +26,6 @@ See also BatchCommandDialog and BatchProcessDialog.
|
|||
#include <wx/textfile.h>
|
||||
|
||||
#include "Project.h"
|
||||
#include "BatchCommands.h"
|
||||
#include "commands/CommandManager.h"
|
||||
#include "effects/EffectManager.h"
|
||||
#include "FileNames.h"
|
||||
|
@ -41,6 +41,7 @@ See also BatchCommandDialog and BatchProcessDialog.
|
|||
#include "Theme.h"
|
||||
#include "AllThemeResources.h"
|
||||
|
||||
#include "Track.h"
|
||||
|
||||
// KLUDGE: All commands should be on the same footing
|
||||
// however, for historical reasons we distinguish between
|
||||
|
|
|
@ -42,6 +42,8 @@ out.
|
|||
|
||||
*//*******************************************************************/
|
||||
|
||||
#include "BlockFile.h"
|
||||
|
||||
#include <float.h>
|
||||
#include <math.h>
|
||||
|
||||
|
@ -51,7 +53,6 @@ out.
|
|||
#include <wx/log.h>
|
||||
#include <wx/math.h>
|
||||
|
||||
#include "BlockFile.h"
|
||||
#include "Internat.h"
|
||||
|
||||
// msmeyer: Define this to add debug output via printf()
|
||||
|
|
|
@ -16,11 +16,11 @@
|
|||
#include <wx/ffile.h>
|
||||
#include <wx/filename.h>
|
||||
|
||||
#include "WaveTrack.h"
|
||||
|
||||
#include "xml/XMLTagHandler.h"
|
||||
#include "xml/XMLWriter.h"
|
||||
|
||||
#include "SampleFormat.h"
|
||||
|
||||
|
||||
class SummaryInfo {
|
||||
public:
|
||||
|
@ -209,7 +209,7 @@ class AliasBlockFile : public BlockFile
|
|||
//
|
||||
// These methods are for advanced use only!
|
||||
//
|
||||
wxFileName GetAliasedFileName() { return mAliasedFileName; };
|
||||
wxFileName GetAliasedFileName() { return mAliasedFileName; }
|
||||
void ChangeAliasedFileName(wxFileName newAliasedFile);
|
||||
virtual bool IsAlias() { return true; }
|
||||
|
||||
|
|
|
@ -21,6 +21,8 @@
|
|||
|
||||
**********************************************************************/
|
||||
|
||||
#include "Dependencies.h"
|
||||
|
||||
#include <wx/button.h>
|
||||
#include <wx/defs.h>
|
||||
#include <wx/dialog.h>
|
||||
|
@ -30,13 +32,13 @@
|
|||
#include <wx/choice.h>
|
||||
|
||||
#include "BlockFile.h"
|
||||
#include "Dependencies.h"
|
||||
#include "DirManager.h"
|
||||
#include "Internat.h"
|
||||
#include "Prefs.h"
|
||||
#include "Project.h"
|
||||
#include "ShuttleGui.h"
|
||||
#include "Track.h"
|
||||
#include "WaveTrack.h"
|
||||
#include "WaveClip.h"
|
||||
|
||||
// Note, this #include must occur here, not up with the others!
|
||||
// It must be between the WX_DECLARE_OBJARRAY and WX_DEFINE_OBJARRAY.
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
#define __AUDACITY_DEPENDENCIES__
|
||||
|
||||
#include <wx/dynarray.h>
|
||||
#include <wx/filename.h>
|
||||
|
||||
class AudacityProject;
|
||||
|
||||
|
|
|
@ -62,6 +62,7 @@
|
|||
|
||||
|
||||
#include "Audacity.h"
|
||||
#include "DirManager.h"
|
||||
|
||||
#include <time.h> // to use time() for srand()
|
||||
|
||||
|
@ -94,7 +95,6 @@
|
|||
#include "blockfile/PCMAliasBlockFile.h"
|
||||
#include "blockfile/ODPCMAliasBlockFile.h"
|
||||
#include "blockfile/ODDecodeBlockFile.h"
|
||||
#include "DirManager.h"
|
||||
#include "Internat.h"
|
||||
#include "Project.h"
|
||||
#include "Prefs.h"
|
||||
|
@ -103,6 +103,8 @@
|
|||
|
||||
#include "ondemand/ODManager.h"
|
||||
|
||||
#include "Track.h"
|
||||
|
||||
#if defined(__WXMAC__)
|
||||
#include <mach/mach.h>
|
||||
#include <mach/vm_statistics.h>
|
||||
|
|
|
@ -15,8 +15,10 @@
|
|||
#include <wx/string.h>
|
||||
#include <wx/filename.h>
|
||||
#include <wx/hashmap.h>
|
||||
#include <wx/utils.h>
|
||||
|
||||
#include "WaveTrack.h"
|
||||
#include "audacity/Types.h"
|
||||
#include "xml/XMLTagHandler.h"
|
||||
|
||||
class wxHashTable;
|
||||
class BlockFile;
|
||||
|
@ -105,7 +107,7 @@ class DirManager: public XMLTagHandler {
|
|||
void SetMaxSamples(sampleCount max) { mMaxSamples = max; }
|
||||
bool HandleXMLTag(const wxChar *tag, const wxChar **attrs);
|
||||
XMLTagHandler *HandleXMLChild(const wxChar * WXUNUSED(tag)) { return NULL; }
|
||||
void WriteXML(XMLWriter & WXUNUSED(xmlFile)) { wxASSERT(false); }; // This class only reads tags.
|
||||
void WriteXML(XMLWriter & WXUNUSED(xmlFile)) { wxASSERT(false); } // This class only reads tags.
|
||||
bool AssignFile(wxFileName &filename,wxString value,bool check);
|
||||
|
||||
// Clean the temp dir. Note that now where we have auto recovery the temp
|
||||
|
|
|
@ -84,6 +84,8 @@ and in the spectrogram spectral selection.
|
|||
|
||||
#include "FileDialog.h"
|
||||
|
||||
#include "WaveTrack.h"
|
||||
|
||||
#if defined(__WXGTK__)
|
||||
#define GSocket GSocketHack
|
||||
#include <gtk/gtk.h>
|
||||
|
|
|
@ -31,6 +31,7 @@ simplifies construction of menu items.
|
|||
*//*******************************************************************/
|
||||
|
||||
#include "Audacity.h"
|
||||
#include "Project.h"
|
||||
|
||||
#include <iterator>
|
||||
#include <limits>
|
||||
|
@ -53,7 +54,6 @@ simplifies construction of menu items.
|
|||
#include "effects/Contrast.h"
|
||||
#include "TrackPanel.h"
|
||||
|
||||
#include "Project.h"
|
||||
#include "effects/EffectManager.h"
|
||||
|
||||
#include "AudacityApp.h"
|
||||
|
@ -120,6 +120,8 @@ simplifies construction of menu items.
|
|||
#include "CaptureEvents.h"
|
||||
#include "Snap.h"
|
||||
|
||||
#include "WaveTrack.h"
|
||||
|
||||
#if defined(EXPERIMENTAL_CRASH_REPORT)
|
||||
#include <wx/debugrpt.h>
|
||||
#endif
|
||||
|
|
|
@ -15,10 +15,13 @@
|
|||
#include <wx/string.h>
|
||||
|
||||
#include "SampleFormat.h"
|
||||
#include "WaveTrack.h"
|
||||
#include "Resample.h"
|
||||
|
||||
class DirManager;
|
||||
class TimeTrack;
|
||||
class TrackFactory;
|
||||
class TrackList;
|
||||
class WaveTrack;
|
||||
|
||||
/** @brief Mixes together all input tracks, applying any envelopes, amplitude
|
||||
* gain, panning, and real-time effects in the process.
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
**********************************************************************/
|
||||
|
||||
#include "Audacity.h"
|
||||
|
||||
#include "Experimental.h"
|
||||
#include "MixerBoard.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
|
@ -22,12 +22,11 @@
|
|||
|
||||
#include "AColor.h"
|
||||
#include "AudioIO.h"
|
||||
#include "MixerBoard.h"
|
||||
#ifdef EXPERIMENTAL_MIDI_OUT
|
||||
#include "NoteTrack.h"
|
||||
#endif
|
||||
#include "Project.h"
|
||||
#include "Track.h"
|
||||
#include "WaveTrack.h"
|
||||
|
||||
|
||||
#include "../images/MusicalInstruments.h"
|
||||
|
|
|
@ -1215,6 +1215,11 @@ void AudacityProject::SetProjectTitle()
|
|||
SetName(name); // to make the nvda screen reader read the correct title
|
||||
}
|
||||
|
||||
bool AudacityProject::GetIsEmpty()
|
||||
{
|
||||
return mTracks->IsEmpty();
|
||||
}
|
||||
|
||||
double AudacityProject::AS_GetRate()
|
||||
{
|
||||
return mRate;
|
||||
|
@ -4420,7 +4425,7 @@ void AudacityProject::GetRegionsByLabel( Regions ®ions )
|
|||
//If the function replaces the selection with audio of a different length,
|
||||
// bSyncLockedTracks should be set true to perform the same action on sync-lock selected
|
||||
// tracks.
|
||||
void AudacityProject::EditByLabel( WaveTrack::EditFunction action,
|
||||
void AudacityProject::EditByLabel( EditFunction action,
|
||||
bool bSyncLockedTracks )
|
||||
{
|
||||
Regions regions;
|
||||
|
@ -4469,7 +4474,7 @@ void AudacityProject::EditByLabel( WaveTrack::EditFunction action,
|
|||
//Functions copy the edited regions to clipboard, possibly in multiple tracks
|
||||
//This probably should not be called if *action() changes the timeline, because
|
||||
// the copy needs to happen by track, and the timeline change by group.
|
||||
void AudacityProject::EditClipboardByLabel( WaveTrack::EditDestFunction action )
|
||||
void AudacityProject::EditClipboardByLabel( EditDestFunction action )
|
||||
{
|
||||
Regions regions;
|
||||
|
||||
|
|
|
@ -86,6 +86,9 @@ class MixerBoardFrame;
|
|||
|
||||
struct AudioIOStartStreamOptions;
|
||||
|
||||
class WaveTrackArray;
|
||||
class Regions;
|
||||
|
||||
AudacityProject *CreateNewAudacityProject();
|
||||
AUDACITY_DLL_API AudacityProject *GetActiveProject();
|
||||
void RedrawAllProjects();
|
||||
|
@ -236,7 +239,7 @@ class AUDACITY_DLL_API AudacityProject: public wxFrame,
|
|||
|
||||
TrackPanel * GetTrackPanel(){return mTrackPanel;}
|
||||
|
||||
bool GetIsEmpty() { return mTracks->IsEmpty(); }
|
||||
bool GetIsEmpty();
|
||||
|
||||
bool GetTracksFitVerticallyZoomed() { return mTracksFitVerticallyZoomed; } //lda
|
||||
void SetTracksFitVerticallyZoomed(bool flag) { mTracksFitVerticallyZoomed = flag; } //lda
|
||||
|
@ -313,8 +316,14 @@ class AUDACITY_DLL_API AudacityProject: public wxFrame,
|
|||
void ZoomBy(double multiplier);
|
||||
void Rewind(bool shift);
|
||||
void SkipEnd(bool shift);
|
||||
void EditByLabel( WaveTrack::EditFunction action, bool bSyncLockedTracks );
|
||||
void EditClipboardByLabel( WaveTrack::EditDestFunction action );
|
||||
|
||||
|
||||
typedef bool (WaveTrack::* EditFunction)(double, double);
|
||||
typedef bool (WaveTrack::* EditDestFunction)(double, double, Track**);
|
||||
|
||||
void EditByLabel(EditFunction action, bool bSyncLockedTracks);
|
||||
void EditClipboardByLabel(EditDestFunction action );
|
||||
|
||||
bool IsSyncLocked();
|
||||
void SetSyncLock(bool flag);
|
||||
|
||||
|
|
|
@ -34,6 +34,8 @@
|
|||
#include "Prefs.h"
|
||||
#include "toolbars/ToolManager.h"
|
||||
|
||||
#include "Track.h"
|
||||
|
||||
class CommandType;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
#include "LabelTrack.h"
|
||||
#include "Project.h"
|
||||
#include "TrackPanel.h"
|
||||
#include "WaveTrack.h"
|
||||
#include "widgets/NumericTextCtrl.h"
|
||||
|
||||
// Change this to "true" to snap to nearest and "false" to snap to previous
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
#ifndef __AUDACITY_SPECTRUM__
|
||||
#define __AUDACITY_SPECTRUM__
|
||||
|
||||
#include "WaveTrack.h"
|
||||
#include "FFT.h"
|
||||
|
||||
/*
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include <wx/string.h>
|
||||
#include <wx/timer.h>
|
||||
#include <wx/dynlib.h> //<! For windows.h
|
||||
#include <wx/msgdlg.h>
|
||||
|
||||
#include "ShuttleGui.h"
|
||||
#include "Project.h"
|
||||
|
|
|
@ -1441,7 +1441,7 @@ void TrackArtist::DrawWaveform(WaveTrack *track,
|
|||
if (xx >= 0 && xx < rect.width) {
|
||||
dc.SetPen(*wxGREY_PEN);
|
||||
AColor::Line(dc, (int) (rect.x + xx - 1), rect.y, (int) (rect.x + xx - 1), rect.y + rect.height);
|
||||
if (loc.typ == WaveTrack::locationCutLine) {
|
||||
if (loc.typ == WaveTrackLocation::locationCutLine) {
|
||||
dc.SetPen(*wxRED_PEN);
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -6537,7 +6537,7 @@ bool TrackPanel::HandleTrackLocationMouseEvent(WaveTrack * track, wxRect &r, wxM
|
|||
|
||||
if (event.LeftDown())
|
||||
{
|
||||
if (mCapturedTrackLocation.typ == WaveTrack::locationCutLine)
|
||||
if (mCapturedTrackLocation.typ == WaveTrackLocation::locationCutLine)
|
||||
{
|
||||
// When user presses left button on cut line, expand the line again
|
||||
double cutlineStart = 0, cutlineEnd = 0;
|
||||
|
@ -6558,7 +6558,7 @@ bool TrackPanel::HandleTrackLocationMouseEvent(WaveTrack * track, wxRect &r, wxM
|
|||
MakeParentPushState(_("Expanded Cut Line"), _("Expand"));
|
||||
handled = true;
|
||||
}
|
||||
} else if (mCapturedTrackLocation.typ == WaveTrack::locationMergePoint)
|
||||
} else if (mCapturedTrackLocation.typ == WaveTrackLocation::locationMergePoint)
|
||||
{
|
||||
if (!track->MergeClips(mCapturedTrackLocation.clipidx1, mCapturedTrackLocation.clipidx2))
|
||||
return false;
|
||||
|
|
|
@ -23,10 +23,11 @@
|
|||
#include "Experimental.h"
|
||||
#include "Sequence.h" //Stm: included for the sampleCount declaration
|
||||
#include "WaveClip.h"
|
||||
#include "WaveTrack.h"
|
||||
#include "UndoManager.h" //JKC: Included for PUSH_XXX definitions.
|
||||
#include "widgets/NumericTextCtrl.h"
|
||||
|
||||
#include "WaveTrackLocation.h"
|
||||
|
||||
class wxMenu;
|
||||
class wxRect;
|
||||
|
||||
|
@ -47,6 +48,8 @@ class TrackPanelAx;
|
|||
|
||||
class ViewInfo;
|
||||
|
||||
class WaveTrack;
|
||||
|
||||
WX_DEFINE_ARRAY(LWSlider *, LWSliderArray);
|
||||
|
||||
class AUDACITY_DLL_API TrackClip
|
||||
|
@ -643,7 +646,7 @@ protected:
|
|||
WaveClip *mCapturedClip;
|
||||
TrackClipArray mCapturedClipArray;
|
||||
bool mCapturedClipIsSelection;
|
||||
WaveTrack::Location mCapturedTrackLocation;
|
||||
WaveTrackLocation mCapturedTrackLocation;
|
||||
wxRect mCapturedTrackLocationRect;
|
||||
wxRect mCapturedRect;
|
||||
|
||||
|
|
|
@ -14,6 +14,9 @@
|
|||
|
||||
*//*******************************************************************/
|
||||
|
||||
#include "Audacity.h"
|
||||
#include "TrackPanelAx.h"
|
||||
|
||||
// For compilers that support precompilation, includes "wx/wx.h".
|
||||
#include <wx/wxprec.h>
|
||||
|
||||
|
@ -23,11 +26,10 @@
|
|||
#endif
|
||||
|
||||
|
||||
#include "Audacity.h"
|
||||
#include "TrackPanelAx.h"
|
||||
|
||||
#include <wx/intl.h>
|
||||
|
||||
#include "Track.h"
|
||||
|
||||
TrackPanelAx::TrackPanelAx( wxWindow *window )
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
:wxWindowAccessible( window )
|
||||
|
|
|
@ -32,6 +32,8 @@ or "OFF" point
|
|||
#include <wx/intl.h>
|
||||
#include <iostream>
|
||||
|
||||
#include "WaveTrack.h"
|
||||
|
||||
using std::cout;
|
||||
using std::endl;
|
||||
|
||||
|
|
|
@ -11,13 +11,15 @@
|
|||
#ifndef __AUDACITY_VOICEKEY__
|
||||
#define __AUDACITY_VOICEKEY__
|
||||
|
||||
#include "WaveTrack.h"
|
||||
|
||||
|
||||
#ifndef M_PI
|
||||
#define M_PI 3.14159265358979323846 /* pi */
|
||||
#endif
|
||||
|
||||
#include "audacity/Types.h"
|
||||
|
||||
class WaveTrack;
|
||||
|
||||
enum VoiceKeyTypes
|
||||
{
|
||||
VKT_NONE = 0,
|
||||
|
@ -91,10 +93,10 @@ class VoiceKey {
|
|||
};
|
||||
|
||||
|
||||
inline int sgn(int number){ return (number<0) ? -1: 1;};
|
||||
inline int sgn(int number){ return (number<0) ? -1: 1;}
|
||||
|
||||
//This returns a logistic density based on a z-score
|
||||
// a logistic distn has variance (pi*s)^2/3
|
||||
|
||||
//inline float inline float logistic(float z){ return fexp(-1 * z/(pi / sqrt(3)) / (1 + pow(fexp(-1 * z(pi / sqrt(3))),2)));};
|
||||
//inline float inline float logistic(float z){ return fexp(-1 * z/(pi / sqrt(3)) / (1 + pow(fexp(-1 * z(pi / sqrt(3))),2)));}
|
||||
#endif
|
||||
|
|
|
@ -32,6 +32,7 @@
|
|||
#include "Envelope.h"
|
||||
#include "Resample.h"
|
||||
#include "Project.h"
|
||||
#include "WaveTrack.h"
|
||||
|
||||
#include "prefs/SpectrogramSettings.h"
|
||||
|
||||
|
|
|
@ -2407,7 +2407,7 @@ void WaveTrack::UpdateLocationsCache()
|
|||
it = it->GetNext())
|
||||
{
|
||||
// Add cut line expander point
|
||||
mDisplayLocations[curpos].typ = locationCutLine;
|
||||
mDisplayLocations[curpos].typ = WaveTrackLocation::locationCutLine;
|
||||
mDisplayLocations[curpos].pos =
|
||||
clip->GetOffset() + it->GetData()->GetOffset();
|
||||
curpos++;
|
||||
|
@ -2421,7 +2421,7 @@ void WaveTrack::UpdateLocationsCache()
|
|||
< WAVETRACK_MERGE_POINT_TOLERANCE)
|
||||
{
|
||||
// Add merge point
|
||||
mDisplayLocations[curpos].typ = locationMergePoint;
|
||||
mDisplayLocations[curpos].typ = WaveTrackLocation::locationMergePoint;
|
||||
mDisplayLocations[curpos].pos = clips.Item(i-1)->GetEndTime();
|
||||
mDisplayLocations[curpos].clipidx1 = mClips.IndexOf(previousClip);
|
||||
mDisplayLocations[curpos].clipidx2 = mClips.IndexOf(clip);
|
||||
|
|
|
@ -22,6 +22,8 @@
|
|||
#include <wx/longlong.h>
|
||||
#include <wx/thread.h>
|
||||
|
||||
#include "WaveTrackLocation.h"
|
||||
|
||||
class SpectrogramSettings;
|
||||
class WaveformSettings;
|
||||
class TimeWarper;
|
||||
|
@ -53,7 +55,7 @@ WX_DEFINE_ARRAY( Region*, Regions );
|
|||
|
||||
class Envelope;
|
||||
|
||||
class AUDACITY_DLL_API WaveTrack: public Track {
|
||||
class AUDACITY_DLL_API WaveTrack : public Track {
|
||||
|
||||
private:
|
||||
|
||||
|
@ -79,22 +81,8 @@ class AUDACITY_DLL_API WaveTrack: public Track {
|
|||
#ifdef EXPERIMENTAL_OUTPUT_DISPLAY
|
||||
static bool mMonoAsVirtualStereo;
|
||||
#endif
|
||||
enum LocationType {
|
||||
locationCutLine = 1,
|
||||
locationMergePoint
|
||||
};
|
||||
|
||||
struct Location {
|
||||
// Position of track location
|
||||
double pos;
|
||||
|
||||
// Type of track location
|
||||
LocationType typ;
|
||||
|
||||
// Only for typ==locationMergePoint
|
||||
int clipidx1; // first clip (left one)
|
||||
int clipidx2; // second clip (right one)
|
||||
};
|
||||
typedef WaveTrackLocation Location;
|
||||
|
||||
virtual ~WaveTrack();
|
||||
virtual double GetOffset() const;
|
||||
|
@ -184,9 +172,6 @@ class AUDACITY_DLL_API WaveTrack: public Track {
|
|||
virtual bool Join (double t0, double t1);
|
||||
virtual bool Disjoin (double t0, double t1);
|
||||
|
||||
typedef bool ( WaveTrack::* EditFunction )( double, double );
|
||||
typedef bool ( WaveTrack::* EditDestFunction )( double, double, Track** );
|
||||
|
||||
virtual bool Trim (double t0, double t1);
|
||||
|
||||
bool HandleClear(double t0, double t1, bool addCutLines, bool split);
|
||||
|
|
|
@ -0,0 +1,32 @@
|
|||
/**********************************************************************
|
||||
|
||||
Audacity: A Digital Audio Editor
|
||||
|
||||
WaveTrackLocation.h
|
||||
|
||||
Paul Licameli -- split from WaveTrack.h
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
#ifndef __AUDACITY_WAVE_TRACK_LOCATION__
|
||||
#define __AUDACITY_WAVE_TRACK_LOCATION__
|
||||
|
||||
struct WaveTrackLocation {
|
||||
|
||||
enum LocationType {
|
||||
locationCutLine = 1,
|
||||
locationMergePoint
|
||||
};
|
||||
|
||||
// Position of track location
|
||||
double pos;
|
||||
|
||||
// Type of track location
|
||||
LocationType typ;
|
||||
|
||||
// Only for typ==locationMergePoint
|
||||
int clipidx1; // first clip (left one)
|
||||
int clipidx2; // second clip (right one)
|
||||
};
|
||||
|
||||
#endif
|
|
@ -20,6 +20,7 @@ threshold of difference in two selected tracks
|
|||
#include "CompareAudioCommand.h"
|
||||
#include "../Project.h"
|
||||
#include "Command.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
wxString CompareAudioCommandType::BuildName()
|
||||
{
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include "../TrackPanel.h"
|
||||
#include "../Project.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
wxString GetProjectInfoCommandType::BuildName()
|
||||
{
|
||||
|
@ -149,3 +148,23 @@ void GetProjectInfoCommand::SendTracksInfo(TrackList *projTracks,
|
|||
}
|
||||
Status(boolValueStr);
|
||||
}
|
||||
|
||||
bool GetProjectInfoCommand::testSelected(Track * track) const
|
||||
{
|
||||
return track->GetSelected();
|
||||
}
|
||||
|
||||
bool GetProjectInfoCommand::testLinked(Track * track) const
|
||||
{
|
||||
return track->GetLinked();
|
||||
}
|
||||
|
||||
bool GetProjectInfoCommand::testSolo(Track * track) const
|
||||
{
|
||||
return track->GetSolo();
|
||||
}
|
||||
|
||||
bool GetProjectInfoCommand::testMute(Track * track) const
|
||||
{
|
||||
return track->GetMute();
|
||||
}
|
||||
|
|
|
@ -50,10 +50,10 @@ private:
|
|||
void SendTracksInfo(TrackList *projTracks, Getter);
|
||||
|
||||
// Functions pointed to for getting track parameters
|
||||
bool testSelected(Track * track) const {return track->GetSelected();}
|
||||
bool testLinked( Track * track) const {return track->GetLinked();}
|
||||
bool testSolo( Track * track) const {return track->GetSolo();}
|
||||
bool testMute( Track * track) const {return track->GetMute();}
|
||||
bool testSelected(Track * track) const;
|
||||
bool testLinked(Track * track) const;
|
||||
bool testSolo(Track * track) const;
|
||||
bool testMute(Track * track) const;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
#include "GetTrackInfoCommand.h"
|
||||
#include "../TrackPanel.h"
|
||||
#include "../Project.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
wxString GetTrackInfoCommandType::BuildName()
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
|
||||
#include "ImportExportCommands.h"
|
||||
#include "../Project.h"
|
||||
#include "../Track.h"
|
||||
#include "../export/Export.h"
|
||||
|
||||
// Import
|
||||
|
|
|
@ -25,6 +25,7 @@ project window.
|
|||
#include <wx/settings.h>
|
||||
#include <wx/bitmap.h>
|
||||
|
||||
#include "../Track.h"
|
||||
#include "../TrackPanel.h"
|
||||
#include "../toolbars/ToolManager.h"
|
||||
#include "../toolbars/ToolBar.h"
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include "SelectCommand.h"
|
||||
#include <wx/string.h>
|
||||
#include "../Project.h"
|
||||
#include "../Track.h"
|
||||
|
||||
wxString SelectCommandType::BuildName()
|
||||
{
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
#include "SetProjectInfoCommand.h"
|
||||
#include "../Project.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
// The following parameters have a boolean string, indicated by the kSetOfTracksStr
|
||||
#define kSetOfTracksStr "TrackSet"
|
||||
|
|
|
@ -33,6 +33,8 @@
|
|||
#include "../Theme.h"
|
||||
#include "../widgets/valnum.h"
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
// Define keys, defaults, minimums, and maximums for the effect parameters
|
||||
//
|
||||
// Name Type Key Def Min Max Scale
|
||||
|
|
|
@ -19,8 +19,6 @@
|
|||
#include <wx/textctrl.h>
|
||||
#include <wx/window.h>
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
||||
class EffectAutoDuckPanel;
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
*//*******************************************************************/
|
||||
|
||||
#include "../Audacity.h"
|
||||
#include "ChangeSpeed.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
|
@ -27,9 +28,8 @@
|
|||
#include "../ShuttleGui.h"
|
||||
#include "../widgets/valnum.h"
|
||||
|
||||
#include "ChangeSpeed.h"
|
||||
|
||||
#include "TimeWarper.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
enum
|
||||
{
|
||||
|
|
|
@ -19,7 +19,6 @@
|
|||
#include <wx/string.h>
|
||||
#include <wx/textctrl.h>
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
#include "../widgets/NumericTextCtrl.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
|
|
@ -37,6 +37,8 @@
|
|||
#include "../ShuttleGui.h"
|
||||
#include "../widgets/valnum.h"
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
enum
|
||||
{
|
||||
ID_Thresh = 10000,
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
#include <wx/textctrl.h>
|
||||
|
||||
#include "../Envelope.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
||||
|
|
|
@ -41,6 +41,8 @@
|
|||
#include "../float_cast.h"
|
||||
#include "../widgets/Ruler.h"
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
enum
|
||||
{
|
||||
ID_Threshold = 10000,
|
||||
|
|
|
@ -2060,6 +2060,11 @@ TimeWarper *Effect::GetTimeWarper()
|
|||
// Use these two methods to copy the input tracks to mOutputTracks, if
|
||||
// doing the processing on them, and replacing the originals only on success (and not cancel).
|
||||
// Copy the group tracks that have tracks selected
|
||||
void Effect::CopyInputTracks()
|
||||
{
|
||||
CopyInputTracks(Track::Wave);
|
||||
}
|
||||
|
||||
void Effect::CopyInputTracks(int trackType)
|
||||
{
|
||||
// Reset map
|
||||
|
|
|
@ -30,7 +30,6 @@ class wxWindow;
|
|||
#include "audacity/EffectInterface.h"
|
||||
|
||||
#include "../Experimental.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../SelectedRegion.h"
|
||||
#include "../Shuttle.h"
|
||||
#include "../Internat.h"
|
||||
|
@ -40,9 +39,14 @@ class ShuttleGui;
|
|||
|
||||
#define BUILTIN_EFFECT_PREFIX wxT("Built-in Effect: ")
|
||||
|
||||
class AudacityProject;
|
||||
class SelectedRegion;
|
||||
class TimeWarper;
|
||||
class EffectUIHost;
|
||||
class Track;
|
||||
class TrackList;
|
||||
class TrackFactory;
|
||||
class WaveTrack;
|
||||
|
||||
// TODO: Apr-06-2015
|
||||
// TODO: Much more cleanup of old methods and variables is needed, but
|
||||
|
@ -337,7 +341,8 @@ protected:
|
|||
|
||||
// Use these two methods to copy the input tracks to mOutputTracks, if
|
||||
// doing the processing on them, and replacing the originals only on success (and not cancel).
|
||||
void CopyInputTracks(int trackType = Track::Wave);
|
||||
void CopyInputTracks(); // trackType = Track::Wave
|
||||
void CopyInputTracks(int trackType);
|
||||
|
||||
// If bGoodResult, replace mWaveTracks tracks in mTracks with successfully processed
|
||||
// mOutputTracks copies, get rid of old mWaveTracks, and set mWaveTracks to mOutputTracks.
|
||||
|
|
|
@ -53,6 +53,7 @@
|
|||
|
||||
|
||||
#include "../Audacity.h"
|
||||
#include "Equalization.h"
|
||||
|
||||
#include <math.h>
|
||||
#include <vector>
|
||||
|
@ -95,13 +96,10 @@
|
|||
#include "../xml/XMLFileReader.h"
|
||||
#include "../Theme.h"
|
||||
#include "../AllThemeResources.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../float_cast.h"
|
||||
|
||||
#include "FileDialog.h"
|
||||
|
||||
#include "Equalization.h"
|
||||
|
||||
#ifdef EXPERIMENTAL_EQ_SSE_THREADED
|
||||
#include "Equalization48x.h"
|
||||
#endif
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
|
||||
#include "Effect.h"
|
||||
#include "../Envelope.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../xml/XMLTagHandler.h"
|
||||
#include "../widgets/Grid.h"
|
||||
#include "../widgets/Ruler.h"
|
||||
|
|
|
@ -30,6 +30,8 @@
|
|||
#include "../ShuttleGui.h"
|
||||
#include "../widgets/valnum.h"
|
||||
|
||||
#include "../Wavetrack.h"
|
||||
|
||||
// Define keys, defaults, minimums, and maximums for the effect parameters
|
||||
//
|
||||
// Name Type Key Def Min Max Scale
|
||||
|
|
|
@ -17,7 +17,6 @@ class wxString;
|
|||
#include <wx/string.h>
|
||||
|
||||
#include "../LabelTrack.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
||||
|
|
|
@ -14,10 +14,12 @@
|
|||
|
||||
**********************************************************************/
|
||||
|
||||
#include "Generator.h"
|
||||
|
||||
#include "../Project.h"
|
||||
#include "../Prefs.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Generator.h"
|
||||
#include "TimeWarper.h"
|
||||
|
||||
#include <memory>
|
||||
|
|
|
@ -43,6 +43,8 @@
|
|||
#include "../ShuttleGui.h"
|
||||
#include "../Prefs.h"
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <vector>
|
||||
#include <math.h>
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
|
||||
#include "../Audacity.h" // for rint from configwin.h
|
||||
#include "Normalize.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
|
@ -28,8 +29,6 @@
|
|||
#include "../WaveTrack.h"
|
||||
#include "../widgets/valnum.h"
|
||||
|
||||
#include "Normalize.h"
|
||||
|
||||
// Define keys, defaults, minimums, and maximums for the effect parameters
|
||||
//
|
||||
// Name Type Key Def Min Max Scale
|
||||
|
|
|
@ -18,8 +18,6 @@
|
|||
#include <wx/string.h>
|
||||
#include <wx/textctrl.h>
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
||||
class ShuttleGui;
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include "../FFT.h"
|
||||
#include "../widgets/valnum.h"
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
// Define keys, defaults, minimums, and maximums for the effect parameters
|
||||
//
|
||||
// Name Type Key Def Min Max Scale
|
||||
|
|
|
@ -12,8 +12,6 @@
|
|||
|
||||
#include <wx/string.h>
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
||||
class ShuttleGui;
|
||||
|
|
|
@ -15,14 +15,14 @@
|
|||
|
||||
|
||||
#include "../Audacity.h"
|
||||
#include "Reverse.h"
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#include <wx/intl.h>
|
||||
|
||||
#include "../LabelTrack.h"
|
||||
|
||||
#include "Reverse.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
//
|
||||
// EffectReverse
|
||||
|
|
|
@ -15,8 +15,6 @@
|
|||
|
||||
#include <wx/string.h>
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Effect.h"
|
||||
|
||||
#define REVERSE_PLUGIN_SYMBOL XO("Reverse")
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include <wx/intl.h>
|
||||
|
||||
#include "../ShuttleGui.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
EffectSilence::EffectSilence()
|
||||
{
|
||||
|
|
|
@ -15,7 +15,6 @@
|
|||
|
||||
#include <wx/string.h>
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
#include "../widgets/NumericTextCtrl.h"
|
||||
|
||||
#include "Generator.h"
|
||||
|
|
|
@ -14,12 +14,12 @@
|
|||
*//*******************************************************************/
|
||||
|
||||
#include "../Audacity.h"
|
||||
#include "StereoToMono.h"
|
||||
|
||||
#include <wx/intl.h>
|
||||
|
||||
#include "../Project.h"
|
||||
|
||||
#include "StereoToMono.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
EffectStereoToMono::EffectStereoToMono()
|
||||
{
|
||||
|
|
|
@ -22,6 +22,8 @@ doing the second pass over all selected tracks.
|
|||
|
||||
#include "TwoPassSimpleMono.h"
|
||||
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
bool EffectTwoPassSimpleMono::Process()
|
||||
{
|
||||
mPass = 0;
|
||||
|
|
|
@ -40,6 +40,8 @@
|
|||
#include "../../ShuttleGui.h"
|
||||
#include "../../widgets/valnum.h"
|
||||
|
||||
#include "../../WaveTrack.h"
|
||||
|
||||
enum
|
||||
{
|
||||
ID_Program = 10000,
|
||||
|
|
|
@ -71,7 +71,6 @@
|
|||
#include "../Prefs.h"
|
||||
#include "../Project.h"
|
||||
#include "../ShuttleGui.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../widgets/Warning.h"
|
||||
#include "../AColor.h"
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include <wx/button.h>
|
||||
#include <wx/combobox.h>
|
||||
#include <wx/log.h>
|
||||
#include <wx/msgdlg.h>
|
||||
#include <wx/process.h>
|
||||
#include <wx/sizer.h>
|
||||
#include <wx/textctrl.h>
|
||||
|
@ -31,6 +32,8 @@
|
|||
#include "../float_cast.h"
|
||||
#include "../widgets/FileHistory.h"
|
||||
|
||||
#include "../Track.h"
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
// ExportCLOptions
|
||||
|
|
|
@ -42,7 +42,6 @@ function.
|
|||
#include "../Project.h"
|
||||
#include "../Tags.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
#include "Export.h"
|
||||
#include "ExportFFmpeg.h"
|
||||
|
|
|
@ -41,6 +41,8 @@ and libvorbis examples, Monty <monty@xiph.org>
|
|||
#include "../Internat.h"
|
||||
#include "../Tags.h"
|
||||
|
||||
#include "../Track.h"
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
// ExportFLACOptions Class
|
||||
//----------------------------------------------------------------------------
|
||||
|
|
|
@ -55,7 +55,7 @@
|
|||
#include "../Project.h"
|
||||
#include "../ShuttleGui.h"
|
||||
#include "../Tags.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../Track.h"
|
||||
|
||||
#define LIBTWOLAME_STATIC
|
||||
#include "twolame.h"
|
||||
|
|
|
@ -86,7 +86,7 @@
|
|||
#include "../Project.h"
|
||||
#include "../ShuttleGui.h"
|
||||
#include "../Tags.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../Track.h"
|
||||
#include "../widgets/LinkingHtmlWindow.h"
|
||||
|
||||
#include "FileDialog.h"
|
||||
|
|
|
@ -48,6 +48,7 @@
|
|||
#include "../Prefs.h"
|
||||
#include "../ShuttleGui.h"
|
||||
#include "../Tags.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../widgets/HelpSystem.h"
|
||||
|
||||
|
||||
|
|
|
@ -35,6 +35,7 @@
|
|||
|
||||
#include "../Internat.h"
|
||||
#include "../Tags.h"
|
||||
#include "../Track.h"
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
// ExportOGGOptions
|
||||
|
|
|
@ -35,7 +35,6 @@
|
|||
#include "../ShuttleGui.h"
|
||||
#include "../Tags.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../ondemand/ODManager.h"
|
||||
|
||||
#include "Export.h"
|
||||
|
|
|
@ -90,7 +90,6 @@
|
|||
#include "../Project.h"
|
||||
#include "../FileFormats.h"
|
||||
#include "../Prefs.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../Internat.h"
|
||||
|
||||
#define BINARY_FILE_CHECK_BUFFER_SIZE 1024
|
||||
|
|
|
@ -20,6 +20,7 @@ updating the ODPCMAliasBlockFile and the GUI of the newly available data.
|
|||
|
||||
#include "ODComputeSummaryTask.h"
|
||||
#include "../blockfile/ODPCMAliasBlockFile.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include <wx/wx.h>
|
||||
|
||||
//36 blockfiles > 3 minutes stereo 44.1kHz per ODTask::DoSome
|
||||
|
|
|
@ -18,6 +18,7 @@ updating the ODPCMAliasBlockFile and the GUI of the newly available data.
|
|||
|
||||
#include "ODDecodeTask.h"
|
||||
#include "../blockfile/ODDecodeBlockFile.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include <wx/wx.h>
|
||||
|
||||
///Creates a new task that computes summaries for a wavetrack that needs to be specified through SetWaveTrack()
|
||||
|
|
|
@ -20,12 +20,15 @@ KeyConfigPrefs and MousePrefs use.
|
|||
*//*********************************************************************/
|
||||
|
||||
#include "../Audacity.h"
|
||||
#include "../Experimental.h"
|
||||
#include "KeyConfigPrefs.h"
|
||||
|
||||
#include <wx/defs.h>
|
||||
#include <wx/ffile.h>
|
||||
#include <wx/intl.h>
|
||||
#include <wx/filedlg.h>
|
||||
#include <wx/button.h>
|
||||
#include <wx/msgdlg.h>
|
||||
|
||||
#include "../Prefs.h"
|
||||
#include "../Project.h"
|
||||
|
@ -35,7 +38,6 @@ KeyConfigPrefs and MousePrefs use.
|
|||
|
||||
#include "../Internat.h"
|
||||
#include "../ShuttleGui.h"
|
||||
#include "KeyConfigPrefs.h"
|
||||
|
||||
#include "FileDialog.h"
|
||||
|
||||
|
|
|
@ -30,6 +30,8 @@ class ShuttleGui;
|
|||
|
||||
#include "PrefsPanel.h"
|
||||
|
||||
class wxStaticText;
|
||||
|
||||
class KeyConfigPrefs :public PrefsPanel
|
||||
{
|
||||
public:
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
*//*******************************************************************/
|
||||
|
||||
#include "../Audacity.h"
|
||||
#include "QualityPrefs.h"
|
||||
|
||||
#include <wx/defs.h>
|
||||
|
||||
|
@ -26,8 +27,6 @@
|
|||
#include "../SampleFormat.h"
|
||||
#include "../ShuttleGui.h"
|
||||
|
||||
#include "QualityPrefs.h"
|
||||
|
||||
#define ID_SAMPLE_RATE_CHOICE 7001
|
||||
|
||||
BEGIN_EVENT_TABLE(QualityPrefs, PrefsPanel)
|
||||
|
|
|
@ -21,6 +21,7 @@ Paul Licameli
|
|||
#include "../Project.h"
|
||||
#include "../TrackPanel.h"
|
||||
#include "../ShuttleGui.h"
|
||||
#include "../WaveTrack.h"
|
||||
|
||||
WaveformPrefs::WaveformPrefs(wxWindow * parent, WaveTrack *wt)
|
||||
: PrefsPanel(parent, _("Waveforms"))
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
|
||||
#include "../Audacity.h"
|
||||
#include "../Experimental.h"
|
||||
#include "ControlToolBar.h"
|
||||
|
||||
// For compilers that support precompilation, includes "wx/wx.h".
|
||||
#include <wx/wxprec.h>
|
||||
|
@ -51,7 +52,6 @@
|
|||
#endif
|
||||
#include <wx/tooltip.h>
|
||||
|
||||
#include "ControlToolBar.h"
|
||||
#include "TranscriptionToolBar.h"
|
||||
#include "MeterToolBar.h"
|
||||
|
||||
|
@ -62,7 +62,7 @@
|
|||
#include "../Prefs.h"
|
||||
#include "../Project.h"
|
||||
#include "../Theme.h"
|
||||
#include "../Track.h"
|
||||
#include "../WaveTrack.h"
|
||||
#include "../widgets/AButton.h"
|
||||
#include "../widgets/Meter.h"
|
||||
|
||||
|
|
|
@ -52,6 +52,7 @@
|
|||
#include "../Prefs.h"
|
||||
#include "../Project.h"
|
||||
#include "../Theme.h"
|
||||
#include "../Track.h"
|
||||
#include "../UndoManager.h"
|
||||
#include "../widgets/AButton.h"
|
||||
|
||||
|
|
|
@ -544,6 +544,7 @@
|
|||
<ClInclude Include="..\..\..\src\SseMathFuncs.h" />
|
||||
<ClInclude Include="..\..\..\src\toolbars\SpectralSelectionBar.h" />
|
||||
<ClInclude Include="..\..\..\src\toolbars\SpectralSelectionBarListener.h" />
|
||||
<ClInclude Include="..\..\..\src\WaveTrackLocation.h" />
|
||||
<ClInclude Include="..\..\..\src\widgets\HelpSystem.h" />
|
||||
<ClInclude Include="..\..\..\src\widgets\NumericTextCtrl.h" />
|
||||
<ClInclude Include="..\..\configwin.h" />
|
||||
|
|
|
@ -1700,6 +1700,9 @@
|
|||
<ClInclude Include="..\..\..\src\prefs\WaveformSettings.h">
|
||||
<Filter>src/prefs</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\..\src\WaveTrackLocation.h">
|
||||
<Filter>src</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Image Include="..\..\audacity.ico">
|
||||
|
|
Loading…
Reference in New Issue