Barely-functioning GL playback with new arrangement.
[dcpomatic.git] / src / lib / string_text_file_content.cc
index 35f76be7c4d1894346a4426363a1aba4f416060c..9a25ef06f00ce6e10532721b88183a9d0ed46d9a 100644 (file)
@@ -35,6 +35,7 @@ using std::cout;
 using boost::shared_ptr;
 using boost::optional;
 using dcp::raw_convert;
+using namespace dcpomatic;
 
 StringTextFileContent::StringTextFileContent (boost::filesystem::path path)
        : Content (path)
@@ -91,6 +92,20 @@ StringTextFileContent::as_xml (xmlpp::Node* node, bool with_paths) const
 DCPTime
 StringTextFileContent::full_length (shared_ptr<const Film> film) const
 {
-       FrameRateChange const frc (active_video_frame_rate(film), film->video_frame_rate());
+       FrameRateChange const frc (film, shared_from_this());
        return DCPTime (_length, frc);
 }
+
+DCPTime
+StringTextFileContent::approximate_length () const
+{
+       return DCPTime (_length, FrameRateChange());
+}
+
+string
+StringTextFileContent::identifier () const
+{
+       string s = Content::identifier ();
+       s += "_" + only_text()->identifier();
+       return s;
+}