summaryrefslogtreecommitdiff
path: root/libs/ardour/playlist.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2011-12-27 16:29:40 +0000
committerCarl Hetherington <carl@carlh.net>2011-12-27 16:29:40 +0000
commit8f462004494e9d2eb8f716984770515d802a659f (patch)
tree0894a21e3236ea033741c9c48a4bf4f4ea838191 /libs/ardour/playlist.cc
parente41d64724caeca3ca7bc098153c6e6c50e310bc4 (diff)
Basic DEBUG_TRACE for layering code.
git-svn-id: svn://localhost/ardour2/branches/3.0@11091 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/playlist.cc')
-rw-r--r--libs/ardour/playlist.cc11
1 files changed, 11 insertions, 0 deletions
diff --git a/libs/ardour/playlist.cc b/libs/ardour/playlist.cc
index f2084fda0c..4d7e63599f 100644
--- a/libs/ardour/playlist.cc
+++ b/libs/ardour/playlist.cc
@@ -2361,9 +2361,16 @@ Playlist::compute_temporary_layers (RegionList const & relayer_regions)
for (RegionList::const_iterator i = relayer_regions.begin(); i != relayer_regions.end(); ++i) {
+ DEBUG_TRACE (DEBUG::Layering, string_compose ("Compute temporary layer for %1\n", (*i)->name()));
+
/* current_overlaps: regions that overlap *i now */
RegionList current_overlaps = cache.get ((*i)->bounds ());
current_overlaps.remove (*i);
+
+ DEBUG_TRACE (DEBUG::Layering, "Current overlaps:\n");
+ for (RegionList::iterator j = current_overlaps.begin(); j != current_overlaps.end(); ++j) {
+ DEBUG_TRACE (DEBUG::Layering, string_compose ("\t%1\n", (*j)->name()));
+ }
/* overlaps_to_preserve: regions that overlap *i now, but which aren't being
worked on during this relayer: these will have their relationship with
@@ -2486,6 +2493,8 @@ Playlist::commit_temporary_layers (TemporaryLayers const & temporary_layers)
RegionList all_regions = regions.rlist ();
all_regions.sort (SortByTemporaryLayer (temporary_layers));
+ DEBUG_TRACE (DEBUG::Layering, "Commit layering:\n");
+
for (RegionList::iterator i = all_regions.begin(); i != all_regions.end(); ++i) {
/* Go through the regions that we have already layered and hence work
@@ -2509,6 +2518,8 @@ Playlist::commit_temporary_layers (TemporaryLayers const & temporary_layers)
/* no overlap, so put on the bottom layer */
(*i)->set_layer (0);
}
+
+ DEBUG_TRACE (DEBUG::Layering, string_compose ("\t%1 %2\n", (*i)->name(), (*i)->layer()));
}
notify_layering_changed ();