Tests pass again.
[dcpomatic.git] / src / lib / util.cc
index 2194418653b96d4a753e54218bdf3ce3dc1e98e5..5e82650a56c6e29a5c00ff988cf1c493fe3e3b1b 100644 (file)
@@ -620,12 +620,18 @@ Rect::intersection (Rect const & other) const
  */
 
 int
-round_up (int a, int t)
+stride_round_up (int c, int const * stride, int t)
 {
-       a += (t - 1);
+       int const a = stride[c] + (t - 1);
        return a - (a % t);
 }
 
+int
+stride_lookup (int c, int const * stride)
+{
+       return stride[c];
+}
+
 /** Read a sequence of key / value pairs from a text stream;
  *  the keys are the first words on the line, and the values are
  *  the remainder of the line following the key.  Lines beginning