summaryrefslogtreecommitdiff
path: root/src/lib/resampler.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2017-05-21 19:48:14 +0100
committerCarl Hetherington <cth@carlh.net>2017-05-21 19:48:14 +0100
commitfa4d2529d63bcfa7cf7c516b7227e20a1b6dec7e (patch)
tree1ac1107370c7384fbce6cc67ee3e3aa6475f807e /src/lib/resampler.h
parent5bcbd6821a6ff1419f9069cf9e1a94c8557a992c (diff)
Do resampling in AudioDecoder rather than Player.
This fixes the problem where the decoder's position would not take into account that all samples pushed into the resampler do not always immediately come out. This would result in Player thinking that there would be gaps when there are not.
Diffstat (limited to 'src/lib/resampler.h')
-rw-r--r--src/lib/resampler.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/lib/resampler.h b/src/lib/resampler.h
index 9e9304fb4..4b19dc511 100644
--- a/src/lib/resampler.h
+++ b/src/lib/resampler.h
@@ -31,8 +31,8 @@ public:
Resampler (int, int, int);
~Resampler ();
- std::pair<boost::shared_ptr<const AudioBuffers>, Frame> run (boost::shared_ptr<const AudioBuffers>, Frame);
- std::pair<boost::shared_ptr<const AudioBuffers>, Frame> flush ();
+ boost::shared_ptr<const AudioBuffers> run (boost::shared_ptr<const AudioBuffers>);
+ boost::shared_ptr<const AudioBuffers> flush ();
void reset ();
void set_fast ();
@@ -41,6 +41,4 @@ private:
int _in_rate;
int _out_rate;
int _channels;
- boost::optional<Frame> _next_in;
- boost::optional<Frame> _next_out;
};