[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Pingus-CVS] CVS: Games/Pingus/src/sound slot_manager.cxx,1.1,1.2 slot_m
From: |
torangan |
Subject: |
[Pingus-CVS] CVS: Games/Pingus/src/sound slot_manager.cxx,1.1,1.2 slot_manager.hxx,1.1,1.2 sound.cxx,1.4,1.5 sound.hxx,1.2,1.3 sound_dummy.cxx,1.1,1.2 sound_dummy.hxx,1.1,1.2 sound_real.cxx,1.7,1.8 sound_real.hxx,1.2,1.3 sound_res_mgr.cxx,1.1,1.2 sound_res_mgr.hxx,1.1,1.2sounds.hxx,1.1,1.2 |
Date: |
19 Apr 2003 10:23:21 -0000 |
Update of /var/lib/cvs/Games/Pingus/src/sound
In directory dark:/tmp/cvs-serv20737/sound
Modified Files:
slot_manager.cxx slot_manager.hxx sound.cxx sound.hxx
sound_dummy.cxx sound_dummy.hxx sound_real.cxx sound_real.hxx
sound_res_mgr.cxx sound_res_mgr.hxx sounds.hxx
Log Message:
removed trailing whitespace
Index: slot_manager.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/slot_manager.cxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- slot_manager.cxx 18 Feb 2003 17:30:32 -0000 1.1
+++ slot_manager.cxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -21,7 +21,7 @@
SlotEntry& find_slot(const std::string& name)
{
-
+
}
void
@@ -29,20 +29,20 @@
{
CL_SoundBuffer * buffer;
CL_SoundBuffer_Session sess;
-
+
try {
buffer = new CL_SoundBuffer (new CL_Sample(filename.c_str(), NULL), true);
sess = buffer -> prepare();
} catch (const CL_Error & e) {
perr(PINGUS_DEBUG_SOUND) << "Can't open file " << filename << " --
skipping\n"
- << " CL_Error: " << e.message << std::endl;
+ << " CL_Error: " << e.message << std::endl;
return;
}
-
+
sess.set_volume(volume);
sess.set_pan(panning);
sess.set_looping(false);
- sess.play();
+ sess.play();
}
/* EOF */
Index: slot_manager.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/slot_manager.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- slot_manager.hxx 18 Feb 2003 17:30:32 -0000 1.1
+++ slot_manager.hxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -1,5 +1,5 @@
// $Id$
-//
+//
// Pingus - A free Lemmings clone
// Copyright (C) 2002 Ingo Ruhnke <address@hidden>
//
@@ -12,7 +12,7 @@
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -25,7 +25,7 @@
struct SlotEntry
{
/** Name of the sound effect */
- std::string name;
+ std::string name;
/** Time when the last sound playback started */
unsigned int last_time;
@@ -44,12 +44,12 @@
{
private:
std::map<std::string, SlotEntry> slots;
-
+
public:
SlotManager();
void play_sound(const std::string& name);
-
+
private:
SlotEntry& find_slot(const std::string& name);
Index: sound.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound.cxx,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- sound.cxx 12 Apr 2003 15:33:30 -0000 1.4
+++ sound.cxx 19 Apr 2003 10:23:19 -0000 1.5
@@ -34,11 +34,11 @@
{
if (s == 0)
{
- if (sound_enabled || music_enabled)
+ if (sound_enabled || music_enabled)
{
if (verbose)
std::cout << "Init Sound" << std::endl;
-
+
try {
PingusSound::init (new PingusSoundReal ());
} catch (CL_Error& err) {
@@ -68,10 +68,10 @@
}
/** Load a sound file and play it immediately.
-
+
@param filename The complete filename */
-
-void
+
+void
PingusSound::play_sound(const std::string& name, float volume, float panning)
{
assert (sound);
@@ -105,10 +105,10 @@
}
/** Load a sound file and play it immediately.
-
+
@param name
@param volume volume */
-void
+void
PingusSound::play_music(const std::string & name, float volume)
{
assert (sound);
Index: sound.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound.hxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- sound.hxx 4 Mar 2003 13:59:44 -0000 1.2
+++ sound.hxx 19 Apr 2003 10:23:19 -0000 1.3
@@ -1,5 +1,5 @@
// $Id$
-//
+//
// Pingus - A free Lemmings clone
// Copyright (C) 2000 Ingo Ruhnke <address@hidden>
//
@@ -12,7 +12,7 @@
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -25,10 +25,10 @@
class PingusSound
{
-protected:
+protected:
/** FIXME: this should be SoundImpl, not PingusSound */
static PingusSound* sound;
-
+
protected:
PingusSound () { }
@@ -46,12 +46,12 @@
@param volume volume
@param panning panning */
static void play_sound(const std::string & name, float volume = 1.0f, float
panning = 0.0f);
-
+
static void play_music(const std::string & name, float volume = 1.0f);
static void stop_music();
static void play_sound(Sound::Name name, float volume = 1.0f, float panning
= 0.0f);
-
+
private:
PingusSound (const PingusSound&);
PingusSound& operator= (const PingusSound&);
Index: sound_dummy.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound_dummy.cxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- sound_dummy.cxx 18 Feb 2003 17:30:32 -0000 1.1
+++ sound_dummy.cxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -23,14 +23,14 @@
namespace Sound {
-void
+void
PingusSoundDummy::real_play_sound(const std::string & filename, float
/*volume*/, float /*panning*/)
{
pout(PINGUS_DEBUG_SOUND) << "PingusSoundDummy::real_play_sound: " <<
filename << std::endl;
}
-void
+void
PingusSoundDummy::real_play_music(const std::string & filename, float
/*volume*/)
{
pout(PINGUS_DEBUG_SOUND) << "PingusSoundDummy::real_play_music: " <<
filename << std::endl;
Index: sound_dummy.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound_dummy.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- sound_dummy.hxx 18 Feb 2003 17:30:32 -0000 1.1
+++ sound_dummy.hxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -1,5 +1,5 @@
// $Id$
-//
+//
// Pingus - A free Lemmings clone
// Copyright (C) 2000 Ingo Ruhnke <address@hidden>
//
@@ -12,7 +12,7 @@
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
Index: sound_real.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound_real.cxx,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- sound_real.cxx 12 Apr 2003 02:05:47 -0000 1.7
+++ sound_real.cxx 19 Apr 2003 10:23:19 -0000 1.8
@@ -41,11 +41,11 @@
: music_sample (0), music_session(0)
{
pout(PINGUS_DEBUG_SOUND) << "Initializing ClanLib-Sound" << std::endl;
-
+
CL_SetupSound::init();
-
+
pout(PINGUS_DEBUG_SOUND) << "Initializing ClanLib-MikMod" << std::endl;
-
+
#ifdef HAVE_LIBCLANVORBIS
CL_SetupVorbis::init();
#endif
@@ -85,20 +85,20 @@
SoundHandle buffer;
CL_SoundBuffer_Session sess;
-
+
try {
buffer = SoundResMgr::load(name);
sess = buffer->prepare();
} catch (const CL_Error & e) {
perr(PINGUS_DEBUG_SOUND) << "Can't open sound '" << name << "' --
skipping\n"
- << " CL_Error: " << e.message << std::endl;
+ << " CL_Error: " << e.message << std::endl;
return;
}
-
+
sess.set_volume(volume);
sess.set_pan(panning);
sess.set_looping(false);
- sess.play();
+ sess.play();
}
void
@@ -129,12 +129,12 @@
return;
pout(PINGUS_DEBUG_SOUND) << "PingusSoundReal: Playing music: " << filename
<< std::endl;
-
+
real_stop_music();
music_sample = 0;
- if (filename.substr(filename.size()-4, 4) == ".ogg")
+ if (filename.substr(filename.size()-4, 4) == ".ogg")
{
#ifdef HAVE_LIBCLANVORBIS
music_sample = new CL_SoundBuffer (new
CL_VorbisSoundProvider(filename.c_str()), true);
@@ -142,19 +142,19 @@
music_sample = 0;
#endif
}
- else if (filename.substr(filename.size()-4, 4) == ".wav")
+ else if (filename.substr(filename.size()-4, 4) == ".wav")
{
music_sample = new CL_SoundBuffer (new CL_Sample(filename.c_str(),
NULL), true);
- }
+ }
else
{ // MikMod should support the rest...
#ifdef HAVE_LIBCLANMIKMOD
music_sample = new CL_SoundBuffer (new
CL_Streamed_MikModSample(filename.c_str()), true);
#else
music_sample = 0;
-#endif
+#endif
}
-
+
if (music_sample)
{
music_session = new CL_SoundBuffer_Session(music_sample->prepare());
Index: sound_real.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound_real.hxx,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- sound_real.hxx 4 Mar 2003 13:59:44 -0000 1.2
+++ sound_real.hxx 19 Apr 2003 10:23:19 -0000 1.3
@@ -1,5 +1,5 @@
// $Id$
-//
+//
// Pingus - A free Lemmings clone
// Copyright (C) 2000 Ingo Ruhnke <address@hidden>
//
@@ -12,7 +12,7 @@
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@@ -54,16 +54,16 @@
virtual void real_stop_music();
/** Load a sound file and play it immediately
-
+
@param filename The complete filename
- @param volume The volume to play the sound at
+ @param volume The volume to play the sound at
@param panning The panning to play the sound with */
virtual void real_play_sound(const std::string & filename, float volume,
float panning);
private:
PingusSoundReal (const PingusSoundReal&);
- PingusSoundReal& operator= (const PingusSoundReal&);
+ PingusSoundReal& operator= (const PingusSoundReal&);
};
} // namespace Sound
Index: sound_res_mgr.cxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound_res_mgr.cxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- sound_res_mgr.cxx 4 Mar 2003 13:59:44 -0000 1.1
+++ sound_res_mgr.cxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -33,8 +33,8 @@
if (i == sound_map.end())
{
std::string filename = path_manager.complete("sounds/" + name + ".wav");
- CL_SoundBuffer* buffer = new CL_SoundBuffer (new CL_Sample(filename,
NULL), true);
- pout(PINGUS_DEBUG_LOADING) << "SoundResMgr: Loading sound from disk: "
+ CL_SoundBuffer* buffer = new CL_SoundBuffer (new CL_Sample(filename,
NULL), true);
+ pout(PINGUS_DEBUG_LOADING) << "SoundResMgr: Loading sound from disk: "
<< name << " -> " << filename << std::endl;
sound_map[name] = buffer;
Index: sound_res_mgr.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sound_res_mgr.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- sound_res_mgr.hxx 4 Mar 2003 13:59:44 -0000 1.1
+++ sound_res_mgr.hxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -1,5 +1,5 @@
// $Id$
-//
+//
// Pingus - A free Lemmings clone
// Copyright (C) 2002 Ingo Ruhnke <address@hidden>
//
@@ -12,7 +12,7 @@
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
Index: sounds.hxx
===================================================================
RCS file: /var/lib/cvs/Games/Pingus/src/sound/sounds.hxx,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- sounds.hxx 18 Feb 2003 17:30:32 -0000 1.1
+++ sounds.hxx 19 Apr 2003 10:23:19 -0000 1.2
@@ -1,5 +1,5 @@
// $Id$
-//
+//
// Pingus - A free Lemmings clone
// Copyright (C) 2000 Ingo Ruhnke <address@hidden>
//
@@ -12,7 +12,7 @@
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
-//
+//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Pingus-CVS] CVS: Games/Pingus/src/sound slot_manager.cxx,1.1,1.2 slot_manager.hxx,1.1,1.2 sound.cxx,1.4,1.5 sound.hxx,1.2,1.3 sound_dummy.cxx,1.1,1.2 sound_dummy.hxx,1.1,1.2 sound_real.cxx,1.7,1.8 sound_real.hxx,1.2,1.3 sound_res_mgr.cxx,1.1,1.2 sound_res_mgr.hxx,1.1,1.2sounds.hxx,1.1,1.2,
torangan <=
- Prev by Date:
[Pingus-CVS] CVS: Games/Pingus/src/actions angel.cxx,1.17,1.18 angel.hxx,1.14,1.15 basher.cxx,1.28,1.29 basher.hxx,1.16,1.17 blocker.cxx,1.18,1.19 blocker.hxx,1.14,1.15 boarder.cxx,1.14,1.15 boarder.hxx,1.13,1.14 bomber.cxx,1.33,1.34 bomber.hxx,1.19,1.20 bridger.cxx,1.29,1.30 bridger.hxx,1.17,1.18 climber.cxx,1.21,1.22 climber.hxx,1.14,1.15 digger.cxx,1.23,1.24 digger.hxx,1.14,1.15 drown.cxx,1.13,1.14 drown.hxx,1.12,1.13 exiter.cxx,1.17,1.18 exiter.hxx,1.13,1.14 faller.cxx,1.39,1.40 faller.hxx,1.19,1.20 floater.cxx,1.23,1.24 floater.hxx,1.14,1.15 jumper.cxx,1.19,1.20 jumper.hxx,1.12,1.13 laser_kill.cxx,1.14,1.15 laser_kill.hxx,1.13,1.14 miner.cxx,1.21,1.22 miner.hxx,1.13,1.14 rocket_launcher.cxx,1.14,1.15 rocket_launcher.hxx,1.12,1.13 slider.cxx,1.17,1.18 slider.hxx,1.12,1.13 smashed.cxx,1.13,1.14 smashed.hxx,1.14,1.15 splashed.cxx,1.14,1.15 splashed.hxx,1.14,1.15 superman.cxx,1.11,1.12 superman.hxx,1.13,1.14 teleported.cxx,1.12,1.13 teleported.hxx,1.13,1.14 waiter.cxx,1.13,1.14 waiter.hxx,1.13,1.14 walker.cxx,1.32,1.33 walker.hxx,1.13,1.14
- Next by Date:
[Pingus-CVS] CVS: Games/Pingus/src/particles explosive_particle.cxx,1.5,1.6 explosive_particle.hxx,1.5,1.6 ground_particle.cxx,1.3,1.4 ground_particle.hxx,1.5,1.6 pingu_particle_holder.cxx,1.8,1.9 pingu_particle_holder.hxx,1.3,1.4 rain_particle_holder.cxx,1.5,1.6 rain_particle_holder.hxx,1.4,1.5 smoke_particle_holder.cxx,1.4,1.5 smoke_particle_holder.hxx,1.2,1.3 snow_particle_holder.cxx,1.6,1.7 snow_particle_holder.hxx,1.3,1.4
- Previous by thread:
[Pingus-CVS] CVS: Games/Pingus/src/actions angel.cxx,1.17,1.18 angel.hxx,1.14,1.15 basher.cxx,1.28,1.29 basher.hxx,1.16,1.17 blocker.cxx,1.18,1.19 blocker.hxx,1.14,1.15 boarder.cxx,1.14,1.15 boarder.hxx,1.13,1.14 bomber.cxx,1.33,1.34 bomber.hxx,1.19,1.20 bridger.cxx,1.29,1.30 bridger.hxx,1.17,1.18 climber.cxx,1.21,1.22 climber.hxx,1.14,1.15 digger.cxx,1.23,1.24 digger.hxx,1.14,1.15 drown.cxx,1.13,1.14 drown.hxx,1.12,1.13 exiter.cxx,1.17,1.18 exiter.hxx,1.13,1.14 faller.cxx,1.39,1.40 faller.hxx,1.19,1.20 floater.cxx,1.23,1.24 floater.hxx,1.14,1.15 jumper.cxx,1.19,1.20 jumper.hxx,1.12,1.13 laser_kill.cxx,1.14,1.15 laser_kill.hxx,1.13,1.14 miner.cxx,1.21,1.22 miner.hxx,1.13,1.14 rocket_launcher.cxx,1.14,1.15 rocket_launcher.hxx,1.12,1.13 slider.cxx,1.17,1.18 slider.hxx,1.12,1.13 smashed.cxx,1.13,1.14 smashed.hxx,1.14,1.15 splashed.cxx,1.14,1.15 splashed.hxx,1.14,1.15 superman.cxx,1.11,1.12 superman.hxx,1.13,1.14 teleported.cxx,1.12,1.13 teleported.hxx,1.13,1.14 waiter.cxx,1.13,1.14 waiter.hxx,1.13,1.14 walker.cxx,1.32,1.33 walker.hxx,1.13,1.14
- Next by thread:
[Pingus-CVS] CVS: Games/Pingus/src/particles explosive_particle.cxx,1.5,1.6 explosive_particle.hxx,1.5,1.6 ground_particle.cxx,1.3,1.4 ground_particle.hxx,1.5,1.6 pingu_particle_holder.cxx,1.8,1.9 pingu_particle_holder.hxx,1.3,1.4 rain_particle_holder.cxx,1.5,1.6 rain_particle_holder.hxx,1.4,1.5 smoke_particle_holder.cxx,1.4,1.5 smoke_particle_holder.hxx,1.2,1.3 snow_particle_holder.cxx,1.6,1.7 snow_particle_holder.hxx,1.3,1.4
- Index(es):