SuperTuxKart
Loading...
Searching...
No Matches
dummy_sfx.hpp
1//
2// SuperTuxKart - a fun racing game with go-kart
3// Copyright (C) 2006-2015 Patrick Ammann <pammann@aro.ch>
4// Copyright (C) 2008-2015 Joerg Henrichs, Patrick Ammann
5//
6// This program is free software; you can redistribute it and/or
7// modify it under the terms of the GNU General Public License
8// as published by the Free Software Foundation; either version 3
9// of the License, or (at your option) any later version.
10//
11// This program is distributed in the hope that it will be useful,
12// but WITHOUT ANY WARRANTY; without even the implied warranty of
13// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14// GNU General Public License for more details.
15//
16// You should have received a copy of the GNU General Public License
17// along with this program; if not, write to the Free Software
18// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19
20#ifndef HEADER_DUMMY_SFX_HPP
21#define HEADER_DUMMY_SFX_HPP
22
23#include "audio/sfx_base.hpp"
24#include "utils/cpp2011.hpp"
25
30class DummySFX : public SFXBase
31{
32public:
33 DummySFX(SFXBuffer* buffer, bool positional,
34 float gain) {}
35 virtual ~DummySFX() {}
36
38 virtual bool init() OVERRIDE { return true; }
39 virtual bool isLooped() OVERRIDE { return false; }
40 virtual void updatePlayingSFX(float dt) OVERRIDE {}
41 virtual void setLoop(bool status) OVERRIDE {}
42 virtual void reallySetLoop(bool status) OVERRIDE {}
43 virtual void setPosition(const Vec3 &p) OVERRIDE {}
44 virtual void reallySetPosition(const Vec3 &p) OVERRIDE {}
45 virtual void setSpeedPosition(float factor,
46 const Vec3 &p) OVERRIDE {}
47 virtual void reallySetSpeedPosition(float f,
48 const Vec3 &p) OVERRIDE {}
49 virtual void play() OVERRIDE {}
50 virtual void reallyPlayNow(SFXBuffer* buffer = NULL) OVERRIDE {}
51 virtual void play(const Vec3 &xyz, SFXBuffer* buffer = NULL) OVERRIDE {}
52 virtual void reallyPlayNow(const Vec3 &xyz, SFXBuffer* buffer = NULL) OVERRIDE {}
53 virtual void stop() OVERRIDE {}
54 virtual void reallyStopNow() OVERRIDE {}
55 virtual void pause() OVERRIDE {}
56 virtual void reallyPauseNow() OVERRIDE {}
57 virtual void resume() OVERRIDE {}
58 virtual void reallyResumeNow() OVERRIDE {}
59 virtual void deleteSFX() OVERRIDE {}
60 virtual void setSpeed(float factor) OVERRIDE {}
61 virtual void reallySetSpeed(float factor) OVERRIDE {}
62 virtual void setVolume(float gain) OVERRIDE {}
63 virtual void reallySetVolume(float gain) OVERRIDE {}
64 virtual void setMasterVolume(float gain) OVERRIDE {}
65 virtual void reallySetMasterVolumeNow(float gain) OVERRIDE {}
66 virtual SFXStatus getStatus() OVERRIDE { return SFX_STOPPED; }
67 virtual void onSoundEnabledBack() OVERRIDE {}
68 virtual void setRolloff(float rolloff) OVERRIDE {}
69 virtual SFXBuffer* getBuffer() const OVERRIDE { return NULL; }
70
71}; // DummySFX
72
73
74#endif // HEADER_SFX_HPP
75
Dummy sound when ogg or openal aren't available.
Definition: dummy_sfx.hpp:31
virtual bool init() OVERRIDE
Late creation, if SFX was initially disabled.
Definition: dummy_sfx.hpp:38
The base class for sound effects.
Definition: sfx_base.hpp:43
SFXStatus
Status of a sound effect.
Definition: sfx_base.hpp:47
The buffer (data) for one kind of sound effects.
Definition: sfx_buffer.hpp:44
A wrapper around bullets btVector3 to include conventient conversion functions (e....
Definition: vec3.hpp:35