12#ifndef __AUDACITY_MIX__
13#define __AUDACITY_MIX__
33 using Stages = std::vector<MixerOptions::StageSpecification>;
37 std::shared_ptr<const WideSampleSequence> pSequence = {},
39 ) : pSequence{ move(pSequence) }, stages{ move(stages) }
42 std::shared_ptr<const WideSampleSequence>
pSequence;
59 double startTime,
double stopTime,
60 unsigned numOutChannels,
size_t outBufferSize,
bool outInterleaved,
62 bool highQuality =
true,
65 bool applytTrackGains =
true);
86 size_t Process(
size_t maxSamples);
94 void Reposition(
double t,
bool bSkipping =
false);
97 void SetTimesAndSpeed(
98 double t0,
double t1,
double speed,
bool bSkipping =
false);
99 void SetSpeedForKeyboardScrubbing(
double speed,
double startTime);
103 double MixGetCurrentTime();
127 std::pair<bool, sampleFormat>
128 NeedsDither(
bool needsDither,
double rate)
const;
152 std::vector<std::vector<float>>
mTemp;
160 std::vector<std::unique_ptr<EffectStage>>
mStages;
Accumulates (non-interleaved) data during effect processing.
Upstream producer of sample streams, taking Buffers as external context.
Decorates a source with a non-timewarping effect, which may have latency.
Functions for doing the mixdown of the tracks.
AudioGraph::Buffers mFloatBuffers
std::vector< EffectSettings > mSettings
const std::vector< SampleBuffer > mBuffer
std::vector< Input > Inputs
std::vector< std::unique_ptr< EffectStage > > mStages
std::vector< Source > mDecoratedSources
const bool mApplyTrackGains
const sampleFormat mFormat
std::vector< std::vector< float > > mTemp
const unsigned mNumChannels
sampleFormat mEffectiveFormat
std::vector< MixerOptions::StageSpecification > Stages
Mixer(const Mixer &)=delete
std::vector< AudioGraph::Buffers > mStageBuffers
std::vector< MixerSource > mSources
size_t BufferSize() const
Mixer & operator=(const Mixer &)=delete
const std::shared_ptr< TimesAndSpeed > mTimesAndSpeed
A matrix of booleans, one row per input channel, column per output.
A flat linked list of tracks supporting Add, Remove, Clear, and Contains, serialization of the list o...
Positions or offsets within audio files need a wide type.
AudioGraph::Source & downstream
Immutable structure is an argument to Mixer's constructor.