summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2018-03-22 21:52:18 +0000
committerCarl Hetherington <cth@carlh.net>2018-03-22 21:52:18 +0000
commitc0ffeee7cade9bf7e238e388da288a21aa885961 (patch)
tree0395c05854e62bf2909021b6ff5afd28401184a8
parent7ab664a235fcdd29b1f64d1b13bf4f022249c32a (diff)
Add hint about making a DCP with a very different frame rate to the content.
-rw-r--r--ChangeLog5
-rw-r--r--src/lib/hints.cc24
2 files changed, 29 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 662b19c12..9720cc001 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2018-03-22 Carl Hetherington <cth@carlh.net>
+
+ * Add hint about making a DCP with a very different frame rate
+ to the content.
+
2018-03-21 Carl Hetherington <cth@carlh.net>
* Updated nl_NL translation from Rob van Nieuwkerk.
diff --git a/src/lib/hints.cc b/src/lib/hints.cc
index 62e04f499..91aabdd56 100644
--- a/src/lib/hints.cc
+++ b/src/lib/hints.cc
@@ -133,6 +133,30 @@ get_hints (shared_ptr<const Film> film)
hints.push_back (h);
}
+ optional<double> lowest_speed_up;
+ optional<double> highest_speed_up;
+ BOOST_FOREACH (shared_ptr<const Content> i, content) {
+ double spu = film->active_frame_rate_change(i->position()).speed_up;
+ if (!lowest_speed_up || spu < *lowest_speed_up) {
+ lowest_speed_up = spu;
+ }
+ if (!highest_speed_up || spu > *highest_speed_up) {
+ highest_speed_up = spu;
+ }
+ }
+
+ double worst_speed_up = 1;
+ if (highest_speed_up) {
+ worst_speed_up = *highest_speed_up;
+ }
+ if (lowest_speed_up) {
+ worst_speed_up = max (worst_speed_up, 1 / *lowest_speed_up);
+ }
+
+ if (worst_speed_up > 25.5/24.0) {
+ hints.push_back (_("There is a large difference between the frame rate of your DCP and that of some of your content. This will cause your audio to play back at a much lower or higher pitch than it should. You are advised to set your DCP frame rate to one closer to your content, provided that your target projection systems support your chosen DCP rate."));
+ }
+
int vob = 0;
BOOST_FOREACH (shared_ptr<const Content> i, content) {
if (boost::algorithm::starts_with (i->path(0).filename().string(), "VTS_")) {