summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2024-06-28 17:46:42 +0200
committerCarl Hetherington <cth@carlh.net>2024-06-28 17:46:42 +0200
commit85eebdf558ca89ce53bb59a0127f1c804e82981b (patch)
treebb7e6c654ed281ced61cece92452481a7f396288 /src
parent632fd6b46be907c044474a09ffffad6cccb14d08 (diff)
Diffstat (limited to 'src')
-rw-r--r--src/asset.cc2
-rw-r--r--src/cpl.cc6
-rw-r--r--src/subtitle_asset.cc3
3 files changed, 11 insertions, 0 deletions
diff --git a/src/asset.cc b/src/asset.cc
index ef06ea8d..f2efb293 100644
--- a/src/asset.cc
+++ b/src/asset.cc
@@ -114,10 +114,12 @@ Asset::add_to_assetmap(AssetMap& asset_map, boost::filesystem::path root) const
void
Asset::add_file_to_assetmap(AssetMap& asset_map, boost::filesystem::path root, boost::filesystem::path file, string id)
{
+ std::cout << "toot toot " << root << " " << file << "\n";
auto path = relative_to_root (
filesystem::canonical(root),
filesystem::canonical(file)
);
+ std::cout << "addin " << *path << "\n";
if (!path) {
/* The path of this asset is not within our DCP, so we assume it's an external
diff --git a/src/cpl.cc b/src/cpl.cc
index d3832d89..abbb57c1 100644
--- a/src/cpl.cc
+++ b/src/cpl.cc
@@ -615,6 +615,12 @@ add_file_assets (vector<shared_ptr<T>>& assets, vector<shared_ptr<Reel>> reels)
if (i->main_subtitle ()) {
assets.push_back (i->main_subtitle());
}
+ if (i->main_caption()) {
+ assets.push_back(i->main_caption());
+ }
+ for (auto j: i->closed_subtitles()) {
+ assets.push_back (j);
+ }
for (auto j: i->closed_captions()) {
assets.push_back (j);
}
diff --git a/src/subtitle_asset.cc b/src/subtitle_asset.cc
index 1cd4fc07..9203f508 100644
--- a/src/subtitle_asset.cc
+++ b/src/subtitle_asset.cc
@@ -567,8 +567,11 @@ vector<shared_ptr<const Subtitle>>
SubtitleAsset::subtitles_during (Time from, Time to, bool starting) const
{
vector<shared_ptr<const Subtitle>> s;
+ // std::cout << "checkin " << _subtitles.size() << "\n";
for (auto i: _subtitles) {
+ // std::cout << "starting=" << starting << " " << from << " " << to << " " << i->in() << " " << i->out() << "\n";
if ((starting && from <= i->in() && i->in() < to) || (!starting && i->out() >= from && i->in() <= to)) {
+ std::cout << "given it up\n";
s.push_back (i);
}
}