swaroop: support validity periods in ecinema KDMs.
[dcpomatic.git] / src / tools / dcpomatic_player.cc
index 6a64bd0ded4f26d80492b9fd3505c472671425b5..90cc818ca5d85271001c576ce0df8c5a033c37ad 100644 (file)
@@ -287,6 +287,15 @@ public:
                        }
                }
 
+#ifdef DCPOMATIC_VARIANT_SWAROOP
+               BOOST_FOREACH (shared_ptr<Content> i, _film->content()) {
+                       shared_ptr<FFmpegContent> c = dynamic_pointer_cast<FFmpegContent>(i);
+                       if (c && !c->kdm_timing_window_valid()) {
+                               ok = false;
+                       }
+               }
+#endif
+
                if (!ok) {
                        error_dialog (this, _("The KDM does not allow playback of this content at this time."));
                }