X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fresampler.h;h=0dbd0b491edaa3c3b64d0ad00291ef0dca95ce91;hb=f4e42377cfce59a6b88dcb29c3be2d95c5045b29;hp=359598b122b17b4f1dbe30139eaba8ce91409bbe;hpb=89aa9d4ba69e471949f791cdafe4ae20cea554d2;p=dcpomatic.git diff --git a/src/lib/resampler.h b/src/lib/resampler.h index 359598b12..0dbd0b491 100644 --- a/src/lib/resampler.h +++ b/src/lib/resampler.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2013-2015 Carl Hetherington + Copyright (C) 2013-2021 Carl Hetherington This file is part of DCP-o-matic. @@ -18,28 +18,31 @@ */ + #include "types.h" #include -#include -#include + class AudioBuffers; -class Resampler : public boost::noncopyable + +class Resampler { public: Resampler (int, int, int); ~Resampler (); - std::pair, Frame> run (boost::shared_ptr, Frame); - boost::shared_ptr flush (); + Resampler (Resampler const&) = delete; + Resampler& operator= (Resampler const&) = delete; + + std::shared_ptr run (std::shared_ptr); + std::shared_ptr flush (); + void reset (); void set_fast (); private: - SRC_STATE* _src; + SRC_STATE* _src = nullptr; int _in_rate; int _out_rate; int _channels; - boost::optional _next_in; - boost::optional _next_out; };