Name captures after their source track: label and filename both, on every interactive mint site, and show the name on the panel card
This commit is contained in:
@@ -54,9 +54,9 @@ namespace reasampler::capture {
|
||||
// captureAndIndexOne so every precision invariant holds; nothing lands in the
|
||||
// arrange (load-bearing principle).
|
||||
//
|
||||
// Each unit's baseName carries its ordinal ("item-1", "item-2", ...) so two units
|
||||
// in one batch never share a stem, and makeUniqueTag's per-session monotonic
|
||||
// counter keeps same-second units across batches from colliding too.
|
||||
// Each unit is named after its own source track and carries its batch ordinal, so two
|
||||
// units in one batch read apart even when they came off the same track; makeUniqueTag's
|
||||
// per-session monotonic counter keeps same-second units across batches from colliding.
|
||||
|
||||
namespace {
|
||||
|
||||
@@ -219,12 +219,14 @@ void RunBatchCaptureItems(ReaSamplerSession& session)
|
||||
// selected-items render source prints exactly it — batch keeps the
|
||||
// one-sample-per-item-at-item-extent semantics, unchanged.
|
||||
src.itemExtentIsWindow = true;
|
||||
src.trackNames.push_back(trackName(u.track));
|
||||
if (std::string g = guidString(u.track); !g.empty())
|
||||
src.trackGuids.push_back(std::move(g));
|
||||
|
||||
const std::string baseName = "item-" + std::to_string(unit.ordinal);
|
||||
const CaptureName name =
|
||||
captureNameFor(src.trackNames, unit.ordinal, "item");
|
||||
CaptureResult res = captureAndIndexOne(
|
||||
session, CaptureScope::Item, src, baseName,
|
||||
session, CaptureScope::Item, src, name,
|
||||
unit.startSeconds, unit.endSeconds);
|
||||
|
||||
const bool ok = (res.status == CaptureStatus::Ok);
|
||||
@@ -283,12 +285,14 @@ void RunBatchCaptureRazor(ReaSamplerSession& session)
|
||||
src.startSeconds = unit.startSeconds;
|
||||
src.endSeconds = unit.endSeconds;
|
||||
src.sourceTracks.push_back(tr);
|
||||
src.trackNames.push_back(trackName(tr));
|
||||
if (std::string g = guidString(tr); !g.empty())
|
||||
src.trackGuids.push_back(std::move(g));
|
||||
|
||||
const std::string baseName = "razor-" + std::to_string(unit.ordinal);
|
||||
const CaptureName name =
|
||||
captureNameFor(src.trackNames, unit.ordinal, "razor");
|
||||
CaptureResult res = captureAndIndexOne(
|
||||
session, CaptureScope::Track, src, baseName,
|
||||
session, CaptureScope::Track, src, name,
|
||||
unit.startSeconds, unit.endSeconds);
|
||||
|
||||
const bool ok = (res.status == CaptureStatus::Ok);
|
||||
|
||||
Reference in New Issue
Block a user