Refactor!
This commit is contained in:
parent
cb09a6f5de
commit
cd451d1c2a
14 changed files with 13024 additions and 1920 deletions
34
LibraryViewer/public/Streamer.hpp
Normal file
34
LibraryViewer/public/Streamer.hpp
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
#pragma once
|
||||
|
||||
#include "Library.hpp"
|
||||
|
||||
class Context;
|
||||
|
||||
class MusicStream {
|
||||
friend Context;
|
||||
|
||||
public:
|
||||
MusicStream();
|
||||
~MusicStream();
|
||||
|
||||
bool openStream(SongId id);
|
||||
void closeStream();
|
||||
|
||||
tp::halnf* getBuffer();
|
||||
tp::ualni* getProgressLive();
|
||||
tp::uhalni getRate() const;
|
||||
|
||||
void continueStream();
|
||||
tp::ualni getFramesLength() const;
|
||||
tp::ualni getFramesLoaded() const;
|
||||
|
||||
public:
|
||||
class Context* mContext = nullptr;
|
||||
// tp::Mutex mMutex;
|
||||
|
||||
tp::ualni mLengthFrames = 0;
|
||||
tp::ualni mChanels = 0;
|
||||
tp::ualni mRate = 0;
|
||||
tp::ualni mProgress;
|
||||
tp::Buffer<tp::halnf> mBuffer;
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue