summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2017-07-24 12:10:26 +0100
committerCarl Hetherington <cth@carlh.net>2017-07-24 12:10:26 +0100
commita01d614435e4c13dcede5d9f325a1864e576147d (patch)
tree8a1022da2d2a8bd991991a464b014ff79281a468
parentd6e86ba2a977db14120c3dc6c9169df83ef23a5b (diff)
Comments.
-rw-r--r--src/interop_subtitle_asset.cc6
-rw-r--r--src/subtitle_asset.h1
2 files changed, 6 insertions, 1 deletions
diff --git a/src/interop_subtitle_asset.cc b/src/interop_subtitle_asset.cc
index 54c27ff5..7d3114c3 100644
--- a/src/interop_subtitle_asset.cc
+++ b/src/interop_subtitle_asset.cc
@@ -192,6 +192,10 @@ InteropSubtitleAsset::write (boost::filesystem::path p) const
}
}
+/** Look at a supplied list of assets and find the fonts. Then match these
+ * fonts up with anything requested by a <LoadFont> so that _fonts contains
+ * a list of font ID, load ID and data.
+ */
void
InteropSubtitleAsset::resolve_fonts (list<shared_ptr<Asset> > assets)
{
@@ -209,7 +213,7 @@ InteropSubtitleAsset::resolve_fonts (list<shared_ptr<Asset> > assets)
break;
}
}
-
+
if (!got && font->file() && j->uri == font->file()->leaf().string()) {
_fonts.push_back (Font (j->id, i->id(), font->file().get()));
}
diff --git a/src/subtitle_asset.h b/src/subtitle_asset.h
index e40118c4..ce76eb3b 100644
--- a/src/subtitle_asset.h
+++ b/src/subtitle_asset.h
@@ -161,6 +161,7 @@ protected:
mutable boost::optional<boost::filesystem::path> file;
};
+ /** TTF font data that we need */
std::list<Font> _fonts;
private: