diff options
| author | Carl Hetherington <cth@carlh.net> | 2016-12-14 12:41:01 +0000 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2016-12-14 12:41:01 +0000 |
| commit | 9f034b0e2b39c2c56b767371af90deb888d8779f (patch) | |
| tree | cf84779fd6b377e97aafadddb1927223a3126e38 /src/lib/dcp_examiner.cc | |
| parent | c0811d5fdd337682a396be566d7a3399f722cec9 (diff) | |
Store reel lengths in DCPContent to speed up e.g. timeline with many DCPs.
Diffstat (limited to 'src/lib/dcp_examiner.cc')
| -rw-r--r-- | src/lib/dcp_examiner.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/dcp_examiner.cc b/src/lib/dcp_examiner.cc index 74640ff00..996924530 100644 --- a/src/lib/dcp_examiner.cc +++ b/src/lib/dcp_examiner.cc @@ -163,6 +163,14 @@ DCPExaminer::DCPExaminer (shared_ptr<const DCPContent> content) _has_subtitles = true; } + + if (i->main_picture()) { + _reel_lengths.push_back (i->main_picture()->duration()); + } else if (i->main_sound()) { + _reel_lengths.push_back (i->main_sound()->duration()); + } else if (i->main_subtitle()) { + _reel_lengths.push_back (i->main_subtitle()->duration()); + } } _encrypted = cpl->encrypted (); |
