InvSounds.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. /*
  2. * Copyright (c) 2011 Nokia Corporation.
  3. */
  4. #ifndef __CINVSOUNDS__
  5. #define __CINVSOUNDS__
  6. #include <QObject>
  7. #include <QStringList>
  8. #include "ga_src/GEAudioBuffer.h"
  9. #include "ga_src/GEAudioOut.h"
  10. class CInvSounds : public QObject
  11. {
  12. Q_OBJECT
  13. public:
  14. CInvSounds(QObject *parent);
  15. ~CInvSounds();
  16. void enableInternalSounds();
  17. void enableSounds(QStringList sounds);
  18. void disableInternalSounds();
  19. void disableSounds();
  20. void beginMusicOn();
  21. void beginMusicOff();
  22. void enableSounds(bool enable);
  23. void gameStartSound();
  24. public slots:
  25. void playSound(int index);
  26. void playSounds(int index, int count);
  27. void playInternalSound(int index);
  28. void playInternalSounds(int index, int count);
  29. protected:
  30. QStringList m_soundPaths;
  31. QStringList m_internalSoundPaths;
  32. GE::CAudioBufferPlayInstance *m_musicInstance;
  33. GE::CAudioMixer m_mixer;
  34. GE::AudioOut *m_audioOut;
  35. GE::CAudioBuffer **m_sounds;
  36. int m_soundCount;
  37. GE::CAudioBuffer **m_internalSounds;
  38. int m_internalSoundCount;
  39. };
  40. #endif