You can subscribe to this list here.
| 2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(25) |
Jul
(288) |
Aug
(119) |
Sep
(31) |
Oct
(59) |
Nov
(458) |
Dec
(359) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2010 |
Jan
(268) |
Feb
(26) |
Mar
(36) |
Apr
(48) |
May
(119) |
Jun
(37) |
Jul
(173) |
Aug
(429) |
Sep
(137) |
Oct
(156) |
Nov
(59) |
Dec
(45) |
| 2011 |
Jan
(398) |
Feb
(257) |
Mar
(49) |
Apr
(5) |
May
(34) |
Jun
(11) |
Jul
(38) |
Aug
(12) |
Sep
(1) |
Oct
(49) |
Nov
(5) |
Dec
(10) |
| 2012 |
Jan
(21) |
Feb
(32) |
Mar
(20) |
Apr
(1) |
May
(2) |
Jun
|
Jul
(173) |
Aug
|
Sep
(25) |
Oct
(6) |
Nov
(44) |
Dec
|
|
From: Tapio V. <aa...@us...> - 2010-09-16 07:16:06
|
Module: performous
Branch: master
Commit: 790cfdf98b40d72a3574fcd4ac278e14217857b5
Author: Tapio Vierros <tap...@gm...>
Date: Thu Sep 16 10:15:21 2010 +0300
Allow dismissing Dialog with instrument nav buttons.
---
game/main.cc | 2 ++
game/screen.hh | 4 +++-
2 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/game/main.cc b/game/main.cc
index 08770fc..d5a1874 100644
--- a/game/main.cc
+++ b/game/main.cc
@@ -98,6 +98,8 @@ static void checkEvents_SDL(ScreenManager& sm) {
if (sm.closeDialog()) continue;
break;
}
+ // Close dialog in case of a nav event
+ if (sm.isDialogOpen() && input::getNav(event) != input::NONE) { sm.closeDialog(); continue; }
// Forward to screen even if the input system takes it (ignoring pushEvent return value)
// This is needed to allow navigation (quiting the song) to function even then
input::SDL::pushEvent(event);
diff --git a/game/screen.hh b/game/screen.hh
index b692ccb..a5e5371 100644
--- a/game/screen.hh
+++ b/game/screen.hh
@@ -61,11 +61,13 @@ class ScreenManager: public Singleton <ScreenManager> {
void dialog(std::string const& text);
/// Close dialog and return true if it was opened in the first place
bool closeDialog();
+ /// Returns true if dialog is open
+ bool isDialogOpen() { return m_dialog; }
/// Draw dialogs & flash messages in current screen
void drawNotifications();
/// Sets finished to true
- void finished() { m_finished=true; };
+ void finished() { m_finished = true; };
/// Returns finished state
bool isFinished() { return m_finished; };
|
|
From: Tapio V. <aa...@us...> - 2010-09-16 07:01:40
|
Module: performous
Branch: master
Commit: a922772f3863a813cafd60dfcff54271e27cf70f
Author: Tapio Vierros <tap...@gm...>
Date: Thu Sep 16 10:00:10 2010 +0300
Audio now has limited time to shut itself down (anti-hang hack).
---
game/audio.cc | 3 ++-
game/audio.hh | 3 ++-
game/main.cc | 12 ++++++++----
game/screen_audiodevices.cc | 14 +++++++++++---
4 files changed, 23 insertions(+), 9 deletions(-)
diff --git a/game/audio.cc b/game/audio.cc
index ba96a09..111c6f7 100644
--- a/game/audio.cc
+++ b/game/audio.cc
@@ -520,7 +520,8 @@ struct Audio::Impl {
Audio::Audio(): self(new Impl) {}
Audio::~Audio() {}
-void Audio::reset() { self.reset(new Impl); };
+void Audio::restart() { self.reset(new Impl); };
+void Audio::close() { self.reset(); };
bool Audio::isOpen() const {
return !self->devices.empty();
diff --git a/game/audio.hh b/game/audio.hh
index a5c98ae..a8d6650 100644
--- a/game/audio.hh
+++ b/game/audio.hh
@@ -46,7 +46,8 @@ class Audio {
public:
Audio();
~Audio();
- void reset();
+ void restart();
+ void close();
boost::ptr_vector<Analyzer>& analyzers();
boost::ptr_vector<Device>& devices();
bool isOpen() const;
diff --git a/game/main.cc b/game/main.cc
index 3c883ba..08770fc 100644
--- a/game/main.cc
+++ b/game/main.cc
@@ -202,6 +202,12 @@ void mainLoop(std::string const& songlist) {
} catch (QuitNow&) {
std::cout << "Terminated." << std::endl;
}
+ // Give audio a little time to shutdown but then just quit
+ boost::thread audiokiller(boost::bind(&Audio::close, boost::ref(audio)));
+ if (!audiokiller.timed_join(boost::posix_time::milliseconds(2000))) {
+ std::cout << "Audio hung." << std::endl;
+ exit(EXIT_SUCCESS);
+ }
}
/// Simple test utility to make mapping of joystick buttons/axes easier
@@ -299,10 +305,10 @@ int main(int argc, char** argv) try {
}
po::notify(vm);
- // initialize the verbose message sink
+ // Initialize the verbose message sink
//logger::__log_hh_test(); // debug
logger::setup(loglevel_regexp);
-
+ atexit(logger::teardown); // We might exit from many places due to audio hangs
if (vm.count("version")) {
// Already printed the version string in the beginning...
@@ -346,8 +352,6 @@ int main(int argc, char** argv) try {
// Run the game init and main loop
mainLoop(songlist);
- logger::teardown();
-
return EXIT_SUCCESS; // Do not remove. SDL_Main (which this function is called on some platforms) needs return statement.
} catch (std::exception& e) {
std::cerr << "FATAL ERROR: " << e.what() << std::endl;
diff --git a/game/screen_audiodevices.cc b/game/screen_audiodevices.cc
index 4df3663..4e22204 100644
--- a/game/screen_audiodevices.cc
+++ b/game/screen_audiodevices.cc
@@ -5,7 +5,9 @@
#include "theme.hh"
#include "audio.hh"
#include "i18n.hh"
-
+#include <cstdlib>
+#include <boost/thread.hpp>
+#include <boost/bind.hpp>
namespace {
const float yoff = 0.18; // Offset from center where to place top row
@@ -175,8 +177,14 @@ bool ScreenAudioDevices::save(bool skip_ui_config) {
}
writeConfig(); // Save the new config
size_t unassigned_id = m_devs.size();
- // TODO: Make sure this isn't particularly prone to crashes
- m_audio.reset(); // Reload audio to take the new settings into use
+ // Give audio a little time to shutdown but then just quit
+ boost::thread audiokiller(boost::bind(&Audio::close, boost::ref(m_audio)));
+ if (!audiokiller.timed_join(boost::posix_time::milliseconds(4000))) {
+ // FIXME: Notify user
+ std::cout << "Audio hung. Please restart Performous" << std::endl;
+ std::exit(EXIT_FAILURE);
+ }
+ m_audio.restart(); // Reload audio to take the new settings into use
m_audio.playMusic(getThemePath("menu.ogg"), true); // Start music again
// Check that all went well
bool ret = verify(unassigned_id);
|
|
From: Tapio V. <aa...@us...> - 2010-09-16 06:16:56
|
Module: performous
Branch: master
Commit: 1fef67e8eb7caf9064bf1170fa6d2456ab960f75
Author: Tapio Vierros <tap...@gm...>
Date: Thu Sep 16 09:16:07 2010 +0300
Fix hiscrore game mode IDs.
---
game/dancegraph.cc | 2 +-
game/guitargraph.cc | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index 901ee50..22a8219 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -210,7 +210,7 @@ std::string DanceGraph::getDifficultyString() const {
/// Get a string id for track and difficulty
std::string DanceGraph::getModeId() const {
- return m_gamingMode + diffv[m_level] + (m_input.isKeyboard() ? " (kbd)" : "");
+ return m_gamingMode + " - " + diffv[m_level] + (m_input.isKeyboard() ? " (kbd)" : "");
}
/// Attempt to change the difficulty by a step
diff --git a/game/guitargraph.cc b/game/guitargraph.cc
index 9339ff4..bb77221 100644
--- a/game/guitargraph.cc
+++ b/game/guitargraph.cc
@@ -225,7 +225,7 @@ std::string GuitarGraph::getDifficultyString() const {
/// Get a string id for track and difficulty
std::string GuitarGraph::getModeId() const {
- return m_track_index->first + diffv[m_level].name
+ return m_track_index->first + " - " + diffv[m_level].name
+ (m_drums && m_input.isKeyboard() ? " (kbd)" : "");
}
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2010-09-15 22:09:11
|
Module: performous
Branch: master
Commit: 5e4587b6432bbde4d2d4af20a7d9e912e69e3513
Author: Lasse Karkkainen <tro...@tr...>
Date: Thu Sep 16 01:05:04 2010 +0300
Fix compile warning about unused time parameter
---
game/dancegraph.cc | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index 867c088..901ee50 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -561,7 +561,7 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
}
/// Draw popups and other info texts
-void DanceGraph::drawInfo(double time, double offsetX, Dimensions dimensions) {
+void DanceGraph::drawInfo(double /*time*/, double offsetX, Dimensions dimensions) {
if (!menuOpen()) {
// Draw scores
m_text.dimensions.screenBottom(-0.35).middle(0.32 * dimensions.w() + offsetX);
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 22:07:19
|
Module: performous
Branch: master
Commit: b769ce164467fabedfa90142f257fc004a57eab2
Author: Tapio Vierros <tap...@gm...>
Date: Thu Sep 16 01:06:07 2010 +0300
Reduce alpha for devices that lack channels for selection type in audio config.
---
game/screen_audiodevices.cc | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/game/screen_audiodevices.cc b/game/screen_audiodevices.cc
index 51d2d12..4df3663 100644
--- a/game/screen_audiodevices.cc
+++ b/game/screen_audiodevices.cc
@@ -97,10 +97,14 @@ void ScreenAudioDevices::draw() {
m_theme->device_bg.dimensions.stretch(std::abs(xoff*2), m_mic_icon->dimensions.h()*0.9).middle();
for (size_t i = 0; i <= m_devs.size(); ++i) {
const float y = -yoff + i*ystep;
+ float alpha = 1.0f;
+ // "Grey out" devices that doesn't fit the selection
+ if (m_mics[m_selected_column].name == "OUT" && !m_devs[i].out) alpha = 0.5f;
+ else if (m_mics[m_selected_column].name != "OUT" && !m_devs[i].in) alpha = 0.5f;
m_theme->device_bg.dimensions.center(y);
m_theme->device_bg.draw();
m_theme->device.dimensions.middle(-xstep*0.5).center(y);
- m_theme->device.draw(i < m_devs.size() ? m_devs[i].desc() : _("- Unassigned -"));
+ m_theme->device.draw(i < m_devs.size() ? m_devs[i].desc() : _("- Unassigned -"), alpha);
}
// Icons
for (size_t i = 0; i < m_mics.size(); ++i) {
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 19:55:08
|
Module: performous
Branch: master
Commit: db94d0bf19fe8e2735864f42b7c07e4921303cd1
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 22:54:24 2010 +0300
Fix a missing ) in audio devices screen.
---
game/libda/portaudio.hpp | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/game/libda/portaudio.hpp b/game/libda/portaudio.hpp
index c149203..16c7b83 100644
--- a/game/libda/portaudio.hpp
+++ b/game/libda/portaudio.hpp
@@ -37,8 +37,8 @@ namespace portaudio {
oss << name << " (";
if (in) oss << in << " in";
if (in && out) oss << ", ";
- if (out) oss << out << " out)";
- return oss.str();
+ if (out) oss << out << " out";
+ return oss.str() + ")";
}
std::string name;
unsigned int in, out;
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 19:46:28
|
Module: performous Branch: master Commit: bf51daaa98e583e6d7318b6262b945226feff4ce Author: Tapio Vierros <tap...@gm...> Date: Wed Sep 15 22:45:52 2010 +0300 Cross-compilation script fixes/tweaks. --- win32/cross-from-debian/makedeps.sh | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) diff --git a/win32/cross-from-debian/makedeps.sh b/win32/cross-from-debian/makedeps.sh index 0dc83db..253614f 100755 --- a/win32/cross-from-debian/makedeps.sh +++ b/win32/cross-from-debian/makedeps.sh @@ -452,7 +452,8 @@ if test ! -f "$PREFIX"/build-stamps/libcroco; then download http://ftp.gnome.org/pub/GNOME/sources/libcroco/0.6/$LIBCROCO.tar.bz2 tar jxvf $LIBCROCO.tar.bz2 cd $LIBCROCO - ./configure $COMMON_AUTOCONF_FLAGS + # We bypass a file magick check here + lt_cv_deplibs_check_method=pass_all ./configure $COMMON_AUTOCONF_FLAGS make make install cd .. @@ -644,7 +645,7 @@ if test ! -f "$PREFIX"/build-stamps/opencv; then download http://download.sourceforge.net/opencvlibrary/$OPENCV-win.zip unzip -o $OPENCV-win.zip cd $OPENCV - ln -s ../deps/include/videoInput.h /src/highgui/videoinput.h + ln -s "$PREFIX/include/videoInput.h" src/highgui/videoinput.h mkdir -pv build cd build cmake \ @@ -657,15 +658,13 @@ if test ! -f "$PREFIX"/build-stamps/opencv; then make make install cp -v unix-install/opencv.pc "$PREFIX"/lib/pkgconfig # No auto-install :( - pushd . cd "$PREFIX"/lib # Create some symlinks so the cmake scripts detect it correctly ln -svf libcv210.dll.a libcv.dll.a ln -svf libcxcore210.dll.a libcxcore.dll.a ln -svf libcvaux210.dll.a libcvaux.dll.a ln -svf libhighgui210.dll.a libhighgui.dll.a - popd - cd ../.. + cd "$PREFIX/.." touch "$PREFIX"/build-stamps/opencv $RM_RF $OPENCV fi |
|
From: Tapio V. <aa...@us...> - 2010-09-15 17:54:17
|
Module: performous
Branch: master
Commit: 0e880d471a07fa8e3a3bb2c306c30a59c9dae1f6
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 20:53:23 2010 +0300
Use key names for keyboard instruments instead of icons in instrument menu.
---
game/instrumentgraph.cc | 45 +++++++++++++++++++++++++++++++--------------
1 files changed, 31 insertions(+), 14 deletions(-)
diff --git a/game/instrumentgraph.cc b/game/instrumentgraph.cc
index 4eace91..e403db8 100644
--- a/game/instrumentgraph.cc
+++ b/game/instrumentgraph.cc
@@ -79,8 +79,8 @@ void InstrumentGraph::drawMenu() {
const float step = txth * 0.7f;
const float h = m_menu.getOptions().size() * step + step;
float y = -h * .5f + step;
- float x = offsetX - w*.5f + step + button_margin*1.0f;
- float xx = offsetX + w*.5f - step - button_margin*1.0f;
+ float x = offsetX - w*.5f + step + button_margin;
+ float xx = offsetX + w*.5f - step - button_margin;
// Background
th.bg.dimensions.middle(offsetX).center(0).stretch(w, h);
th.bg.draw();
@@ -94,24 +94,41 @@ void InstrumentGraph::drawMenu() {
if (cur == it) {
// Draw the key hints
if (getGraphType() != input::DANCEPAD) {
- glColor4fv(color(getGraphType() == input::GUITAR ? 0 : 1));
- m_button.dimensions.middle(x - button_margin).center(y);
- m_button.draw();
- glColor4fv(color(getGraphType() == input::GUITAR ? 1 : 4));
- m_button.dimensions.middle(xx + button_margin);
- m_button.draw();
+ if (m_input.isKeyboard()) { // Key letters for keyboard
+ txt->dimensions.middle(x - button_margin - m_button.dimensions.w()*0.5f).center(y);
+ txt->draw(getGraphType() == input::GUITAR ? "1" : "U");
+ txt->dimensions.middle(xx + button_margin - m_button.dimensions.w()*0.5f).center(y);
+ txt->draw(getGraphType() == input::GUITAR ? "2" : "P");
+ } else { // Colored icons for real instruments
+ glColor4fv(color(getGraphType() == input::GUITAR ? 0 : 1));
+ m_button.dimensions.middle(x - button_margin).center(y);
+ m_button.draw();
+ glColor4fv(color(getGraphType() == input::GUITAR ? 1 : 4));
+ m_button.dimensions.middle(xx + button_margin);
+ m_button.draw();
+ }
}
// Drum up hint
if (getGraphType() == input::DRUMS && i > 0) {
- glColor4fv(color(2));
- m_button.dimensions.middle(x - button_margin).center(y - step);
- m_button.draw();
+ if (m_input.isKeyboard()) { // Key letters for keyboard
+ txt->dimensions.middle(x - button_margin - m_button.dimensions.w()*0.5f).center(y - step);
+ txt->draw("I");
+ } else { // Colored icons for real instruments
+ glColor4fv(color(2));
+ m_button.dimensions.middle(x - button_margin).center(y - step);
+ m_button.draw();
+ }
}
// Drum down hint
if (getGraphType() == input::DRUMS && i < m_menu.getOptions().size()-1) {
- glColor4fv(color(3));
- m_button.dimensions.middle(x - button_margin).center(y + step);
- m_button.draw();
+ if (m_input.isKeyboard()) {
+ txt->dimensions.middle(x - button_margin - m_button.dimensions.w()*0.5f).center(y + step);
+ txt->draw("O");
+ } else {
+ glColor4fv(color(3));
+ m_button.dimensions.middle(x - button_margin).center(y + step);
+ m_button.draw();
+ }
}
//th.back_h.dimensions.middle(0.05 + offsetX).center(y);
//th.back_h.draw();
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 17:05:08
|
Module: performous
Branch: master
Commit: a19cefecc60b0cfb6c6345cbd8dfd6adb74ad0e7
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 20:04:31 2010 +0300
Attempt to beautify the in-game menu background.
---
themes/default/instrumentmenu_bg.svg | 72 +++++++++++++++++++++++++++++++---
1 files changed, 66 insertions(+), 6 deletions(-)
diff --git a/themes/default/instrumentmenu_bg.svg b/themes/default/instrumentmenu_bg.svg
index 248fe4e..18dc7e7 100644
--- a/themes/default/instrumentmenu_bg.svg
+++ b/themes/default/instrumentmenu_bg.svg
@@ -7,18 +7,45 @@
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="300"
height="400"
id="svg2"
sodipodi:version="0.32"
- inkscape:version="0.47 r22583"
+ inkscape:version="0.48.0 r9654"
version="1.0"
sodipodi:docname="instrumentmenu_bg.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape">
<defs
id="defs4">
+ <linearGradient
+ id="linearGradient3897">
+ <stop
+ id="stop3899"
+ offset="0"
+ style="stop-color:#ffffff;stop-opacity:0.88554215;" />
+ <stop
+ style="stop-color:#81cedf;stop-opacity:0.78313255;"
+ offset="0.30000001"
+ id="stop3903" />
+ <stop
+ id="stop3901"
+ offset="1"
+ style="stop-color:#0e0f11;stop-opacity:0.83734941;" />
+ </linearGradient>
+ <linearGradient
+ id="linearGradient3879">
+ <stop
+ style="stop-color:#000000;stop-opacity:1;"
+ offset="0"
+ id="stop3881" />
+ <stop
+ style="stop-color:#000000;stop-opacity:0;"
+ offset="1"
+ id="stop3883" />
+ </linearGradient>
<inkscape:perspective
sodipodi:type="inkscape:persp3d"
inkscape:vp_x="0 : 526.18109 : 1"
@@ -33,6 +60,39 @@
inkscape:vp_y="0 : 1000 : 0"
inkscape:vp_x="0 : 88 : 1"
sodipodi:type="inkscape:persp3d" />
+ <radialGradient
+ r="500"
+ fy="757.60583"
+ fx="727.25122"
+ cy="757.60583"
+ cx="727.25122"
+ gradientTransform="matrix(0.43355171,-0.84504566,1.805509,0.92631863,-980.8803,536.04792)"
+ gradientUnits="userSpaceOnUse"
+ id="radialGradient3750"
+ xlink:href="#linearGradient3629-3"
+ inkscape:collect="always" />
+ <linearGradient
+ id="linearGradient3629-3">
+ <stop
+ style="stop-color:#00cbff;stop-opacity:0.8012048;"
+ offset="0"
+ id="stop3631-1" />
+ <stop
+ style="stop-color:#000000;stop-opacity:0.88554215;"
+ offset="1"
+ id="stop3633-4" />
+ </linearGradient>
+ <radialGradient
+ inkscape:collect="always"
+ xlink:href="#linearGradient3897"
+ id="radialGradient3893"
+ cx="152.33708"
+ cy="185.20837"
+ fx="152.33708"
+ fy="185.20837"
+ r="140"
+ gradientTransform="matrix(1.8932799,-1.1288249,2.9734822,4.987163,-586.095,-459.97648)"
+ gradientUnits="userSpaceOnUse" />
</defs>
<sodipodi:namedview
id="base"
@@ -41,16 +101,16 @@
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
- inkscape:zoom="0.98994949"
- inkscape:cx="55.32752"
+ inkscape:zoom="0.49497475"
+ inkscape:cx="-97.971012"
inkscape:cy="231.31119"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1313"
inkscape:window-height="722"
- inkscape:window-x="0"
- inkscape:window-y="25"
+ inkscape:window-x="321"
+ inkscape:window-y="41"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
@@ -69,7 +129,7 @@
id="layer1"
transform="translate(0,80)">
<rect
- style="fill:#ffffff;fill-opacity:0.66810346;stroke:#000000;stroke-width:1.50000000000000000;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ style="fill:url(#radialGradient3893);fill-opacity:1.0;stroke:#000000;stroke-width:1.50000000000000000;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect2383"
width="278.5"
height="378.5"
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 16:24:33
|
Module: performous
Branch: master
Commit: e45c1039882152e89ffb90a9489190e23d6e668b
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 19:22:25 2010 +0300
Refactor ppa script and make the version supercede the one in maverick repos.
---
tools/ppa/ppa.sh | 70 ++++++++++++++++++++++++------------------------------
1 files changed, 31 insertions(+), 39 deletions(-)
diff --git a/tools/ppa/ppa.sh b/tools/ppa/ppa.sh
index 7f9ad18..e392fca 100755
--- a/tools/ppa/ppa.sh
+++ b/tools/ppa/ppa.sh
@@ -16,8 +16,7 @@ export DEBEMAIL="`gpg --list-keys | grep uid | sed 's/ *(.*)//; s/>.*//; s/.*[:<
# Config
PKG="performous"
-PPAVERSIONNUM="1"
-VERSIONCOMMON="+git"`date '+%Y%m%d'`"~ppa${PPAVERSIONNUM}"
+VERSIONCOMMON="0.5.1-9+git"`date '+%Y%m%d'`"~ppa1"
SUITES="karmic lucid maverick"
GITURL="git://git.performous.org/gitroot/performous/performous"
DESTINATIONPPA="ppa:performous-team/ppa"
@@ -44,63 +43,56 @@ PPAPATCHDIR="`pwd`"
cd "$TEMPDIR"
-# Download the "old" source package
+# Figure out the version of the "old" official package
version=`apt-cache showsrc $PKG | sed -n 's/^Version: \(.*\)/\1/p' | head -n 1`
-pkgversion=`apt-cache showsrc $PKG | sed -n 's/^Version: \(.*\)-.*/\1/p' | head -n 1`
-pkgversion=${pkgversion##*:}
-if [ -z "$pkgversion" ] ; then
- echo "Assuming native package"
- pkgversion="$version"
-fi
-echo "Working on $PKG $version ($pkgversion)"
+echo "Working on $PKG $version"
+
mkdir -p $PKG-$version
cd $PKG-$version
+
+# Download the "old" source package we use as a base
apt-get --download-only source $PKG
# Download fresh version from git
echo "Fetch from git..."
git clone "$GITURL" "$SOURCEDIR"
+
# Get some info from git for changelog
pushd .
cd "$SOURCEDIR"
+# 10 chars from the HEAD commit hash
headcommit=`git log | head -n 1 | cut --delimiter=" " -f 2 | cut -c 1-10`
popd
-filenameversion=${version##*:}
# Loop suites
for suite in $SUITES ; do
- versionsuffix="${VERSIONCOMMON}~${suite}"
- ppaversion="${version}${versionsuffix}"
- filenameppaversion="${filenameversion}${versionsuffix}"
- rm -rf $suite
- mkdir $suite
+ newversion="${VERSIONCOMMON}~${suite}"
+ rm -rf $suite; mkdir $suite
cd $suite
ln ../${PKG}_* .
- dpkg-source -x ${PKG}_$filenameversion.dsc
- cd $PKG-$pkgversion
-
- # Copy new files
- echo "Copy new files..."
- CopyNewFiles "$SOURCEDIR" .
- # Apply patches
- echo "Apply some patches..."
- cp "$PPAPATCHDIR/"*.patch .
- patch -p0 < *.patch
- rm *.patch
-
- # Do changelog
- # Dch complains about unknown suites
- yes '' | dch -b -v $ppaversion -D $suite "Upload development version from Git $headcommit to Ubuntu PPA for $suite."
- if [ -f debian/source/format -a ! -f debian/patches/series ] ; then
- rm debian/source/format
- fi
- # Build package
- #dpkg-buildpackage -sa -S # Full .orig.gz
- dpkg-buildpackage -sd -S # Only .diff.gz
- pwd
+ dpkg-source -x ${PKG}_${version}.dsc extracted
+ cd extracted
+ # Copy new files
+ echo "Copy new files..."
+ CopyNewFiles "$SOURCEDIR" .
+ # Apply patches
+ echo "Apply some patches..."
+ cp "$PPAPATCHDIR/"*.patch .
+ patch -p0 < *.patch
+ rm *.patch
+
+ # Do changelog
+ # Dch complains about unknown suites
+ yes '' | dch -b -v $newversion -D $suite "Upload development version from Git $headcommit to Ubuntu PPA for $suite."
+ if [ -f debian/source/format -a ! -f debian/patches/series ] ; then
+ rm debian/source/format
+ fi
+ # Build package
+ #dpkg-buildpackage -sa -S # Full .orig.gz
+ dpkg-buildpackage -sd -S # Only .diff.gz
cd ..
# Upload to PPA
- dput $DESTINATIONPPA ${PKG}_${filenameppaversion}_source.changes
+ dput $DESTINATIONPPA ${PKG}_${newversion}_source.changes
cd ..
done
cd ..
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 15:03:57
|
Module: performous
Branch: master
Commit: 0ab67d1b0c92dda94d56b4e716ace3342b4fcb96
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 18:03:34 2010 +0300
Fix keyboard drum kit.
---
game/joystick.cc | 2 --
1 files changed, 0 insertions(+), 2 deletions(-)
diff --git a/game/joystick.cc b/game/joystick.cc
index 2691ae0..095ed04 100644
--- a/game/joystick.cc
+++ b/game/joystick.cc
@@ -505,7 +505,6 @@ bool input::SDL::pushEvent(SDL_Event _e) {
button++;
case SDLK_SPACE:
if(!drumkit) return false;
- if(devices.find(joy_id)->second.pressed(button)) return true; // repeating
is_drumkit_event = true;
event.type = input::Event::PRESS;
event.pressed[button] = true;
@@ -646,7 +645,6 @@ bool input::SDL::pushEvent(SDL_Event _e) {
button++;
case SDLK_SPACE:
if(!drumkit) return false;
- if(devices.find(joy_id)->second.pressed(button)) return true; // repeating
is_drumkit_event = true;
event.type = input::Event::RELEASE;
event.pressed[button] = true;
|
|
From: Tapio V. <aa...@us...> - 2010-09-15 05:34:18
|
Module: performous
Branch: master
Commit: f5e1ae1dcc7c60a68f13ca560e587a425c212a62
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 08:33:17 2010 +0300
Fix Analyzer::input again.
---
game/pitch.hh | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/game/pitch.hh b/game/pitch.hh
index 52b14ae..d7ca49e 100644
--- a/game/pitch.hh
+++ b/game/pitch.hh
@@ -60,7 +60,7 @@ class Analyzer {
if (w == r) overflow = true;
}
m_bufWrite = w;
- if (overflow) m_bufRead = w; // Reset read pointer on overflow
+ if (overflow) m_bufRead = (w + 1) % BUF_N; // Reset read pointer on overflow
}
/** Call this to process all data input so far. **/
void process();
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2010-09-14 22:09:00
|
Module: performous Branch: master Commit: 404d4ee397611574f0a028cecda0be6def004c6f Author: Lasse Karkkainen <tro...@tr...> Date: Wed Sep 15 01:08:39 2010 +0300 Merge branch 'master' of ssh://git.performous.org/gitroot/performous/performous --- |
|
From: Lasse Kärkkäi. <tr...@us...> - 2010-09-14 22:08:58
|
Module: performous
Branch: master
Commit: 8926b55eb9392b13aae7b5e8761ed33d1c7ab74e
Author: Lasse Karkkainen <tro...@tr...>
Date: Wed Sep 15 00:24:07 2010 +0300
Cleanup to pitch.hh (hopefully I don't break it again).
---
game/pitch.hh | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/game/pitch.hh b/game/pitch.hh
index 7cc617f..52b14ae 100644
--- a/game/pitch.hh
+++ b/game/pitch.hh
@@ -48,7 +48,6 @@ class Analyzer {
template <typename InIt> void input(InIt begin, InIt end) {
size_t r = m_bufRead; // The read position
size_t w = m_bufWrite; // The write position
- size_t wNext; // The next write position
bool overflow = false;
while (begin != end) {
float s = *begin++; // Read input sample
@@ -57,12 +56,11 @@ class Analyzer {
if (p > m_peak) m_peak = p; else m_peak *= 0.999;
m_buf[w] = s;
// Cursor updates
- wNext = (w + 1) % BUF_N;
- if (wNext == r) overflow = true;
- w = wNext;
+ w = (w + 1) % BUF_N;
+ if (w == r) overflow = true;
}
m_bufWrite = w;
- if (overflow) m_bufRead = (wNext + 1) % BUF_N; // Reset read pointer on overflow
+ if (overflow) m_bufRead = w; // Reset read pointer on overflow
}
/** Call this to process all data input so far. **/
void process();
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2010-09-14 22:08:56
|
Module: performous Branch: master Commit: 5fa1c585e0e39a95cad37493ec4d187ee5ddc97b Author: Lasse Karkkainen <tro...@tr...> Date: Wed Sep 15 00:14:20 2010 +0300 Merge remote branch 'origin/master' --- |
|
From: Lasse Kärkkäi. <tr...@us...> - 2010-09-14 22:08:53
|
Module: performous Branch: master Commit: e0e5bbd1a0a5eca3890041917344e1713bb93e81 Author: Lasse Karkkainen <tro...@tr...> Date: Mon Sep 6 21:18:46 2010 +0300 Minor cleanup of a confusing control structure into a confusing short-circuit structure + a clarifying comment. --- game/guitargraph.cc | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/game/guitargraph.cc b/game/guitargraph.cc index 9e81b4f..e05670e 100644 --- a/game/guitargraph.cc +++ b/game/guitargraph.cc @@ -125,12 +125,12 @@ GuitarGraph::GuitarGraph(Audio& audio, Song const& song, bool drums, int number, m_track_index = m_instrumentTracks.begin(); while (number--) if (++m_track_index == m_instrumentTracks.end()) m_track_index = m_instrumentTracks.begin(); - // Pick a nice default difficulty - if (difficulty(DIFFICULTY_EASY)); - else if (difficulty(DIFFICULTY_SUPAEASY)); - else if (difficulty(DIFFICULTY_MEDIUM)); - else if (difficulty(DIFFICULTY_AMAZING)); - else difficultyAuto(); + // Pick a nice default difficulty (note: the execution of || stops when true is returned) + difficulty(DIFFICULTY_EASY) || + difficulty(DIFFICULTY_SUPAEASY) || + difficulty(DIFFICULTY_MEDIUM) || + difficulty(DIFFICULTY_AMAZING) || + (difficultyAuto(), true); updateNeck(); setupJoinMenu(); } |
|
From: Tapio V. <aa...@us...> - 2010-09-14 21:34:46
|
Module: performous
Branch: master
Commit: 72459cc6678c368a88fe5d2b3375ff4d482fbe6f
Author: Tapio Vierros <tap...@gm...>
Date: Wed Sep 15 00:32:56 2010 +0300
Moved man pages to a subdir (cleaner looking docs dir), also updated slightly.
---
docs/CMakeLists.txt | 45 +-------------------------------------
docs/man/CMakeLists.txt | 41 ++++++++++++++++++++++++++++++++++
docs/{ => man}/gh_fsb_decrypt.1 | 0
docs/{ => man}/gh_xen_decrypt.1 | 0
docs/{ => man}/performous.h2m | 5 ++-
docs/{ => man}/ss_adpcm_decode.1 | 0
docs/{ => man}/ss_chc_decode.1 | 0
docs/{ => man}/ss_cover_conv.1 | 0
docs/{ => man}/ss_extract.1 | 0
docs/{ => man}/ss_ipu_conv.1 | 0
docs/{ => man}/ss_ipu_decode.1 | 0
docs/{ => man}/ss_pak_extract.1 | 0
12 files changed, 45 insertions(+), 46 deletions(-)
diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt
index 7fa9733..790aefd 100644
--- a/docs/CMakeLists.txt
+++ b/docs/CMakeLists.txt
@@ -1,46 +1,3 @@
-
if(UNIX)
- find_program(HELP2MAN help2man DOC "Location of the help2man program")
- find_program(GZIP gzip DOC "Location of the gzip program")
- mark_as_advanced(HELP2MAN)
- mark_as_advanced(GZIP)
- if(HELP2MAN AND GZIP)
- set(MANFILE ${CMAKE_CURRENT_BINARY_DIR}/performous.6.gz)
- set(H2MFILE ${CMAKE_CURRENT_SOURCE_DIR}/performous.h2m)
- set(PERFORMOUS_EXEC ${CMAKE_BINARY_DIR}/game/performous)
- add_custom_command(
- OUTPUT ${MANFILE}
- COMMAND ${HELP2MAN} ${PERFORMOUS_EXEC} -s 6 -i ${H2MFILE} -N | ${GZIP} > ${MANFILE}
- MAIN_DEPENDENCY ${H2MFILE}
- DEPENDS ${PERFORMOUS_EXEC}
- COMMENT "Building Performous man page"
- VERBATIM
- )
- add_custom_target(manpage ALL DEPENDS ${MANFILE})
- install(FILES ${MANFILE} DESTINATION share/man/man6)
- else(HELP2MAN AND GZIP)
- message("WARNING: One of the following is missing: help2man, gzip; performous man page will not be generated")
- endif(HELP2MAN AND GZIP)
- if(ENABLE_TOOLS AND GZIP)
- set(TOOLS
- "ss_pak_extract" "ss_extract" "ss_cover_conv"
- "ss_adpcm_decode" "ss_ipu_decode" "ss_ipu_conv"
- "gh_xen_decrypt" "ss_chc_decode")
- set(MAN_SECTION "1")
- foreach(TOOL ${TOOLS})
- set(TOOL_MANFILE ${CMAKE_CURRENT_SOURCE_DIR}/${TOOL}.${MAN_SECTION})
- set(TOOL_MANFILE_GZ ${CMAKE_CURRENT_BINARY_DIR}/${TOOL}.${MAN_SECTION}.gz)
- add_custom_command(
- OUTPUT ${TOOL_MANFILE_GZ}
- COMMAND ${GZIP} -c ${TOOL_MANFILE} > ${TOOL_MANFILE_GZ}
- MAIN_DEPENDENCY ${TOOL_MANFILE}
- COMMENT "Building ${TOOL} man page"
- VERBATIM
- )
- add_custom_target(${TOOL}.${MAN_SECTION} ALL DEPENDS ${TOOL_MANFILE_GZ})
- install(FILES ${TOOL_MANFILE_GZ} DESTINATION share/man/man${MAN_SECTION})
- endforeach(TOOL)
- endif(ENABLE_TOOLS AND GZIP)
+ add_subdirectory(man)
endif(UNIX)
-
-
diff --git a/docs/man/CMakeLists.txt b/docs/man/CMakeLists.txt
new file mode 100644
index 0000000..7261ee6
--- /dev/null
+++ b/docs/man/CMakeLists.txt
@@ -0,0 +1,41 @@
+find_program(HELP2MAN help2man DOC "Location of the help2man program")
+find_program(GZIP gzip DOC "Location of the gzip program")
+mark_as_advanced(HELP2MAN)
+mark_as_advanced(GZIP)
+if(HELP2MAN AND GZIP)
+ set(MANFILE ${CMAKE_CURRENT_BINARY_DIR}/performous.6.gz)
+ set(H2MFILE ${CMAKE_CURRENT_SOURCE_DIR}/performous.h2m)
+ set(PERFORMOUS_EXEC ${CMAKE_BINARY_DIR}/game/performous)
+ add_custom_command(
+ OUTPUT ${MANFILE}
+ COMMAND ${HELP2MAN} ${PERFORMOUS_EXEC} -s 6 -i ${H2MFILE} -N | ${GZIP} > ${MANFILE}
+ MAIN_DEPENDENCY ${H2MFILE}
+ DEPENDS ${PERFORMOUS_EXEC}
+ COMMENT "Building Performous man page"
+ VERBATIM
+ )
+ add_custom_target(manpage ALL DEPENDS ${MANFILE})
+ install(FILES ${MANFILE} DESTINATION share/man/man6)
+else(HELP2MAN AND GZIP)
+ message("WARNING: One of the following is missing: help2man, gzip; performous man page will not be generated")
+endif(HELP2MAN AND GZIP)
+if(ENABLE_TOOLS AND GZIP)
+ set(TOOLS
+ "ss_pak_extract" "ss_extract" "ss_cover_conv"
+ "ss_adpcm_decode" "ss_ipu_decode" "ss_ipu_conv"
+ "gh_xen_decrypt" "ss_chc_decode")
+ set(MAN_SECTION "1")
+ foreach(TOOL ${TOOLS})
+ set(TOOL_MANFILE ${CMAKE_CURRENT_SOURCE_DIR}/${TOOL}.${MAN_SECTION})
+ set(TOOL_MANFILE_GZ ${CMAKE_CURRENT_BINARY_DIR}/${TOOL}.${MAN_SECTION}.gz)
+ add_custom_command(
+ OUTPUT ${TOOL_MANFILE_GZ}
+ COMMAND ${GZIP} -c ${TOOL_MANFILE} > ${TOOL_MANFILE_GZ}
+ MAIN_DEPENDENCY ${TOOL_MANFILE}
+ COMMENT "Building ${TOOL} man page"
+ VERBATIM
+ )
+ add_custom_target(${TOOL}.${MAN_SECTION} ALL DEPENDS ${TOOL_MANFILE_GZ})
+ install(FILES ${TOOL_MANFILE_GZ} DESTINATION share/man/man${MAN_SECTION})
+ endforeach(TOOL)
+endif(ENABLE_TOOLS AND GZIP)
diff --git a/docs/gh_fsb_decrypt.1 b/docs/man/gh_fsb_decrypt.1
similarity index 100%
rename from docs/gh_fsb_decrypt.1
rename to docs/man/gh_fsb_decrypt.1
diff --git a/docs/gh_xen_decrypt.1 b/docs/man/gh_xen_decrypt.1
similarity index 100%
rename from docs/gh_xen_decrypt.1
rename to docs/man/gh_xen_decrypt.1
diff --git a/docs/performous.h2m b/docs/man/performous.h2m
similarity index 86%
rename from docs/performous.h2m
rename to docs/man/performous.h2m
index 98e578d..cad1c42 100644
--- a/docs/performous.h2m
+++ b/docs/man/performous.h2m
@@ -84,11 +84,12 @@ Toggle pitch wave rendering (only when karaoke mode is disabled)
Hot reload song from disk (useful for making or repairing songs)
[audio device configuration]
-Performous normally autodetects microphones and playback devices correctly, but if this fails on your machine, you will need to configure them from command line because in-game configuration is not yet implemented. Once you have them working, enter the configuration menu and press \fBCtrl+S\fR to save them to your config file so that they don't need to specified when starting the program.
+Performous normally autodetects microphones and playback devices correctly, but if this fails on your machine, you will need to configure them in the Audio Devices -screen. Advanced configuration is possible through the command line, just remember to enter the configuration menu and press \fBCtrl+S\fR to save them to your config file so that they don't need to be specified every time the program starts.
-Additionally, the current version prints a list of ALSA devices detected to console. Use this as a reference for your configuration.
+The list of available PortAudio devices is printed to the console, but it can also be seen from the GUI.
[see also]
You can find more information at http://performous.org/ or
+http://wiki.performous.org or
http://sourceforge.net/projects/performous/
diff --git a/docs/ss_adpcm_decode.1 b/docs/man/ss_adpcm_decode.1
similarity index 100%
rename from docs/ss_adpcm_decode.1
rename to docs/man/ss_adpcm_decode.1
diff --git a/docs/ss_chc_decode.1 b/docs/man/ss_chc_decode.1
similarity index 100%
rename from docs/ss_chc_decode.1
rename to docs/man/ss_chc_decode.1
diff --git a/docs/ss_cover_conv.1 b/docs/man/ss_cover_conv.1
similarity index 100%
rename from docs/ss_cover_conv.1
rename to docs/man/ss_cover_conv.1
diff --git a/docs/ss_extract.1 b/docs/man/ss_extract.1
similarity index 100%
rename from docs/ss_extract.1
rename to docs/man/ss_extract.1
diff --git a/docs/ss_ipu_conv.1 b/docs/man/ss_ipu_conv.1
similarity index 100%
rename from docs/ss_ipu_conv.1
rename to docs/man/ss_ipu_conv.1
diff --git a/docs/ss_ipu_decode.1 b/docs/man/ss_ipu_decode.1
similarity index 100%
rename from docs/ss_ipu_decode.1
rename to docs/man/ss_ipu_decode.1
diff --git a/docs/ss_pak_extract.1 b/docs/man/ss_pak_extract.1
similarity index 100%
rename from docs/ss_pak_extract.1
rename to docs/man/ss_pak_extract.1
|
|
From: Tapio V. <aa...@us...> - 2010-09-14 21:34:46
|
Module: performous Branch: master Commit: cb4a4cf7e14fc075b8118ff42bbf183771c27eab Author: Tapio Vierros <tap...@gm...> Date: Wed Sep 15 00:23:35 2010 +0300 Docs updates. --- docs/Authors.txt | 20 ++++++++++++++------ docs/Compiling.txt | 6 +++++- docs/DeveloperReadme.txt | 23 +++++++++++++++++------ docs/TODO.txt | 2 -- 4 files changed, 36 insertions(+), 15 deletions(-) diff --git a/docs/Authors.txt b/docs/Authors.txt index 7876be1..06d6f8b 100644 --- a/docs/Authors.txt +++ b/docs/Authors.txt @@ -9,6 +9,10 @@ Lasse Kärkkäinen <tronic+ndrm at trn.iki.fi> * Core developer * FFT/Analyzer, LibDA and a lot of other things +Tapio Vierros <aave000 at users.sourceforge.net> + * Core developer + * Lots of stuff in various areas + Topnob <topnob at users.sourceforge.net> * Non-power-of-two texture loading on older hardware * Many other fixes @@ -30,9 +34,6 @@ dex7 <dex7 at users.sourceforge.net> Fabian Fingerle <fabian at datensalat.eu> * Dependency testing -Tapio Vierros <aave000 at users.sourceforge.net> - * Various things and features - Miguel Sánchez de León Peque <msdeleonpeque at gmail.com> * Main menu * SVG design @@ -41,14 +42,21 @@ Xaldyz <xaldyz at users.sourceforge.net> * Windows build fixes and testing Markus Raab <ich at markus-raab.org> - * hiscore (xml + ultrastar format) + * Hiscore (xml + ultrastar format) Matti Kemppainen <mpkemppa at users.sf.net> - * prototyping dance game + * Prototyping dance game Jaakko Nikkola <jnikkola at users.sourceforge.net> * Dance game developer - + +John Stumpo <stump at jstump.com> + * Windows compilation scripts + +Fredrik Klasson <scientica at gmail.com> + * Logging stuff, xml i18n, image loading tweaks + + INACTIVE DEVELOPERS ------------------- diff --git a/docs/Compiling.txt b/docs/Compiling.txt index 62237c9..19cecdc 100644 --- a/docs/Compiling.txt +++ b/docs/Compiling.txt @@ -17,11 +17,13 @@ To install from git: Dependencies: + - OpenGL : graphics + - Boost : threads, parsers/conversions, pointer containers, ... - SDL : window management and input - - FFMpeg (avcodec, avformat and swscale): A/V decoding + - FFmpeg (avcodec, avformat and swscale): A/V decoding - Cairo >= 1.2 : scalable graphical support @@ -31,6 +33,8 @@ Dependencies: - PortAudio v19 : audio capture and playback + - Gettext (optional) for internationalization + - PortMidi (optional) for MIDI drum support - OpenCV (optional) for webcam support diff --git a/docs/DeveloperReadme.txt b/docs/DeveloperReadme.txt index 6ebe040..3ce9f6e 100644 --- a/docs/DeveloperReadme.txt +++ b/docs/DeveloperReadme.txt @@ -1,8 +1,22 @@ +NOTICE +====== +**Developer guides are now located at the wiki: http://wiki.performous.org/index.php/Developing** + +**This file is out dated.** + Where to find the files you are looking for: -share/ icons and other such binary files -themes/ all graphics, menu music, etc -game/ the source code of the game + docs/ documentation and man pages + data/ sounds and other such binaries + configuration files + themes/ all graphics, menu music, etc + game/ the source code of the game + tools/ various tools and scripts for both end-users and developers + lang/ translations + osx-utils/ OSX packaging tools + win32/ Windows specific stuff and packaging utilities + editor/ defunct song editor + portage-overlay/ ebuilds for Gentoo + cmake/ CMake modules When adding new data files, you may need to edit the CMakeLists.txt file in that folder to have CMake actually install it. When adding new source code files, @@ -166,6 +180,3 @@ there are no specifications to follow (you only find out what you will be doing after implementing some of it). Writing useful tests for code dealing with graphics, threads etc. is also very difficult. - -TODO: move the documentation in this file to the website developers page? - diff --git a/docs/TODO.txt b/docs/TODO.txt index 3c51138..2eb7331 100644 --- a/docs/TODO.txt +++ b/docs/TODO.txt @@ -26,10 +26,8 @@ Features: * Audio roundtrip by analyzing the sound captured by the microphone * Controller/audio latency by playing blindly (listening to the beat only) * Audio/video by playing visually without audio? (needs controller/audio calibrated) -- Better audio card configuration ingame (needs PortAudio backend) - Allow playing a single song given as commandline argument (no menus) - Kiosk/arcade mode (disable exiting game and limit other functions) -- Allow left-handed/reversed controllers (guitars, drum kits) Dance features: |
|
From: Tapio V. <aa...@us...> - 2010-09-14 20:45:43
|
Module: performous Branch: master Commit: c7dcba6fff1da81bb3491789d6e09e604d6331c7 Author: Tapio Vierros <tap...@gm...> Date: Tue Sep 14 23:44:47 2010 +0300 Update fi translation + a couple of small tweaks. --- game/configuration.cc | 5 +- game/screen_intro.cc | 2 +- lang/fi.po | 744 +++++++++++++++++++++++++++++-------------------- 3 files changed, 450 insertions(+), 301 deletions(-) |
|
From: Tapio V. <aa...@us...> - 2010-09-14 18:19:20
|
Module: performous
Branch: master
Commit: 8d64557571abcc1bd8efdf90839e7200c5603dd2
Author: Tapio Vierros <tap...@gm...>
Date: Tue Sep 14 21:18:41 2010 +0300
Fixed Analyzer::input so that we can sing again.
---
game/libda/sample.hpp | 2 +-
game/pitch.hh | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/game/libda/sample.hpp b/game/libda/sample.hpp
index 5d53b6e..7c055a4 100644
--- a/game/libda/sample.hpp
+++ b/game/libda/sample.hpp
@@ -55,7 +55,7 @@ namespace da {
ValueType& operator*() { return *m_pos; }
step_iterator operator+(std::ptrdiff_t rhs) { return step_iterator(m_pos + m_step * rhs, m_step); }
step_iterator& operator++() { m_pos += m_step; return *this; }
- step_iterator operator++(int) { step_iterator ret = *this; ++*this; return ret; }
+ step_iterator operator++(int) { step_iterator ret = *this; ++*this; return ret; }
bool operator!=(step_iterator const& rhs) const { return m_pos != rhs.m_pos; }
std::ptrdiff_t operator-(step_iterator const& rhs) const { return (m_pos - rhs.m_pos) / m_step; }
// TODO: more operators
diff --git a/game/pitch.hh b/game/pitch.hh
index 2f27bf3..7cc617f 100644
--- a/game/pitch.hh
+++ b/game/pitch.hh
@@ -55,13 +55,14 @@ class Analyzer {
// Peak level calculation
float p = s * s;
if (p > m_peak) m_peak = p; else m_peak *= 0.999;
+ m_buf[w] = s;
// Cursor updates
wNext = (w + 1) % BUF_N;
if (wNext == r) overflow = true;
w = wNext;
}
m_bufWrite = w;
- if (overflow) m_bufRead = wNext; // Reset read pointer on overflow
+ if (overflow) m_bufRead = (wNext + 1) % BUF_N; // Reset read pointer on overflow
}
/** Call this to process all data input so far. **/
void process();
|
|
From: Tapio V. <aa...@us...> - 2010-09-14 17:15:28
|
Module: performous
Branch: master
Commit: 58022eae5dd288936c3a46de776de5fc55507508
Author: Tapio Vierros <tap...@gm...>
Date: Tue Sep 14 20:14:47 2010 +0300
Drop GL attribute errors to warning class.
---
game/video_driver.cc | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/game/video_driver.cc b/game/video_driver.cc
index 4e33ac0..4ad9d69 100644
--- a/game/video_driver.cc
+++ b/game/video_driver.cc
@@ -17,13 +17,13 @@ namespace {
/// Tests for success when destoryed.
struct GLattrSetter {
GLattrSetter(SDL_GLattr attr, int value): m_attr(attr), m_value(value) {
- if (SDL_GL_SetAttribute(attr, value)) std::clog << "video/error: Error setting GLattr " << m_attr << std::endl;
+ if (SDL_GL_SetAttribute(attr, value)) std::clog << "video/warning: Error setting GLattr " << m_attr << std::endl;
}
~GLattrSetter() {
int value;
SDL_GL_GetAttribute(m_attr, &value);
if (value != m_value)
- std::clog << "video/error: Error setting GLattr " << m_attr
+ std::clog << "video/warning: Error setting GLattr " << m_attr
<< ": requested " << m_value << ", got " << value << std::endl;
}
SDL_GLattr m_attr;
|
|
From: Tapio V. <aa...@us...> - 2010-09-14 17:06:29
|
Module: performous
Branch: master
Commit: 95d1976b857f62ff4c56b2509be50777d6138b78
Author: Tapio Vierros <tap...@gm...>
Date: Tue Sep 14 20:03:11 2010 +0300
Simple framework for indicating loading progress to user.
* Main loop loading and screen_sing loading converted.
* Give more info than before.
* Currently output looks as lame as before.
---
game/main.cc | 11 +++++++----
game/screen.hh | 4 +++-
game/screen_sing.cc | 17 +++++++++++++----
game/screenmanager.cc | 9 +++++++++
4 files changed, 32 insertions(+), 9 deletions(-)
diff --git a/game/main.cc b/game/main.cc
index b91b40b..3c883ba 100644
--- a/game/main.cc
+++ b/game/main.cc
@@ -111,10 +111,11 @@ static void checkEvents_SDL(ScreenManager& sm) {
void mainLoop(std::string const& songlist) {
Window window(config["graphic/window_width"].i(), config["graphic/window_height"].i(), config["graphic/fullscreen"].b());
- Audio audio;
ScreenManager sm(window);
+ sm.loading(_("Audio..."), 0.1);
+ Audio audio;
try {
- sm.flashMessage(_("Miscellaneous..."), 0.0f, 1.0f, 1.0f); window.blank(); sm.drawNotifications(); window.swap();
+ sm.loading(_("Launching background loaders..."), 0.4);
Backgrounds backgrounds;
Database database(getConfigDir() / "database.xml");
Songs songs(database, songlist);
@@ -122,6 +123,7 @@ void mainLoop(std::string const& songlist) {
// TODO: Proper error handling...
try { midiDrums.reset(new input::MidiDrums); } catch (std::runtime_error&) {}
// Load audio samples
+ sm.loading(_("Loading audio samples..."), 0.5);
audio.loadSample("drum bass", getPath("sounds/drum_bass.ogg"));
audio.loadSample("drum snare", getPath("sounds/drum_snare.ogg"));
audio.loadSample("drum hi-hat", getPath("sounds/drum_hi-hat.ogg"));
@@ -135,6 +137,7 @@ void mainLoop(std::string const& songlist) {
audio.loadSample("guitar fail5", getPath("sounds/guitar_fail5.ogg"));
audio.loadSample("guitar fail6", getPath("sounds/guitar_fail6.ogg"));
// Load screens
+ sm.loading(_("Creating screens..."), 0.7);
sm.addScreen(new ScreenIntro("Intro", audio));
sm.addScreen(new ScreenSongs("Songs", audio, songs, database));
sm.addScreen(new ScreenSing("Sing", audio, database, backgrounds));
@@ -143,9 +146,9 @@ void mainLoop(std::string const& songlist) {
sm.addScreen(new ScreenAudioDevices("AudioDevices", audio));
sm.addScreen(new ScreenPlayers("Players", audio, database));
sm.activateScreen("Intro");
- sm.flashMessage(_("Main menu..."), 0.0f, 1.0f, 1.0f); window.blank(); sm.drawNotifications(); window.swap();
+ sm.loading(_("Entering main menu"), 0.8);
sm.updateScreen(); // exit/enter, any exception is fatal error
- sm.flashMessage("");
+ sm.loading(_("Loading complete"), 1.0);
// Main loop
boost::xtime time = now();
unsigned frames = 0;
diff --git a/game/screen.hh b/game/screen.hh
index 2ee93d3..b692ccb 100644
--- a/game/screen.hh
+++ b/game/screen.hh
@@ -53,8 +53,10 @@ class ScreenManager: public Singleton <ScreenManager> {
/// Returns a reference to the window
Window& window() { return m_window; };
+ /// Draw a loading progress indication
+ void loading(std::string const& message, float progress);
/// Set a message to flash in current screen
- void flashMessage(std::string const& name, float fadeIn=0.5f, float hold=1.5f, float fadeOut=1.0f);
+ void flashMessage(std::string const& message, float fadeIn=0.5f, float hold=1.5f, float fadeOut=1.0f);
/// Create a new dialog message
void dialog(std::string const& text);
/// Close dialog and return true if it was opened in the first place
diff --git a/game/screen_sing.cc b/game/screen_sing.cc
index 486f8ad..daf4439 100644
--- a/game/screen_sing.cc
+++ b/game/screen_sing.cc
@@ -33,10 +33,10 @@ namespace {
void ScreenSing::enter() {
//m_practmode = true; // un-comment this line to play with practice mode. temporary, of course!
ScreenManager* sm = ScreenManager::getSingletonPtr();
- sm->flashMessage(_("Loading song..."), 0.0, 1.0, 0.5);
- sm->drawNotifications(); sm->window().swap(); // Make loading message show
+ sm->loading(_("Loading theme..."), 0.0);
theme.reset(new ThemeSing());
m_menuTheme.reset(new ThemeInstrumentMenu());
+ sm->loading(_("Loading song..."), 0.3);
// Load the rest of the song
if (m_song->loadStatus != Song::FULL) {
try { SongParser sp(*m_song); }
@@ -46,9 +46,8 @@ void ScreenSing::enter() {
sm->activateScreen("Songs");
}
}
- // Notify about broken tracks
- if (m_song->b0rkedTracks) ScreenManager::getSingletonPtr()->flashMessage(_("Song contains broken tracks!"));
// Load background
+ sm->loading(_("Loading background..."), 0.4);
bool foundbg = false;
if (!m_song->background.empty()) { // Load bg image
try {
@@ -60,17 +59,20 @@ void ScreenSing::enter() {
}
}
// Initialize webcam
+ sm->loading(_("Initializing webcam..."), 0.5);
if (config["graphic/webcam"].b() && Webcam::enabled()) {
try {
m_cam.reset(new Webcam(config["graphic/webcamid"].i()));
} catch (std::exception& e) { std::cout << e.what() << std::endl; };
}
// Load video
+ sm->loading(_("Loading video..."), 0.6);
if (!m_song->video.empty() && config["graphic/video"].b()) {
m_video.reset(new Video(m_song->path + m_song->video, m_song->videoGap));
}
// Use random bg if specified fails (also for tracks with video)
if (!foundbg) {
+ sm->loading(_("Random background..."), 0.65);
for (int i = 1; i <= 2; ++i) { // Try two times in case first is b0rked
try {
std::string bgpath = m_backgrounds.getRandom();
@@ -81,6 +83,7 @@ void ScreenSing::enter() {
}
}
}
+ sm->loading(_("Loading user interface..."), 0.7);
m_pause_icon.reset(new Surface(getThemePath("sing_pause.svg")));
m_help.reset(new Surface(getThemePath("instrumenthelp.svg")));
m_progress.reset(new ProgressBar(getThemePath("sing_progressbg.svg"), getThemePath("sing_progressfg.svg"), ProgressBar::HORIZONTAL, 0.01f, 0.01f, true));
@@ -89,6 +92,7 @@ void ScreenSing::enter() {
boost::ptr_vector<Analyzer>& analyzers = m_audio.analyzers();
m_layout_singer.reset(new LayoutSinger(m_song->vocals, m_database, theme));
// Load instrument and dance tracks
+ sm->loading(_("Loading instruments..."), 0.8);
{
int type = 0; // 0 for dance, 1 for guitars, 2 for drums
int idx = 0;
@@ -110,6 +114,7 @@ void ScreenSing::enter() {
}
}
// Populate the pause menu
+ sm->loading(_("Loading menu..."), 0.9);
m_menu.clear();
m_menu.add(MenuOption(_("Resume"), _("Back to performing!")));
m_menu.add(MenuOption(_("Restart"), _("Start the song\nfrom the beginning"), "Sing"));
@@ -117,8 +122,12 @@ void ScreenSing::enter() {
m_menu.close();
// Startup delay for instruments is longer than for singing only
double setup_delay = (m_instruments.empty() && m_dancers.empty() ? -1.0 : -3.0);
+ sm->loading(_("Finalizing..."), 0.95);
m_audio.playMusic(m_song->music, false, 0.0, setup_delay);
m_engine.reset(new Engine(m_audio, m_song->vocals, analyzers.begin(), analyzers.end(), m_database));
+ sm->loading(_("Loading complete"), 1.0);
+ // Notify about broken tracks
+ if (m_song->b0rkedTracks) ScreenManager::getSingletonPtr()->dialog(_("Song contains broken tracks!"));
}
diff --git a/game/screenmanager.cc b/game/screenmanager.cc
index ccbc7b7..82b7c4d 100644
--- a/game/screenmanager.cc
+++ b/game/screenmanager.cc
@@ -2,6 +2,7 @@
#include "fs.hh"
#include "configuration.hh"
+#include <boost/lexical_cast.hpp>
#include <stdexcept>
template<> ScreenManager* Singleton<ScreenManager>::ms_Singleton = NULL;
@@ -36,6 +37,14 @@ Screen* ScreenManager::getScreen(std::string const& name) {
}
}
+void ScreenManager::loading(std::string const& message, float progress) {
+ // TODO: Create a better one, this is quite ugly
+ flashMessage(message + " " + boost::lexical_cast<std::string>(progress*100) + "%", 0.0f, 1.0f, 1.0f);
+ m_window.blank();
+ drawNotifications();
+ m_window.swap();
+}
+
void ScreenManager::flashMessage(std::string const& message, float fadeIn, float hold, float fadeOut) {
m_message = message;
m_timeToFadeIn = fadeIn;
|
|
From: Tapio V. <aa...@us...> - 2010-09-14 16:29:07
|
Module: performous Branch: master Commit: a8245d29d660ef37a2772f54e46fc1768d7382c2 Author: Tapio Vierros <tap...@gm...> Date: Tue Sep 14 19:26:53 2010 +0300 Add awesomely simple-to-use warning popup dialog system. * Intro screen and audio device config screen coverted to use this. * Fixed flawed intro screen missing playback device detection. --- game/audio.cc | 6 +++++ game/audio.hh | 1 + game/main.cc | 10 +++++--- game/screen.hh | 24 ++++++++++++++------- game/screen_audiodevices.cc | 21 +++++++----------- game/screen_audiodevices.hh | 4 +-- game/screen_intro.cc | 9 +------ game/screen_intro.hh | 2 - game/screen_sing.cc | 2 +- game/screenmanager.cc | 49 +++++++++++++++++++++++++++--------------- 10 files changed, 72 insertions(+), 56 deletions(-) |
|
From: Tapio V. <aa...@us...> - 2010-09-14 15:34:59
|
Module: performous
Branch: master
Commit: 36fae85f9941822a95bad9dea1e5f3ef9cbda9e4
Author: Tapio Vierros <tap...@gm...>
Date: Tue Sep 14 18:33:59 2010 +0300
Main menu selection highlight bg image now has adaptive width.
---
game/screen_intro.cc | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/game/screen_intro.cc b/game/screen_intro.cc
index 2732ea3..9cd7d20 100644
--- a/game/screen_intro.cc
+++ b/game/screen_intro.cc
@@ -57,17 +57,24 @@ void ScreenIntro::manageEvent(SDL_Event event) {
void ScreenIntro::draw_menu_options() {
int i = 0;
+ double wcounter = 0;
+ const float x = -0.35;
+ const float sel_margin = 0.05;
+ theme->back_h.dimensions.stretch(m_menu.dimensions.w(), theme->back_h.dimensions.h());
for (MenuOptions::const_iterator it = m_menu.begin(); it != m_menu.end(); ++it, ++i) {
if (static_cast<MenuOptions::const_iterator>(&m_menu.current()) == it) {
- theme->back_h.dimensions.left(-0.4).center(-0.097 + i*0.08);
+ theme->back_h.dimensions.left(x - sel_margin).center(-0.097 + i*0.08);
theme->back_h.draw();
- theme->option_selected.dimensions.left(-0.35).center(-0.1 + i*0.08);
+ theme->option_selected.dimensions.left(x).center(-0.1 + i*0.08);
theme->option_selected.draw(it->getName());
+ wcounter = std::max(wcounter, theme->option_selected.w() + 2 * sel_margin); // Calculate the widest entry
} else {
- theme->option.dimensions.left(-0.35).center(-0.1 + i*0.08);
+ theme->option.dimensions.left(x).center(-0.1 + i*0.08);
theme->option.draw(it->getName());
+ wcounter = std::max(wcounter, theme->option.w() + 2 * sel_margin); // Calculate the widest entry
}
}
+ m_menu.dimensions.stretch(wcounter, 1);
}
void ScreenIntro::draw() {
|
|
From: Tapio V. <aa...@us...> - 2010-09-14 15:22:50
|
Module: performous
Branch: master
Commit: 334320ad3ccfaa30708328a489cb28c6c22c259f
Author: Tapio Vierros <tap...@gm...>
Date: Tue Sep 14 18:11:06 2010 +0300
Allow mic colors to be assigned in any way wanted.
---
game/audio.cc | 13 +++++++------
game/engine.hh | 14 --------------
game/layout_singer.cc | 2 +-
game/libda/portaudio.hpp | 2 +-
game/player.cc | 11 +++++++++--
5 files changed, 18 insertions(+), 24 deletions(-)
diff --git a/game/audio.cc b/game/audio.cc
index 4ffca83..2fd1aff 100644
--- a/game/audio.cc
+++ b/game/audio.cc
@@ -408,7 +408,7 @@ struct Audio::Impl {
boost::ptr_vector<Device> devices;
boost::ptr_vector<Analyzer> analyzers;
bool playback;
- Impl(): playback() {
+ Impl(): init(), playback() {
// Parse audio devices from config
ConfigItem::StringList devs = config["audio/devices"].sl();
for (ConfigItem::StringList::const_iterator it = devs.begin(), end = devs.end(); it != end; ++it) {
@@ -480,11 +480,12 @@ struct Audio::Impl {
if (analyzers.size() >= 4) break; // Too many mics
std::string const& m = params.mics[j];
if (m.empty()) continue; // Input channel not used
- // TODO: allow assignment in any order (not sequentially like the following code does)
- if (m == "blue" && analyzers.size() != 0) continue;
- if (m == "red" && analyzers.size() != 1) continue;
- if (m == "green" && analyzers.size() != 2) continue;
- if (m == "orange" && analyzers.size() != 3) continue;
+ // Check that the color is not already taken
+ bool mic_used = false;
+ for (size_t mi = 0; mi < analyzers.size(); ++mi) {
+ if (analyzers[mi].getId() == m) { mic_used = true; break; }
+ }
+ if (mic_used) continue;
// Add the new analyzer
Analyzer* a = new Analyzer(d.rate, m);
analyzers.push_back(a);
diff --git a/game/engine.hh b/game/engine.hh
index c2dad6d..88f7061 100644
--- a/game/engine.hh
+++ b/game/engine.hh
@@ -1,24 +1,12 @@
#pragma once
#include "audio.hh"
-#include "color.hh"
#include "song.hh"
#include "configuration.hh"
#include "database.hh"
#include <boost/bind.hpp>
#include <boost/thread/thread.hpp>
#include <list>
-
-namespace {
- const Color playerColors[] = {
- Color(0.2, 0.5, 0.7),
- Color(0.8, 0.3, 0.3),
- Color(0.2, 0.9, 0.2),
- Color(1.0, 0.6, 0.0)
- };
- size_t playerColorsSize = sizeof(playerColors) / sizeof(*playerColors);
-}
-
#include <iostream>
/// performous engine
@@ -51,8 +39,6 @@ class Engine {
// Calculate the space required for pitch frames
size_t frames = vocals.endTime / Engine::TIMESTEP;
while (anBegin != anEnd) m_database.cur.push_back(Player(vocals, *anBegin++, frames));
- size_t player = 0;
- for (std::list<Player>::iterator it = m_database.cur.begin(); it != m_database.cur.end(); ++it, ++player) it->m_color = playerColors[player % playerColorsSize];
}
m_thread.reset(new boost::thread(boost::ref(*this)));
}
diff --git a/game/layout_singer.cc b/game/layout_singer.cc
index 02ec959..54c8297 100644
--- a/game/layout_singer.cc
+++ b/game/layout_singer.cc
@@ -36,7 +36,7 @@ void LayoutSinger::drawScore(Position position) {
float r = p->m_color.r;
float g = p->m_color.g;
float b = p->m_color.b;
- glColor4f(r, g, b,act);
+ glColor4f(r, g, b, act);
m_score_text[i%4]->render((boost::format("%04d") % p->getScore()).str());
switch(position) {
case LayoutSinger::BOTTOM: // Fullscreen
diff --git a/game/libda/portaudio.hpp b/game/libda/portaudio.hpp
index 2104d22..c149203 100644
--- a/game/libda/portaudio.hpp
+++ b/game/libda/portaudio.hpp
@@ -73,7 +73,7 @@ namespace portaudio {
AudioDevices ads;
ads.dump();
}
- ~Init() { Pa_Terminate(); }
+ ~Init() { std::cout << "Pa_Terminate..."; std::cout.flush(); Pa_Terminate(); std::cout << "ok" << std::endl; }
};
struct Params {
diff --git a/game/player.cc b/game/player.cc
index ad56fcc..5c1c625 100644
--- a/game/player.cc
+++ b/game/player.cc
@@ -1,14 +1,21 @@
#include "player.hh"
#include "song.hh"
-
#include "engine.hh" // just for Engine::TIMESTEP
+
Player::Player(VocalTrack& vocals, Analyzer& analyzer, size_t frames):
m_vocals(vocals), m_analyzer(analyzer), m_pitch(frames, std::make_pair(getNaN(),
-getInf())), m_pos(), m_score(), m_noteScore(), m_lineScore(), m_maxLineScore(),
m_prevLineScore(-1), m_feedbackFader(0.0, 2.0), m_activitytimer(),
m_scoreIt(m_vocals.notes.begin())
-{ }
+{
+ // Assign colors
+ if (m_analyzer.getId() == "blue") m_color = Color(0.2, 0.5, 0.7);
+ else if (m_analyzer.getId() == "red") m_color = Color(0.8, 0.3, 0.3);
+ else if (m_analyzer.getId() == "green") m_color = Color(0.2, 0.9, 0.2);
+ else if (m_analyzer.getId() == "orange") m_color = Color(1.0, 0.6, 0.0);
+ else m_color = Color(0.5, 0.5, 0.5);
+}
void Player::update() {
if (m_pos == m_pitch.size()) return; // End of song already
|