Fill audio in the Player.
[dcpomatic.git] / src / lib / playlist.cc
index 09b67e921bf42e2820937212fd1cfae32a3bdef7..d37f287837110a283b8ee56003d58011853fb1f3 100644 (file)
@@ -555,6 +555,18 @@ Playlist::video_content_at (DCPTime time) const
        return false;
 }
 
+bool
+Playlist::audio_content_at (DCPTime time) const
+{
+       BOOST_FOREACH (shared_ptr<Content> i, _content) {
+               if (i->audio && i->position() <= time && time < i->end()) {
+                       return true;
+               }
+       }
+
+       return false;
+}
+
 pair<double, double>
 Playlist::speed_up_range (int dcp_video_frame_rate) const
 {