MCPcopy Create free account
hub / github.com/HertzDevil/0CC-FamiTracker / IsPatternInUse

Method IsPatternInUse

Source/SongData.cpp:59–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57}
58
59bool CSongData::IsPatternInUse(stChannelID Channel, unsigned int Pattern) const
60{
61 // Check if pattern is addressed in frame list
62 if (Pattern < MAX_PATTERN)
63 if (auto *pTrack = GetTrack(Channel))
64 for (unsigned i = 0; i < GetFrameCount(); ++i)
65 if (pTrack->GetFramePattern(i) == Pattern)
66 return true;
67 return false;
68}
69
70unsigned CSongData::GetFreePatternIndex(stChannelID Channel, unsigned Whence) const { // // //
71 while (++Whence < MAX_PATTERN)

Callers 3

SavePatternsMethod · 0.80
ExportRowsMethod · 0.80
RemoveUnusedPatternsMethod · 0.80

Calls 1

GetFramePatternMethod · 0.45

Tested by

no test coverage detected