- boost::shared_ptr<const AudioContent> _audio_content;
- boost::shared_ptr<Resampler> _resampler;
- /* End time of last audio that we wrote to _pending; only used for flushing the resampler */
- ContentTime _last_audio;
+ dcpomatic::ContentTime stream_position (std::shared_ptr<const Film> film, AudioStreamPtr stream) const;
+
+ boost::signals2::signal<void (AudioStreamPtr, ContentAudio)> Data;
+
+private:
+ void silence (int milliseconds);
+
+ std::shared_ptr<const AudioContent> _content;
+ /** Frame after the last one that was emitted from Data (i.e. at the resampled rate, if applicable)
+ * for each AudioStream.
+ */
+ typedef std::map<AudioStreamPtr, Frame> PositionMap;
+ PositionMap _positions;
+ typedef std::map<AudioStreamPtr, std::shared_ptr<Resampler>> ResamplerMap;
+ ResamplerMap _resamplers;
+
+ bool _fast;