X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=simgear%2Fsound%2Fsample_openal.hxx;h=9e816c21aaf9aed5316003e9f590135829258a3c;hb=be7065674586ffbb5940ab21a028bc8c461217e2;hp=75d0975285e7ad9e16639b1476cb520f5c03146b;hpb=2a2e2716bdfbecb3494ab935171ed6224a178470;p=simgear.git diff --git a/simgear/sound/sample_openal.hxx b/simgear/sound/sample_openal.hxx index 75d09752..9e816c21 100644 --- a/simgear/sound/sample_openal.hxx +++ b/simgear/sound/sample_openal.hxx @@ -43,6 +43,8 @@ #include #include +class SGPath; + /** * manages everything we need to know for an individual audio sample */ @@ -58,11 +60,10 @@ public: /** * Constructor - * @param path Path name to sound * @param file File name of sound Buffer data is freed by the sample group */ - SGSoundSample( const char *path, const char *file ); + SGSoundSample(const char *file, const SGPath& currentDir); /** * Constructor. @@ -81,7 +82,7 @@ public: /** * Destructor */ - ~SGSoundSample (); + virtual ~SGSoundSample (); /** * Detect wheter this audio sample holds the information of a sound file. @@ -89,6 +90,8 @@ public: */ inline bool is_file() const { return _is_file; } + SGPath file_path() const; + /** * Test if this audio sample configuration has changed since the last call. * Calling this function will reset the flag so calling it a second @@ -115,7 +118,7 @@ public: * @param _loop Define whether this sound should be played in a loop. */ void play( bool loop = false ) { - _playing = true; _loop = loop; _changed = true; + _playing = true; _loop = loop; _changed = true; _static_changed = true; } /**