|
From: Lasse Kärkkäi. <tr...@us...> - 2009-06-29 02:10:24
|
Module: performous
Branch: master
Commit: ee4f006b8b84b1e9ccff9c725fc2d631c81658e1
Author: Lasse Karkkainen <tro...@tr...>
Date: Mon Jun 29 05:08:54 2009 +0300
Fix the things that were b0rked by the Windows hacking...
SIGQUIT is apparently not needed, so removed (didn't work on Windows).
---
game/main.cc | 1 -
game/surface.hh | 2 +-
libs/libda/plugins/audio_dev_tone.cpp | 2 +-
3 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/game/main.cc b/game/main.cc
index 0e01007..c9c87c4 100644
--- a/game/main.cc
+++ b/game/main.cc
@@ -171,7 +171,6 @@ template <typename Container> void confOverride(Container const& c, std::string
int main(int argc, char** argv) {
std::signal(SIGINT, quit);
- // No such thing on Windows: signal(SIGQUIT, quit);
std::signal(SIGTERM, quit);
std::ios::sync_with_stdio(false); // We do not use C stdio
da::initialize libda;
diff --git a/game/surface.hh b/game/surface.hh
index 298af09..cc20103 100644
--- a/game/surface.hh
+++ b/game/surface.hh
@@ -123,7 +123,7 @@ class UseTexture: boost::noncopyable {
};
/** Draw the texture using the specified dimensions and texture coordinates. **/
-template <GLenum Type> void OpenGLTexture<Type>::draw(Dimensions const& dim, TexCoords const& tex = TexCoords()) const {
+template <GLenum Type> void OpenGLTexture<Type>::draw(Dimensions const& dim, TexCoords const& tex) const {
UseTexture texture(*this);
glBegin(GL_QUADS);
glTexCoord2f(tex.x1, tex.y1); glVertex2f(dim.x1(), dim.y1());
diff --git a/libs/libda/plugins/audio_dev_tone.cpp b/libs/libda/plugins/audio_dev_tone.cpp
index b2c307a..bdc3266 100644
--- a/libs/libda/plugins/audio_dev_tone.cpp
+++ b/libs/libda/plugins/audio_dev_tone.cpp
@@ -35,7 +35,7 @@ namespace {
m_phase(2.0 * M_PI * phase), m_step(2.0 * M_PI * freq / rate), m_amplitude(amplitude) {}
sample_t operator()() {
double s = m_amplitude * std::sin(m_phase = fmod(m_phase + m_step, 2.0 * M_PI));
- return return static_cast<sample_t>(s);
+ return static_cast<sample_t>(s);
}
operator sample_t() { return (*this)(); }
};
|