Audacity 3.2.0
|
Two sample formats, remembering format of original source and describing stored format. More...
#include <SampleFormat.h>
Public Member Functions | |
SampleFormats (sampleFormat effective, sampleFormat stored) | |
sampleFormat | Effective () const |
sampleFormat | Stored () const |
void | UpdateEffective (sampleFormat effective) |
Update the effective format, for insertion of more samples into the sequence. More... | |
Private Attributes | |
sampleFormat | m_Effective |
sampleFormat | m_Stored |
Two sample formats, remembering format of original source and describing stored format.
Useful when imported data are stored temporarily in a wider format but should be exported bit-perfect without dither if to the original format again
Effective() <= Stored()
Definition at line 79 of file SampleFormat.h.
|
inline |
Construct sampleFormats, but may change effective to satisfy the invariant
effective | How much real information in each sample |
stored | The form used for storage |
Definition at line 82 of file SampleFormat.h.
|
inline |
Definition at line 90 of file SampleFormat.h.
References m_Effective.
Referenced by Sequence::ConvertToSampleFormat(), Sequence::Copy(), Sequence::HandleXMLTag(), operator==(), and Sequence::Paste().
|
inline |
Definition at line 91 of file SampleFormat.h.
References m_Stored.
Referenced by Sequence::Append(), Sequence::ConvertToSampleFormat(), Sequence::Copy(), Sequence::Delete(), Sequence::DoAppend(), Sequence::Flush(), anonymous_namespace{WaveDataCache.cpp}::AppendBufferHelper::GetAppendBufferPointer(), Sequence::HandleXMLTag(), Sequence::InsertSilence(), operator==(), WaveClip::Paste(), Sequence::Paste(), Sequence::SetSamples(), and Sequence::SetSilence().
|
inline |
Update the effective format, for insertion of more samples into the sequence.
GetEffective()
will not necessarily equal the given value, because the invariant will be preserved, and also GetEffective()
will never become narrower than before: if any material in the sequence had a wider format, assume that the whole sequence still requires dithering to lesser formats than that.
Definition at line 98 of file SampleFormat.h.
References m_Effective, m_Stored, and min().
Referenced by Sequence::Append(), Sequence::AppendNewBlock(), Sequence::Flush(), Sequence::Paste(), and Sequence::SetSamples().
|
private |
Definition at line 105 of file SampleFormat.h.
Referenced by Effective(), and UpdateEffective().
|
private |
Definition at line 106 of file SampleFormat.h.
Referenced by Stored(), and UpdateEffective().