dcpomatic::ContentTime dcp_to_content_time (boost::shared_ptr<const Film> film, dcpomatic::DCPTime t) const;
dcpomatic::DCPTime content_time_to_dcp (dcpomatic::ContentTime t) const;
+ void add_fonts (std::list<boost::shared_ptr<dcpomatic::Font> >& fonts) const;
+
private:
std::vector<boost::shared_ptr<Content> > _content;
std::vector<boost::shared_ptr<Decoder> > _decoder;
list<shared_ptr<Font> > fonts;
BOOST_FOREACH (shared_ptr<Piece> i, _pieces) {
- BOOST_FOREACH (shared_ptr<TextContent> j, i->content->text) {
- /* XXX: things may go wrong if there are duplicate font IDs
- with different font files.
- */
- list<shared_ptr<Font> > f = j->fonts ();
- copy (f.begin(), f.end(), back_inserter (fonts));
- }
+ i->add_fonts (fonts);
}
return fonts;