X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=simgear%2Fsound%2Fxmlsound.hxx;h=95582aab12ca65cda2c5f8ec924653965c565464;hb=bcb320b537b6f7e5e3724e8a30d309322171eb43;hp=d161bbca4acf5f32035da558f38d26963d18ba22;hpb=7e7ce2f38e87d6244e05730fa4382da088bb25f1;p=simgear.git diff --git a/simgear/sound/xmlsound.hxx b/simgear/sound/xmlsound.hxx index d161bbca..95582aab 100644 --- a/simgear/sound/xmlsound.hxx +++ b/simgear/sound/xmlsound.hxx @@ -36,10 +36,11 @@ #include #include -#include +#include + +#include "sample_group.hxx" #include "sample_openal.hxx" -#include "soundmgr_openal.hxx" static const double MAX_TRANSIT_TIME = 0.1; // 100 ms. @@ -99,11 +100,12 @@ public: * @param root The root node of the programs property tree. * @param child A pointer to the location of the current event as defined * in the configuration file. - * @param sndmgr A pointer to a pre-initialized sound manager class. + * @param sgrp A pointer to a pre-initialized sample group class. + * @param avionics A pointer to the pre-initialized avionics sample group. * @param path The path where the audio files remain. */ - virtual void init (SGPropertyNode *, SGPropertyNode *, SGSoundMgr *, - const string &); + virtual void init (SGPropertyNode *, SGPropertyNode *, SGSampleGroup *, + SGSampleGroup *, const SGPath& currentDir); /** * Check whether an event has happened and if action has to be taken. @@ -135,7 +137,7 @@ protected: private: - SGSoundMgr * _mgr; + SGSampleGroup * _sgrp; SGSharedPtr _sample; SGSharedPtr _condition; @@ -148,12 +150,12 @@ private: double _dt_play; double _dt_stop; double _delay; // time after which the sound should be started (default: 0) - double _stopping; // time after the sound should have stopped. - // This is useful for lost packets in in-transit mode. + double _stopping; // time after the sound should have stopped. + // This is useful for lost packets in in-transit mode. + bool _initialized; std::vector<_snd_prop> _volume; std::vector<_snd_prop> _pitch; - }; #endif // _SG_SOUND_HXX