1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-19 15:44:20 +01:00

Sequence.cpp does not depend on ODDecodeBlockFile.cpp...

... This frees Sequence.cpp from dependency cycles
This commit is contained in:
Paul Licameli
2019-05-15 10:44:21 -04:00
parent 0832bccc7b
commit 7b51653b36
3 changed files with 11 additions and 19 deletions

View File

@@ -1599,12 +1599,21 @@ void WaveTrack::AppendCoded(const FilePath &fName, sampleCount start,
}
///gets an int with OD flags so that we can determine which ODTasks should be run on this track after save/open, etc.
#include "blockfile/ODDecodeBlockFile.h"
unsigned int WaveTrack::GetODFlags() const
{
unsigned int ret = 0;
for (const auto &clip : mClips)
{
ret = ret | clip->GetSequence()->GetODFlags();
auto sequence = clip->GetSequence();
const auto &blocks = sequence->GetBlockArray();
for ( const auto &block : blocks ) {
const auto &file = block.f;
if(!file->IsDataAvailable())
ret |= (static_cast< ODDecodeBlockFile * >( &*file ))->GetDecodeType();
else if(!file->IsSummaryAvailable())
ret |= ODTask::eODPCMSummary;
}
}
return ret;
}