+
+/** @return a list of properties that might be interesting to the user */
+list<UserProperty>
+Content::user_properties () const
+{
+ list<UserProperty> p;
+ add_properties (p);
+ return p;
+}
+
+shared_ptr<const Film>
+Content::film () const
+{
+ shared_ptr<const Film> film = _film.lock ();
+ DCPOMATIC_ASSERT (film);
+ return film;
+}
+
+/** @return DCP times of points within this content where a reel split could occur */
+list<DCPTime>
+Content::reel_split_points () const
+{
+ list<DCPTime> t;
+ /* XXX: this is questionable; perhaps the position itself should be forced to be on a frame boundary */
+ t.push_back (position().round_up (film()->video_frame_rate()));
+ return t;
+}
+
+void
+Content::set_video_frame_rate (double r)
+{
+ {
+ boost::mutex::scoped_lock lm (_mutex);
+ _video_frame_rate = r;
+ }
+
+ signal_changed (ContentProperty::VIDEO_FRAME_RATE);
+}
+
+double
+Content::active_video_frame_rate () const
+{
+ {
+ boost::mutex::scoped_lock lm (_mutex);
+ if (_video_frame_rate) {
+ return _video_frame_rate.get ();
+ }
+ }
+
+ /* No frame rate specified, so assume this content has been
+ prepared for any concurrent video content or perhaps
+ just the DCP rate.
+ */
+ shared_ptr<const Film> film = _film.lock ();
+ DCPOMATIC_ASSERT (film);
+ return film->active_frame_rate_change(position()).source;
+}
+
+void
+Content::add_properties (list<UserProperty>& p) const
+{
+ p.push_back (UserProperty (UserProperty::GENERAL, _("Filename"), path(0).string ()));
+
+ if (_video_frame_rate) {
+ p.push_back (
+ UserProperty (
+ UserProperty::GENERAL, _("Video frame rate"), raw_convert<string> (_video_frame_rate.get(), 5), _("frames per second")
+ )
+ );
+ }
+}