X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fyoink;a=blobdiff_plain;f=src%2Fmoof%2Fsound.cc;fp=src%2Fmoof%2Fsound.cc;h=a6fbf0310679faacc76175aa9d67b71079b1e9e5;hp=853c21a3d806f92bbb48fb91cb188b6d70e5c678;hb=382626aad0a683ed8642a6a807eea743db45f7f8;hpb=1da520638918096276158ecdfaeebc14a3d70be7 diff --git a/src/moof/sound.cc b/src/moof/sound.cc index 853c21a..a6fbf03 100644 --- a/src/moof/sound.cc +++ b/src/moof/sound.cc @@ -17,6 +17,7 @@ #include #include +#include #include #include #include @@ -233,7 +234,7 @@ buffer::retcount_lookup buffer::retain_counts_; // SOUND RESOURCE -class sound_resource +class sound_resource : public boost::noncopyable { public: @@ -252,7 +253,7 @@ public: } - bool read(buffer& buf) + bool read(buffer& buf) const { if (buffer_) { @@ -305,7 +306,7 @@ public: } - bool read(buffer& buf, uint64_t& sample) + bool read(buffer& buf, uint64_t& sample) const { if (ov_pcm_seek_lap(&file_, sample) != 0) { @@ -344,8 +345,8 @@ public: private: - OggVorbis_File file_; - buffer buffer_; + mutable OggVorbis_File file_; + mutable buffer buffer_; };