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: Peque <ms...@us...> - 2009-11-27 22:03:41
|
Module: performous Branch: menu Commit: debfb431f8cf6277eab13047cbc54998d29e4a05 Author: Miguel Sánchez de León Peque <msd...@gm...> Date: Fri Nov 27 23:02:34 2009 +0100 Added changes on SVG images, still trying Intro Menu, not working... --- game/screen_intro.cc | 7 +++ game/theme.cc | 2 +- game/theme.hh | 2 +- themes/default/songs_bg.svg | 61 +++++++++++---------------- themes/default/songs_bg_default.svg | 78 ++++------------------------------- 5 files changed, 43 insertions(+), 107 deletions(-) |
|
From: Peque <ms...@us...> - 2009-11-27 20:28:33
|
Module: performous Branch: menu Commit: 2c8fee2a641993fea7ed9e7b2105cee4ce84de85 Author: Miguel Sánchez de León Peque <msd...@gm...> Date: Fri Nov 27 21:24:50 2009 +0100 testing intro menu, not working yet... --- docs/Compiling.txt | 2 +- game/screen_intro.cc | 18 +- game/screen_intro.hh | 5 +- game/theme.cc | 7 + game/theme.hh | 12 + themes/default/prueba_configure.svg | 499 +++++++++++++++++++++++++++++++++++ themes/default/prueba_intro.svg | 416 +++++++++++++++++++++++++++++ themes/default/prueba_practice.svg | 499 +++++++++++++++++++++++++++++++++++ themes/default/prueba_quit.svg | 499 +++++++++++++++++++++++++++++++++++ themes/default/prueba_sing.svg | 499 +++++++++++++++++++++++++++++++++++ 10 files changed, 2450 insertions(+), 6 deletions(-) |
|
From: Peque <ms...@us...> - 2009-11-27 20:28:32
|
Module: performous
Branch: menu
Commit: 5c57eb8ccf571551f5c72a6a29ec9d1eb79703f4
Author: Miguel Sánchez de León Peque <msd...@gm...>
Date: Wed Nov 25 17:55:56 2009 +0100
Revert "Little change for testing GIT"
This reverts commit f0115ff02ab2faae17ecc39145d9c2a58861f0e5.
---
game/screen_intro.cc | 5 -----
1 files changed, 0 insertions(+), 5 deletions(-)
diff --git a/game/screen_intro.cc b/game/screen_intro.cc
index e8a9acc..c48e9b6 100644
--- a/game/screen_intro.cc
+++ b/game/screen_intro.cc
@@ -29,11 +29,6 @@ void ScreenIntro::manageEvent(SDL_Event event) {
else if (key == SDLK_s) sm->activateScreen("Songs");
else if (key == SDLK_c) sm->activateScreen("Configuration");
else if (key == SDLK_p) sm->activateScreen("Practice");
-
- else if (key == SDLK_LEFT) {
- sm->activateScreen("Practice");
- }
-
else if (key == SDLK_SPACE || key == SDLK_PAUSE) m_audio.togglePause();
} else if (event.type == SDL_JOYBUTTONDOWN) {
int button = event.jbutton.button;
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-27 14:31:46
|
Module: performous
Branch: master
Commit: d7a662fd6f74836c84b4548a1a0c5bdfb8feb74f
Author: Lasse Karkkainen <tro...@tr...>
Date: Fri Nov 27 16:31:32 2009 +0200
Use static linkage on libs to avoid installing them, remove relative RPATHs
---
game/CMakeLists.txt | 4 ++--
libs/libda/src/CMakeLists.txt | 2 +-
libs/plugin++/CMakeLists.txt | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/game/CMakeLists.txt b/game/CMakeLists.txt
index 951e708..1e9e60e 100644
--- a/game/CMakeLists.txt
+++ b/game/CMakeLists.txt
@@ -48,9 +48,9 @@ target_link_libraries(performous ${LIBS})
# Store library paths in executable
if(APPLE)
- set_target_properties(performous PROPERTIES INSTALL_RPATH_USE_LINK_PATH TRUE INSTALL_RPATH "@loader_path/../lib${LIB_SUFFIX}:@loader_path/../../lib${LIB_SUFFIX}")
+ set_target_properties(performous PROPERTIES INSTALL_RPATH_USE_LINK_PATH TRUE)
else()
- set_target_properties(performous PROPERTIES INSTALL_RPATH_USE_LINK_PATH TRUE INSTALL_RPATH "\$ORIGIN/../lib${LIB_SUFFIX}:\$ORIGIN/../../lib${LIB_SUFFIX}")
+ set_target_properties(performous PROPERTIES INSTALL_RPATH_USE_LINK_PATH TRUE)
endif()
# Generate config.hh
diff --git a/libs/libda/src/CMakeLists.txt b/libs/libda/src/CMakeLists.txt
index a767b7d..f98f903 100644
--- a/libs/libda/src/CMakeLists.txt
+++ b/libs/libda/src/CMakeLists.txt
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 2.6)
-add_library(da SHARED audio.cpp)
+add_library(da STATIC audio.cpp)
target_link_libraries(da ${Boost_LIBRARIES} ${Plugin++_LIBRARIES})
set_target_properties(da PROPERTIES
diff --git a/libs/plugin++/CMakeLists.txt b/libs/plugin++/CMakeLists.txt
index b8e8b16..d311340 100644
--- a/libs/plugin++/CMakeLists.txt
+++ b/libs/plugin++/CMakeLists.txt
@@ -28,7 +28,7 @@ if(CMAKE_COMPILER_IS_GNUCXX)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++98 -Wall -Wextra")
endif()
-add_library(plugin++ SHARED src/dll.cc src/execname.cc src/loader.cc)
+add_library(plugin++ STATIC src/dll.cc src/execname.cc src/loader.cc)
find_package(DL REQUIRED)
include_directories(${DL_INCLUDE_DIRS})
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-27 14:20:19
|
Module: performous
Branch: master
Commit: c32b0e39924263b0c7727a269d7b7a0079be51e6
Author: Lasse Karkkainen <tro...@tr...>
Date: Fri Nov 27 16:19:53 2009 +0200
Made libs part of performous build again
---
CMakeLists.txt | 3 ++-
docs/Compiling.txt | 16 +++-------------
game/CMakeLists.txt | 16 ++++++++++++----
libs/CMakeLists.txt | 8 ++++++++
libs/libda/CMakeLists.txt | 30 +++++++++++++++++-------------
libs/libda/src/CMakeLists.txt | 4 +++-
libs/plugin++/CMakeLists.txt | 16 +++++++++-------
7 files changed, 54 insertions(+), 39 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 35002bb..6437a8e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -8,7 +8,7 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR)
message(FATAL_ERROR "In-source builds are not permitted. Make a separate folder for building:\nmkdir build; cd build; cmake ..\nBefore that, remove the files already created:\nrm -rf CMakeCache.txt CMakeFiles")
endif(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR)
-include("${CMAKE_SOURCE_DIR}/cmake/performous-packaging.cmake")
+include(cmake/performous-packaging.cmake)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
@@ -32,6 +32,7 @@ mark_as_advanced(SHARE_INSTALL)
include_directories(libs/plugin++/include)
include_directories(libs/libda/include)
+add_subdirectory(libs)
add_subdirectory(themes)
add_subdirectory(data)
add_subdirectory(game)
diff --git a/docs/Compiling.txt b/docs/Compiling.txt
index 4327ad9..ef02a4b 100644
--- a/docs/Compiling.txt
+++ b/docs/Compiling.txt
@@ -2,21 +2,11 @@ To install from git:
# Checkout the git
git clone git://performous.git.sourceforge.net/gitroot/performous/performous
- # Create separate build folder under trunk to avoid polluting the source three
+ # Create separate build folder under trunk to avoid polluting the source tree
mkdir performous/build
cd performous/build
- # Compile and install libplugin++ (our C++ plugin/DLL library)
- cmake ../libs/plugin++/
- make
- sudo make install
- rm -rf *
- # Compile and install libda (our audio library)
- cmake ../libs/libda/
- make
- sudo make install
- rm -rf *
- # Compile the game itself
- cmake ..
+ # Compile the game and its support libraries
+ cmake ../
make
sudo make install
# Run the game
diff --git a/game/CMakeLists.txt b/game/CMakeLists.txt
index 66b61da..951e708 100644
--- a/game/CMakeLists.txt
+++ b/game/CMakeLists.txt
@@ -9,20 +9,28 @@ set(SOURCES ${SOURCE_FILES} ${HEADER_FILES})
find_package(Boost 1.36 REQUIRED COMPONENTS thread date_time program_options regex filesystem)
include_directories(${Boost_INCLUDE_DIRS})
-set(LIBS ${LIBS} ${Boost_LIBRARIES})
+list(APPEND LIBS ${Boost_LIBRARIES})
+
+# Libraries are part of Performous build process (for now)
+set(SLAVE_LIBS TRUE)
+if(SLAVE_LIBS)
+ list(APPEND LIBS plugin++ da)
+else()
+ set(OUR_LIBS Plugin++ LibDA)
+endif()
# Find all the libs that don't require extra parameters
-foreach(lib Plugin++ LibDA SDL PangoCairo LibRSVG LibXML++ Magick++ GLEW AVFormat SWScale OpenGL)
+foreach(lib ${OUR_LIBS} SDL PangoCairo LibRSVG LibXML++ Magick++ GLEW AVFormat SWScale OpenGL)
find_package(${lib} REQUIRED)
include_directories(${${lib}_INCLUDE_DIRS})
- set(LIBS ${LIBS} ${${lib}_LIBRARIES})
+ list(APPEND LIBS ${${lib}_LIBRARIES})
add_definitions(${${lib}_DEFINITIONS})
endforeach(lib)
find_package(PortMidi)
if(PortMidi_FOUND)
include_directories(PortMidi_INCLUDE_DIRS)
- set(LIBS ${LIBS} ${PortMidi_LIBRARIES})
+ list(APPEND LIBS ${PortMidi_LIBRARIES})
add_definitions("-DHAVE_PORTMIDI")
endif(PortMidi_FOUND)
diff --git a/libs/CMakeLists.txt b/libs/CMakeLists.txt
new file mode 100644
index 0000000..679f8c3
--- /dev/null
+++ b/libs/CMakeLists.txt
@@ -0,0 +1,8 @@
+cmake_minimum_required(VERSION 2.6)
+
+# Make plugin++ and libda not install themselves on the system
+set(SLAVE_LIB TRUE)
+
+add_subdirectory(plugin++)
+add_subdirectory(libda)
+
diff --git a/libs/libda/CMakeLists.txt b/libs/libda/CMakeLists.txt
index f151649..5c8f5d4 100644
--- a/libs/libda/CMakeLists.txt
+++ b/libs/libda/CMakeLists.txt
@@ -11,8 +11,6 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR)
message(FATAL_ERROR "In-source builds are not permitted. Make a separate folder for building:\nmkdir build; cd build; cmake ..\nBefore that, remove the files already created:\nrm -rf CMakeCache.txt CMakeFiles")
endif()
-include("${CMAKE_SOURCE_DIR}/cmake/libda-packaging.cmake")
-
# Add a sensible build type default and warning because empty means no optimization and no debug info.
if(NOT CMAKE_BUILD_TYPE)
message("WARNING: CMAKE_BUILD_TYPE is not defined!\n Defaulting to CMAKE_BUILD_TYPE=Release. Use ccmake to set a proper value.")
@@ -27,13 +25,17 @@ set(LibDA_PLUGIN_DIR "lib${LIB_SUFFIX}/libda")
include_directories(include)
-# Store version data in config.h
-set(CONFIG_H ${CMAKE_CURRENT_BINARY_DIR}/config.h)
-configure_file(cmake/config.h.in ${CONFIG_H} ESCAPE_QUOTES @ONLY)
-
-# Install include files
-file(GLOB HEADER_FILES "include/libda/*")
-install(FILES ${HEADER_FILES} ${CONFIG_H} DESTINATION include/libda)
+if(NOT SLAVE_LIB)
+ include(cmake/libda-packaging.cmake)
+ # Store version data in config.h
+ set(CONFIG_H ${CMAKE_CURRENT_BINARY_DIR}/config.h)
+ configure_file(cmake/config.h.in ${CONFIG_H} ESCAPE_QUOTES @ONLY)
+ # Install include files
+ file(GLOB HEADER_FILES "include/libda/*")
+ install(FILES ${HEADER_FILES} ${CONFIG_H} DESTINATION include/libda)
+ # Generate CMake scripts for finding the library
+ add_subdirectory(cmake)
+endif()
if(CMAKE_COMPILER_IS_GNUCXX)
message(STATUS "GCC detected, adding compile flags")
@@ -48,11 +50,13 @@ set(Boost_USE_MULTITHREAD ON)
find_package(Boost 1.36 REQUIRED COMPONENTS thread date_time)
include_directories(${Boost_INCLUDE_DIRS})
-find_package(Plugin++ REQUIRED)
-message(plugin++ ${Plugin++_INCLUDE_DIRS})
-include_directories(${Plugin++_INCLUDE_DIRS})
+if(SLAVE_LIB)
+ set(Plugin++_LIBRARIES da)
+else()
+ find_package(Plugin++ REQUIRED)
+ include_directories(${Plugin++_INCLUDE_DIRS})
+endif()
add_subdirectory(src)
add_subdirectory(plugins)
-add_subdirectory(cmake)
diff --git a/libs/libda/src/CMakeLists.txt b/libs/libda/src/CMakeLists.txt
index ba22301..a767b7d 100644
--- a/libs/libda/src/CMakeLists.txt
+++ b/libs/libda/src/CMakeLists.txt
@@ -11,5 +11,7 @@ set_target_properties(da PROPERTIES
INSTALL_RPATH_USE_LINK_PATH TRUE
)
-install(TARGETS da EXPORT LibDA DESTINATION lib${LIB_SUFFIX})
+if(NOT SLAVE_LIB)
+ install(TARGETS da EXPORT LibDA DESTINATION lib${LIB_SUFFIX})
+endif()
diff --git a/libs/plugin++/CMakeLists.txt b/libs/plugin++/CMakeLists.txt
index 4d2e22c..b8e8b16 100644
--- a/libs/plugin++/CMakeLists.txt
+++ b/libs/plugin++/CMakeLists.txt
@@ -10,8 +10,6 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR)
message(FATAL_ERROR "In-source builds are not permitted. Make a separate folder for building:\nmkdir build; cd build; cmake ..\nBefore that, remove the files already created:\nrm -rf CMakeCache.txt CMakeFiles")
endif()
-include("${CMAKE_SOURCE_DIR}/cmake/plugin++-packaging.cmake")
-
# Add a sensible build type default and warning because empty means no optimization and no debug info.
if(NOT CMAKE_BUILD_TYPE)
message("WARNING: CMAKE_BUILD_TYPE is not defined!\n Defaulting to CMAKE_BUILD_TYPE=Release. Use ccmake to set a proper value.")
@@ -50,11 +48,15 @@ set_target_properties(plugin++ PROPERTIES
INSTALL_RPATH_USE_LINK_PATH TRUE
)
-install(TARGETS plugin++ EXPORT Plugin++ DESTINATION lib${LIB_SUFFIX})
+if(NOT SLAVE_LIB)
+ include(cmake/plugin++-packaging.cmake)
+
+ install(TARGETS plugin++ EXPORT Plugin++ DESTINATION lib${LIB_SUFFIX})
-FILE(GLOB HEADER_FILES "include/plugin++/*")
-install(FILES ${HEADER_FILES} DESTINATION include/plugin++)
+ FILE(GLOB HEADER_FILES "include/plugin++/*")
+ install(FILES ${HEADER_FILES} DESTINATION include/plugin++)
-# Install/generate CMake files for finding Plugin++
-add_subdirectory(cmake)
+ # Install/generate CMake files for finding Plugin++
+ add_subdirectory(cmake)
+endif()
|
|
From: Tapio V. <aa...@us...> - 2009-11-27 13:27:43
|
Module: performous
Branch: dance
Commit: 0eddb91770805b02470dbdc3a1686814573be229
Author: Tapio Vierros <tap...@gm...>
Date: Fri Nov 27 15:24:32 2009 +0200
Now cursor arrows cannot be held down (graphicswise).
StepMania does the same.
---
game/dancegraph.cc | 11 +++++++----
game/dancegraph.hh | 3 ++-
2 files changed, 9 insertions(+), 5 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index e082eb8..84587cc 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -57,7 +57,8 @@ DanceGraph::DanceGraph(Audio& audio, Song const& song):
{
m_arrow.dimensions.middle().center();
- for(size_t i = 0; i < 4; i++) m_pressed[i] = AnimValue(0.0, 8.0);
+ for(size_t i = 0; i < 4; i++) m_pressed[i] = false;
+ for(size_t i = 0; i < 4; i++) m_pressed_anim[i] = AnimValue(0.0, 4.0);
DanceTracks::const_iterator it = m_song.danceTracks.find(m_gamingMode);
if(it == m_song.danceTracks.end())
@@ -106,11 +107,13 @@ void DanceGraph::engine() {
}
}
if (ev.type == input::Event::RELEASE) {
- m_pressed[ev.button].setTarget(0.0, false);
+ m_pressed[ev.button] = false;
}
else if (ev.type == input::Event::PRESS) {
+ m_pressed[ev.button] = true;
dance(time, ev);
- m_pressed[ev.button].setTarget(1.0, true);
+ m_pressed_anim[ev.button].setValue(1.0);
+ m_pressed_anim[ev.button].setTarget(0.0);
}
}
@@ -206,7 +209,7 @@ void DanceGraph::draw(double time) {
// Arrows on cursor
for (int arrow_i = 0; arrow_i < 4; ++arrow_i) {
float x = -1.5f + arrow_i;
- float l = m_pressed[arrow_i].get();
+ float l = m_pressed_anim[arrow_i].get();
float s = (5.0 - l) / 5.0;
glutil::Color c = color(arrow_i);
c.r += l; c.g += l; c.b +=l;
diff --git a/game/dancegraph.hh b/game/dancegraph.hh
index 6b0f430..4805934 100644
--- a/game/dancegraph.hh
+++ b/game/dancegraph.hh
@@ -76,7 +76,8 @@ class DanceGraph {
};
typedef std::vector<Event> Events;
Events m_events;
- AnimValue m_pressed[4];
+ bool m_pressed[4];
+ AnimValue m_pressed_anim[4];
int m_dead;
SvgTxtTheme m_text;
AnimValue m_correctness;
|
|
From: Tapio V. <aa...@us...> - 2009-11-27 13:27:41
|
Module: performous
Branch: dance
Commit: e72effae0a540561b669962047610b5a81596ed8
Author: Tapio Vierros <tap...@gm...>
Date: Fri Nov 27 15:09:10 2009 +0200
Different effect for hitting mines.
---
game/dancegraph.cc | 20 +++++++++++++++-----
1 files changed, 15 insertions(+), 5 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index 3dd6ddd..e082eb8 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -242,7 +242,10 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
float yEnd = time2y(tEnd);
glutil::Color c = color(arrow_i);
- if (note.isHit && std::abs(tEnd) < maxTolerance) note.hitAnim.setTarget(1.0, false);
+ if (note.isHit && std::abs(tEnd) < maxTolerance) {
+ if (mine) note.hitAnim.setRate(1.0);
+ note.hitAnim.setTarget(1.0, false);
+ }
double glow = note.hitAnim.get();
if (tEnd - tBeg > 0.1) {
@@ -270,9 +273,16 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
drawArrow(arrow_i, x, yBeg, s);
} else {
// Draw short note
- s = arrowScale + glow;
- glColor4fv(colorGlow(c,glow));
- if (mine) drawMine(x, yBeg, int(time*360) % 360, s);
- else drawArrow(arrow_i, x, yBeg, s);
+ if (mine) {
+ c.a = 1.0 - glow; glColor4fv(c);
+ s += glow * 0.5;
+ float rot = int(time*360 * (note.isHit ? 2.0 : 1.0) ) % 360;
+ if (note.isHit) yBeg = time2y(0.0);
+ drawMine(x, yBeg, rot, s);
+ } else {
+ s = arrowScale + glow;
+ glColor4fv(colorGlow(c, glow));
+ drawArrow(arrow_i, x, yBeg, s);
+ }
}
}
|
|
From: Tapio V. <aa...@us...> - 2009-11-27 13:27:40
|
Module: performous
Branch: dance
Commit: d76b50a63fce3a7aabdd42974cbf85d87ed22782
Author: Tapio Vierros <tap...@gm...>
Date: Fri Nov 27 14:37:35 2009 +0200
Animation for completing hold note.
---
game/dancegraph.cc | 27 ++++++++++++++++++---------
1 files changed, 18 insertions(+), 9 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index 8904152..3dd6ddd 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -114,7 +114,7 @@ void DanceGraph::engine() {
}
}
-
+
}
@@ -126,7 +126,6 @@ void DanceGraph::dance(double time, input::Event const& ev) {
double p = points(it->note.begin - time);
it->score = p;
m_score += p;
- it->hitAnim.setTarget(1.0, false);
}
}
}
@@ -141,6 +140,15 @@ namespace {
glTexCoord2f(0.0f, ty); glVertex2f(x - holdWidth, y);
glTexCoord2f(1.0f, ty); glVertex2f(x + holdWidth, y);
}
+
+ glutil::Color& colorGlow(glutil::Color& c, double glow) {
+ //c.a = std::sqrt(1.0 - glow);
+ c.a = 1.0 - glow;
+ c.r += glow *.5;
+ c.g += glow *.5;
+ c.b += glow *.5;
+ return c;
+ }
}
glutil::Color const& DanceGraph::color(int arrow_i) const {
@@ -234,6 +242,9 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
float yEnd = time2y(tEnd);
glutil::Color c = color(arrow_i);
+ if (note.isHit && std::abs(tEnd) < maxTolerance) note.hitAnim.setTarget(1.0, false);
+ double glow = note.hitAnim.get();
+
if (tEnd - tBeg > 0.1) {
// Draw holds
glColor4fv(c);
@@ -252,17 +263,15 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
vertexPair(x, yBeg, 0.0f);
}
// Draw begin
+ if (note.isHit && tEnd < 0.1) {
+ glColor4fv(colorGlow(c,glow));
+ s = arrowScale + glow;
+ }
drawArrow(arrow_i, x, yBeg, s);
} else {
// Draw short note
- double glow = note.hitAnim.get();
- //c.a = std::sqrt(1.0 - glow);
- c.a = 1.0 - glow;
- c.r += glow *.5;
- c.g += glow *.5;
- c.b += glow *.5;
s = arrowScale + glow;
- glColor4fv(c);
+ glColor4fv(colorGlow(c,glow));
if (mine) drawMine(x, yBeg, int(time*360) % 360, s);
else drawArrow(arrow_i, x, yBeg, s);
}
|
|
From: Tapio V. <aa...@us...> - 2009-11-27 13:27:37
|
Module: performous
Branch: dance
Commit: b65ae226f6b4d6b6eada6e1a30acec57bd55525c
Author: Tapio Vierros <tap...@gm...>
Date: Fri Nov 27 13:41:40 2009 +0200
Graphical handling of hold note hitting ending prematurely.
(Requires DanceNote's releaseTime to be set correctly.)
---
game/dancegraph.cc | 19 ++++++++++---------
game/dancegraph.hh | 5 +++--
2 files changed, 13 insertions(+), 11 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index 2596fe7..8904152 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -234,22 +234,18 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
float yEnd = time2y(tEnd);
glutil::Color c = color(arrow_i);
- double glow = note.hitAnim.get();
- //c.a = std::sqrt(1.0 - glow);
- c.r += glow *.5;
- c.g += glow *.5;
- c.b += glow *.5;
-
if (tEnd - tBeg > 0.1) {
// Draw holds
glColor4fv(c);
- if (note.isHit) {
- // TODO: What if hold is ended prematurely?
+ if (note.isHit && note.releaseTime <= 0) {
yBeg = std::max(time2y(0.0), yBeg);
yEnd = std::max(time2y(0.0), yEnd);
glColor3f(1.0f, 1.0f, 1.0f);
+ // Hack to test hold releasing
+ //if (time > note.note.begin + 1) note.releaseTime = time;
}
- {
+ if (note.releaseTime > 0) yBeg = time2y(note.releaseTime - time);
+ { // Scope block for Begin and UseTexture
UseTexture tblock(m_arrow_hold);
glutil::Begin block(GL_TRIANGLE_STRIP);
vertexPair(x, yEnd, 1.0f);
@@ -259,7 +255,12 @@ void DanceGraph::drawNote(DanceNote& note, double time) {
drawArrow(arrow_i, x, yBeg, s);
} else {
// Draw short note
+ double glow = note.hitAnim.get();
+ //c.a = std::sqrt(1.0 - glow);
c.a = 1.0 - glow;
+ c.r += glow *.5;
+ c.g += glow *.5;
+ c.b += glow *.5;
s = arrowScale + glow;
glColor4fv(c);
if (mine) drawMine(x, yBeg, int(time*360) % 360, s);
diff --git a/game/dancegraph.hh b/game/dancegraph.hh
index 9e064fb..6b0f430 100644
--- a/game/dancegraph.hh
+++ b/game/dancegraph.hh
@@ -14,9 +14,10 @@ class Song;
struct DanceNote {
DanceNote(Note note) :
- note(note), hitAnim(0.0, 5.0), score(0), isHit(false) {}
+ note(note), hitAnim(0.0, 5.0), releaseTime(0), score(0), isHit(false) {}
Note note;
- AnimValue hitAnim;
+ AnimValue hitAnim; /// for animating hits
+ double releaseTime; /// tells when a hold was ended
int score;
bool isHit;
};
|
|
From: Tapio V. <aa...@us...> - 2009-11-27 13:27:36
|
Module: performous
Branch: dance
Commit: 76ffb6a8825fb3041aa4bd16c6f47ec53bfb4ec6
Author: Tapio Vierros <tap...@gm...>
Date: Fri Nov 27 13:09:22 2009 +0200
Cleaning and code re-arrangement.
---
game/dancegraph.cc | 122 ++++++++++++++++++++++-----------------------------
game/dancegraph.hh | 5 +-
2 files changed, 55 insertions(+), 72 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index 094343c..2596fe7 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -132,17 +132,6 @@ void DanceGraph::dance(double time, input::Event const& ev) {
}
-glutil::Color const& DanceGraph::color(int arrow_i) const {
- static glutil::Color arrowColors[4] = {
- glutil::Color(0.0f, 0.9f, 0.0f),
- glutil::Color(0.9f, 0.0f, 0.0f),
- glutil::Color(0.9f, 0.9f, 0.0f),
- glutil::Color(0.0f, 0.0f, 0.9f),
- };
- if (arrow_i < 0 || arrow_i > 3) throw std::logic_error("Invalid arrow number in DanceGraph::getColor");
- return arrowColors[arrow_i];
-}
-
namespace {
const float arrowScale = 0.6f;
const float arrowRotations[4] = { 270.0f, 180.0f, 0.0f, 90.0f };
@@ -154,6 +143,17 @@ namespace {
}
}
+glutil::Color const& DanceGraph::color(int arrow_i) const {
+ static glutil::Color arrowColors[4] = {
+ glutil::Color(0.0f, 0.9f, 0.0f),
+ glutil::Color(0.9f, 0.0f, 0.0f),
+ glutil::Color(0.9f, 0.9f, 0.0f),
+ glutil::Color(0.0f, 0.0f, 0.9f),
+ };
+ if (arrow_i < 0 || arrow_i > 3) throw std::logic_error("Invalid arrow index in DanceGraph::getColor");
+ return arrowColors[arrow_i];
+}
+
void DanceGraph::drawArrow(int arrow_i, float x, float y, float scale) {
glTranslatef(x, y, 0.0f);
glRotatef(arrowRotations[arrow_i], 0.0f, 0.0f, 1.0f);
@@ -189,18 +189,13 @@ void DanceGraph::draw(double time) {
m_text.draw(boost::lexical_cast<std::string>(unsigned(m_streak)) + "/"
+ boost::lexical_cast<std::string>(unsigned(m_longestStreak)));
}
-//std::cout << "m" << dimensions.x1() << " " << dimensions.x2() << std::endl;
-//std::cout << dimensions.y1() << " " << dimensions.y2() << std::endl;
glutil::PushMatrixMode pmm(GL_PROJECTION);
glTranslatef(frac * 2.0 * offsetX, 0.0f, 0.0f);
glutil::PushMatrixMode pmb(GL_MODELVIEW);
glTranslatef((1.0 - frac) * offsetX, dimensions.y1(), 0.0f);
- //glTranslatef((1.0 - frac) * offsetX, 0.0f, 0.0f);
{ float s = dimensions.w() / 5.0f; glScalef(s, s, s); }
// Arrows on cursor
- // TODO: suitable effect for pressing the arrows?
- // TODO: effect possibilities: zooming, whitening, external glow
for (int arrow_i = 0; arrow_i < 4; ++arrow_i) {
float x = -1.5f + arrow_i;
float l = m_pressed[arrow_i].get();
@@ -213,54 +208,9 @@ void DanceGraph::draw(double time) {
// Draw the notes
for (DanceNotes::iterator it = m_notes.begin(); it != m_notes.end(); ++it) {
- float tBeg = it->note.begin - time;
- float tEnd = it->note.end - time;
-
- // TODO: Remove me (temporary hack to test hold note drawing)
- //tEnd += 0.6;
-
- if (tEnd < past) continue;
- if (tBeg > future) break;
-
- int arrow_i = it->note.note;
- bool mine = it->note.type == Note::MINE;
- float x = -1.5f + arrow_i;
- float s = arrowScale;
- float yBeg = time2y(tBeg);
- float yEnd = time2y(tEnd);
- glutil::Color c = color(arrow_i);
-
- double glow = it->hitAnim.get();
- //c.a = std::sqrt(1.0 - glow);
- c.r += glow *.5;
- c.g += glow *.5;
- c.b += glow *.5;
-
- if (tEnd - tBeg > 0.1) {
- // Draw holds
- glColor4fv(c);
- if (it->isHit) {
- // TODO: What if hold is ended prematurely?
- yBeg = std::max(time2y(0.0), yBeg);
- yEnd = std::max(time2y(0.0), yEnd);
- glColor3f(1.0f, 1.0f, 1.0f);
- }
- {
- UseTexture tblock(m_arrow_hold);
- glutil::Begin block(GL_TRIANGLE_STRIP);
- vertexPair(x, yEnd, 1.0f);
- vertexPair(x, yBeg, 0.0f);
- }
- // Draw begin
- drawArrow(arrow_i, x, yBeg, s);
- } else {
- // Draw short note
- c.a = 1.0 - glow;
- s = arrowScale + glow;
- glColor4fv(c);
- if (mine) drawMine(x, yBeg, int(time*360) % 360, s);
- else drawArrow(arrow_i, x, yBeg, s);
- }
+ if (it->note.end - time < past) continue;
+ if (it->note.begin - time > future) break;
+ drawNote(*it, time);
}
// To test arrow coordinate positioning
@@ -272,13 +222,47 @@ void DanceGraph::draw(double time) {
glColor3f(1.0f, 1.0f, 1.0f);
}
-// TODO: See if this is needed at all
/// Draws a single note (or hold)
-void DanceGraph::drawNote(int arrow_i, glutil::Color c, float tBeg, float tEnd) {
+void DanceGraph::drawNote(DanceNote& note, double time) {
+ float tBeg = note.note.begin - time;
+ float tEnd = note.note.end - time;
+ int arrow_i = note.note.note;
+ bool mine = note.note.type == Note::MINE;
float x = -1.5f + arrow_i;
+ float s = arrowScale;
float yBeg = time2y(tBeg);
float yEnd = time2y(tEnd);
- //c.a = time2a(tBeg);
- glColor4fv(c);
- drawArrow(arrow_i, x, yBeg, 0.6);
+ glutil::Color c = color(arrow_i);
+
+ double glow = note.hitAnim.get();
+ //c.a = std::sqrt(1.0 - glow);
+ c.r += glow *.5;
+ c.g += glow *.5;
+ c.b += glow *.5;
+
+ if (tEnd - tBeg > 0.1) {
+ // Draw holds
+ glColor4fv(c);
+ if (note.isHit) {
+ // TODO: What if hold is ended prematurely?
+ yBeg = std::max(time2y(0.0), yBeg);
+ yEnd = std::max(time2y(0.0), yEnd);
+ glColor3f(1.0f, 1.0f, 1.0f);
+ }
+ {
+ UseTexture tblock(m_arrow_hold);
+ glutil::Begin block(GL_TRIANGLE_STRIP);
+ vertexPair(x, yEnd, 1.0f);
+ vertexPair(x, yBeg, 0.0f);
+ }
+ // Draw begin
+ drawArrow(arrow_i, x, yBeg, s);
+ } else {
+ // Draw short note
+ c.a = 1.0 - glow;
+ s = arrowScale + glow;
+ glColor4fv(c);
+ if (mine) drawMine(x, yBeg, int(time*360) % 360, s);
+ else drawArrow(arrow_i, x, yBeg, s);
+ }
}
diff --git a/game/dancegraph.hh b/game/dancegraph.hh
index f26a87e..9e064fb 100644
--- a/game/dancegraph.hh
+++ b/game/dancegraph.hh
@@ -1,7 +1,6 @@
#pragma once
#include <vector>
-
#include <boost/ptr_container/ptr_map.hpp>
#include "animvalue.hh"
#include "song.hh"
@@ -50,9 +49,9 @@ class DanceGraph {
void difficultyDelta(int delta);
void difficulty(DanceDifficulty level);
DanceDifficulty m_level;
- void dance(double time, input::Event const& ev);
- void drawNote(int arrow_i, glutil::Color, float tBeg, float tEnd);
glutil::Color const& color(int arrow_i) const;
+ void dance(double time, input::Event const& ev);
+ void drawNote(DanceNote& note, double time);
void drawArrow(int arrow_i, float x, float y, float scale = 1.0);
void drawMine(float x, float y, float rot = 0.0, float scale = 1.0);
Audio& m_audio;
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-27 03:44:02
|
Module: performous
Branch: master
Commit: bc84486eeedcc8af3579ec7426521f4df871da94
Author: Lasse Karkkainen <tro...@tr...>
Date: Fri Nov 27 05:43:37 2009 +0200
Minor plugin++ cleanup
---
libs/plugin++/include/plugin++/execname.hpp | 4 ++++
libs/plugin++/include/plugin++/loader.hpp | 1 +
libs/plugin++/include/plugin++/plugin.hpp | 11 +----------
3 files changed, 6 insertions(+), 10 deletions(-)
diff --git a/libs/plugin++/include/plugin++/execname.hpp b/libs/plugin++/include/plugin++/execname.hpp
index 4c53315..e999cb9 100644
--- a/libs/plugin++/include/plugin++/execname.hpp
+++ b/libs/plugin++/include/plugin++/execname.hpp
@@ -1,4 +1,7 @@
#pragma once
+#ifndef EXECNAME_HPP_INCLUDED
+#define EXECNAME_HPP_INCLUDED
+
#include <boost/filesystem.hpp>
namespace plugin {
@@ -7,3 +10,4 @@ namespace plugin {
boost::filesystem::path execname();
}
+#endif
diff --git a/libs/plugin++/include/plugin++/loader.hpp b/libs/plugin++/include/plugin++/loader.hpp
index 5c551a9..4463cf6 100644
--- a/libs/plugin++/include/plugin++/loader.hpp
+++ b/libs/plugin++/include/plugin++/loader.hpp
@@ -1,3 +1,4 @@
+#pragma once
#ifndef LOADER_HPP_INCLUDED
#define LOADER_HPP_INCLUDED
diff --git a/libs/plugin++/include/plugin++/plugin.hpp b/libs/plugin++/include/plugin++/plugin.hpp
index b1fa2f0..3222e79 100644
--- a/libs/plugin++/include/plugin++/plugin.hpp
+++ b/libs/plugin++/include/plugin++/plugin.hpp
@@ -1,13 +1,4 @@
-// plugin.hpp - C++ plugin framework
-
-// Copyright Lasse Karkkainen 2007-2008
-
-// Use, modification, and distribution is subject to the Boost Software
-// License, Version 1.0 or later. (See accompanying file LICENSE_1_0.txt or
-// copy at http://www.boost.org/LICENSE_1_0.txt)
-
-// See library home page at http://www.boost.org/libs/plugin
-
+#pragma once
#ifndef PLUGIN_HPP_INCLUDED
#define PLUGIN_HPP_INCLUDED
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-26 15:58:56
|
Module: performous
Branch: master
Commit: 3af6a7970126fecd8ee41d720fe35109fc4d8712
Author: Lasse Karkkainen <tro...@tr...>
Date: Thu Nov 26 17:58:43 2009 +0200
Omit libs dir from source package
---
cmake/performous-packaging.cmake | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/cmake/performous-packaging.cmake b/cmake/performous-packaging.cmake
index d987ed5..8fe3e9f 100644
--- a/cmake/performous-packaging.cmake
+++ b/cmake/performous-packaging.cmake
@@ -6,6 +6,7 @@ set(CPACK_SOURCE_IGNORE_FILES
"/.cvsignore"
"/.gitignore"
"/songs/"
+ "/libs/"
"/build/"
"/.svn/"
"/.git/"
|
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-26 14:54:40
|
Module: performous Branch: master Commit: 217deed21757a41d185176e44998aea42d570876 Author: Lasse Karkkainen <tro...@tr...> Date: Thu Nov 26 16:54:23 2009 +0200 Merge branch 'master' of ssh://tronic@git.performous.org/gitroot/performous/performous --- |
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-26 14:54:37
|
Module: performous
Branch: master
Commit: 8b318c7c2e81cd83f626ddf2796f3e2f96f48932
Author: Lasse Karkkainen <tro...@tr...>
Date: Thu Nov 26 16:31:36 2009 +0200
LibDA header docs and config.h with version macros
---
libs/libda/CMakeLists.txt | 9 +++++++--
libs/libda/cmake/config.h.in | 9 +++++++++
libs/libda/include/libda/audio.hpp | 7 +++----
libs/libda/include/libda/audio_dev.hpp | 7 +++++++
libs/libda/include/libda/mixer.hpp | 5 ++++-
5 files changed, 30 insertions(+), 7 deletions(-)
diff --git a/libs/libda/CMakeLists.txt b/libs/libda/CMakeLists.txt
index c856b95..763e8d7 100644
--- a/libs/libda/CMakeLists.txt
+++ b/libs/libda/CMakeLists.txt
@@ -25,8 +25,13 @@ set(LibDA_PLUGIN_DIR "lib${LIB_SUFFIX}/libda")
include_directories(include)
-FILE(GLOB HEADER_FILES "include/libda/*")
-install(FILES ${HEADER_FILES} DESTINATION include/libda)
+# Store version data in config.h
+set(CONFIG_H ${CMAKE_CURRENT_BINARY_DIR}/config.h)
+configure_file(cmake/config.h.in ${CONFIG_H} ESCAPE_QUOTES @ONLY)
+
+# Install include files
+file(GLOB HEADER_FILES "include/libda/*")
+install(FILES ${HEADER_FILES} ${CONFIG_H} DESTINATION include/libda)
if(CMAKE_COMPILER_IS_GNUCXX)
message(STATUS "GCC detected, adding compile flags")
diff --git a/libs/libda/cmake/config.h.in b/libs/libda/cmake/config.h.in
new file mode 100644
index 0000000..b08238c
--- /dev/null
+++ b/libs/libda/cmake/config.h.in
@@ -0,0 +1,9 @@
+#ifndef LIBDA_CONFIG_H
+#define LIBDA_CONFIG_H
+
+#define LIBDA_VERSION "@LibDA_VERSION@"
+#define LIBDA_VERSION_MAJOR @LibDA_VERSION_MAJOR@
+#define LIBDA_VERSION_MINOR @LibDA_VERSION_MINOR@
+
+#endif
+
diff --git a/libs/libda/include/libda/audio.hpp b/libs/libda/include/libda/audio.hpp
index 10e5cf5..4626f36 100644
--- a/libs/libda/include/libda/audio.hpp
+++ b/libs/libda/include/libda/audio.hpp
@@ -2,16 +2,15 @@
#define LIBDA_AUDIO_HPP_INCLUDED
/**
-@file audio.hpp LibDA public interface.
+@file audio.hpp LibDA audio I/O public interface
-Link with libda when you use this.
+Link with libda when you use this. ABI will change, API is likely to change in
+future versions (which hopefully will bring API and ABI compatibility).
**/
// Library version number, may be used to test whether a certain function is
// available. Incremented by one each time a new release is done.
-#define LIBDA_VERSION 0
-
#include "sample.hpp"
#include <boost/function.hpp>
#include <boost/scoped_ptr.hpp>
diff --git a/libs/libda/include/libda/audio_dev.hpp b/libs/libda/include/libda/audio_dev.hpp
index ad8ab00..10970f2 100644
--- a/libs/libda/include/libda/audio_dev.hpp
+++ b/libs/libda/include/libda/audio_dev.hpp
@@ -1,6 +1,13 @@
#ifndef AUDIO_DEV_HPP_INCLUDED
#define AUDIO_DEV_HPP_INCLUDED
+/**
+@file audio_dev.hpp Audio plugin interface. Not very stable yet.
+
+This requires linking with libda and the ABI is not stable yet. The API might
+also change.
+**/
+
#include <libda/audio.hpp>
#include <plugin++/plugin.hpp>
diff --git a/libs/libda/include/libda/mixer.hpp b/libs/libda/include/libda/mixer.hpp
index 370056e..29ae38e 100644
--- a/libs/libda/include/libda/mixer.hpp
+++ b/libs/libda/include/libda/mixer.hpp
@@ -2,7 +2,10 @@
#define LIBDA_MIXER_HPP_INCLUDED
/**
-@file mixer.hpp LibDA mixer interface.
+@file mixer.hpp LibDA mixer interface, version 1.
+
+This appears to be too complex and will probably be removed in later release in
+favor of something easier and faster.
Link with libda when you use this.
**/
|
|
From: Markus R. <god...@us...> - 2009-11-26 09:29:20
|
Module: performous
Branch: master
Commit: 5680d527e223e072cd9f0407fa21eb770fdad187
Author: Markus Raab <un...@ma...>
Date: Thu Nov 26 10:28:52 2009 +0100
libda packaging
---
libs/libda/CMakeLists.txt | 2 +
libs/libda/cmake/LibDAConfig.cmake.in | 2 +-
libs/libda/cmake/LibDAConfigVersion.cmake.in | 10 ++--
libs/libda/cmake/libda-packaging.cmake | 61 ++++++++++++++++++++++++++
libs/plugin++/cmake/plugin++-packaging.cmake | 2 +-
5 files changed, 70 insertions(+), 7 deletions(-)
diff --git a/libs/libda/CMakeLists.txt b/libs/libda/CMakeLists.txt
index c856b95..8404f91 100644
--- a/libs/libda/CMakeLists.txt
+++ b/libs/libda/CMakeLists.txt
@@ -11,6 +11,8 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR)
message(FATAL_ERROR "In-source builds are not permitted. Make a separate folder for building:\nmkdir build; cd build; cmake ..\nBefore that, remove the files already created:\nrm -rf CMakeCache.txt CMakeFiles")
endif()
+include("${CMAKE_SOURCE_DIR}/cmake/libda-packaging.cmake")
+
# Add a sensible build type default and warning because empty means no optimization and no debug info.
if(NOT CMAKE_BUILD_TYPE)
message("WARNING: CMAKE_BUILD_TYPE is not defined!\n Defaulting to CMAKE_BUILD_TYPE=Release. Use ccmake to set a proper value.")
diff --git a/libs/libda/cmake/LibDAConfig.cmake.in b/libs/libda/cmake/LibDAConfig.cmake.in
index 29973af..17a77e4 100644
--- a/libs/libda/cmake/LibDAConfig.cmake.in
+++ b/libs/libda/cmake/LibDAConfig.cmake.in
@@ -6,5 +6,5 @@ if(NOT LibDA_FOUND)
include("@CMAKE_INSTALL_PREFIX@/@LibDA_CMAKE_DIR@/LibDA.cmake")
set(LibDA_LIBRARIES da)
-endif()
+endif(NOT LibDA_FOUND)
diff --git a/libs/libda/cmake/LibDAConfigVersion.cmake.in b/libs/libda/cmake/LibDAConfigVersion.cmake.in
index 2f5b3dd..12739be 100644
--- a/libs/libda/cmake/LibDAConfigVersion.cmake.in
+++ b/libs/libda/cmake/LibDAConfigVersion.cmake.in
@@ -1,13 +1,13 @@
-if ("${PACKAGE_VERSION}" VERSION_EQUAL "@LibDA_VERSION@")
+if ("${PACKAGE_VERSION}" EQUAL "@LibDA_VERSION@")
set(PACKAGE_VERSION_EXACT TRUE)
-else()
+else("${PACKAGE_VERSION}" EQUAL "@LibDA_VERSION@")
set(PACKAGE_VERSION_EXACT FALSE)
-endif()
+endif("${PACKAGE_VERSION}" EQUAL "@LibDA_VERSION@")
-if (PACKAGE_VERSION_EXACT OR "${PACKAGE_VERSION}" VERSION_LESS "@LibDA_VERSION@")
+if (PACKAGE_VERSION_EXACT OR "${PACKAGE_VERSION}" LESS "@LibDA_VERSION@")
set(PACKAGE_VERSION "@LibDA_VERSION@")
set(PACKAGE_VERSION_COMPATIBLE TRUE)
set(PACKAGE_VERSION_UNSUITABLE FALSE)
set(PACKAGE_VERSION_EXACT FALSE)
-endif()
+endif(PACKAGE_VERSION_EXACT OR "${PACKAGE_VERSION}" LESS "@LibDA_VERSION@")
diff --git a/libs/libda/cmake/libda-packaging.cmake b/libs/libda/cmake/libda-packaging.cmake
new file mode 100644
index 0000000..e107fad
--- /dev/null
+++ b/libs/libda/cmake/libda-packaging.cmake
@@ -0,0 +1,61 @@
+set(CPACK_PACKAGE_NAME "${CMAKE_PROJECT_NAME}")
+set(CPACK_PACKAGE_VERSION "${LibDA_VERSION}")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "C++ digital audio I/O and processing library.")
+set(CPACK_PACKAGE_CONTACT "http://performous.org/")
+set(CPACK_SOURCE_IGNORE_FILES
+ "/.cvsignore"
+ "/.gitignore"
+ "/songs/"
+ "/build/"
+ "/.svn/"
+ "/.git/"
+ "/osx-utils/"
+ "/portage-overlay/"
+)
+
+
+if("${CMAKE_BUILD_TYPE}" MATCHES "Release")
+ set(CPACK_STRIP_FILES TRUE)
+endif("${CMAKE_BUILD_TYPE}" MATCHES "Release")
+
+
+if(UNIX)
+ # Try to find architecture
+ execute_process(COMMAND uname -m OUTPUT_VARIABLE CPACK_PACKAGE_ARCHITECTURE)
+ string(STRIP "${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_ARCHITECTURE)
+ # Try to find distro name and distro-specific arch
+ execute_process(COMMAND lsb_release -is OUTPUT_VARIABLE LSB_ID)
+ execute_process(COMMAND lsb_release -rs OUTPUT_VARIABLE LSB_RELEASE)
+ string(STRIP "${LSB_ID}" LSB_ID)
+ string(STRIP "${LSB_RELEASE}" LSB_RELEASE)
+ set(LSB_DISTRIB "${LSB_ID}${LSB_RELEASE}")
+ if(NOT LSB_DISTRIB)
+ set(LSB_DISTRIB "unix")
+ endif(NOT LSB_DISTRIB)
+ # For Debian-based distros we want to create DEB packages.
+ if("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian")
+ set(CPACK_GENERATOR "DEB")
+ set(CPACK_DEBIAN_PACKAGE_PRIORITY "extra")
+ set(CPACK_DEBIAN_PACKAGE_SECTION "universe/games")
+ set(CPACK_DEBIAN_PACKAGE_RECOMMENDS "ultrastar-songs, ultrastar-songs-restricted, msttcorefonts")
+ # We need to alter the architecture names as per distro rules
+ if("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86")
+ set(CPACK_PACKAGE_ARCHITECTURE i386)
+ endif("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86")
+ if("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "x86_64")
+ set(CPACK_PACKAGE_ARCHITECTURE amd64)
+ endif("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "x86_64")
+ # Set the dependencies based on the distro version
+ if("${LSB_DISTRIB}" MATCHES "Debian5.*")
+ set(CPACK_DEBIAN_PACKAGE_DEPENDS "libboost-dev, libasound2, libjack0")
+ endif("${LSB_DISTRIB}" MATCHES "Debian5.*")
+ if(NOT CPACK_DEBIAN_PACKAGE_DEPENDS)
+ message("WARNING: ${LSB_DISTRIB} not supported yet.\nPlease set deps in cmake/performous-packaging.cmake before packaging.")
+ endif(NOT CPACK_DEBIAN_PACKAGE_DEPENDS)
+ endif("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian")
+ set(CPACK_SYSTEM_NAME "${LSB_DISTRIB}-${CPACK_PACKAGE_ARCHITECTURE}")
+ message(STATUS "Detected ${CPACK_SYSTEM_NAME}. Use make package to build packages (${CPACK_GENERATOR}).")
+endif(UNIX)
+
+include(CPack)
+
diff --git a/libs/plugin++/cmake/plugin++-packaging.cmake b/libs/plugin++/cmake/plugin++-packaging.cmake
index c0c192a..68e8862 100644
--- a/libs/plugin++/cmake/plugin++-packaging.cmake
+++ b/libs/plugin++/cmake/plugin++-packaging.cmake
@@ -1,6 +1,6 @@
set(CPACK_PACKAGE_NAME "${CMAKE_PROJECT_NAME}")
set(CPACK_PACKAGE_VERSION "${Plugin++_VERSION}")
-set(CPACK_PACKAGE_DESCRIPTION_SUMMARY " Plugin++ is a cross platform plug-in framework for C++ that uses XML to marshal data across the application and the shared library space.")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Plugin++ is a cross platform plug-in framework for C++ that uses XML to marshal data across the application and the shared library space.")
set(CPACK_PACKAGE_CONTACT "http://sourceforge.net/projects/pluginpp/")
set(CPACK_SOURCE_IGNORE_FILES
"/.cvsignore"
|
|
From: Markus R. <god...@us...> - 2009-11-26 09:09:12
|
Module: performous
Branch: master
Commit: 4b22765913c319bb6ddf9ed511727c600fbc7a5d
Author: Markus Raab <un...@ma...>
Date: Thu Nov 26 10:08:32 2009 +0100
Make Plugin++Config* cmake 2.6 compatible
---
libs/plugin++/cmake/Plugin++Config.cmake.in | 2 +-
libs/plugin++/cmake/Plugin++ConfigVersion.cmake.in | 10 +++++-----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/libs/plugin++/cmake/Plugin++Config.cmake.in b/libs/plugin++/cmake/Plugin++Config.cmake.in
index 8b539c8..34df072 100644
--- a/libs/plugin++/cmake/Plugin++Config.cmake.in
+++ b/libs/plugin++/cmake/Plugin++Config.cmake.in
@@ -6,5 +6,5 @@ if(NOT Plugin++_FOUND)
include("@CMAKE_INSTALL_PREFIX@/@Plugin++_CMAKE_DIR@/Plugin++.cmake")
set(Plugin++_LIBRARIES "plugin++")
-endif()
+endif(NOT Plugin++_FOUND)
diff --git a/libs/plugin++/cmake/Plugin++ConfigVersion.cmake.in b/libs/plugin++/cmake/Plugin++ConfigVersion.cmake.in
index f7c9948..2f2643c 100644
--- a/libs/plugin++/cmake/Plugin++ConfigVersion.cmake.in
+++ b/libs/plugin++/cmake/Plugin++ConfigVersion.cmake.in
@@ -1,13 +1,13 @@
-if ("${PACKAGE_VERSION}" VERSION_EQUAL "@Plugin++_VERSION@")
+if ("${PACKAGE_VERSION}" EQUAL "@Plugin++_VERSION@")
set(PACKAGE_VERSION_EXACT TRUE)
-else()
+else("${PACKAGE_VERSION}" EQUAL "@Plugin++_VERSION@")
set(PACKAGE_VERSION_EXACT FALSE)
-endif()
+endif("${PACKAGE_VERSION}" EQUAL "@Plugin++_VERSION@")
-if (PACKAGE_VERSION_EXACT OR "${PACKAGE_VERSION}" VERSION_LESS "@Plugin++_VERSION@")
+if (PACKAGE_VERSION_EXACT OR "${PACKAGE_VERSION}" LESS "@Plugin++_VERSION@")
set(PACKAGE_VERSION "@Plugin++_VERSION@")
set(PACKAGE_VERSION_COMPATIBLE TRUE)
set(PACKAGE_VERSION_UNSUITABLE FALSE)
set(PACKAGE_VERSION_EXACT FALSE)
-endif()
+endif(PACKAGE_VERSION_EXACT OR "${PACKAGE_VERSION}" LESS "@Plugin++_VERSION@")
|
|
From: Markus R. <god...@us...> - 2009-11-26 08:12:23
|
Module: performous
Branch: master
Commit: 6a211f3778dcb876f6c5b59e88d21b1ca77b3c6a
Author: Markus Raab <un...@ma...>
Date: Thu Nov 26 09:11:25 2009 +0100
Packaging for plugin++ (Debian 5.*)
---
libs/plugin++/CMakeLists.txt | 2 +
libs/plugin++/cmake/plugin++-packaging.cmake | 61 ++++++++++++++++++++++++++
2 files changed, 63 insertions(+), 0 deletions(-)
diff --git a/libs/plugin++/CMakeLists.txt b/libs/plugin++/CMakeLists.txt
index fca339f..4d2e22c 100644
--- a/libs/plugin++/CMakeLists.txt
+++ b/libs/plugin++/CMakeLists.txt
@@ -10,6 +10,8 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR)
message(FATAL_ERROR "In-source builds are not permitted. Make a separate folder for building:\nmkdir build; cd build; cmake ..\nBefore that, remove the files already created:\nrm -rf CMakeCache.txt CMakeFiles")
endif()
+include("${CMAKE_SOURCE_DIR}/cmake/plugin++-packaging.cmake")
+
# Add a sensible build type default and warning because empty means no optimization and no debug info.
if(NOT CMAKE_BUILD_TYPE)
message("WARNING: CMAKE_BUILD_TYPE is not defined!\n Defaulting to CMAKE_BUILD_TYPE=Release. Use ccmake to set a proper value.")
diff --git a/libs/plugin++/cmake/plugin++-packaging.cmake b/libs/plugin++/cmake/plugin++-packaging.cmake
new file mode 100644
index 0000000..c0c192a
--- /dev/null
+++ b/libs/plugin++/cmake/plugin++-packaging.cmake
@@ -0,0 +1,61 @@
+set(CPACK_PACKAGE_NAME "${CMAKE_PROJECT_NAME}")
+set(CPACK_PACKAGE_VERSION "${Plugin++_VERSION}")
+set(CPACK_PACKAGE_DESCRIPTION_SUMMARY " Plugin++ is a cross platform plug-in framework for C++ that uses XML to marshal data across the application and the shared library space.")
+set(CPACK_PACKAGE_CONTACT "http://sourceforge.net/projects/pluginpp/")
+set(CPACK_SOURCE_IGNORE_FILES
+ "/.cvsignore"
+ "/.gitignore"
+ "/songs/"
+ "/build/"
+ "/.svn/"
+ "/.git/"
+ "/osx-utils/"
+ "/portage-overlay/"
+)
+
+
+if("${CMAKE_BUILD_TYPE}" MATCHES "Release")
+ set(CPACK_STRIP_FILES TRUE)
+endif("${CMAKE_BUILD_TYPE}" MATCHES "Release")
+
+
+if(UNIX)
+ # Try to find architecture
+ execute_process(COMMAND uname -m OUTPUT_VARIABLE CPACK_PACKAGE_ARCHITECTURE)
+ string(STRIP "${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_ARCHITECTURE)
+ # Try to find distro name and distro-specific arch
+ execute_process(COMMAND lsb_release -is OUTPUT_VARIABLE LSB_ID)
+ execute_process(COMMAND lsb_release -rs OUTPUT_VARIABLE LSB_RELEASE)
+ string(STRIP "${LSB_ID}" LSB_ID)
+ string(STRIP "${LSB_RELEASE}" LSB_RELEASE)
+ set(LSB_DISTRIB "${LSB_ID}${LSB_RELEASE}")
+ if(NOT LSB_DISTRIB)
+ set(LSB_DISTRIB "unix")
+ endif(NOT LSB_DISTRIB)
+ # For Debian-based distros we want to create DEB packages.
+ if("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian")
+ set(CPACK_GENERATOR "DEB")
+ set(CPACK_DEBIAN_PACKAGE_PRIORITY "extra")
+ set(CPACK_DEBIAN_PACKAGE_SECTION "universe/games")
+ set(CPACK_DEBIAN_PACKAGE_RECOMMENDS "ultrastar-songs, ultrastar-songs-restricted, msttcorefonts")
+ # We need to alter the architecture names as per distro rules
+ if("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86")
+ set(CPACK_PACKAGE_ARCHITECTURE i386)
+ endif("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86")
+ if("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "x86_64")
+ set(CPACK_PACKAGE_ARCHITECTURE amd64)
+ endif("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "x86_64")
+ # Set the dependencies based on the distro version
+ if("${LSB_DISTRIB}" MATCHES "Debian5.*")
+ set(CPACK_DEBIAN_PACKAGE_DEPENDS "libboost-dev, libc6-dev")
+ endif("${LSB_DISTRIB}" MATCHES "Debian5.*")
+ if(NOT CPACK_DEBIAN_PACKAGE_DEPENDS)
+ message("WARNING: ${LSB_DISTRIB} not supported yet.\nPlease set deps in cmake/performous-packaging.cmake before packaging.")
+ endif(NOT CPACK_DEBIAN_PACKAGE_DEPENDS)
+ endif("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian")
+ set(CPACK_SYSTEM_NAME "${LSB_DISTRIB}-${CPACK_PACKAGE_ARCHITECTURE}")
+ message(STATUS "Detected ${CPACK_SYSTEM_NAME}. Use make package to build packages (${CPACK_GENERATOR}).")
+endif(UNIX)
+
+include(CPack)
+
|
|
From: Jaakko N. <jni...@us...> - 2009-11-25 21:32:25
|
Module: performous Branch: dance Commit: a297948e9bec8fd74c9875e3306c9fa95df6b1aa Author: Jaakko Nikkola <jaa...@tk...> Date: Wed Nov 25 23:32:04 2009 +0200 Merge branch 'dance' of jni...@gi...:/gitroot/performous/performous into dance --- |
|
From: Jaakko N. <jni...@us...> - 2009-11-25 21:32:22
|
Module: performous
Branch: dance
Commit: f559361bc821991697821fb91508a1101f0f2963
Author: Jaakko Nikkola <jaa...@tk...>
Date: Wed Nov 25 23:30:22 2009 +0200
Hold notes added as hold notes and some types added to note type enumeration.
---
game/notes.hh | 3 +--
game/songparser-sm.cc | 33 ++++++++++++++-------------------
2 files changed, 15 insertions(+), 21 deletions(-)
diff --git a/game/notes.hh b/game/notes.hh
index 916d0d9..4632226 100644
--- a/game/notes.hh
+++ b/game/notes.hh
@@ -73,8 +73,7 @@ struct Note {
/// power of note
mutable double power;
/// note type
- int danceType; ///1 for tap, 2 for hold begin note, 3 for hold end etc. (perhars enum could be made)
- enum Type { FREESTYLE = 'F', NORMAL = ':', GOLDEN = '*', SLIDE = '+', SLEEP = '-', MINE = 'M'} type;
+ enum Type { FREESTYLE = 'F', NORMAL = ':', GOLDEN = '*', SLIDE = '+', SLEEP = '-', TAP = '1', HOLDBEGIN = '2', HOLDEND = '3', MINE = 'M'} type;
int note; ///< MIDI pitch of the note (at the end for slide notes)
int notePrev; ///< MIDI pitch of the previous note (should be same as note for everything but SLIDE)
/// lyrics syllable for that note
diff --git a/game/songparser-sm.cc b/game/songparser-sm.cc
index 03fea2a..c6b2e25 100644
--- a/game/songparser-sm.cc
+++ b/game/songparser-sm.cc
@@ -146,6 +146,7 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
double dur; //note duration
std::vector<int> holdMarks(4, -1); //vector to contain mark for the chord where hold began for each "fret" (-1 if no mark set)
+
while(getline(line)) {
if (line.empty() || line == "\r") continue;
if (line[0] == '/' && line[1] == '/') continue;
@@ -156,27 +157,25 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
dur = 4.0 * ( 1.0/(m_bpm/60.0) ) / lcount; //counts one note duration in seconds;
//std::cout << "DUR: " << dur << "TM: " << tm << std::endl;
for(int j = count - lcount; j<count ; j++) {
- DanceChord _chord = chords.at(j);
+ DanceChord& _chord = chords.at(j);
for(int i = 0; i<4; i++) {
if(_chord.find(i) != _chord.end()) {
- //if(_chord[i].danceType == 1) {
+ if(_chord[i].type == Note::TAP || _chord[i].type == Note::MINE) {
_chord[i].begin = tm;
_chord[i].end = tm;
notes.push_back(_chord[i]); //note added to notes container used in DanceTrack
- /*}
- if(_chord[i].danceType == 2) {
+ }
+ if(_chord[i].type == Note::HOLDBEGIN) {
_chord[i].begin = tm;
notes.push_back(_chord[i]); //note added to notes container used in DanceTrack
+ holdMarks.at(i) = notes.size() - 1; //mark to hold beginning in notes vector
}
- if(_chord[i].danceType == 3) {
+ if(_chord[i].type == Note::HOLDEND) {
if(holdMarks.at(i) < 0) throw std::runtime_error("hold end without beginning");
- std::cout << "mark1" << std::endl;
- Note _note = notes.at(holdMarks.at(i));
- std::cout << "mark2" << std::endl;
+ Note& _note = notes.at(holdMarks.at(i));
_note.end = tm;
- std::cout << "mark3" << std::endl;
holdMarks.at(i) = -1;
- }*/
+ }
}
}
tm += dur;
@@ -189,10 +188,10 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
std::istringstream iss(line);
for(int i =0; i<4; i++){
char notetype = iss.get();
- if(notetype == '1' || notetype == '2') {
+ if(notetype == '1') {
Note note;
note.note = i;
- //note.danceType = 1;
+ note.type = Note::TAP;
chord[i] = note;
}
if(notetype == 'M') {
@@ -201,23 +200,19 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
note.type = Note::MINE;
chord[i] = note;
}
- /*
+
if(notetype == '2') {
- std::cout << "hold begin" << std::endl;
Note note;
note.note = i;
- note.danceType = 2;
+ note.type = Note::HOLDBEGIN;
chord[i] = note;
- holdMarks.at(i) = count;
}
if(notetype == '3') {
- std::cout << "hold end" << std::endl;
Note note;
note.note = i;
- note.danceType = 3;
+ note.type = Note::HOLDEND;
chord[i] = note;
}
- */
}
lcount++;
count++;
|
|
From: Tapio V. <aa...@us...> - 2009-11-25 21:07:21
|
Module: performous
Branch: dance
Commit: 7d387e3d9aab4eef04e56e94b40bdce3b0df4340
Author: Tapio Vierros <tap...@gm...>
Date: Wed Nov 25 23:06:49 2009 +0200
Basic mine note displaying.
---
game/dancegraph.cc | 17 ++++++-
game/dancegraph.hh | 2 +
themes/default/mine.svg | 128 +++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 145 insertions(+), 2 deletions(-)
diff --git a/game/dancegraph.cc b/game/dancegraph.cc
index c3fa6bf..094343c 100644
--- a/game/dancegraph.cc
+++ b/game/dancegraph.cc
@@ -40,6 +40,7 @@ DanceGraph::DanceGraph(Audio& audio, Song const& song):
m_song(song),
m_input(input::GUITAR), // TODO: to be replaced by DANCEPAD
m_arrow(getThemePath("arrow.svg")),
+ m_mine(getThemePath("mine.svg")),
m_arrow_hold(getThemePath("arrow_hold.svg")),
m_cx(0.0, 0.2),
m_width(0.5, 0.4),
@@ -160,7 +161,17 @@ void DanceGraph::drawArrow(int arrow_i, float x, float y, float scale) {
m_arrow.draw();
if (scale != 1.0) glScalef(1.0/scale, 1.0/scale, 1.0/scale);
glRotatef(-arrowRotations[arrow_i], 0.0f, 0.0f, 1.0f);
- glTranslatef(-x, -y, 0.0f);
+ glTranslatef(-x, -y, 0.0f);
+}
+
+void DanceGraph::drawMine(float x, float y, float rot, float scale) {
+ glTranslatef(x, y, 0.0f);
+ glRotatef(rot, 0.0f, 0.0f, 1.0f);
+ if (scale != 1.0) glScalef(scale, scale, scale);
+ m_mine.draw();
+ if (scale != 1.0) glScalef(1.0/scale, 1.0/scale, 1.0/scale);
+ glRotatef(-rot, 0.0f, 0.0f, 1.0f);
+ glTranslatef(-x, -y, 0.0f);
}
/// Draws the dance graph
@@ -212,6 +223,7 @@ void DanceGraph::draw(double time) {
if (tBeg > future) break;
int arrow_i = it->note.note;
+ bool mine = it->note.type == Note::MINE;
float x = -1.5f + arrow_i;
float s = arrowScale;
float yBeg = time2y(tBeg);
@@ -246,7 +258,8 @@ void DanceGraph::draw(double time) {
c.a = 1.0 - glow;
s = arrowScale + glow;
glColor4fv(c);
- drawArrow(arrow_i, x, yBeg, s);
+ if (mine) drawMine(x, yBeg, int(time*360) % 360, s);
+ else drawArrow(arrow_i, x, yBeg, s);
}
}
diff --git a/game/dancegraph.hh b/game/dancegraph.hh
index c8866b3..f26a87e 100644
--- a/game/dancegraph.hh
+++ b/game/dancegraph.hh
@@ -54,12 +54,14 @@ class DanceGraph {
void drawNote(int arrow_i, glutil::Color, float tBeg, float tEnd);
glutil::Color const& color(int arrow_i) const;
void drawArrow(int arrow_i, float x, float y, float scale = 1.0);
+ void drawMine(float x, float y, float rot = 0.0, float scale = 1.0);
Audio& m_audio;
Song const& m_song;
input::InputDev m_input;
DanceNotes m_notes;
DanceNotes::iterator m_notesIt;
Surface m_arrow;
+ Surface m_mine;
Texture m_arrow_hold;
AnimValue m_cx, m_width;
std::size_t m_stream;
diff --git a/themes/default/mine.svg b/themes/default/mine.svg
new file mode 100644
index 0000000..4463bbb
--- /dev/null
+++ b/themes/default/mine.svg
@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ 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="64"
+ height="64"
+ id="svg2463"
+ sodipodi:version="0.32"
+ inkscape:version="0.47 r22583"
+ version="1.0"
+ sodipodi:docname="mine.svg"
+ inkscape:output_extension="org.inkscape.output.svg.inkscape">
+ <defs
+ id="defs2465">
+ <linearGradient
+ id="linearGradient3262">
+ <stop
+ style="stop-color:#f5f5f5;stop-opacity:0.22680412;"
+ offset="0"
+ id="stop3264" />
+ <stop
+ style="stop-color:#f5f5f5;stop-opacity:0.96078432;"
+ offset="1"
+ id="stop3266" />
+ </linearGradient>
+ <linearGradient
+ id="linearGradient3751"
+ inkscape:collect="always">
+ <stop
+ id="stop3753"
+ offset="0"
+ style="stop-color:black;stop-opacity:1;" />
+ <stop
+ id="stop3755"
+ offset="1"
+ style="stop-color:black;stop-opacity:0;" />
+ </linearGradient>
+ <inkscape:perspective
+ sodipodi:type="inkscape:persp3d"
+ inkscape:vp_x="0 : 526.18109 : 1"
+ inkscape:vp_y="0 : 1000 : 0"
+ inkscape:vp_z="744.09448 : 526.18109 : 1"
+ inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
+ id="perspective2471" />
+ <linearGradient
+ inkscape:collect="always"
+ xlink:href="#linearGradient3751"
+ id="linearGradient3272"
+ gradientUnits="userSpaceOnUse"
+ gradientTransform="matrix(0.3868046,0,0,0.3868046,40.335717,481.59837)"
+ x1="665.12128"
+ y1="684.16162"
+ x2="381.28015"
+ y2="449.80624" />
+ <linearGradient
+ inkscape:collect="always"
+ xlink:href="#linearGradient3751"
+ id="linearGradient2406"
+ gradientUnits="userSpaceOnUse"
+ gradientTransform="matrix(0.3868046,0,0,0.3868046,43.114888,485.8841)"
+ x1="665.12128"
+ y1="684.16162"
+ x2="381.28015"
+ y2="449.80624" />
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#f5f5f5"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ gridtolerance="10000"
+ guidetolerance="10"
+ objecttolerance="10"
+ inkscape:pageopacity="0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="5.6"
+ inkscape:cx="27.116923"
+ inkscape:cy="40.003406"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer1"
+ showgrid="false"
+ inkscape:window-width="860"
+ inkscape:window-height="806"
+ inkscape:window-x="568"
+ inkscape:window-y="26"
+ inkscape:window-maximized="0" />
+ <metadata
+ id="metadata2468">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:label="Layer 1"
+ inkscape:groupmode="layer"
+ id="layer1"
+ transform="translate(-110.35967,-771.51188)">
+ <path
+ sodipodi:type="star"
+ style="fill:#1a1a1a;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.50462699;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ id="path2824"
+ sodipodi:sides="10"
+ sodipodi:cx="30.892857"
+ sodipodi:cy="33.285713"
+ sodipodi:r1="32.142857"
+ sodipodi:r2="20.415771"
+ sodipodi:arg1="1.5707963"
+ sodipodi:arg2="2.5575682"
+ inkscape:flatsided="false"
+ inkscape:rounded="0"
+ inkscape:randomized="0"
+ d="M 30.892857,65.42857 13.860991,44.54268 11.99976,59.289831 10.497109,32.381711 0.32318364,43.218403 14.92371,20.566041 0.32318311,23.353025 25.449981,13.608853 11.999759,7.2815965 38.055246,14.167557 30.892856,1.1428566 47.924722,22.028747 49.785953,7.2815955 51.288604,34.189715 61.46253,23.353023 46.862004,46.005386 61.46253,43.218401 36.335732,52.962574 49.785954,59.28983 23.730467,52.40387 l 7.16239,13.0247 z"
+ transform="matrix(1.0222549,0,0,0.97222224,110.7793,771.15077)" />
+ </g>
+</svg>
|
|
From: Jaakko N. <jni...@us...> - 2009-11-25 20:44:53
|
Module: performous
Branch: dance
Commit: 91bee4def7adcb2918b88aaaf0fc2c524fd27c97
Author: Jaakko Nikkola <jaa...@tk...>
Date: Wed Nov 25 22:43:46 2009 +0200
Hold notes added as normal notes, and Mines added in Note type enum.
---
game/notes.hh | 3 ++-
game/songparser-sm.cc | 43 ++++++++++++++++++++++++++++++++++++++++++-
2 files changed, 44 insertions(+), 2 deletions(-)
diff --git a/game/notes.hh b/game/notes.hh
index 4d43e89..916d0d9 100644
--- a/game/notes.hh
+++ b/game/notes.hh
@@ -73,7 +73,8 @@ struct Note {
/// power of note
mutable double power;
/// note type
- enum Type { FREESTYLE = 'F', NORMAL = ':', GOLDEN = '*', SLIDE = '+', SLEEP = '-'} type;
+ int danceType; ///1 for tap, 2 for hold begin note, 3 for hold end etc. (perhars enum could be made)
+ enum Type { FREESTYLE = 'F', NORMAL = ':', GOLDEN = '*', SLIDE = '+', SLEEP = '-', MINE = 'M'} type;
int note; ///< MIDI pitch of the note (at the end for slide notes)
int notePrev; ///< MIDI pitch of the previous note (should be same as note for everything but SLIDE)
/// lyrics syllable for that note
diff --git a/game/songparser-sm.cc b/game/songparser-sm.cc
index 00450eb..03fea2a 100644
--- a/game/songparser-sm.cc
+++ b/game/songparser-sm.cc
@@ -145,6 +145,7 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
double tm = 0; //time counter
double dur; //note duration
+ std::vector<int> holdMarks(4, -1); //vector to contain mark for the chord where hold began for each "fret" (-1 if no mark set)
while(getline(line)) {
if (line.empty() || line == "\r") continue;
if (line[0] == '/' && line[1] == '/') continue;
@@ -158,9 +159,24 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
DanceChord _chord = chords.at(j);
for(int i = 0; i<4; i++) {
if(_chord.find(i) != _chord.end()) {
+ //if(_chord[i].danceType == 1) {
_chord[i].begin = tm;
_chord[i].end = tm;
notes.push_back(_chord[i]); //note added to notes container used in DanceTrack
+ /*}
+ if(_chord[i].danceType == 2) {
+ _chord[i].begin = tm;
+ notes.push_back(_chord[i]); //note added to notes container used in DanceTrack
+ }
+ if(_chord[i].danceType == 3) {
+ if(holdMarks.at(i) < 0) throw std::runtime_error("hold end without beginning");
+ std::cout << "mark1" << std::endl;
+ Note _note = notes.at(holdMarks.at(i));
+ std::cout << "mark2" << std::endl;
+ _note.end = tm;
+ std::cout << "mark3" << std::endl;
+ holdMarks.at(i) = -1;
+ }*/
}
}
tm += dur;
@@ -172,11 +188,36 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
DanceChord chord;
std::istringstream iss(line);
for(int i =0; i<4; i++){
- if(iss.get() == '1') {
+ char notetype = iss.get();
+ if(notetype == '1' || notetype == '2') {
+ Note note;
+ note.note = i;
+ //note.danceType = 1;
+ chord[i] = note;
+ }
+ if(notetype == 'M') {
Note note;
note.note = i;
+ note.type = Note::MINE;
+ chord[i] = note;
+ }
+ /*
+ if(notetype == '2') {
+ std::cout << "hold begin" << std::endl;
+ Note note;
+ note.note = i;
+ note.danceType = 2;
+ chord[i] = note;
+ holdMarks.at(i) = count;
+ }
+ if(notetype == '3') {
+ std::cout << "hold end" << std::endl;
+ Note note;
+ note.note = i;
+ note.danceType = 3;
chord[i] = note;
}
+ */
}
lcount++;
count++;
|
|
From: Jaakko N. <jni...@us...> - 2009-11-25 19:47:49
|
Module: performous
Branch: dance
Commit: 6e1c14bfc12ddc8cf29291b2c558a9380622eab6
Author: Jaakko Nikkola <jaa...@tk...>
Date: Wed Nov 25 21:46:45 2009 +0200
Some fixes made to get notes correctly.
---
game/songparser-sm.cc | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/game/songparser-sm.cc b/game/songparser-sm.cc
index ff68f3d..00450eb 100644
--- a/game/songparser-sm.cc
+++ b/game/songparser-sm.cc
@@ -138,6 +138,7 @@ bool SongParser::smParseField(std::string line) {
Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
DanceChords chords; //temporary container for notes
+
Notes notes;
int lcount = 0; //line counter for note duration
int count = 0; //total lines counter
@@ -153,14 +154,13 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
/*Counting the timestamp of each note*/
dur = 4.0 * ( 1.0/(m_bpm/60.0) ) / lcount; //counts one note duration in seconds;
//std::cout << "DUR: " << dur << "TM: " << tm << std::endl;
- for(int j = count - lcount; j<count ; j++) {
+ for(int j = count - lcount; j<count ; j++) {
+ DanceChord _chord = chords.at(j);
for(int i = 0; i<4; i++) {
- DanceChord& _chord = chords.at(j);
if(_chord.find(i) != _chord.end()) {
_chord[i].begin = tm;
_chord[i].end = tm;
notes.push_back(_chord[i]); //note added to notes container used in DanceTrack
-
}
}
tm += dur;
@@ -177,10 +177,10 @@ Notes SongParser::smParseNotes(std::string line, bool endOfInput) {
note.note = i;
chord[i] = note;
}
- chords.push_back(chord);
+ }
lcount++;
count++;
- }
+ chords.push_back(chord);
continue;
}
endOfInput = true;
|
|
From: knittl <kn...@us...> - 2009-11-25 16:46:32
|
Module: performous Branch: master Commit: 295543e7d1e6b7d92ec9632925ca935c56c82d45 Author: knittl <knittl@kbook.(none)> Date: Wed Nov 25 17:45:15 2009 +0100 fixed a typo in docs Compiling.txt had a wrong path in it --- docs/Compiling.txt | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/docs/Compiling.txt b/docs/Compiling.txt index 4358721..4327ad9 100644 --- a/docs/Compiling.txt +++ b/docs/Compiling.txt @@ -16,7 +16,7 @@ To install from git: sudo make install rm -rf * # Compile the game itself - cmake ../libs/libda/ + cmake .. make sudo make install # Run the game |
|
From: Lasse Kärkkäi. <tr...@us...> - 2009-11-25 16:43:46
|
Module: performous Branch: master Commit: d377cde202e7982c21523b6b72e4f36adc6ea612 Author: Lasse Karkkainen <tro...@tr...> Date: Wed Nov 25 16:40:17 2009 +0200 Update Compiling.txt --- docs/Compiling.txt | 21 ++++++++++++++++----- 1 files changed, 16 insertions(+), 5 deletions(-) diff --git a/docs/Compiling.txt b/docs/Compiling.txt index 6e07ea3..4358721 100644 --- a/docs/Compiling.txt +++ b/docs/Compiling.txt @@ -5,16 +5,25 @@ To install from git: # Create separate build folder under trunk to avoid polluting the source three mkdir performous/build cd performous/build - # Configure and build with CMake - cmake .. + # Compile and install libplugin++ (our C++ plugin/DLL library) + cmake ../libs/plugin++/ + make + sudo make install + rm -rf * + # Compile and install libda (our audio library) + cmake ../libs/libda/ + make + sudo make install + rm -rf * + # Compile the game itself + cmake ../libs/libda/ make - # Install into system prefix /usr/local/ sudo make install # Run the game performous - # Should you need to change building settings (e.g. installation prefix) - ccmake . + In order to change installation location (the default is /usr/local/), + use cmake parameter -DCMAKE_INSTALL_PREFIX=/where/to. Dependencies: @@ -39,6 +48,8 @@ Dependencies: * PortAudio v18 or v19 * Pulseaudio + - PortMidi (optional) for MIDI drum support + Please refer to http://performous.org/develop.html for packages to install. |
|
From: Peque <ms...@us...> - 2009-11-25 16:42:43
|
Module: performous
Branch: menu
Commit: f0115ff02ab2faae17ecc39145d9c2a58861f0e5
Author: Miguel Sánchez de León Peque <miguel@vostro1520.(none)>
Date: Wed Nov 25 17:28:44 2009 +0100
Little change for testing GIT
---
game/screen_intro.cc | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/game/screen_intro.cc b/game/screen_intro.cc
index c48e9b6..e8a9acc 100644
--- a/game/screen_intro.cc
+++ b/game/screen_intro.cc
@@ -29,6 +29,11 @@ void ScreenIntro::manageEvent(SDL_Event event) {
else if (key == SDLK_s) sm->activateScreen("Songs");
else if (key == SDLK_c) sm->activateScreen("Configuration");
else if (key == SDLK_p) sm->activateScreen("Practice");
+
+ else if (key == SDLK_LEFT) {
+ sm->activateScreen("Practice");
+ }
+
else if (key == SDLK_SPACE || key == SDLK_PAUSE) m_audio.togglePause();
} else if (event.type == SDL_JOYBUTTONDOWN) {
int button = event.jbutton.button;
|