summaryrefslogtreecommitdiff
path: root/libs/ardour/sndfilesource.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2006-08-31 13:23:43 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2006-08-31 13:23:43 +0000
commit21d85f1854461ab6209d23e278fe289505cd106c (patch)
tree0c6d154757bcfb6c49223e59fc75a433e8e79bb2 /libs/ardour/sndfilesource.cc
parentdde980289aaf264863186eead99fd98a67cc6862 (diff)
merge changes from harrison branch back into trunk, by hand
git-svn-id: svn://localhost/ardour2/trunk@878 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/sndfilesource.cc')
-rw-r--r--libs/ardour/sndfilesource.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/libs/ardour/sndfilesource.cc b/libs/ardour/sndfilesource.cc
index 699522c2ad..faed2409e5 100644
--- a/libs/ardour/sndfilesource.cc
+++ b/libs/ardour/sndfilesource.cc
@@ -292,6 +292,11 @@ SndFileSource::read_unlocked (Sample *dst, jack_nframes_t start, jack_nframes_t
uint32_t real_cnt;
jack_nframes_t file_cnt;
+ //destructive (tape) tracks need to offset reads and writes by the timeline position
+ if (_flags && ARDOUR::Destructive == ARDOUR::Destructive) {
+ start -= timeline_position;
+ }
+
if (start > _length) {
/* read starts beyond end of data, just memset to zero */