~ubuntu-branches/ubuntu/natty/spring/natty

« back to all changes in this revision

Viewing changes to rts/System/Sound/NullSound.h

  • Committer: Bazaar Package Importer
  • Author(s): Scott Ritchie
  • Date: 2010-09-23 18:56:03 UTC
  • mfrom: (3.1.9 experimental)
  • Revision ID: james.westby@ubuntu.com-20100923185603-st97s5chplo42y7w
Tags: 0.82.5.1+dfsg1-1ubuntu1
* Latest upstream version for online play
* debian/control: Replace (rather than conflict) spring-engine
  - spring-engine will be a dummy package (LP: #612905)
  - also set maintainer to MOTU

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* This file is part of the Spring engine (GPL v2 or later), see LICENSE.html */
 
2
 
 
3
#ifndef _NULL_SOUND_H_
 
4
#define _NULL_SOUND_H_
 
5
 
 
6
#include "ISound.h"
 
7
 
 
8
#include <string>
 
9
 
 
10
class float3;
 
11
class SoundSource;
 
12
 
 
13
/// Empty sound system implementation
 
14
class NullSound : public ISound
 
15
{
 
16
public:
 
17
        NullSound();
 
18
        virtual ~NullSound();
 
19
 
 
20
        virtual bool HasSoundItem(const std::string& name);
 
21
        virtual size_t GetSoundId(const std::string& name, bool hardFail = true);
 
22
 
 
23
        virtual SoundSource* GetNextBestSource(bool lock = true);
 
24
 
 
25
        virtual void UpdateListener(const float3& campos, const float3& camdir, const float3& camup, float lastFrameTime);
 
26
        virtual void NewFrame();
 
27
 
 
28
        virtual void ConfigNotify(const std::string& key, const std::string& value);
 
29
        virtual void PitchAdjust(const float newPitch);
 
30
 
 
31
        virtual bool Mute();
 
32
        virtual bool IsMuted() const;
 
33
 
 
34
        virtual void Iconified(bool state);
 
35
 
 
36
        virtual void PrintDebugInfo();
 
37
        virtual bool LoadSoundDefs(const std::string& fileName);
 
38
 
 
39
private:
 
40
        friend class EffectChannel;
 
41
        // this is used by EffectChannel in AudioChannel.cpp
 
42
        virtual void PlaySample(size_t id, const float3 &p, const float3& velocity, float volume, bool relative);
 
43
};
 
44
 
 
45
#endif // _NULL_SOUND_H_