X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fsndfile_decoder.h;h=844d1cdc42818219e81e82a7cf1f04077851e6b6;hb=cc0ac806a2dc698d9c20b24498bc865e2d9798ad;hp=46d9c5e5cf24762b5c2733e4f8c0be6c035a4d97;hpb=e8204f55c981493b99814f71a50b3c3d62601032;p=dcpomatic.git diff --git a/src/lib/sndfile_decoder.h b/src/lib/sndfile_decoder.h index 46d9c5e5c..844d1cdc4 100644 --- a/src/lib/sndfile_decoder.h +++ b/src/lib/sndfile_decoder.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2012-2013 Carl Hetherington + Copyright (C) 2012-2015 Carl Hetherington This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -17,31 +17,22 @@ */ -#include -#include "decoder.h" #include "audio_decoder.h" +#include "sndfile_base.h" class SndfileContent; -class SndfileDecoder : public AudioDecoder +class SndfileDecoder : public Sndfile, public AudioDecoder { public: - SndfileDecoder (boost::shared_ptr, boost::shared_ptr); + SndfileDecoder (boost::shared_ptr c, bool fast); ~SndfileDecoder (); +private: + bool pass (PassReason, bool); void seek (ContentTime, bool); - int audio_channels () const; - AudioFrame audio_length () const; - int audio_frame_rate () const; - -private: - bool pass (); - - boost::shared_ptr _sndfile_content; - SNDFILE* _sndfile; - SF_INFO _info; - AudioFrame _done; - AudioFrame _remaining; + int64_t _done; + int64_t _remaining; float* _deinterleave_buffer; };