mirror of
https://forgejo.xatacraft.ru/Sunshine/mkxp-sunshine.git
synced 2026-08-19 21:39:57 +00:00
alstream.cpp changes
This commit is contained in:
parent
78384d56c9
commit
41731bc796
2 changed files with 5 additions and 5 deletions
|
|
@ -208,15 +208,15 @@ struct ALStreamOpenHandler : FileSystem::OpenHandler
|
||||||
ALDataSource *source;
|
ALDataSource *source;
|
||||||
std::string errorMsg;
|
std::string errorMsg;
|
||||||
|
|
||||||
ALStreamOpenHandler(SDL_IOStream &srcOps, bool looped)
|
ALStreamOpenHandler(SDL_IOStream* &srcOps, bool looped)
|
||||||
: srcOps(&srcOps), looped(looped), source(0)
|
: srcOps(srcOps), looped(looped), source(0)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
bool tryRead(SDL_IOStream &ops, const char *ext)
|
bool tryRead(SDL_IOStream* &ops, const char *ext)
|
||||||
{
|
{
|
||||||
/* Copy this because we need to keep it around,
|
/* Copy this because we need to keep it around,
|
||||||
* as we will continue reading data from it later */
|
* as we will continue reading data from it later */
|
||||||
*srcOps = ops;
|
srcOps = ops;
|
||||||
|
|
||||||
/* Try to read ogg file signature */
|
/* Try to read ogg file signature */
|
||||||
char sig[5] = { 0 };
|
char sig[5] = { 0 };
|
||||||
|
|
|
||||||
|
|
@ -52,7 +52,7 @@ public:
|
||||||
* After this function returns, ops becomes invalid, so don't take
|
* After this function returns, ops becomes invalid, so don't take
|
||||||
* references to it. Instead, copy the structure without closing
|
* references to it. Instead, copy the structure without closing
|
||||||
* if you need to further read from it later. */
|
* if you need to further read from it later. */
|
||||||
virtual bool tryRead(SDL_IOStream &ops, const char *ext) = 0;
|
virtual bool tryRead(SDL_IOStream* &ops, const char *ext) = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
void openRead(OpenHandler &handler,
|
void openRead(OpenHandler &handler,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue