Merge.
[dcpomatic.git] / src / lib / decoder.cc
index 5778949963ccb63cff592626b96094da2e4a6cc5..fd0abee4183e540b4a4db5c5a9cb3588e5d8a34c 100644 (file)
@@ -46,19 +46,31 @@ using boost::shared_ptr;
 using boost::optional;
 
 /** @param f Film.
- *  @param o Options.
+ *  @param o Decode options.
  *  @param j Job that we are running within, or 0
  */
-Decoder::Decoder (boost::shared_ptr<Film> f, boost::shared_ptr<const Options> o, Job* j)
+Decoder::Decoder (boost::shared_ptr<Film> f, DecodeOptions o, Job* j)
        : _film (f)
        , _opt (o)
        , _job (j)
 {
-       
+       _film_connection = f->Changed.connect (bind (&Decoder::film_changed, this, _1));
 }
 
-void
-Decoder::seek (SourceFrame f)
+/** Seek to a position as a source timestamp in seconds.
+ *  @return true on error.
+ */
+bool
+Decoder::seek (double)
+{
+       throw DecodeError ("decoder does not support seek");
+}
+
+/** Seek so that the next frame we will produce is the same as the last one.
+ *  @return true on error.
+ */
+bool
+Decoder::seek_to_last ()
 {
        throw DecodeError ("decoder does not support seek");
 }