[Orxonox-commit 607] r3139 - branches/pch/src/orxonox/sound
rgrieder at orxonox.net
rgrieder at orxonox.net
Wed Jun 10 16:04:43 CEST 2009
Author: rgrieder
Date: 2009-06-10 16:04:42 +0200 (Wed, 10 Jun 2009)
New Revision: 3139
Modified:
branches/pch/src/orxonox/sound/SoundBase.cc
branches/pch/src/orxonox/sound/SoundBase.h
Log:
Typedef is probably better here than a static assert.
Modified: branches/pch/src/orxonox/sound/SoundBase.cc
===================================================================
--- branches/pch/src/orxonox/sound/SoundBase.cc 2009-06-10 14:01:42 UTC (rev 3138)
+++ branches/pch/src/orxonox/sound/SoundBase.cc 2009-06-10 14:04:42 UTC (rev 3139)
@@ -31,17 +31,12 @@
#include <vector>
#include <AL/alut.h>
#include <vorbis/vorbisfile.h>
-#include <boost/static_assert.hpp>
#include "util/Math.h"
#include "core/Core.h"
#include "orxonox/objects/worldentities/WorldEntity.h"
#include "SoundManager.h"
-// Make sure we correctly avoid including al.h in the header
-BOOST_STATIC_ASSERT(sizeof(uint32_t) == sizeof(ALuint));
-BOOST_STATIC_ASSERT(sizeof(int32_t) == sizeof(ALint));
-
namespace orxonox
{
SoundManager* SoundBase::soundmanager_s = NULL;
Modified: branches/pch/src/orxonox/sound/SoundBase.h
===================================================================
--- branches/pch/src/orxonox/sound/SoundBase.h 2009-06-10 14:01:42 UTC (rev 3138)
+++ branches/pch/src/orxonox/sound/SoundBase.h 2009-06-10 14:04:42 UTC (rev 3139)
@@ -31,6 +31,10 @@
#include "OrxonoxPrereqs.h"
#include <string>
+// forward declarations
+typedef unsigned int ALuint;
+typedef int ALint;
+
namespace orxonox
{
/**
@@ -57,12 +61,12 @@
bool loadFile(std::string filename);
private:
- uint32_t loadOggFile(std::string filename);
- uint32_t source_;
- uint32_t buffer_;
+ ALuint loadOggFile(std::string filename);
+ ALuint source_;
+ ALuint buffer_;
WorldEntity* entity_;
- int32_t getSourceState();
+ ALint getSourceState();
static SoundManager* soundmanager_s;
}; // class SoundBase
More information about the Orxonox-commit
mailing list