diff --git a/Output/BackgroundMusic/background track license.txt b/Output/BackgroundMusic/DJad - Walking Alone - License.txt similarity index 100% rename from Output/BackgroundMusic/background track license.txt rename to Output/BackgroundMusic/DJad - Walking Alone - License.txt diff --git a/Output/BackgroundMusic/background track.mp3 b/Output/BackgroundMusic/DJad - Walking Alone.mp3 similarity index 100% rename from Output/BackgroundMusic/background track.mp3 rename to Output/BackgroundMusic/DJad - Walking Alone.mp3 diff --git a/Output/Languages/Deutsch.xml b/Output/Languages/Deutsch.xml index 457e55b8..bdc6f8ab 100644 --- a/Output/Languages/Deutsch.xml +++ b/Output/Languages/Deutsch.xml @@ -23,6 +23,7 @@ Normal Duett Medley + Kurz-Version Vocal Hero Superstar @@ -118,6 +119,16 @@ Warnung: Den Spielern %v sind keine Profile zugeordnet! Songauswahl + Lied singen + Zur Playlist hinzufügen + Schließen + Zufälligen Song wählen + Zufällige Kategorie wählen + Alle Songs singen + Alle sichtbaren Songs singen + Playlist öffnen + Neue Playlist + Lied-Optionen Suche: Ohne Sprache Ohne Jahr @@ -130,11 +141,13 @@ Pause Lied beenden Fortfahren + Lied überspringen Auswertung Bewertung Punkte Schwierigkeit + Gesamtpunktzahl Highscore diff --git a/Output/Languages/English.xml b/Output/Languages/English.xml index 69d4536e..a1ebb6c8 100644 --- a/Output/Languages/English.xml +++ b/Output/Languages/English.xml @@ -23,6 +23,7 @@ Normal Duet Medley + Short version Vocal Hero Superstar @@ -118,6 +119,16 @@ Warning: There are no profiles assigned to players %v! Song Selection + Sing + Add to playlist + Close + Select a random song + Select a random category + Sing all songs + Sing all visible songs + Open playlist + New Playlist + Song Options Search: No Language No Year @@ -130,11 +141,13 @@ Pause Stop singing Continue + Skip this song Scores Rating Points Difficulty + Overall score Highscore diff --git a/Output/Languages/French.xml b/Output/Languages/French.xml index f60e82a3..6da3296d 100644 --- a/Output/Languages/French.xml +++ b/Output/Languages/French.xml @@ -117,6 +117,7 @@ Rechercher: Pas de Langue Pas d'Année + TODO: New Playlist Pas de Genre Pas d'Edition Toutes les chansons diff --git a/Output/Languages/Spanish.xml b/Output/Languages/Spanish.xml index 483e30a3..2c4a8456 100644 --- a/Output/Languages/Spanish.xml +++ b/Output/Languages/Spanish.xml @@ -116,6 +116,7 @@ Selección de Canciones Buscar: Sin Idioma + TODO: New Playlist Sin Año Sin Género Sin Edición diff --git a/Output/Readme.txt b/Output/Readme.txt index 38fc134a..1ec5c587 100644 --- a/Output/Readme.txt +++ b/Output/Readme.txt @@ -109,7 +109,8 @@ Vocaluxe.exe -ConfigFile MyConfig.xml -ScoreFile C:\Vocaluxe\Highscores\MyHighsc Songscreen [CTRL] + [R] to select a random song [F3] to open/close the song search menu -[A] to sing all songs from a category +[A] to sing all songs +[SHIFT] + [A] to sing all songs from a category ================================= diff --git a/Output/Themes/Ambient/Close.png b/Output/Themes/Ambient/Close.png new file mode 100644 index 00000000..b8b8a994 Binary files /dev/null and b/Output/Themes/Ambient/Close.png differ diff --git a/Output/Themes/Ambient/Delete.png b/Output/Themes/Ambient/Delete.png new file mode 100644 index 00000000..46a686ad Binary files /dev/null and b/Output/Themes/Ambient/Delete.png differ diff --git a/Output/Themes/Ambient/MedleyCalcIcon.png b/Output/Themes/Ambient/MedleyCalcIcon.png new file mode 100644 index 00000000..25b73f10 Binary files /dev/null and b/Output/Themes/Ambient/MedleyCalcIcon.png differ diff --git a/Output/Themes/Ambient/MedleyIcon.png b/Output/Themes/Ambient/MedleyIcon.png deleted file mode 100644 index 7c1eb21e..00000000 Binary files a/Output/Themes/Ambient/MedleyIcon.png and /dev/null differ diff --git a/Output/Themes/Ambient/MedleyTagIcon.png b/Output/Themes/Ambient/MedleyTagIcon.png new file mode 100644 index 00000000..2bf40bdc Binary files /dev/null and b/Output/Themes/Ambient/MedleyTagIcon.png differ diff --git a/Output/Themes/Ambient/RepeatIcon.png b/Output/Themes/Ambient/RepeatIcon.png index 6675a41a..ecf82df1 100644 Binary files a/Output/Themes/Ambient/RepeatIcon.png and b/Output/Themes/Ambient/RepeatIcon.png differ diff --git a/Output/Themes/Ambient/Save.png b/Output/Themes/Ambient/Save.png new file mode 100644 index 00000000..1afc3113 Binary files /dev/null and b/Output/Themes/Ambient/Save.png differ diff --git a/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml b/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml index c8330637..104a5e25 100644 --- a/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml +++ b/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml @@ -10,10 +10,10 @@ 0 0,00 1181 - 50 + 42 - Visible + StaticColor @@ -22,11 +22,11 @@ CoverBackground - 50 - 0 + 55 + 2 0,00 - 50 - 50 + 38 + 38 Visible @@ -36,14 +36,14 @@ - 630 - 0 + 410 + 4 0,00 - 50 + 32 - 650 + 769 StaticColor @@ -58,7 +58,7 @@ Outline - + @@ -70,11 +70,11 @@ PlayIcon - 200 - 5 + 146 + 8 0,00 - 40 - 40 + 28 + 28 ButtonColor @@ -103,7 +103,7 @@ Normal - + @@ -119,11 +119,11 @@ PauseIcon - 200 - 5 + 145 + 8 0,00 - 40 - 40 + 28 + 28 ButtonColor @@ -152,7 +152,7 @@ Normal - + @@ -168,11 +168,11 @@ PreviousIcon - 125 - 0 + 100 + 2 0,00 - 50 - 50 + 38 + 38 ButtonColor @@ -201,7 +201,7 @@ Normal - + @@ -217,11 +217,11 @@ NextIcon - 265 - 0 + 185 + 2 0,00 - 50 - 50 + 38 + 38 ButtonColor @@ -250,7 +250,7 @@ Normal - + @@ -266,11 +266,11 @@ RepeatIcon - 330 - 0 + 225 + 2 0,00 - 50 - 50 + 38 + 38 ButtonColor @@ -299,7 +299,7 @@ Normal - + @@ -311,15 +311,15 @@ - VideoIcon + VideoIconCO - VideoIcon + VideoIconCO - 405 - 0 + 270 + 2 0,00 - 50 - 50 + 38 + 38 ButtonColor @@ -348,7 +348,7 @@ Normal - + @@ -364,11 +364,11 @@ DuetIcon - 555 - 0 + 360 + 2 0,00 - 50 - 50 + 38 + 38 ButtonColor @@ -397,7 +397,7 @@ Normal - + @@ -409,15 +409,15 @@ - VideoIcon + VideoIconBG - VideoIcon + VideoIconBG - 480 - 0 + 315 + 2 0,00 - 50 - 50 + 38 + 38 ButtonColor @@ -446,7 +446,7 @@ Normal - + diff --git a/Output/Themes/Ambient/Screens/ScreenHighscore.xml b/Output/Themes/Ambient/Screens/ScreenHighscore.xml index caf13c13..b036b823 100644 --- a/Output/Themes/Ambient/Screens/ScreenHighscore.xml +++ b/Output/Themes/Ambient/Screens/ScreenHighscore.xml @@ -68,7 +68,7 @@ Outline - + TR_SCREENHIGHSCORE_HIGHSCORE @@ -97,7 +97,7 @@ Outline - + @@ -126,7 +126,7 @@ Outline - + @@ -155,7 +155,7 @@ Outline - + @@ -184,7 +184,7 @@ Outline - + @@ -213,7 +213,7 @@ Outline - + @@ -242,7 +242,7 @@ Outline - + @@ -271,7 +271,7 @@ Outline - + @@ -300,7 +300,7 @@ Outline - + @@ -329,7 +329,7 @@ Outline - + @@ -358,7 +358,7 @@ Outline - + @@ -387,7 +387,7 @@ Outline - + @@ -416,7 +416,7 @@ Outline - + @@ -445,7 +445,7 @@ Outline - + @@ -474,7 +474,7 @@ Outline - + @@ -503,7 +503,7 @@ Outline - + @@ -532,7 +532,7 @@ Outline - + @@ -561,7 +561,7 @@ Outline - + @@ -590,7 +590,7 @@ Outline - + @@ -619,7 +619,7 @@ Outline - + @@ -648,7 +648,7 @@ Outline - + @@ -677,7 +677,7 @@ Outline - + @@ -706,7 +706,7 @@ Outline - + @@ -735,7 +735,7 @@ Outline - + @@ -764,7 +764,7 @@ Outline - + @@ -793,7 +793,7 @@ Outline - + @@ -822,7 +822,7 @@ Outline - + @@ -851,7 +851,7 @@ Outline - + @@ -880,7 +880,7 @@ Outline - + @@ -909,7 +909,7 @@ Outline - + @@ -938,7 +938,7 @@ Outline - + @@ -967,7 +967,7 @@ Outline - + @@ -996,7 +996,7 @@ Outline - + @@ -1025,7 +1025,7 @@ Outline - + @@ -1054,7 +1054,7 @@ Outline - + @@ -1083,7 +1083,7 @@ Outline - + @@ -1112,7 +1112,7 @@ Outline - + @@ -1141,7 +1141,7 @@ Outline - + @@ -1170,7 +1170,7 @@ Outline - + @@ -1199,7 +1199,7 @@ Outline - + @@ -1228,7 +1228,7 @@ Outline - + @@ -1257,7 +1257,7 @@ Outline - + @@ -1286,7 +1286,7 @@ Outline - + diff --git a/Output/Themes/Ambient/Screens/ScreenLoad.xml b/Output/Themes/Ambient/Screens/ScreenLoad.xml index a4030b21..6f78787d 100644 --- a/Output/Themes/Ambient/Screens/ScreenLoad.xml +++ b/Output/Themes/Ambient/Screens/ScreenLoad.xml @@ -52,7 +52,7 @@ Outline - + TR_PROGRAM_NAME @@ -81,7 +81,7 @@ Outline - + TR_SCREENLOAD_LOADING @@ -110,7 +110,7 @@ Outline - + diff --git a/Output/Themes/Ambient/Screens/ScreenMain.xml b/Output/Themes/Ambient/Screens/ScreenMain.xml index 6c195ea0..71116b93 100644 --- a/Output/Themes/Ambient/Screens/ScreenMain.xml +++ b/Output/Themes/Ambient/Screens/ScreenMain.xml @@ -68,7 +68,7 @@ Outline - + TR_SCREENMAIN_BUTTON_SING @@ -125,7 +125,7 @@ Outline - + TR_SCREENMAIN_BUTTON_OPTIONS @@ -182,7 +182,7 @@ Outline - + TR_SCREENMAIN_BUTTON_PROFILES @@ -239,7 +239,7 @@ Outline - + TR_BUTTON_EXIT diff --git a/Output/Themes/Ambient/Screens/ScreenNames.xml b/Output/Themes/Ambient/Screens/ScreenNames.xml index c1ac532c..86d907e3 100644 --- a/Output/Themes/Ambient/Screens/ScreenNames.xml +++ b/Output/Themes/Ambient/Screens/ScreenNames.xml @@ -1,7 +1,7 @@  - 2 + 3 Video @@ -276,7 +276,7 @@ Outline - + TR_SCREENNAMES_MENU @@ -306,7 +306,7 @@ Outline - + @@ -336,7 +336,7 @@ Outline - + @@ -365,7 +365,7 @@ Outline - + @@ -394,7 +394,7 @@ Outline - + @@ -423,7 +423,7 @@ Outline - + @@ -452,7 +452,7 @@ Outline - + @@ -481,7 +481,7 @@ Outline - + @@ -510,7 +510,7 @@ Outline - + @@ -555,7 +555,7 @@ Outline - + TR_BUTTON_BACK @@ -612,7 +612,7 @@ Outline - + TR_BUTTON_START @@ -695,6 +695,396 @@ 6 + + + Invisible + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + 41 + 105 + -4,00 + 88 + 20 + + 20 + 105 + -4,01 + 20 + 20 + + 20 + 105 + -4,01 + 20 + 20 + + + SelectSlideColor + + + SelectSlideSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 20,00 + + 86,00 + + Outline + + Bold + + 1 + + + + Invisible + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + 41 + 260 + -4,00 + 88 + 20 + + 20 + 260 + -4,01 + 20 + 20 + + 20 + 260 + -4,01 + 20 + 20 + + + SelectSlideColor + + + SelectSlideSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 20,00 + + 86,00 + + Outline + + Bold + + 1 + + + + Invisible + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + 41 + 415 + -4,00 + 88 + 20 + + 20 + 415 + -4,01 + 20 + 20 + + 20 + 415 + -4,01 + 20 + 20 + + + SelectSlideColor + + + SelectSlideSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 20,00 + + 86,00 + + Outline + + Bold + + 1 + + + + Invisible + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + 1152 + 105 + -4,00 + 88 + 20 + + 1240 + 105 + -4,01 + 20 + 20 + + 1240 + 105 + -4,01 + 20 + 20 + + + SelectSlideColor + + + SelectSlideSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 20,00 + + 86,00 + + Outline + + Bold + + 1 + + + + Invisible + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + 1152 + 260 + -4,00 + 88 + 20 + + 1240 + 260 + -4,01 + 20 + 20 + + 1240 + 260 + -4,01 + 20 + 20 + + + SelectSlideColor + + + SelectSlideSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 20,00 + + 86,00 + + Outline + + Bold + + 1 + + + + Invisible + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + Button + + 1152 + 415 + -4,00 + 88 + 20 + + 1240 + 415 + -4,01 + 20 + 20 + + 1240 + 415 + -4,01 + 20 + 20 + + + SelectSlideColor + + + SelectSlideSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 20,00 + + 86,00 + + Outline + + Bold + + 1 + 172 @@ -738,5 +1128,167 @@ + + + Invisible + + 21 + 152 + -4,00 + 108 + 60 + + 8 + + 2,00 + + + + TR_CONFIG_OFF + + + Player1Dim2 + + + Player1Dim2 + + + + + + + Invisible + + 21 + 307 + -4,00 + 108 + 60 + + 8 + + 2,00 + + + + TR_CONFIG_OFF + + + Player2Dim2 + + + Player2Dim2 + + + + + + + Invisible + + 21 + 467 + -4,00 + 108 + 60 + + 8 + + 2,00 + + + + TR_CONFIG_OFF + + + Player3Dim2 + + + Player3Dim2 + + + + + + + Invisible + + 1153 + 152 + -4,00 + 108 + 60 + + 8 + + 2,00 + + + + TR_CONFIG_OFF + + + Player4Dim2 + + + Player4Dim2 + + + + + + + Invisible + + 1153 + 307 + -4,00 + 108 + 60 + + 8 + + 2,00 + + + + TR_CONFIG_OFF + + + Player5Dim2 + + + Player5Dim2 + + + + + + + Invisible + + 1153 + 467 + -4,00 + 108 + 60 + + 8 + + 2,00 + + + + TR_CONFIG_OFF + + + Player6Dim2 + + + Player6Dim2 + + + + \ No newline at end of file diff --git a/Output/Themes/Ambient/Screens/ScreenOptions.xml b/Output/Themes/Ambient/Screens/ScreenOptions.xml index 5ce06914..808f1d29 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptions.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptions.xml @@ -52,7 +52,7 @@ Outline - + TR_SCREENO_OPTIONS @@ -97,7 +97,7 @@ Outline - + TR_SCREENO_BUTTON_GAME @@ -154,7 +154,7 @@ Outline - + TR_SCRENNO_BUTTON_SOUND @@ -211,7 +211,7 @@ Outline - + TR_SCREENO_BUTTON_RECORD @@ -268,7 +268,7 @@ Outline - + TR_SCREENO_BUTTON_VIDEO @@ -325,7 +325,7 @@ Outline - + TR_SCREENO_BUTTON_LYRICS @@ -382,7 +382,7 @@ Outline - + TR_SCREENO_BUTTON_THEME diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsGame.xml b/Output/Themes/Ambient/Screens/ScreenOptionsGame.xml index 28e4b3d2..bdd2f750 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptionsGame.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptionsGame.xml @@ -148,7 +148,7 @@ Outline - + TR_SCREENOGAME_OPTIONS @@ -177,7 +177,7 @@ Outline - + TR_SCREENOGAME_LANGUAGE @@ -206,7 +206,7 @@ Outline - + TR_SCREENOGAME_DEBUGLEVEL @@ -235,7 +235,7 @@ Outline - + TR_SCREENOGAME_SONGMENU @@ -264,7 +264,7 @@ Outline - + TR_SCREENOGAME_SONGSORTING @@ -293,7 +293,7 @@ Outline - + TR_SCREENOGAME_TABS @@ -322,7 +322,7 @@ Outline - + TR_SCREENOGAME_TIMERMODE @@ -367,7 +367,7 @@ Outline - + TR_BUTTON_BACK diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml b/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml index 521fd578..d544a49f 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml @@ -52,7 +52,7 @@ Outline - + TR_SCREENOLYRICS_OPTIONS @@ -81,7 +81,7 @@ Outline - + TR_SCREENOLYRICS_STYLE @@ -110,7 +110,7 @@ Outline - + TR_SCREENOLYRICS_ONTOP @@ -155,7 +155,7 @@ Outline - + TR_BUTTON_BACK diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml b/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml index 1888fdc0..2100c33e 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml @@ -1,7 +1,7 @@  - 1 + 2 Video @@ -180,7 +180,7 @@ Outline - + TR_SCREENORECORD_OPTIONS @@ -209,7 +209,7 @@ Outline - + TR_SCREENORECORD_DEVICE @@ -238,7 +238,7 @@ Outline - + TR_SCREENORECORD_INPUT @@ -267,7 +267,7 @@ Outline - + TR_SCREENORECORD_CHANNEL_1 @@ -296,7 +296,7 @@ Outline - + TR_SCREENORECORD_CHANNEL_2 @@ -325,7 +325,7 @@ Outline - + TR_SCREENORECORD_MIC_DELAY @@ -355,7 +355,7 @@ Outline - + TR_SCREENORECORD_MIC_WARNING @@ -384,7 +384,7 @@ Outline - + @@ -413,7 +413,7 @@ Outline - + @@ -458,7 +458,7 @@ Outline - + TR_BUTTON_BACK @@ -515,7 +515,7 @@ Outline - + TR_SCREENORECORD_BUTTON_DELAYTEST @@ -858,5 +858,67 @@ 5 + + + Invisible + + 50 + 400 + -1,00 + 230 + 150 + + 10 + + 2,00 + + + + TR_CONFIG_OFF + + + ButtonColor + + + ButtonColor + + + + + 10 + 26 + + + + + Invisible + + 400 + 400 + -1,00 + 230 + 150 + + 10 + + 2,00 + + + + TR_CONFIG_OFF + + + ButtonColor + + + ButtonColor + + + + + 10 + 26 + + \ No newline at end of file diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml b/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml index 597e24f4..3f23d55c 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml @@ -52,7 +52,7 @@ Outline - + TR_SCREENOSOUND_OPTIONS @@ -81,7 +81,7 @@ Outline - + TR_SCREENOSOUND_BACKGROUNDMUSIC @@ -110,7 +110,7 @@ Outline - + TR_SCREENOSOUND_BACKGROUNDMUSICVOLUME @@ -139,7 +139,7 @@ Outline - + TR_SCREENOSOUND_BACKGROUNDMUSICSOURCE @@ -184,7 +184,7 @@ Outline - + TR_BUTTON_BACK diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml b/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml index fbb7f91c..15c6492b 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml @@ -180,7 +180,7 @@ Outline - + TR_SCREENOTHEME_OPTIONS @@ -209,7 +209,7 @@ Outline - + TR_SCREENOTHEME_THEME @@ -238,7 +238,7 @@ Outline - + TR_SCREENOTHEME_SKIN @@ -267,7 +267,7 @@ Outline - + TR_SCREENOTHEME_COVERTHEME @@ -296,7 +296,7 @@ Outline - + TR_SCREENOTHEME_NOTELINES @@ -325,7 +325,7 @@ Outline - + TR_SCREENOTHEME_TONEHELPER @@ -354,7 +354,7 @@ Outline - + TR_SCREENOTHEME_TIMERLOOK @@ -383,7 +383,7 @@ Outline - + TR_SCREENOTHEME_FADEINFO @@ -412,7 +412,7 @@ Outline - + TR_SCREENOTHEME_COVERLOADING @@ -457,7 +457,7 @@ Outline - + TR_BUTTON_BACK diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml b/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml index 35ec03ad..80d1ac13 100644 --- a/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml +++ b/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml @@ -100,7 +100,7 @@ Outline - + TR_SCREENOVIDEO_OPTIONS @@ -129,7 +129,7 @@ Outline - + TR_SCREENOVIDEO_VIDEOBACKGROUNDS @@ -158,7 +158,7 @@ Outline - + TR_SCREENOVIDEO_VIDEOPREVIEW @@ -187,7 +187,7 @@ Outline - + TR_SCREENOVIDEO_VIDEOINSONGS @@ -216,7 +216,7 @@ Normal - + TR_SCREENO_VIDEO_VIDEOSTOBACKGROUND @@ -319,7 +319,7 @@ Outline - + TR_BUTTON_BACK diff --git a/Output/Themes/Ambient/Screens/ScreenProfiles.xml b/Output/Themes/Ambient/Screens/ScreenProfiles.xml index 128a373b..7bd59c6b 100644 --- a/Output/Themes/Ambient/Screens/ScreenProfiles.xml +++ b/Output/Themes/Ambient/Screens/ScreenProfiles.xml @@ -148,7 +148,7 @@ Outline - + TR_SCREENPROFILES_PROFILES @@ -177,7 +177,7 @@ Outline - + TR_SCREENPROFILES_PLAYERNAME @@ -206,7 +206,7 @@ Outline - + TR_SCREENPROFILES_GAMEDIFFICULTY @@ -235,7 +235,7 @@ Outline - + TR_SCREENPROFILES_AVATAR @@ -264,7 +264,7 @@ Outline - + TR_SCREENPROFILES_GUESTPROFILE @@ -293,7 +293,7 @@ Outline - + TR_SCREENPROFILES_ACTIVE @@ -338,7 +338,7 @@ Outline - + @@ -387,7 +387,7 @@ Outline - + TR_BUTTON_BACK @@ -444,7 +444,7 @@ Outline - + TR_BUTTON_SAVE @@ -501,7 +501,7 @@ Outline - + TR_SCREENPROFILES_BUTTON_NEW @@ -558,7 +558,7 @@ Outline - + TR_SCREENPROFILES_BUTTON_DELETE diff --git a/Output/Themes/Ambient/Screens/ScreenScore.xml b/Output/Themes/Ambient/Screens/ScreenScore.xml index cccaaae3..814efcfe 100644 --- a/Output/Themes/Ambient/Screens/ScreenScore.xml +++ b/Output/Themes/Ambient/Screens/ScreenScore.xml @@ -1226,7 +1226,7 @@ Outline - + TR_SCREENSCORE_SCORES @@ -1255,7 +1255,7 @@ Outline - + @@ -1284,7 +1284,7 @@ Outline - + @@ -1313,7 +1313,7 @@ Outline - + @@ -1342,7 +1342,7 @@ Outline - + @@ -1371,7 +1371,7 @@ Outline - + @@ -1400,7 +1400,7 @@ Outline - + @@ -1429,7 +1429,7 @@ Outline - + @@ -1458,7 +1458,7 @@ Outline - + @@ -1487,7 +1487,7 @@ Outline - + @@ -1516,7 +1516,7 @@ Outline - + @@ -1545,7 +1545,7 @@ Outline - + @@ -1574,7 +1574,7 @@ Outline - + @@ -1603,7 +1603,7 @@ Outline - + @@ -1632,7 +1632,7 @@ Outline - + @@ -1661,7 +1661,7 @@ Outline - + @@ -1690,7 +1690,7 @@ Outline - + @@ -1719,7 +1719,7 @@ Outline - + @@ -1748,7 +1748,7 @@ Outline - + @@ -1777,7 +1777,7 @@ Outline - + @@ -1806,7 +1806,7 @@ Outline - + @@ -1835,7 +1835,7 @@ Outline - + @@ -1864,7 +1864,7 @@ Outline - + @@ -1893,7 +1893,7 @@ Outline - + @@ -1922,7 +1922,7 @@ Outline - + @@ -1951,7 +1951,7 @@ Outline - + @@ -1980,7 +1980,7 @@ Outline - + @@ -2009,7 +2009,7 @@ Outline - + @@ -2039,7 +2039,7 @@ Outline - + @@ -2068,7 +2068,7 @@ Outline - + @@ -2097,7 +2097,7 @@ Outline - + @@ -2126,7 +2126,7 @@ Outline - + @@ -2156,7 +2156,7 @@ Outline - + @@ -2185,7 +2185,7 @@ Outline - + @@ -2214,7 +2214,7 @@ Outline - + @@ -2243,7 +2243,7 @@ Outline - + @@ -2273,7 +2273,7 @@ Outline - + @@ -2302,7 +2302,7 @@ Outline - + @@ -2331,7 +2331,7 @@ Outline - + @@ -2360,7 +2360,7 @@ Outline - + @@ -2390,7 +2390,7 @@ Outline - + @@ -2419,7 +2419,7 @@ Outline - + @@ -2449,7 +2449,7 @@ Outline - + @@ -2479,7 +2479,7 @@ Outline - + @@ -2509,7 +2509,7 @@ Outline - + @@ -2539,7 +2539,7 @@ Outline - + @@ -2569,7 +2569,7 @@ Outline - + @@ -2599,7 +2599,7 @@ Outline - + @@ -2629,7 +2629,7 @@ Outline - + @@ -2659,7 +2659,7 @@ Outline - + @@ -2689,7 +2689,7 @@ Outline - + @@ -2719,7 +2719,7 @@ Outline - + @@ -2749,7 +2749,7 @@ Outline - + @@ -2779,7 +2779,7 @@ Outline - + @@ -2809,7 +2809,7 @@ Outline - + @@ -2839,7 +2839,7 @@ Outline - + @@ -2869,7 +2869,7 @@ Outline - + @@ -2899,7 +2899,7 @@ Outline - + @@ -2929,7 +2929,7 @@ Outline - + @@ -2959,7 +2959,7 @@ Outline - + @@ -2989,7 +2989,7 @@ Outline - + @@ -3019,7 +3019,7 @@ Outline - + @@ -3049,7 +3049,7 @@ Outline - + @@ -3079,7 +3079,7 @@ Outline - + @@ -3109,7 +3109,7 @@ Outline - + @@ -3139,7 +3139,7 @@ Outline - + @@ -3169,7 +3169,7 @@ Outline - + @@ -3199,7 +3199,7 @@ Outline - + @@ -3229,7 +3229,7 @@ Outline - + @@ -3259,7 +3259,7 @@ Outline - + @@ -3289,7 +3289,7 @@ Outline - + @@ -3319,7 +3319,7 @@ Outline - + @@ -3349,7 +3349,7 @@ Outline - + @@ -3379,7 +3379,7 @@ Outline - + @@ -3409,7 +3409,7 @@ Outline - + @@ -3439,7 +3439,7 @@ Outline - + @@ -3469,7 +3469,7 @@ Outline - + @@ -3499,7 +3499,7 @@ Outline - + @@ -3529,7 +3529,7 @@ Outline - + @@ -3559,7 +3559,7 @@ Outline - + @@ -3589,7 +3589,7 @@ Outline - + @@ -3619,7 +3619,7 @@ Outline - + @@ -3649,7 +3649,7 @@ Outline - + @@ -3679,7 +3679,7 @@ Outline - + @@ -3709,7 +3709,7 @@ Outline - + @@ -3739,7 +3739,7 @@ Outline - + diff --git a/Output/Themes/Ambient/Screens/ScreenSing.xml b/Output/Themes/Ambient/Screens/ScreenSing.xml index 4d33b2f0..21d12061 100644 --- a/Output/Themes/Ambient/Screens/ScreenSing.xml +++ b/Output/Themes/Ambient/Screens/ScreenSing.xml @@ -1,7 +1,7 @@  - 4 + 5 None @@ -982,7 +982,7 @@ Normal - + @@ -1011,7 +1011,7 @@ Normal - + @@ -1040,12 +1040,70 @@ Normal - + TR_SCREENSING_PAUSE + + + 40 + 80 + + -1,00 + + 35 + + + + TextSColor + + + TextSColor + + Left + + Center + + + + Outline + + + + + + + + + 40 + 585 + + -1,00 + + 35 + + + + TextSColor + + + TextSColor + + Left + + Center + + + + Outline + + + + + + 1240 @@ -1069,7 +1127,7 @@ Normal - + @@ -1101,7 +1159,7 @@ Outline - + @@ -1130,7 +1188,7 @@ Normal - + @@ -1162,7 +1220,7 @@ Outline - + @@ -1191,7 +1249,7 @@ Normal - + @@ -1223,7 +1281,7 @@ Outline - + @@ -1252,7 +1310,7 @@ Normal - + @@ -1284,7 +1342,7 @@ Outline - + @@ -1313,7 +1371,7 @@ Normal - + @@ -1345,7 +1403,7 @@ Outline - + @@ -1374,7 +1432,7 @@ Normal - + @@ -1406,7 +1464,7 @@ Outline - + @@ -1435,7 +1493,7 @@ Normal - + @@ -1467,7 +1525,7 @@ Outline - + @@ -1496,7 +1554,7 @@ Normal - + @@ -1528,7 +1586,7 @@ Outline - + @@ -1557,7 +1615,7 @@ Normal - + @@ -1589,7 +1647,7 @@ Outline - + @@ -1618,7 +1676,7 @@ Normal - + @@ -1650,7 +1708,7 @@ Outline - + @@ -1679,7 +1737,7 @@ Normal - + @@ -1711,7 +1769,7 @@ Outline - + @@ -1740,7 +1798,7 @@ Normal - + @@ -1772,7 +1830,7 @@ Outline - + @@ -1801,7 +1859,7 @@ Normal - + @@ -1833,7 +1891,7 @@ Outline - + @@ -1862,7 +1920,7 @@ Normal - + @@ -1894,7 +1952,7 @@ Outline - + @@ -1923,7 +1981,7 @@ Normal - + @@ -1955,7 +2013,7 @@ Outline - + @@ -1984,7 +2042,7 @@ Normal - + @@ -2016,7 +2074,7 @@ Outline - + @@ -2045,7 +2103,7 @@ Normal - + @@ -2077,7 +2135,7 @@ Outline - + @@ -2106,7 +2164,7 @@ Normal - + @@ -2138,7 +2196,7 @@ Outline - + @@ -2167,7 +2225,7 @@ Normal - + @@ -2199,7 +2257,7 @@ Outline - + @@ -2228,7 +2286,7 @@ Normal - + @@ -2260,7 +2318,7 @@ Outline - + @@ -2289,7 +2347,7 @@ Normal - + @@ -2321,7 +2379,7 @@ Outline - + @@ -2333,7 +2391,7 @@ Button - 670 + 775 300 -2,11 150 @@ -2366,7 +2424,7 @@ Outline - + TR_SCREENSING_BUTTON_CANCEL @@ -2390,7 +2448,7 @@ Button - 460 + 355 300 -2,11 150 @@ -2423,7 +2481,7 @@ Outline - + TR_SCREENSING_BUTTON_CONTINUE @@ -2441,6 +2499,63 @@ 26 + + + Button + + Button + + 565 + 300 + -2,11 + 150 + 50 + + + ButtonColor + + + ButtonSColor + + + 75 + 10 + + 32 + + 142 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSING_BUTTON_SKIP + + + + + + 10 + 26 + + + + + + 10 + 26 + + 637 diff --git a/Output/Themes/Ambient/Screens/ScreenSong.xml b/Output/Themes/Ambient/Screens/ScreenSong.xml index ad07bdd8..7cc7cfd0 100644 --- a/Output/Themes/Ambient/Screens/ScreenSong.xml +++ b/Output/Themes/Ambient/Screens/ScreenSong.xml @@ -1,7 +1,7 @@  - 1 + 3 Video @@ -53,6 +53,25 @@ 26 + + + SongMenuBG + + 40 + 40 + -2,10 + 360 + 360 + + + 1,00 + 1,00 + 1,00 + 1,00 + + + + 220 @@ -77,7 +96,7 @@ Outline - + @@ -111,7 +130,7 @@ Outline - + @@ -144,7 +163,7 @@ Outline - + TR_SCREENSONG_SEARCH @@ -173,12 +192,678 @@ Outline - + + + + 220 + 45 + + -2,11 + + 40 + + 350 + + + StaticColor + + + TextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_SONGOPTIONS + + + + + + + Button + + Button + + 40 + 360 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_CANCEL + + + + + + + + + + + Button + + Button + + 40 + 235 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_PLAYLIST + + + + + + + + + + + Button + + Button + + 40 + 90 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_SING + + + + + + + + + + + Button + + Button + + 40 + 90 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_RANDOM + + + + + + + + + + + Button + + Button + + 40 + 90 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_RANDOMCAT + + + + + + + + + + + Button + + Button + + 40 + 135 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_SINGALL + + + + + + + + + + + Button + + Button + + 40 + 180 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_SINGALLVISIBLE + + + + + + + + + + + Button + + Button + + 40 + 275 + -2,11 + 360 + 40 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + TR_SCREENSONG_BUTTON_OPENPLAYLIST + + + + + + + + + + + Invisible + + Invisible + + 40 + 40 + -1,01 + 360 + 360 + + + Invisible + + + Invisible + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + + + + + + + + + + + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + SelectSlide + + SelectSlideArrowLeft + + SelectSlideArrowRight + + SelectSlide + + 40 + 135 + -2,11 + 360 + 40 + + 45 + 140 + -2,12 + 30 + 30 + + 365 + 140 + -2,12 + 30 + 30 + + + ButtonColor + + + ButtonSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 30,00 + + 280,00 + + Outline + + Bold + + 1 + + + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + SelectSlide + + SelectSlideArrowLeft + + SelectSlideArrowRight + + SelectSlide + + 40 + 190 + -2,11 + 360 + 40 + + 45 + 195 + -2,12 + 30 + 30 + + 365 + 195 + -2,12 + 30 + 30 + + + ButtonColor + + + ButtonSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 30,00 + + 280,00 + + Outline + + Bold + + 1 + + + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + SelectSlide + + SelectSlideArrowLeft + + SelectSlideArrowRight + + SelectSlide + + 40 + 230 + -2,11 + 360 + 40 + + 45 + 235 + -2,12 + 30 + 30 + + 365 + 235 + -2,12 + 30 + 30 + + + ButtonColor + + + ButtonSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 30,00 + + 280,00 + + Outline + + Bold + + 1 + CoverTile @@ -188,12 +873,10 @@ DuetIcon VideoIcon - - 40 - 100 - -1,00 - 1200 - 530 + + MedleyCalcIcon + + MedleyTagIcon 1,00 @@ -210,12 +893,22 @@ 10,00 10,00 + + 4 + + 4 410 40 -1,00 830 550 + + 410 + 40 + -1,00 + 550 + 550 222 @@ -240,7 +933,7 @@ Outline - + @@ -270,7 +963,7 @@ Outline - + @@ -300,7 +993,7 @@ Outline - + @@ -370,7 +1063,450 @@ + + + MedleyCalcIcon + + 280 + 530 + -1,00 + 40 + 40 + + + StaticColor + + + + + + + MedleyTagIcon + + 280 + 530 + -1,00 + 40 + 40 + + + StaticColor + + + + + + + 970 + 80 + -0,90 + 295 + 460 + 50,00 + + CoverTile + + CoverTile + + + StaticColorAlpha + + + StaticColor + + + + + 54 + 4 + + -1,01 + + 24 + + 235 + + + StaticColor + + + TextSColor + + Left + + Top + + + + Outline + + + + + + + + + Menu + + 970 + 550 + -1,00 + 295 + 40 + + + StaticColor + + + + + + + Menu + + 970 + 40 + -1,00 + 295 + 40 + + + StaticColor + + + + + + + + + 4 + 2 + -1,00 + 46 + 46 + + + Visible + + + + + + + Button + + SelectSlideArrowLeft + + SelectSlideArrowRight + + + + SelectSlideArrowLeft + + SelectSlideArrowRight + + + + 0 + 28 + -1,01 + 293 + 24 + + 54 + 30 + -1,02 + 20 + 20 + + 271 + 30 + -1,02 + 20 + 20 + + + ButtonColor + + + ButtonSColor + + + SelectSlideHColor + + + ArrowColor + + + ArrowSColor + + + TextColor + + + TextSColor + + 24,00 + + 25,00 + + 230,00 + + Outline + + Bold + + 1 + + + + Invisible + + Invisible + + 975 + 45 + -1,01 + 220 + 30 + + + ButtonColor + + + ButtonSColor + + + 0 + 0 + + 30 + + 220 + + + ButtonTextColor + + + ButtonTextSColor + + Left + + Center + + + + Outline + + + + + + + + + + + + + CloseIcon + + CloseIcon + + 1215 + 42 + -1,01 + 35 + 35 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + + + + + + + + + + + + DeleteIcon + + DeleteIcon + + 1215 + 553 + -1,01 + 35 + 35 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + + + + + + + + + + + + SaveIcon + + SaveIcon + + 1175 + 553 + -1,01 + 35 + 35 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + + + + + + + + + + + + SingIcon + + SingIcon + + 975 + 553 + -1,01 + 35 + 35 + + + ButtonColor + + + ButtonSColor + + + 180 + 5 + + 30 + + 350 + + + ButtonTextColor + + + ButtonTextSColor + + Center + + Center + + + + Outline + + + + + + + + + + + - \ No newline at end of file + diff --git a/Output/Themes/Ambient/Sing.png b/Output/Themes/Ambient/Sing.png new file mode 100644 index 00000000..c7daf961 Binary files /dev/null and b/Output/Themes/Ambient/Sing.png differ diff --git a/Output/Themes/Ambient/Skin Blue.xml b/Output/Themes/Ambient/Skin Blue.xml index 88672814..7587328b 100644 --- a/Output/Themes/Ambient/Skin Blue.xml +++ b/Output/Themes/Ambient/Skin Blue.xml @@ -130,6 +130,12 @@ 0,969 1,000 + + 0,675 + 0,890 + 0,969 + 0,500 + 0,675 0,890 @@ -166,6 +172,12 @@ 0,969 1,000 + + 0,675 + 0,890 + 0,969 + 0,500 + 0,675 0,890 @@ -305,6 +317,10 @@ EnergyBeam.png DuetIcon.png VideoIcon.png + VideoIconCO.png + VideoIconBG.png + MedleyCalcIcon.png + MedleyTagIcon.png Invisible.png PlayerSelector.png PreviousIcon.png @@ -312,6 +328,11 @@ PlayIcon.png PauseIcon.png RepeatIcon.png + SongMenuBG.png + Close.png + Delete.png + Save.png + Sing.png [Blue]BG_Video.mp4 diff --git a/Output/Themes/Ambient/Skin Green.xml b/Output/Themes/Ambient/Skin Green.xml index fdea0b39..a5928d20 100644 --- a/Output/Themes/Ambient/Skin Green.xml +++ b/Output/Themes/Ambient/Skin Green.xml @@ -130,6 +130,12 @@ 0,674 1,000 + + 0,709 + 0,968 + 0,674 + 0,500 + 0,709 0,968 @@ -305,6 +311,10 @@ EnergyBeam.png DuetIcon.png VideoIcon.png + VideoIconCO.png + VideoIconBG.png + MedleyCalcIcon.png + MedleyTagIcon.png Invisible.png PlayerSelector.png PreviousIcon.png @@ -312,6 +322,11 @@ PlayIcon.png PauseIcon.png RepeatIcon.png + SongMenuBG.png + Close.png + Delete.png + Save.png + Sing.png [Green]BG_Video.mp4 diff --git a/Output/Themes/Ambient/Skin Red.xml b/Output/Themes/Ambient/Skin Red.xml index d5c901d8..fd09e46c 100644 --- a/Output/Themes/Ambient/Skin Red.xml +++ b/Output/Themes/Ambient/Skin Red.xml @@ -130,6 +130,12 @@ 0,674 1,000 + + 0,968 + 0,674 + 0,674 + 0,500 + 0,968 0,674 @@ -305,6 +311,10 @@ EnergyBeam.png DuetIcon.png VideoIcon.png + VideoIconCO.png + VideoIconBG.png + MedleyCalcIcon.png + MedleyTagIcon.png Invisible.png PlayerSelector.png PreviousIcon.png @@ -312,6 +322,11 @@ PlayIcon.png PauseIcon.png RepeatIcon.png + SongMenuBG.png + Close.png + Delete.png + Save.png + Sing.png [Red]BG_Video.mp4 diff --git a/Output/Themes/Ambient/Skin Yellow.xml b/Output/Themes/Ambient/Skin Yellow.xml index 2b118ea7..83fab332 100644 --- a/Output/Themes/Ambient/Skin Yellow.xml +++ b/Output/Themes/Ambient/Skin Yellow.xml @@ -130,6 +130,12 @@ 0,674 1,000 + + 0,968 + 0,956 + 0,674 + 0,500 + 0,968 0,956 @@ -305,6 +311,10 @@ EnergyBeam.png DuetIcon.png VideoIcon.png + VideoIconCO.png + VideoIconBG.png + MedleyCalcIcon.png + MedleyTagIcon.png Invisible.png PlayerSelector.png PreviousIcon.png @@ -312,6 +322,11 @@ PlayIcon.png PauseIcon.png RepeatIcon.png + SongMenuBG.png + Close.png + Delete.png + Save.png + Sing.png [Yellow]BG_Video.mp4 diff --git a/Output/Themes/Ambient/SongMenuBG.png b/Output/Themes/Ambient/SongMenuBG.png new file mode 100644 index 00000000..a7333adb Binary files /dev/null and b/Output/Themes/Ambient/SongMenuBG.png differ diff --git a/Output/Themes/Ambient/VideoIconBG.png b/Output/Themes/Ambient/VideoIconBG.png new file mode 100644 index 00000000..ff0950fe Binary files /dev/null and b/Output/Themes/Ambient/VideoIconBG.png differ diff --git a/Output/Themes/Ambient/VideoIconCO.png b/Output/Themes/Ambient/VideoIconCO.png new file mode 100644 index 00000000..3c76dd30 Binary files /dev/null and b/Output/Themes/Ambient/VideoIconCO.png differ diff --git a/Output/Themes/Changelog/Changelog_ScreenNames.txt b/Output/Themes/Changelog/Changelog_ScreenNames.txt index 47d04016..221c9331 100644 --- a/Output/Themes/Changelog/Changelog_ScreenNames.txt +++ b/Output/Themes/Changelog/Changelog_ScreenNames.txt @@ -1,5 +1,11 @@ SceenNames +++++++++++ +Version 3: + + (One Equalizer for each player): Equalizer shows input from assigned mic for this player. + (One SelectSlide for each player) + ++++++++++ Version 2: diff --git a/Output/Themes/Changelog/Changelog_ScreenOptionsRecord.txt b/Output/Themes/Changelog/Changelog_ScreenOptionsRecord.txt new file mode 100644 index 00000000..89d9465c --- /dev/null +++ b/Output/Themes/Changelog/Changelog_ScreenOptionsRecord.txt @@ -0,0 +1,9 @@ +ScreenOptionsRecord + +++++++++++ +Version 2: + +Add: + and . +This is a new theme-element. Check ScreenOptionsRecord.xml for style-possibilities. +++++++++++ \ No newline at end of file diff --git a/Output/Themes/Changelog/Changelog_ScreenSing.txt b/Output/Themes/Changelog/Changelog_ScreenSing.txt index 22c5fa99..9027a30c 100644 --- a/Output/Themes/Changelog/Changelog_ScreenSing.txt +++ b/Output/Themes/Changelog/Changelog_ScreenSing.txt @@ -1,5 +1,17 @@ ScreenSing ++++++++++ +Version 5 + +Add: + and (only showed when sining duet) + +++++++++++ +Version 5: + +Add: + + ++++++++++ Version 4: Added Elements for 6-player-singing! diff --git a/Output/Themes/Changelog/Changelog_ScreenSong.txt b/Output/Themes/Changelog/Changelog_ScreenSong.txt new file mode 100644 index 00000000..7d2e320c --- /dev/null +++ b/Output/Themes/Changelog/Changelog_ScreenSong.txt @@ -0,0 +1,24 @@ +ScreenSong + +++++++++++ +Version 3: + +Add: + + +, , , , , , , , +, , +and + as a new Screen-Element. For details, look at ScreenSong.xml + +++++++++++ +Version 2: + +Add: + and +to SongMenu + +Add: + and +to SongMenu.SongMenuTileBoard +++++++++++ \ No newline at end of file diff --git a/Output/x86/acinerella.dll b/Output/x86/acinerella.dll index 77b069fa..a39e3501 100644 Binary files a/Output/x86/acinerella.dll and b/Output/x86/acinerella.dll differ diff --git a/Output/x86/avcodec-54.dll b/Output/x86/avcodec-54.dll index 80a08d0a..97d7f850 100644 Binary files a/Output/x86/avcodec-54.dll and b/Output/x86/avcodec-54.dll differ diff --git a/Output/x86/avformat-54.dll b/Output/x86/avformat-54.dll index 2d250708..7328c561 100644 Binary files a/Output/x86/avformat-54.dll and b/Output/x86/avformat-54.dll differ diff --git a/Output/x86/avutil-51.dll b/Output/x86/avutil-51.dll index a51a719c..5ab61687 100644 Binary files a/Output/x86/avutil-51.dll and b/Output/x86/avutil-51.dll differ diff --git a/Output/x86/swscale-2.dll b/Output/x86/swscale-2.dll index 3a58f3a0..afa902a0 100644 Binary files a/Output/x86/swscale-2.dll and b/Output/x86/swscale-2.dll differ diff --git a/Vocaluxe/Base/CBackgroundMusic.cs b/Vocaluxe/Base/CBackgroundMusic.cs index e475081c..fb3ea35c 100644 --- a/Vocaluxe/Base/CBackgroundMusic.cs +++ b/Vocaluxe/Base/CBackgroundMusic.cs @@ -34,6 +34,7 @@ namespace Vocaluxe.Base private static bool _Playing; private static bool _Disabled; private static bool _CanSing; + private static bool _RepeatSong; public static bool VideoEnabled { @@ -84,6 +85,18 @@ namespace Vocaluxe.Base } } + public static bool RepeatSong + { + get + { + return _RepeatSong; + } + set + { + _RepeatSong = value; + } + } + public static int SongID { get @@ -120,7 +133,10 @@ namespace Vocaluxe.Base { get { - return _CurrentPlaylistElement.Artist + " - " + _CurrentPlaylistElement.Title; + if (_CurrentPlaylistElement.Artist != "" && _CurrentPlaylistElement.Title != "") + return _CurrentPlaylistElement.Artist + " - " + _CurrentPlaylistElement.Title; + else + return Path.GetFileNameWithoutExtension(_CurrentPlaylistElement.MusicFilePath); } } @@ -165,7 +181,7 @@ namespace Vocaluxe.Base { if (_CurrentMusicStream != -1) { - CSound.Fade(_CurrentMusicStream, CConfig.BackgroundMusicVolume, CSettings.BackgroundMusicFadeTime); + CSound.Fade(_CurrentMusicStream, 100f, CSettings.BackgroundMusicFadeTime); CSound.Play(_CurrentMusicStream); if (_VideoEnabled && _Video != -1) CVideo.VdResume(_Video); @@ -217,10 +233,22 @@ namespace Vocaluxe.Base { if (_AllFileNames.Count > 0 && _CurrentMusicStream != -1) { - float timeToPlay = CSound.GetLength(_CurrentMusicStream) - CSound.GetPosition(_CurrentMusicStream); + float timeToPlay; + if(_CurrentPlaylistElement.Finish == 0f) //No End-Tag defined + timeToPlay = CSound.GetLength(_CurrentMusicStream) - CSound.GetPosition(_CurrentMusicStream); + else //End-Tag found + timeToPlay = _CurrentPlaylistElement.Finish - CSound.GetPosition(_CurrentMusicStream); + bool finished = CSound.IsFinished(_CurrentMusicStream); if (_Playing && (timeToPlay <= CSettings.BackgroundMusicFadeTime || finished)) - Next(); + if (_RepeatSong) + { + CSound.SetPosition(_CurrentMusicStream, 0); + if (_VideoEnabled && _Video != -1) + CVideo.VdSkip(_Video, 0f, _CurrentPlaylistElement.VideoGap); + } + else + Next(); } } @@ -248,6 +276,12 @@ namespace Vocaluxe.Base _CurrentPlaylistElement = _PreviousFileNames[_PreviousMusicIndex]; } _CurrentMusicStream = CSound.Load(_CurrentPlaylistElement.MusicFilePath); + CSound.SetStreamVolumeMax(_CurrentMusicStream, CConfig.BackgroundMusicVolume); + + //Seek to #Start-Tag, if found + if (_CurrentPlaylistElement.Start != 0f) + CSound.SetPosition(_CurrentMusicStream, _CurrentPlaylistElement.Start); + if (_VideoEnabled) LoadVideo(); CSound.SetStreamVolume(_CurrentMusicStream, 0f); @@ -261,25 +295,31 @@ namespace Vocaluxe.Base { if (_PreviousFileNames.Count > 0 || _PreviousMusicIndex >= 0) { - Stop(); + float pos = CSound.GetPosition(_CurrentMusicStream); + if (CSound.GetPosition(_CurrentMusicStream) >= 1.5f) + { + CSound.SetPosition(_CurrentMusicStream, 0); + if (_VideoEnabled && _Video != -1) + CVideo.VdSkip(_Video, 0f, _CurrentPlaylistElement.VideoGap); + } + else + { + Stop(); + _PreviousMusicIndex--; + if (_PreviousMusicIndex < 0) + _PreviousMusicIndex = 0; //No previous songs left, so play the first - _PreviousMusicIndex--; - if (_PreviousMusicIndex < 0) - _PreviousMusicIndex = 0; //No previous songs left, so play the first + _CurrentPlaylistElement = _PreviousFileNames[_PreviousMusicIndex]; - _CurrentPlaylistElement = _PreviousFileNames[_PreviousMusicIndex]; - - _CurrentMusicStream = CSound.Load(_CurrentPlaylistElement.MusicFilePath); - if (_VideoEnabled) - LoadVideo(); - CSound.SetStreamVolume(_CurrentMusicStream, 0f); - Play(); + _CurrentMusicStream = CSound.Load(_CurrentPlaylistElement.MusicFilePath); + CSound.SetStreamVolumeMax(_CurrentMusicStream, CConfig.BackgroundMusicVolume); + if (_VideoEnabled) + LoadVideo(); + CSound.SetStreamVolume(_CurrentMusicStream, 0f); + Play(); + } } - } - - public static void Repeat() - { - if (_AllFileNames.Count > 0 && _CurrentMusicStream != -1) + else if (_CurrentMusicStream != -1) { CSound.SetPosition(_CurrentMusicStream, 0); if (_VideoEnabled && _Video != -1) @@ -289,7 +329,7 @@ namespace Vocaluxe.Base public static void ApplyVolume() { - CSound.SetStreamVolume(_CurrentMusicStream, CConfig.BackgroundMusicVolume); + CSound.SetStreamVolumeMax(_CurrentMusicStream, CConfig.BackgroundMusicVolume); } public static void AddOwnMusic() @@ -509,7 +549,7 @@ class PlaylistElement if (_Song != null) return _Song.Title; - return "Unknown"; + return ""; } } @@ -520,7 +560,29 @@ class PlaylistElement if (_Song != null) return _Song.Artist; - return "Unknown"; + return ""; + } + } + + public float Start + { + get + { + if (_Song != null) + return _Song.Start; + + return 0f; + } + } + + public float Finish + { + get + { + if (_Song != null) + return _Song.Finish; + + return 0f; } } diff --git a/Vocaluxe/Base/CConfig.cs b/Vocaluxe/Base/CConfig.cs index 35dbb5a6..c87efd6f 100644 --- a/Vocaluxe/Base/CConfig.cs +++ b/Vocaluxe/Base/CConfig.cs @@ -960,6 +960,11 @@ namespace Vocaluxe.Base CSettings.sFileHighscoreDB = value; } break; + + case "playlistfolder": + CSettings.CreateFolder(value); + CSettings.sFolderPlaylists = value; + break; } } } diff --git a/Vocaluxe/Base/CDraw.cs b/Vocaluxe/Base/CDraw.cs index d1743b0a..e468162e 100644 --- a/Vocaluxe/Base/CDraw.cs +++ b/Vocaluxe/Base/CDraw.cs @@ -117,6 +117,11 @@ namespace Vocaluxe.Base _Draw.DrawColor(color, rect); } + public static void DrawColorReflection(SColorF color, SRectF rect, float space, float height) + { + _Draw.DrawColorReflection(color, rect, space, height); + } + public static void ClearScreen() { _Draw.ClearScreen(); diff --git a/Vocaluxe/Base/CFont.cs b/Vocaluxe/Base/CFont.cs index 97fcd8a4..1349f672 100644 --- a/Vocaluxe/Base/CFont.cs +++ b/Vocaluxe/Base/CFont.cs @@ -40,13 +40,20 @@ namespace Vocaluxe.Base class CGlyph { - public readonly float SIZEh = 50f; + private float _SIZEh = 50f; + public float SIZEh + { + get { return _SIZEh; } + } + public STexture Texture; public char Chr; public int width; - public CGlyph(char chr) + public CGlyph(char chr, float MaxHigh) { + _SIZEh = MaxHigh; + float outline = CFonts.Outline; TextFormatFlags flags = TextFormatFlags.NoPadding | TextFormatFlags.NoPrefix; @@ -152,7 +159,8 @@ namespace Vocaluxe.Base private Hashtable _htGlyphs; private PrivateFontCollection fonts; private FontFamily family; - + private float SIZEh; + public string FilePath; @@ -181,6 +189,28 @@ namespace Vocaluxe.Base _Glyphs = new List(); _htGlyphs = new Hashtable(); + + switch (CConfig.TextureQuality) + { + case ETextureQuality.TR_CONFIG_TEXTURE_LOWEST: + SIZEh = 25f; + break; + case ETextureQuality.TR_CONFIG_TEXTURE_LOW: + SIZEh = 50f; + break; + case ETextureQuality.TR_CONFIG_TEXTURE_MEDIUM: + SIZEh = 100f; + break; + case ETextureQuality.TR_CONFIG_TEXTURE_HIGH: + SIZEh = 200f; + break; + case ETextureQuality.TR_CONFIG_TEXTURE_HIGHEST: + SIZEh = 400f; + break; + default: + SIZEh = 100f; + break; + } } public void DrawGlyph(char chr, float x, float y, float h, float z, SColorF color) @@ -243,7 +273,7 @@ namespace Vocaluxe.Base return; float h = CFonts.Height; - _Glyphs.Add(new CGlyph(chr)); + _Glyphs.Add(new CGlyph(chr, SIZEh)); _htGlyphs.Add(chr, _Glyphs.Count - 1); CFonts.Height = h; } @@ -803,10 +833,10 @@ namespace Vocaluxe.Base writer.WriteElementString("Folder", _Fonts[Index].Folder); writer.WriteElementString("Outline", _Fonts[Index].Outline.ToString("#0.00")); - writer.WriteElementString("ColorR", _Fonts[Index].OutlineColor.R.ToString("#0.00")); - writer.WriteElementString("ColorG", _Fonts[Index].OutlineColor.G.ToString("#0.00")); - writer.WriteElementString("ColorB", _Fonts[Index].OutlineColor.B.ToString("#0.00")); - writer.WriteElementString("ColorA", _Fonts[Index].OutlineColor.A.ToString("#0.00")); + writer.WriteElementString("OutlineColorR", _Fonts[Index].OutlineColor.R.ToString("#0.00")); + writer.WriteElementString("OutlineColorG", _Fonts[Index].OutlineColor.G.ToString("#0.00")); + writer.WriteElementString("OutlineColorB", _Fonts[Index].OutlineColor.B.ToString("#0.00")); + writer.WriteElementString("OutlineColorA", _Fonts[Index].OutlineColor.A.ToString("#0.00")); writer.WriteElementString("FileNormal", _Fonts[Index].FileNormal); writer.WriteElementString("FileBold", _Fonts[Index].FileBold); diff --git a/Vocaluxe/Base/CGame.cs b/Vocaluxe/Base/CGame.cs index 7b58e227..a6323536 100644 --- a/Vocaluxe/Base/CGame.cs +++ b/Vocaluxe/Base/CGame.cs @@ -27,6 +27,7 @@ namespace Vocaluxe.Base public int SongID; public bool Medley; public bool Duet; + public bool ShortSong; public long DateTicks; public bool SongFinished; } @@ -179,6 +180,11 @@ namespace Vocaluxe.Base return _GameMode.GetSong(Num); } + public static EGameMode GetGameMode(int Num) + { + return _GameMode.GetGameMode(Num); + } + public static int GetNumSongs() { return _GameMode.GetNumSongs(); @@ -189,6 +195,11 @@ namespace Vocaluxe.Base return _GameMode.GetPoints(); } + public static int NumRounds + { + get { return _GameMode.GetNumSongs(); } + } + public static int NumPlayer { get { return _NumPlayer; } @@ -214,6 +225,7 @@ namespace Vocaluxe.Base _Player[i].SongID = -1; _Player[i].Medley = false; _Player[i].Duet = false; + _Player[i].ShortSong = false; _Player[i].DateTicks = DateTime.Now.Ticks; _Player[i].SongFinished = false; } diff --git a/Vocaluxe/Base/CPlaylists.cs b/Vocaluxe/Base/CPlaylists.cs new file mode 100644 index 00000000..c9babd16 --- /dev/null +++ b/Vocaluxe/Base/CPlaylists.cs @@ -0,0 +1,109 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Lib.Song; +using Vocaluxe.Lib.Playlist; + +namespace Vocaluxe.Base +{ + + static class CPlaylists + { + private static List _Playlists; + private static CHelper Helper = new CHelper(); + + public static CPlaylistFile[] Playlists + { + get { return _Playlists.ToArray(); } + } + + public static string[] PlaylistNames + { + get + { + List names = new List(); + for (int i = 0; i < _Playlists.Count; i++) + { + names.Add(_Playlists[i].PlaylistName); + } + return names.ToArray(); + } + } + + public static int NumPlaylists + { + get { return _Playlists.Count; } + } + + public static void Init() + { + LoadPlaylists(); + } + + public static void LoadPlaylists() + { + _Playlists = new List(); + List files = new List(); + files.AddRange(Helper.ListFiles(CSettings.sFolderPlaylists, "*.xml", true, true)); + + foreach (string file in files) + { + CPlaylistFile playlist = new CPlaylistFile(file); + _Playlists.Add(playlist); + } + + SortPlaylistsByName(); + } + + #region private methods + + private static void SortPlaylistsByName() + { + _Playlists.Sort(CompareByPlaylistName); + } + + private static int CompareByPlaylistName(CPlaylistFile a, CPlaylistFile b) + { + return String.Compare(a.PlaylistName, b.PlaylistName); + } + + public static void DeletePlaylist(int PlaylistID) + { + if (PlaylistID < 0 || PlaylistID >= _Playlists.Count) + return; + if (_Playlists[PlaylistID].PlaylistFile != String.Empty) + { + try + { + File.Delete(_Playlists[PlaylistID].PlaylistFile); + _Playlists.RemoveAt(PlaylistID); + } + catch (Exception) + { + CLog.LogError("Can't delete Profile File " + _Playlists[PlaylistID].PlaylistFile + ".xml"); + } + } + } + + public static void SavePlaylist(int PlaylistID) + { + if (PlaylistID < 0 || PlaylistID >= _Playlists.Count) + return; + _Playlists[PlaylistID].SavePlaylist(); + } + + public static int NewPlaylist() + { + CPlaylistFile pl = new CPlaylistFile(); + pl.PlaylistName = "New Playlist"; + _Playlists.Add(pl); + return (_Playlists.Count - 1); + } + + #endregion + } +} diff --git a/Vocaluxe/Base/CSettings.cs b/Vocaluxe/Base/CSettings.cs index 7b12f5e4..c222613c 100644 --- a/Vocaluxe/Base/CSettings.cs +++ b/Vocaluxe/Base/CSettings.cs @@ -47,7 +47,7 @@ namespace Vocaluxe.Base public const int iVersionSub = 0; // patches public const ERevision VersionRevision = ERevision.Alpha; - public const int iBuild = 67; // Increase on every published version! Never Reset! + public const int iBuild = 69; // Increase on every published version! Never Reset! public const int iDatabaseHighscoreVersion = 1; public const int iDatabaseCoverVersion = 1; @@ -94,6 +94,7 @@ namespace Vocaluxe.Base public const string sFolderLanguages = "Languages"; public const string sFolderScreenshots = "Screenshots"; public const string sFolderBackgroundMusic = "BackgroundMusic"; + public static string sFolderPlaylists = "Playlists"; //public const String[] ToneStrings = new String[]{ "C", "C#", "D", "D#", "E", "F", "F#", "G", "G#", "A", "A#", "B" }; public const int ToneMin = -36; @@ -112,6 +113,11 @@ namespace Vocaluxe.Base public const float LyricHelperMoveTime = 1.5f; public const float LyricHelperMinTime = 0.2f; + public const float DefaultMedleyFadeInTime = 8f; + public const float DefaultMedleyFadeOutTime = 2f; + public const int MedleyMinSeriesLength = 3; + public const float MedleyMinDuration = 40f; + public static bool TabNavigation = false; public const float BackgroundMusicFadeTime = 0.5f; @@ -158,7 +164,7 @@ namespace Vocaluxe.Base return (float)iRenderW / (float)iRenderH; } - public static void MouseInacive() + public static void MouseInactive() { MouseMoveDiffMin = 15; } @@ -179,6 +185,7 @@ namespace Vocaluxe.Base Folders.Add(sFolderScreenshots); Folders.Add(sFolderBackgroundMusic); Folders.Add(sFolderSounds); + Folders.Add(sFolderPlaylists); foreach (string folder in Folders) { @@ -187,5 +194,11 @@ namespace Vocaluxe.Base Directory.CreateDirectory(path); } } + + public static void CreateFolder(string path) + { + if (!Directory.Exists(path)) + Directory.CreateDirectory(path); + } } } diff --git a/Vocaluxe/Base/CSongs.cs b/Vocaluxe/Base/CSongs.cs index cc33b1ed..147e1c01 100644 --- a/Vocaluxe/Base/CSongs.cs +++ b/Vocaluxe/Base/CSongs.cs @@ -56,6 +56,7 @@ namespace Vocaluxe.Base private static int _CoverLoadIndex = -1; private static int _CatIndex = -1; private static List _Categories = new List(); + private static List _CategoriesForRandom = new List(); private static Stopwatch _CoverLoadTimer = new Stopwatch(); @@ -275,6 +276,35 @@ namespace Vocaluxe.Base _SongsForRandom.AddRange(VisibleSongs); } + public static int GetRandomCategory() + { + if (_CategoriesForRandom.Count == 0) + UpdateRandomCategoryList(); + + if (_CategoriesForRandom.Count == 0) + return -1; + + CCategory category = _CategoriesForRandom[CGame.Rand.Next(0, _CategoriesForRandom.Count - 1)]; + _CategoriesForRandom.Remove(category); + return GetCategoryNumber(category); + } + + public static void UpdateRandomCategoryList() + { + _CategoriesForRandom.Clear(); + _CategoriesForRandom.AddRange(Categories); + } + + private static int GetCategoryNumber(CCategory category) + { + for (int i = 0; i < Categories.Length; i++) + { + if (Categories[i] == category) + return i; + } + return -1; + } + public static CSong[] AllSongs { get { return _Songs.ToArray(); } diff --git a/Vocaluxe/Base/CSound.cs b/Vocaluxe/Base/CSound.cs index 85112fd3..7f6414d4 100644 --- a/Vocaluxe/Base/CSound.cs +++ b/Vocaluxe/Base/CSound.cs @@ -108,6 +108,10 @@ namespace Vocaluxe.Base _Playback.SetStreamVolume(Stream, Volume); } + public static void SetStreamVolumeMax(int Stream, float Volume) + { + _Playback.SetStreamVolumeMax(Stream, Volume); + } public static float GetLength(int Stream) { @@ -315,6 +319,10 @@ namespace Vocaluxe.Base public CBuffer() { _ToneWeigth = new float[_NumHalfTones]; + for (int i = 0; i < _ToneWeigth.Length; i++) + { + _ToneWeigth[i] = 0.99f; + } _Stream = new MemoryStream(); _NewSamples = false; } diff --git a/Vocaluxe/Base/CUtility.cs b/Vocaluxe/Base/CUtility.cs index bfd28130..4eca0857 100644 --- a/Vocaluxe/Base/CUtility.cs +++ b/Vocaluxe/Base/CUtility.cs @@ -68,6 +68,7 @@ namespace Vocaluxe.Base public int X; public int Y; public bool LB; //left button click + public bool LD; //left button double click public bool RB; //right button click public bool MB; //middle button click @@ -82,11 +83,12 @@ namespace Vocaluxe.Base public Modifier Mod; public int Wheel; - public MouseEvent(bool alt, bool shift, bool ctrl, int x, int y, bool lb, bool rb, int wheel, bool lbh, bool rbh, bool mb, bool mbh) + public MouseEvent(bool alt, bool shift, bool ctrl, int x, int y, bool lb, bool ld, bool rb, int wheel, bool lbh, bool rbh, bool mb, bool mbh) { X = x; Y = y; LB = lb; + LD = ld; RB = rb; MB = mb; @@ -327,6 +329,8 @@ namespace Vocaluxe.Base private bool _ModCTRL; private bool _ModSHIFT; + private System.Diagnostics.Stopwatch _timer; + public int X { get { return _x; } @@ -347,13 +351,16 @@ namespace Vocaluxe.Base _EventsPool = new List(); _CurrentPool = new List(); + + _timer = new System.Diagnostics.Stopwatch(); } - private void Add(bool alt, bool shift, bool ctrl, int x, int y, bool lb, bool rb, int wheel, bool lbh, bool rbh, bool mb, bool mbh) + private void Add(bool alt, bool shift, bool ctrl, int x, int y, bool lb, bool ld, bool rb, int wheel, bool lbh, bool rbh, bool mb, bool mbh) { x = (int)((float)x * (float)CSettings.iRenderW / (float)CDraw.GetScreenWidth()); y = (int)((float)y * (float)CSettings.iRenderH / (float)CDraw.GetScreenHeight()); - MouseEvent pool = new MouseEvent(alt, shift, ctrl, x, y, lb, rb, -wheel/120, lbh, rbh, mb, mbh); + + MouseEvent pool = new MouseEvent(alt, shift, ctrl, x, y, lb, ld, rb, -wheel / 120, lbh, rbh, mb, mbh); lock (_CopyLock) { @@ -380,21 +387,42 @@ namespace Vocaluxe.Base public void MouseMove(MouseEventArgs e) { CheckModifiers(); - Add(_ModALT, _ModSHIFT, _ModCTRL, e.X, e.Y, false, false, e.Delta, e.Button == MouseButtons.Left, e.Button == MouseButtons.Right, + Add(_ModALT, _ModSHIFT, _ModCTRL, e.X, e.Y, false, false, false, e.Delta, e.Button == MouseButtons.Left, e.Button == MouseButtons.Right, false, e.Button == MouseButtons.Middle); } public void MouseWheel(MouseEventArgs e) { CheckModifiers(); - Add(_ModALT, _ModSHIFT, _ModCTRL, e.X, e.Y, false, false, e.Delta, e.Button == MouseButtons.Left, e.Button == MouseButtons.Right, + Add(_ModALT, _ModSHIFT, _ModCTRL, e.X, e.Y, false, false, false, e.Delta, e.Button == MouseButtons.Left, e.Button == MouseButtons.Right, false, e.Button == MouseButtons.Middle); } public void MouseDown(MouseEventArgs e) { CheckModifiers(); - Add(_ModALT, _ModSHIFT, _ModCTRL, e.X, e.Y, e.Button == MouseButtons.Left, e.Button == MouseButtons.Right, e.Delta, false, false, + + bool lb = e.Button == MouseButtons.Left; + bool ld = false; + if (lb) + { + if (_timer.IsRunning && _timer.ElapsedMilliseconds < 450) + { + ld = true; + _timer.Reset(); + } + else + { + _timer.Reset(); + _timer.Start(); + } + } + else + { + _timer.Reset(); + } + + Add(_ModALT, _ModSHIFT, _ModCTRL, e.X, e.Y, lb, ld, e.Button == MouseButtons.Right, e.Delta, false, false, e.Button == MouseButtons.Middle, false); } diff --git a/Vocaluxe/Doc/Roadmap.txt b/Vocaluxe/Doc/Roadmap.txt index 5cbb31b5..7a73c9ed 100644 --- a/Vocaluxe/Doc/Roadmap.txt +++ b/Vocaluxe/Doc/Roadmap.txt @@ -71,31 +71,34 @@ - PortAudio Record and Playback ------------------------------------------------------------- -+ v0.1.0: ++ v0.1.0 (reached: 07.04.2012): - Menu Background Music + - Jukebox light (bg music controls) - Theme System Update - A nicer Theme! + v0.2.0: - Medley - - WiiMote Support - - Jukebox light (bg music controls) - - Show Avatars and Player Name in Sing Screen (and perhaps some other screens) + - Sing Short Version Mode + - Show Avatars and Player Name in Sing Screen - New Lyric Effects + - More Player at once (up to 6) + - Duet (full support, choose/toggle names) + - Playlist-Support + - Spectrum Analyzer (Record Screen and Player Selection Screen) ----------------- just some ideas: + - WiiMote Support - Installer - More Song List Views - Tile Board: Show title and artist under each tile - OnScreen Keyboard? - Kinect Support? - Help System - - Party Mode: Casting Show - - More Player at once - - Mark newly added songs - - Playlist-Support + - Party Mode: Casting Show + - Mark newly added songs - Theme Editor - Jukebox - Tournament Mode @@ -103,5 +106,4 @@ just some ideas: - Party Mode: Tic, Tac, Toe - Party Mode: 4 in a row - Challenge Mode (with more than 2 player at once) - - Song Editor - - Duet (full support, choose/toggle names) \ No newline at end of file + - Song Editor \ No newline at end of file diff --git a/Vocaluxe/GameModes/CGameMode.cs b/Vocaluxe/GameModes/CGameMode.cs index aa3304f3..b58ca133 100644 --- a/Vocaluxe/GameModes/CGameMode.cs +++ b/Vocaluxe/GameModes/CGameMode.cs @@ -39,12 +39,13 @@ namespace Vocaluxe.GameModes _Rounds[round, player].PointsLineBonus = 0f; _Rounds[round, player].Medley = false; _Rounds[round, player].Duet = false; + _Rounds[round, player].ShortSong = false; _Rounds[round, player].SongFinished = false; } } } - public void SetPoints(int Round, int SongID, SPlayer[] Player, bool Medley, bool Duet) + public void SetPoints(int Round, int SongID, SPlayer[] Player, bool Medley, bool Duet, bool ShortSong) { long DateTicks = DateTime.Now.Ticks; for (int player = 0; player < Player.Length; player++) @@ -56,6 +57,7 @@ namespace Vocaluxe.GameModes _Rounds[Round, player].PointsLineBonus = Player[player].PointsLineBonus; _Rounds[Round, player].Medley = Medley; _Rounds[Round, player].Duet = Duet; + _Rounds[Round, player].ShortSong = ShortSong; _Rounds[Round, player].DateTicks = DateTicks; _Rounds[Round, player].SongFinished = Player[player].SongFinished; } @@ -91,6 +93,7 @@ namespace Vocaluxe.GameModes player[p].Difficulty = _Rounds[Round, p].Difficulty; player[p].Medley = _Rounds[Round, p].Medley; player[p].Duet = _Rounds[Round, p].Duet; + player[p].ShortSong = _Rounds[Round, p].ShortSong; player[p].DateTicks = _Rounds[Round, p].DateTicks; player[p].SongFinished = _Rounds[Round, p].SongFinished; player[p].ProfileID = _Rounds[Round, p].ProfileID; @@ -119,7 +122,7 @@ namespace Vocaluxe.GameModes { return _SongQueque[_CurrentSong].GameMode; } - return EGameMode.Normal; + return EGameMode.TR_GAMEMODE_NORMAL; } public virtual bool AddVisibleSong(int VisibleIndex, EGameMode GameMode) @@ -127,7 +130,7 @@ namespace Vocaluxe.GameModes if (CSongs.VisibleSongs.Length > VisibleIndex) { int SongID = CSongs.VisibleSongs[VisibleIndex].ID; - if (GameMode == EGameMode.Duet && !CSongs.GetSong(SongID).IsDuet) + if (GameMode == EGameMode.TR_GAMEMODE_DUET && !CSongs.GetSong(SongID).IsDuet) return false; _SongQueque.Add(new SongQueque(SongID, GameMode)); @@ -141,7 +144,7 @@ namespace Vocaluxe.GameModes if (CSongs.AllSongs.Length > AbsoluteIndex) { int SongID = CSongs.AllSongs[AbsoluteIndex].ID; - if (GameMode == EGameMode.Duet && !CSongs.GetSong(SongID).IsDuet) + if (GameMode == EGameMode.TR_GAMEMODE_DUET && !CSongs.GetSong(SongID).IsDuet) return false; _SongQueque.Add(new SongQueque(SongID, GameMode)); @@ -188,7 +191,6 @@ namespace Vocaluxe.GameModes break; } } - if (index == -1) return false; @@ -223,8 +225,9 @@ namespace Vocaluxe.GameModes _CurrentSong, _SongQueque[_CurrentSong].SongID, Player, - _SongQueque[_CurrentSong].GameMode == EGameMode.Medley, - _SongQueque[_CurrentSong].GameMode == EGameMode.Duet); + _SongQueque[_CurrentSong].GameMode == EGameMode.TR_GAMEMODE_MEDLEY, + _SongQueque[_CurrentSong].GameMode == EGameMode.TR_GAMEMODE_DUET, + _SongQueque[_CurrentSong].GameMode == EGameMode.TR_GAMEMODE_SHORTSONG); } _CurrentSong++; } @@ -244,7 +247,32 @@ namespace Vocaluxe.GameModes { if (_CurrentSong >= 0 && _CurrentSong < _SongQueque.Count) { - return CSongs.GetSong(_SongQueque[_CurrentSong].SongID); + CSong song = CSongs.GetSong(_SongQueque[_CurrentSong].SongID); + song = new CSong(song); + + switch (GetCurrentGameMode()) + { + case EGameMode.TR_GAMEMODE_MEDLEY: + // set medley mode timings + song.Start = CGame.GetTimeFromBeats(song.Medley.StartBeat, song.BPM) - song.Medley.FadeInTime + song.Gap; + if (song.Start < 0f) + song.Start = 0f; + + song.Finish = CGame.GetTimeFromBeats(song.Medley.EndBeat, song.BPM) + song.Medley.FadeOutTime + song.Gap; + + // set lines to medley mode + song.Notes.SetMedley(song.Medley.StartBeat, song.Medley.EndBeat); + break; + + case EGameMode.TR_GAMEMODE_SHORTSONG: + song.Finish = CGame.GetTimeFromBeats(song.ShortEnd, song.BPM) + CSettings.DefaultMedleyFadeOutTime + song.Gap; + + // set lines to medley mode + song.Notes.SetMedley(song.Notes.GetLines(0).Line[0].FirstNoteBeat, song.ShortEnd); + break; + } + + return song; } return null; } @@ -256,16 +284,28 @@ namespace Vocaluxe.GameModes public virtual CSong GetSong(int Num) { - if (Num - 1 < _SongQueque.Count) + if (Num - 1 < _SongQueque.Count && Num - 1 > -1) return CSongs.GetSong(_SongQueque[Num - 1].SongID); return null; } + public virtual EGameMode GetGameMode(int Num) + { + if(Num - 1 < _SongQueque.Count && Num > -1) + return _SongQueque[Num].GameMode; + + return EGameMode.TR_GAMEMODE_NORMAL; + } + public virtual CPoints GetPoints() { return _Points; } #endregion Implementation + + protected virtual void SongManipulation(int SongIndex) + { + } } } diff --git a/Vocaluxe/GameModes/CGameModeNormal.cs b/Vocaluxe/GameModes/CGameModeNormal.cs index 4a66383c..5f05bd6c 100644 --- a/Vocaluxe/GameModes/CGameModeNormal.cs +++ b/Vocaluxe/GameModes/CGameModeNormal.cs @@ -10,7 +10,7 @@ namespace Vocaluxe.GameModes public override void Init() { base.Init(); - + _Initialized = true; } } diff --git a/Vocaluxe/GameModes/IGameMode.cs b/Vocaluxe/GameModes/IGameMode.cs index 6a1572f4..79a8fefc 100644 --- a/Vocaluxe/GameModes/IGameMode.cs +++ b/Vocaluxe/GameModes/IGameMode.cs @@ -9,9 +9,10 @@ namespace Vocaluxe.GameModes { public enum EGameMode { - Normal, - Medley, - Duet + TR_GAMEMODE_NORMAL, + TR_GAMEMODE_MEDLEY, + TR_GAMEMODE_DUET, + TR_GAMEMODE_SHORTSONG } interface IGameMode @@ -37,5 +38,6 @@ namespace Vocaluxe.GameModes int GetNumSongs(); CSong GetSong(); CSong GetSong(int Num); + EGameMode GetGameMode(int Num); } } diff --git a/Vocaluxe/Lib/Draw/CDirect3D.cs b/Vocaluxe/Lib/Draw/CDirect3D.cs index 7207a945..a5a5e167 100644 --- a/Vocaluxe/Lib/Draw/CDirect3D.cs +++ b/Vocaluxe/Lib/Draw/CDirect3D.cs @@ -55,6 +55,8 @@ namespace Vocaluxe.Lib.Draw private Queue _VerticesTextures; private Queue _VerticesRotationMatrices; + private bool _NonPowerOf2TextureSupported; + #endregion private vars /// @@ -182,6 +184,13 @@ namespace Vocaluxe.Lib.Draw flags = CreateFlags.HardwareVertexProcessing; else flags = CreateFlags.SoftwareVertexProcessing; + + //Check if Pow2 textures are needed + _NonPowerOf2TextureSupported = true; + _NonPowerOf2TextureSupported &= (caps.TextureCaps & TextureCaps.Pow2) == 0; + _NonPowerOf2TextureSupported &= (caps.TextureCaps & TextureCaps.NonPow2Conditional) == 0; + _NonPowerOf2TextureSupported &= (caps.TextureCaps & TextureCaps.SquareOnly) == 0; + try { _Device = new Device(_D3D, _D3D.Adapters.DefaultAdapter.Adapter, DeviceType.Hardware, Handle, flags, _PresentParameters); @@ -731,8 +740,8 @@ namespace Vocaluxe.Lib.Draw texture.rect = new SRectF(0f, 0f, texture.width, texture.height, 0f); texture.width = w; texture.height = h; - texture.w2 = NextPowerOfTwo(texture.width); - texture.h2 = NextPowerOfTwo(texture.height); + texture.w2 = CheckForNextPowerOf2(texture.width); + texture.h2 = CheckForNextPowerOf2(texture.height); texture.index = _IDs.Dequeue(); lock (MutexTexture) @@ -836,6 +845,19 @@ namespace Vocaluxe.Lib.Draw { DrawTexture(_BlankTexture, rect, color); } + + /// + /// Draws reflection of a colored rectangle + /// + /// The color in which the rectangle will be drawn in + /// The coordinates in a SRectF struct + /// The space between the texture and the reflection + /// The height of the reflection + public void DrawColorReflection(SColorF color, SRectF rect, float space, float height) + { + DrawTextureReflection(_BlankTexture, rect, color, rect, space, height); + } + #endregion Basic Draw Methods #region Textures #region adding @@ -919,8 +941,8 @@ namespace Vocaluxe.Lib.Draw texture.height = h; //Older graphics card can only handle textures with sizes being powers of two - texture.w2 = (float)NextPowerOfTwo(w); - texture.h2 = (float)NextPowerOfTwo(h); + texture.w2 = (float)CheckForNextPowerOf2(w); + texture.h2 = (float)CheckForNextPowerOf2(h); //Create a new Bitmap with the new sizes Bitmap bmp2 = new Bitmap((int)texture.w2, (int)texture.h2); @@ -1014,8 +1036,8 @@ namespace Vocaluxe.Lib.Draw STexture texture = new STexture(-1); texture.width = W; texture.height = H; - texture.w2 = NextPowerOfTwo(texture.width); - texture.h2 = NextPowerOfTwo(texture.height); + texture.w2 = CheckForNextPowerOf2(texture.width); + texture.h2 = CheckForNextPowerOf2(texture.height); texture.width_ratio = texture.width / texture.w2; texture.height_ratio = texture.height / texture.h2; @@ -1079,8 +1101,8 @@ namespace Vocaluxe.Lib.Draw } _D3DTextures[Texture.index].UnlockRectangle(0); - Texture.height_ratio = Texture.height / NextPowerOfTwo(Texture.height); - Texture.width_ratio = Texture.width / NextPowerOfTwo(Texture.width); + Texture.height_ratio = Texture.height / CheckForNextPowerOf2(Texture.height); + Texture.width_ratio = Texture.width / CheckForNextPowerOf2(Texture.width); return true; /*Surface s = _D3DTextures[Texture.index].GetSurfaceLevel(0); @@ -1434,8 +1456,8 @@ namespace Vocaluxe.Lib.Draw texture.width = q.width; texture.height = q.height; - texture.w2 = NextPowerOfTwo(texture.width); - texture.h2 = NextPowerOfTwo(texture.height); + texture.w2 = CheckForNextPowerOf2(texture.width); + texture.h2 = CheckForNextPowerOf2(texture.height); texture.width_ratio = texture.width / texture.w2; texture.height_ratio = texture.height / texture.h2; @@ -1475,14 +1497,18 @@ namespace Vocaluxe.Lib.Draw #region utility /// - /// Calculates the next power of two + /// Calculates the next power of two if the device has the POW2 flag set /// /// The value of which the next power of two will be calculated /// The next power of two - private static float NextPowerOfTwo(float n) + private float CheckForNextPowerOf2(float n) { - if (n < 0) throw new ArgumentOutOfRangeException("n", "Must be positive."); - return (float)System.Math.Pow(2, System.Math.Ceiling(System.Math.Log((double)n, 2))); + if (!_NonPowerOf2TextureSupported) + { + if (n < 0) throw new ArgumentOutOfRangeException("n", "Must be positive."); + return (float)System.Math.Pow(2, System.Math.Ceiling(System.Math.Log((double)n, 2))); + } + else return n; } private Matrix CalculateRotationMatrix(float rot, float rx1, float rx2, float ry1, float ry2) diff --git a/Vocaluxe/Lib/Draw/CDrawWinForm.cs b/Vocaluxe/Lib/Draw/CDrawWinForm.cs index c94f0073..51cc0c4f 100644 --- a/Vocaluxe/Lib/Draw/CDrawWinForm.cs +++ b/Vocaluxe/Lib/Draw/CDrawWinForm.cs @@ -352,6 +352,11 @@ namespace Vocaluxe.Lib.Draw } + public void DrawColorReflection(SColorF color, SRectF rect, float space, float height) + { + + } + public STexture AddTexture(Bitmap bmp) { Bitmap bmp2 = new Bitmap(bmp); diff --git a/Vocaluxe/Lib/Draw/COpenGL.cs b/Vocaluxe/Lib/Draw/COpenGL.cs index 54ee1fcf..06a09e95 100644 --- a/Vocaluxe/Lib/Draw/COpenGL.cs +++ b/Vocaluxe/Lib/Draw/COpenGL.cs @@ -661,6 +661,59 @@ namespace Vocaluxe.Lib.Draw GL.Disable(EnableCap.Blend); } + public void DrawColorReflection(SColorF color, SRectF rect, float space, float height) + { + + if (rect.H < height) + height = rect.H; + + float rx1 = rect.X; + float rx2 = rect.X + rect.W; + float ry1 = rect.Y + rect.H + space; + float ry2 = rect.Y + rect.H + space + height; + + if (rx1 < rect.X) + rx1 = rect.X; + + if (rx2 > rect.X + rect.W) + rx2 = rect.X + rect.W; + + if (ry1 < rect.Y + space) + ry1 = rect.Y + space; + + if (ry2 > rect.Y + rect.H + space + height) + ry2 = rect.Y + rect.H + space + height; + + + GL.Enable(EnableCap.Blend); + + if (rect.Rotation != 0f) + { + GL.Translate(0.5f, 0.5f, 0); + GL.Rotate(-rect.Rotation, 0f, 0f, 1f); + GL.Translate(-0.5f, -0.5f, 0); + } + + GL.Begin(BeginMode.Quads); + + GL.Color4(color.R, color.G, color.B, color.A * CGraphics.GlobalAlpha); + GL.Vertex3(rx2, ry1, rect.Z + CGraphics.ZOffset); + + GL.Color4(color.R, color.G, color.B, 0f); + GL.Vertex3(rx2, ry2, rect.Z + CGraphics.ZOffset); + + GL.Color4(color.R, color.G, color.B, 0f); + GL.Vertex3(rx1, ry2, rect.Z + CGraphics.ZOffset); + + GL.Color4(color.R, color.G, color.B, color.A * CGraphics.GlobalAlpha); + GL.Vertex3(rx1, ry1, rect.Z + CGraphics.ZOffset); + + GL.End(); + + GL.Disable(EnableCap.Blend); + + } + #endregion Basic Draw Methods #region Textures diff --git a/Vocaluxe/Lib/Draw/IDraw.cs b/Vocaluxe/Lib/Draw/IDraw.cs index 2f8bbc82..9a7bf1d6 100644 --- a/Vocaluxe/Lib/Draw/IDraw.cs +++ b/Vocaluxe/Lib/Draw/IDraw.cs @@ -125,6 +125,7 @@ namespace Vocaluxe.Lib.Draw // Basic Draw Methods void DrawLine(int a, int r, int g, int b, int w, int x1, int y1, int x2, int y2); void DrawColor(SColorF color, SRectF rect); + void DrawColorReflection(SColorF color, SRectF rect, float space, float height); void ClearScreen(); STexture CopyScreen(); diff --git a/Vocaluxe/Lib/Playlist/CPlaylistFile.cs b/Vocaluxe/Lib/Playlist/CPlaylistFile.cs new file mode 100644 index 00000000..57e9fb55 --- /dev/null +++ b/Vocaluxe/Lib/Playlist/CPlaylistFile.cs @@ -0,0 +1,282 @@ +using System; +using System.Collections.Generic; +using System.IO; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Base; +using Vocaluxe.GameModes; +using Vocaluxe.Lib.Song; + + +namespace Vocaluxe.Lib.Playlist +{ + public class CPlaylistSong + { + public int SongID; + public EGameMode GameMode; + + public CPlaylistSong(int SongID, EGameMode gm) + { + this.SongID = SongID; + this.GameMode = gm; + } + + public CPlaylistSong() + { + GameMode = EGameMode.TR_GAMEMODE_NORMAL; + } + + public CPlaylistSong(CPlaylistSong ps) + { + SongID = ps.SongID; + GameMode = ps.GameMode; + } + } + + public class CPlaylistFile + { + private static XmlWriterSettings _settings = new XmlWriterSettings(); + private static CHelper Helper = new CHelper(); + + public string PlaylistName; + public string PlaylistFile; + public List Songs = new List(); + + public CPlaylistFile() + { + Init(); + PlaylistName = string.Empty; + PlaylistFile = string.Empty; + } + + public CPlaylistFile(string file) + { + Init(); + PlaylistFile = file; + LoadPlaylist(); + } + + private void Init() + { + _settings.Indent = true; + _settings.Encoding = System.Text.Encoding.UTF8; + _settings.ConformanceLevel = ConformanceLevel.Document; + } + + + public void SavePlaylist() + { + if (PlaylistFile == string.Empty) + { + string filename = string.Empty; + foreach (char chr in PlaylistName) + { + if (char.IsLetter(chr)) + filename += chr.ToString(); + } + + if (filename == String.Empty) + filename = "1"; + + int i = 0; + while (File.Exists(Path.Combine(CSettings.sFolderPlaylists, filename + ".xml"))) + { + i++; + if (!File.Exists(Path.Combine(CSettings.sFolderPlaylists, filename + i + ".xml"))) + { + filename += i; + } + } + + PlaylistFile = Path.Combine(CSettings.sFolderPlaylists, filename + ".xml"); + } + + XmlWriter writer; + try + { + writer = XmlWriter.Create(PlaylistFile, _settings); + } + catch (Exception e) + { + CLog.LogError("Error creating/opening Playlist File " + PlaylistFile + ": " + e.Message); + return; + } + + if (writer == null) + { + CLog.LogError("Error creating/opening Playlist File " + PlaylistFile); + return; + } + + writer.WriteStartDocument(); + writer.WriteStartElement("root"); + + writer.WriteStartElement("Info"); + writer.WriteElementString("PlaylistName", PlaylistName); + writer.WriteEndElement(); + + writer.WriteStartElement("Songs"); + for (int i = 0; i < Songs.Count; i++) + { + CSong song = CSongs.GetSong(Songs[i].SongID); + if (song != null) + { + writer.WriteStartElement("Song" + (i + 1).ToString()); + writer.WriteElementString("Artist", song.Artist); + writer.WriteElementString("Title", song.Title); + writer.WriteElementString("GameMode", Enum.GetName(typeof(EGameMode), Songs[i].GameMode)); + writer.WriteEndElement(); + } + else + { + CLog.LogError("Playlist.SavePlaylist(): Can't find Song. This should never happen!"); + } + } + writer.WriteEndElement(); + + writer.WriteEndElement(); //end of root + writer.WriteEndDocument(); + + writer.Flush(); + writer.Close(); + } + + private void LoadPlaylist() + { + bool loaded = false; + XPathDocument xPathDoc = null; + XPathNavigator navigator = null; + + try + { + xPathDoc = new XPathDocument(PlaylistFile); + navigator = xPathDoc.CreateNavigator(); + loaded = true; + } + catch (Exception e) + { + loaded = false; + if (navigator != null) + navigator = null; + + if (xPathDoc != null) + xPathDoc = null; + + CLog.LogError("Error opening Playlist File " + PlaylistFile + ": " + e.Message); + } + + if (loaded) + { + string value = String.Empty; + if (CHelper.GetValueFromXML("//root/Info/PlaylistName", navigator, ref value, value)) + { + PlaylistName = value; + + Songs = new List(); + + List songs = CHelper.GetValuesFromXML("Songs", navigator); + string artist = String.Empty; + string title = String.Empty; + EGameMode gm = EGameMode.TR_GAMEMODE_NORMAL; + + for (int i = 0; i < songs.Count; i++) + { + CHelper.GetValueFromXML("//root/Songs/" + songs[i] + "/Artist", navigator, ref artist, String.Empty); + CHelper.GetValueFromXML("//root/Songs/" + songs[i] + "/Title", navigator, ref title, String.Empty); + CHelper.TryGetEnumValueFromXML("//root/Songs/" + songs[i] + "/GameMode", navigator, ref gm); + + CPlaylistSong song = new CPlaylistSong(); + song.SongID = -1; + CSong[] AllSongs = CSongs.AllSongs; + + for (int s = 0; s < AllSongs.Length; s++) + { + if (AllSongs[s].Artist == artist && AllSongs[s].Title == title) + { + song.SongID = AllSongs[s].ID; + break; + } + } + + if (song.SongID != -1) + { + song.GameMode = gm; + Songs.Add(song); + } + else + { + CLog.LogError("Can't find song '" + title + "' from '" + artist + "' in playlist file: " + PlaylistFile); + } + } + } + else + { + CLog.LogError("Can't find PlaylistName in Playlist File: " + PlaylistFile); + } + } + } + + public void AddSong(int SongID) + { + CPlaylistSong song = new CPlaylistSong(); + song.SongID = SongID; + if (CSongs.GetSong(SongID).IsDuet) + song.GameMode = EGameMode.TR_GAMEMODE_DUET; + else + song.GameMode = EGameMode.TR_GAMEMODE_NORMAL; + + Songs.Add(song); + } + + public void AddSong(int SongID, EGameMode gm) + { + CPlaylistSong song = new CPlaylistSong(); + song.SongID = SongID; + song.GameMode = gm; + + Songs.Add(song); + } + + public void DeleteSong(int SongNr) + { + Songs.RemoveAt(SongNr); + } + + public void SongUp(int SongNr) + { + if (SongNr < Songs.Count - 1 && SongNr > 0) + { + Songs.Reverse(SongNr - 1, 2); + } + } + + public void SongDown(int SongNr) + { + if (SongNr < Songs.Count - 1 && SongNr >= 0) + { + Songs.Reverse(SongNr, 2); + } + } + + public void SongMove(int SourceNr, int DestNr) + { + if (SourceNr < 0 || DestNr < 0 || SourceNr == DestNr || SourceNr > Songs.Count - 1 || DestNr > Songs.Count - 1) + return; + + CPlaylistSong ps = new CPlaylistSong(Songs[SourceNr]); + Songs.RemoveAt(SourceNr); + Songs.Insert(DestNr, ps); + } + + public void SongInsert(int DestNr, int SongID, EGameMode gm) + { + if (DestNr < 0 || DestNr > Songs.Count - 1) + return; + + CPlaylistSong ps = new CPlaylistSong(SongID, gm); + Songs.Insert(DestNr, ps); + } + } +} diff --git a/Vocaluxe/Lib/Song/CNotes.cs b/Vocaluxe/Lib/Song/CNotes.cs index edd3b6d3..d6203ca0 100644 --- a/Vocaluxe/Lib/Song/CNotes.cs +++ b/Vocaluxe/Lib/Song/CNotes.cs @@ -6,7 +6,7 @@ using Vocaluxe.Base; namespace Vocaluxe.Lib.Song { - class CNotes + class CNotes { private List _Lines = new List(); @@ -15,6 +15,18 @@ namespace Vocaluxe.Lib.Song get { return _Lines.ToArray(); } } + public CNotes() + { + } + + public CNotes(CNotes notes) + { + foreach (CLines lines in notes._Lines) + { + _Lines.Add(new CLines(lines)); + } + } + public CLines GetLines(int Index) { while (Index >= _Lines.Count) @@ -60,6 +72,13 @@ namespace Vocaluxe.Lib.Song _Lines.Clear(); } + public void SetMedley(int StartBeat, int EndBeat) + { + foreach (CLines lines in _Lines) + { + lines.SetMedley(StartBeat, EndBeat); + } + } } public enum ENoteType @@ -91,6 +110,17 @@ namespace Vocaluxe.Lib.Song _Perfect = false; } + public CNote(CNote note) + { + _StartBeat = note._StartBeat; + _Duration = note._Duration; + _Tone = note._Tone; + _NoteType = note._NoteType; + _Text = note._Text; + _Hit = note._Hit; + _Perfect = note._Perfect; + } + public CNote(int StartBeat, int Duration, int Tone, string Text) : this() { @@ -250,22 +280,43 @@ namespace Vocaluxe.Lib.Song private int _StartBeat; private int _EndBeat; private bool _PerfectLine; // for drawing perfect line effect + private bool _VisibleInTimeLine; private int _MinBeat = int.MaxValue; private int _MaxBeat = int.MinValue; - private List _Notes; + private List _Notes = new List(); #region Constructors public CLine() { - _Notes = new List(); StartBeat = int.MinValue; EndBeat = int.MaxValue; _PerfectLine = false; + _VisibleInTimeLine = true; + } + + public CLine(CLine line) + { + foreach (CNote note in line._Notes) + { + _Notes.Add(new CNote(note)); + } + _StartBeat = line._StartBeat; + _EndBeat = line._EndBeat; + _PerfectLine = line._PerfectLine; + _MinBeat = line._MinBeat; + _MaxBeat = line._MaxBeat; + _VisibleInTimeLine = line._VisibleInTimeLine; } #endregion Constructors #region Properties + public bool VisibleInTimeLine + { + get { return _VisibleInTimeLine; } + set { _VisibleInTimeLine = value; } + } + public int StartBeat { get { return _StartBeat; } @@ -292,7 +343,7 @@ namespace Vocaluxe.Lib.Song set { _PerfectLine = value; } } - public int FirstBeat + public int FirstNoteBeat { get { @@ -300,7 +351,7 @@ namespace Vocaluxe.Lib.Song } } - public int LastBeat + public int LastNoteBeat { get { @@ -465,6 +516,17 @@ namespace Vocaluxe.Lib.Song _MaxBeat = int.MinValue; } + public void SetMedley(int StartBeat, int EndBeat) + { + foreach (CNote note in _Notes) + { + if (note.StartBeat < StartBeat || note.EndBeat > EndBeat) + note.NoteType = ENoteType.Freestyle; + } + + _VisibleInTimeLine = _MinBeat >= StartBeat && _MaxBeat <= EndBeat; + } + private void updateMinMaxBeat(CNote Note) { if (Note.StartBeat < _MinBeat) @@ -487,16 +549,24 @@ namespace Vocaluxe.Lib.Song updateMinMaxBeat(note); } } + #endregion Methods } public class CLines { - private List _Lines; + private List _Lines = new List(); public CLines() { - _Lines = new List(); + } + + public CLines(CLines lines) + { + foreach (CLine line in lines._Lines) + { + _Lines.Add(new CLine(line)); + } } public CLine[] Line @@ -521,15 +591,15 @@ namespace Vocaluxe.Lib.Song int startbeat = int.MaxValue; for (int i = 0; i < _Lines.Count; i++) { - if (_Lines[i].FirstBeat < startbeat) - startbeat = _Lines[i].FirstBeat; + if (_Lines[i].FirstNoteBeat < startbeat) + startbeat = _Lines[i].FirstNoteBeat; } int endbeat = int.MinValue; for (int i = 0; i < _Lines.Count; i++) { - if (_Lines[i].LastBeat < endbeat) - endbeat = _Lines[i].LastBeat; + if (_Lines[i].LastNoteBeat < endbeat) + endbeat = _Lines[i].LastNoteBeat; } int result = endbeat - startbeat; @@ -688,6 +758,13 @@ namespace Vocaluxe.Lib.Song } } + public void SetMedley(int StartBeat, int EndBeat) + { + foreach (CLine line in _Lines) + { + line.SetMedley(StartBeat, EndBeat); + } + } #endregion Methods } } diff --git a/Vocaluxe/Lib/Song/CSong.cs b/Vocaluxe/Lib/Song/CSong.cs index fee895b1..1b874dfc 100644 --- a/Vocaluxe/Lib/Song/CSong.cs +++ b/Vocaluxe/Lib/Song/CSong.cs @@ -7,19 +7,45 @@ using System.Text.RegularExpressions; using Vocaluxe.Base; using Vocaluxe.Lib.Draw; using Vocaluxe.Menu; +using Vocaluxe.GameModes; namespace Vocaluxe.Lib.Song { [Flags] enum EHeaderFlags { - Title, - Artist, - MP3, - BPM, - PreviewStart, - MedleyStartBeat, - MedleyEndBeat + Title = 1, + Artist = 2, + MP3 = 4, + BPM = 8, + PreviewStart = 16, + MedleyStartBeat = 32, + MedleyEndBeat = 64 + } + + enum EMedleySource + { + None, + Calculated, + Tag + } + + struct SMedley + { + public EMedleySource Source; + public int StartBeat; + public int EndBeat; + public float FadeInTime; + public float FadeOutTime; + + public SMedley(int dummy) + { + Source = EMedleySource.None; + StartBeat = 0; + EndBeat = 0; + FadeInTime = 0f; + FadeOutTime = 0f; + } } class CSong @@ -29,10 +55,18 @@ namespace Vocaluxe.Lib.Song private STexture _CoverTextureSmall = new STexture(-1); private STexture _CoverTextureBig = new STexture(-1); + public SMedley Medley = new SMedley(0); + + public bool CalculateMedley = true; + public float PreviewStart = 0f; + + public int ShortEnd = 0; + public Encoding Encoding = Encoding.Default; public string Folder = String.Empty; public string FolderName = String.Empty; public string FileName = String.Empty; + public EOffOn Relative = EOffOn.TR_CONFIG_OFF; public string MP3FileName = String.Empty; public string CoverFileName = String.Empty; @@ -45,9 +79,12 @@ namespace Vocaluxe.Lib.Song { get { return _CoverLoaded; } } + public bool NotesLoaded + { + get { return _NotesLoaded; } + } public bool CoverBigLoaded = false; - public bool BackgroundLoaded = false; public STexture CoverTextureSmall { @@ -84,8 +121,6 @@ namespace Vocaluxe.Lib.Song set { _CoverTextureBig = value; } } - public CBackground Background = new CBackground(); - public string Title = String.Empty; public string Artist = String.Empty; @@ -99,6 +134,9 @@ namespace Vocaluxe.Lib.Song public float Gap = 0f; public float VideoGap = 0f; + public string DuetPart1 = String.Empty; + public string DuetPart2 = String.Empty; + public List Comment = new List(); // Sorting @@ -119,6 +157,104 @@ namespace Vocaluxe.Lib.Song // Notes public CNotes Notes = new CNotes(); + public EGameMode[] AvailableGameModes + { + get + { + List gms = new List(); + if (IsDuet) + gms.Add(EGameMode.TR_GAMEMODE_DUET); + else + gms.Add(EGameMode.TR_GAMEMODE_NORMAL); + if (Medley.Source != EMedleySource.None) + gms.Add(EGameMode.TR_GAMEMODE_MEDLEY); + gms.Add(EGameMode.TR_GAMEMODE_SHORTSONG); + + return gms.ToArray(); + } + } + + public CSong() + { + } + + public CSong(CSong song) + { + this._CoverTextureSmall = song._CoverTextureSmall; + this._CoverTextureBig = song._CoverTextureBig; + + this.Medley = new SMedley(); + this.Medley.Source = song.Medley.Source; + this.Medley.StartBeat = song.Medley.StartBeat; + this.Medley.EndBeat = song.Medley.EndBeat; + this.Medley.FadeInTime = song.Medley.FadeInTime; + this.Medley.FadeOutTime = song.Medley.FadeOutTime; + + this.CalculateMedley = song.CalculateMedley; + this.PreviewStart = song.PreviewStart; + + this.ShortEnd = song.ShortEnd; + + this.Encoding = song.Encoding; + this.Folder = song.Folder; + this.FolderName = song.FolderName; + this.FileName = song.FileName; + this.Relative = song.Relative; + + this.MP3FileName = song.MP3FileName; + this.CoverFileName = song.CoverFileName; + this.BackgroundFileName = song.BackgroundFileName; + this.VideoFileName = song.VideoFileName; + + this.VideoAspect = song.VideoAspect; + this._CoverLoaded = song._CoverLoaded; + this.CoverBigLoaded = song.CoverBigLoaded; + this._NotesLoaded = song._NotesLoaded; + + this.Artist = song.Artist; + this.Title = song.Title; + + this.Start = song.Start; + this.Finish = song.Finish; + + this.BPM = song.BPM; + this.Gap = song.Gap; + this.VideoGap = song.VideoGap; + + this.Comment = new List(); + foreach (string value in song.Comment) + { + this.Comment.Add(value); + } + + this.ID = song.ID; + this.Visible = song.Visible; + this.CatIndex = song.CatIndex; + this.Selected = song.Selected; + + this.Edition = new List(); + foreach (string value in song.Edition) + { + this.Edition.Add(value); + } + + this.Genre = new List(); + foreach (string value in song.Genre) + { + this.Genre.Add(value); + } + + this.Year = song.Year; + + this.Language = new List(); + foreach (string value in song.Language) + { + this.Language.Add(value); + } + + this.Notes = new CNotes(song.Notes); + } + public string GetMP3() { return Path.Combine(Folder, MP3FileName); @@ -254,6 +390,18 @@ namespace Vocaluxe.Lib.Song this.ArtistSorting = Value; } break; + case "P1": + if (Value != String.Empty) + { + this.DuetPart1 = Value; + } + break; + case "P2": + if (Value != String.Empty) + { + this.DuetPart2 = Value; + } + break; case "MP3": if (File.Exists(Path.Combine(this.Folder, Value))) { @@ -328,6 +476,29 @@ namespace Vocaluxe.Lib.Song if (CHelper.TryParse(Value, out this.Finish)) this.Finish /= 1000f; break; + case "PREVIEWSTART": + if (CHelper.TryParse(Value, out this.PreviewStart)) + if (this.PreviewStart < 0f) + this.PreviewStart = 0f; + else + HeaderFlags |= EHeaderFlags.PreviewStart; + break; + case "MEDLEYSTARTBEAT": + if (int.TryParse(Value, out this.Medley.StartBeat)) + HeaderFlags |= EHeaderFlags.MedleyStartBeat; + break; + case "MEDLEYENDBEAT": + if (int.TryParse(Value, out this.Medley.EndBeat)) + HeaderFlags |= EHeaderFlags.MedleyEndBeat; + break; + case "CALCMEDLEY": + if (Value.ToUpper() == "OFF") + this.CalculateMedley = false; + break; + case "RELATIVE": + if (Value.ToUpper() == "YES" && Value.ToUpper() != "NO") + this.Relative = EOffOn.TR_CONFIG_ON; + break; default: ; break; @@ -343,25 +514,82 @@ namespace Vocaluxe.Lib.Song } } //end of while - if (HeaderFlags != (EHeaderFlags.Title | EHeaderFlags.Artist | EHeaderFlags.MP3 | EHeaderFlags.BPM)) + if ((HeaderFlags & EHeaderFlags.Title) == 0) + { + CLog.LogError("Title tag missing: " + FilePath); return false; + } + + if ((HeaderFlags & EHeaderFlags.Artist) == 0) + { + CLog.LogError("Artist tag missing: " + FilePath); + return false; + } + + if ((HeaderFlags & EHeaderFlags.MP3) == 0) + { + CLog.LogError("MP3 tag missing: " + FilePath); + return false; + } + + if ((HeaderFlags & EHeaderFlags.BPM) == 0) + { + CLog.LogError("BPM tag missing: " + FilePath); + return false; + } + + if (this.Relative == EOffOn.TR_CONFIG_ON) + { + CLog.LogError("Relative songs are not supported by Vocaluxe (perhaps later)! (" + FilePath + ")"); + return false; + } + + #region check medley tags + if ((HeaderFlags & EHeaderFlags.MedleyStartBeat) != 0 && (HeaderFlags & EHeaderFlags.MedleyEndBeat) != 0) + { + if (this.Medley.StartBeat > this.Medley.EndBeat) + { + CLog.LogError("MedleyStartBeat is bigger than MedleyEndBeat in file: " + FilePath); + HeaderFlags = HeaderFlags - EHeaderFlags.MedleyStartBeat - EHeaderFlags.MedleyEndBeat; + } + } + + if ((HeaderFlags & EHeaderFlags.PreviewStart) == 0 || this.PreviewStart == 0f) + { + //PreviewStart is not set or <=0 + if ((HeaderFlags & EHeaderFlags.MedleyStartBeat) != 0) + //fallback to MedleyStart + this.PreviewStart = CGame.GetTimeFromBeats(this.Medley.StartBeat, this.BPM); + else + //else set to 0, it will be set in FindRefrainStart + this.PreviewStart = 0f; + } + + if ((HeaderFlags & EHeaderFlags.MedleyStartBeat) != 0 && (HeaderFlags & EHeaderFlags.MedleyEndBeat) != 0) + { + this.Medley.Source = EMedleySource.Tag; + this.Medley.FadeInTime = CSettings.DefaultMedleyFadeInTime; + this.Medley.FadeOutTime = CSettings.DefaultMedleyFadeOutTime; + } + #endregion check medley tags this.Encoding = sr.CurrentEncoding; } - catch (Exception) + catch (Exception e) { + CLog.LogError("Error reading txt header in file \"" + FilePath + "\": " + e.Message); return false; } CheckFiles(); //Before saving this tags to .txt: Check, if ArtistSorting and Artist are equal, then don't save this tag. - if (this.ArtistSorting == "") + if (this.ArtistSorting == String.Empty) { this.ArtistSorting = this.Artist; } - if (this.TitleSorting == "") + if (this.TitleSorting == String.Empty) { this.TitleSorting = this.Title; } @@ -420,9 +648,10 @@ namespace Vocaluxe.Lib.Song FileLineNo++; if (TempC.CompareTo('P') == 0) { - char chr = (char)sr.Read(); - int.TryParse(chr.ToString(), out Param1); + char chr; + while ((chr = (char)sr.Read()) == ' '){ } + int.TryParse(chr.ToString(), out Param1); if (Param1 == 1) Player = 0; else if (Param1 == 2) @@ -481,7 +710,7 @@ namespace Vocaluxe.Lib.Song char chr = (char)sr.Read(); Param1 = CHelper.TryReadInt(sr); - + NewSentence(Player, Param1); isNewSentence = true; @@ -504,7 +733,11 @@ namespace Vocaluxe.Lib.Song CLog.LogError("Error loading song. Line No.: " + FileLineNo.ToString() + ". An unhandled exception occured (" + e.Message + "): " + FilePath); return false; } + FindRefrain(); + FindShortEnd(); _NotesLoaded = true; + if(IsDuet) + CheckDuet(); return true; } @@ -570,5 +803,224 @@ namespace Vocaluxe.Lib.Song } } } + + private void CheckDuet() + { + if (DuetPart1 == String.Empty) + { + DuetPart1 = "Part 1"; + CLog.LogError("Warning: Can't find #P1-tag for duets in \"" + this.Artist + " - " + this.Title + "\"."); + } + if (DuetPart2 == String.Empty) + { + DuetPart2 = "Part 2"; + CLog.LogError("Warning: Can't find #P2-tag for duets in \"" + this.Artist + " - " + this.Title + "\"."); + } + } + + private struct Series + { + public int start; + public int end; + public int length; + } + + private void FindRefrain() + { + if (this.IsDuet) + { + this.Medley.Source = EMedleySource.None; + return; + } + + if (this.Medley.Source == EMedleySource.Tag) + return; + + if (!this.CalculateMedley) + return; + + CLines lines = this.Notes.GetLines(0); + + if (lines.LineCount == 0) + return; + + // build sentences list + List sentences = new List(); + foreach (CLine line in lines.Line) + { + if (line.Points != 0) + sentences.Add(line.Lyrics); + else + sentences.Add(String.Empty); + } + + // find equal sentences series + List series = new List(); + for (int i = 0; i < lines.LineCount - 1; i++) + { + for (int j = i + 1; j < lines.LineCount; j++) + { + if (sentences[i] == sentences[j] && sentences[i] != String.Empty) + { + Series tempSeries = new Series(); + tempSeries.start = i; + tempSeries.end = i; + + int max = 0; + if (j + j - i - 1 > lines.LineCount - 1) + max = lines.LineCount - 1 - j; + else + max = j - i - 1; + + for (int k = 1; k <= max; k++) + { + if (sentences[i + k] == sentences[j + k] && sentences[i + k] != String.Empty) + tempSeries.end = i + k; + else + break; + } + + tempSeries.length = tempSeries.end - tempSeries.start + 1; + series.Add(tempSeries); + } + } + } + + // search for longest series + int longest = 0; + for (int i = 0; i < series.Count; i++) + { + if (series[i].length > series[longest].length) + longest = i; + } + + // set medley vars + if (series.Count > 0 && series[longest].length > CSettings.MedleyMinSeriesLength) + { + this.Medley.StartBeat = lines.Line[series[longest].start].FirstNoteBeat; + this.Medley.EndBeat = lines.Line[series[longest].end].LastNoteBeat; + + bool foundEnd = false; + + // set end if duration > MedleyMinDuration + if (CGame.GetTimeFromBeats(this.Medley.StartBeat, this.BPM) + CSettings.MedleyMinDuration > + CGame.GetTimeFromBeats(this.Medley.EndBeat, this.BPM)) + foundEnd = true; + + if (!foundEnd) + { + for (int i = series[longest].start + 1; i < lines.LineCount - 1; i++) + { + if (CGame.GetTimeFromBeats(this.Medley.StartBeat, this.BPM) + CSettings.MedleyMinDuration > + CGame.GetTimeFromBeats(lines.Line[i].LastNoteBeat, this.BPM)) + { + foundEnd = true; + this.Medley.EndBeat = lines.Line[i].LastNoteBeat; + } + } + } + + if (foundEnd) + { + this.Medley.Source = EMedleySource.Calculated; + this.Medley.FadeInTime = CSettings.DefaultMedleyFadeInTime; + this.Medley.FadeOutTime = CSettings.DefaultMedleyFadeOutTime; + } + } + + if (this.PreviewStart == 0f) + { + if (this.Medley.Source == EMedleySource.Calculated) + this.PreviewStart = CGame.GetTimeFromBeats(this.Medley.StartBeat, this.BPM); + } + } + + private void FindShortEnd(){ + CLines lines = this.Notes.GetLines(0); + + if (lines.LineCount == 0) + return; + + // build sentences list + List sentences = new List(); + foreach (CLine line in lines.Line) + { + if (line.Points != 0) + sentences.Add(line.Lyrics); + else + sentences.Add(String.Empty); + } + + // find equal sentences series + List series = new List(); + for (int i = 0; i < lines.LineCount - 1; i++) + { + for (int j = i + 1; j < lines.LineCount; j++) + { + if (sentences[i] == sentences[j] && sentences[i] != String.Empty) + { + Series tempSeries = new Series(); + tempSeries.start = i; + tempSeries.end = i; + + int max = 0; + if (j + j - i - 1 > lines.LineCount - 1) + max = lines.LineCount - 1 - j; + else + max = j - i - 1; + + for (int k = 1; k <= max; k++) + { + if (sentences[i + k] == sentences[j + k] && sentences[i + k] != String.Empty) + tempSeries.end = i + k; + else + break; + } + + tempSeries.length = tempSeries.end - tempSeries.start + 1; + series.Add(tempSeries); + } + } + } + + //Calculate length of singing + int stop = (lines.Line[lines.Line.Length - 1].LastNoteBeat - lines.Line[0].FirstNoteBeat) / 2; + + //Check if stop is in series + for (int i = 0; i < series.Count; i++) + { + if (lines.Line[series[i].start].FirstNoteBeat < stop && lines.Line[series[i].end].LastNoteBeat > stop) + { + if (stop < (lines.Line[series[i].start].FirstNoteBeat + ((lines.Line[series[i].end].LastNoteBeat - lines.Line[series[i].start].FirstNoteBeat) / 2))) + { + this.ShortEnd = lines.Line[series[i].start-1].LastNote.EndBeat; + return; + } + else + { + this.ShortEnd = lines.Line[series[i].end].LastNote.EndBeat; + return; + } + } + } + + //Check if stop is in line + for (int i = 0; i < lines.Line.Length; i++) + { + if (lines.Line[i].FirstNoteBeat < stop && lines.Line[i].LastNoteBeat > stop) + { + this.ShortEnd = lines.Line[i].LastNoteBeat; + return; + } + } + + ShortEnd = stop; + + } + + public object Clone() + { + return base.MemberwiseClone(); + } } } diff --git a/Vocaluxe/Lib/Sound/COpenALPlay.cs b/Vocaluxe/Lib/Sound/COpenALPlay.cs index 99215d7a..18d91b37 100644 --- a/Vocaluxe/Lib/Sound/COpenALPlay.cs +++ b/Vocaluxe/Lib/Sound/COpenALPlay.cs @@ -234,6 +234,21 @@ namespace Vocaluxe.Lib.Sound } } + public void SetStreamVolumeMax(int Stream, float Volume) + { + if (_Initialized) + { + lock (MutexDecoder) + { + if (AlreadyAdded(Stream)) + { + _Decoder[GetStreamIndex(Stream)].VolumeMax = Volume; + } + } + + } + } + public float GetLength(int Stream) { if (_Initialized) @@ -399,6 +414,7 @@ namespace Vocaluxe.Lib.Sound private bool _Initialized; private int _ByteCount = 4; private float _Volume = 1f; + private float _VolumeMax = 1f; private Stopwatch _fadeTimer = new Stopwatch(); @@ -500,6 +516,23 @@ namespace Vocaluxe.Lib.Sound } } + public float VolumeMax + { + get { return _VolumeMax * 100f; } + set + { + lock (MutexData) + { + _VolumeMax = value / 100f; + if (_VolumeMax < 0f) + _VolumeMax = 0f; + + if (_VolumeMax > 1f) + _VolumeMax = 1f; + } + } + } + public float Position { get @@ -804,7 +837,7 @@ namespace Vocaluxe.Lib.Sound { AL.GetSource(_source, ALGetSourcei.BuffersProcessed, out processed_count); doit = false; - Console.WriteLine("Buffers Prozessed on Stream " + _source.ToString() + " = " + processed_count.ToString()); + Console.WriteLine("Buffers Processed on Stream " + _source.ToString() + " = " + processed_count.ToString()); if (processed_count < 1) return; } @@ -826,7 +859,7 @@ namespace Vocaluxe.Lib.Sound b[0] = buf[i]; b[1] = buf[i + 1]; - b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume)); + b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume * _VolumeMax)); buf[i] = b[0]; buf[i + 1] = b[1]; @@ -835,7 +868,7 @@ namespace Vocaluxe.Lib.Sound b[0] = buf[i + 2]; b[1] = buf[i + 3]; - b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume)); + b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume * _VolumeMax)); buf[i + 2] = b[0]; buf[i + 3] = b[1]; } diff --git a/Vocaluxe/Lib/Sound/CPortAudioPlay.cs b/Vocaluxe/Lib/Sound/CPortAudioPlay.cs index 6c7ebc7c..ebf80f66 100644 --- a/Vocaluxe/Lib/Sound/CPortAudioPlay.cs +++ b/Vocaluxe/Lib/Sound/CPortAudioPlay.cs @@ -218,6 +218,21 @@ namespace Vocaluxe.Lib.Sound } } + public void SetStreamVolumeMax(int Stream, float Volume) + { + if (_Initialized) + { + lock (MutexDecoder) + { + if (AlreadyAdded(Stream)) + { + _Decoder[GetStreamIndex(Stream)].VolumeMax = Volume; + } + } + + } + } + public float GetLength(int Stream) { if (_Initialized) @@ -375,6 +390,7 @@ namespace Vocaluxe.Lib.Sound private bool _Initialized; private int _ByteCount = 4; private float _Volume = 1f; + private float _VolumeMax = 1f; private Stopwatch _fadeTimer = new Stopwatch(); @@ -480,6 +496,23 @@ namespace Vocaluxe.Lib.Sound } } + public float VolumeMax + { + get { return _VolumeMax * 100f; } + set + { + lock (_LockData) + { + _VolumeMax = value / 100f; + if (_VolumeMax < 0f) + _VolumeMax = 0f; + + if (_VolumeMax > 1f) + _VolumeMax = 1f; + } + } + } + public float Position { get @@ -817,7 +850,7 @@ namespace Vocaluxe.Lib.Sound b[0] = buf[i]; b[1] = buf[i + 1]; - b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume)); + b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume * _VolumeMax)); buf[i] = b[0]; buf[i + 1] = b[1]; @@ -826,7 +859,7 @@ namespace Vocaluxe.Lib.Sound b[0] = buf[i + 2]; b[1] = buf[i + 3]; - b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume)); + b = BitConverter.GetBytes((Int16)(BitConverter.ToInt16(b, 0) * _Volume * _VolumeMax)); buf[i + 2] = b[0]; buf[i + 3] = b[1]; } diff --git a/Vocaluxe/Lib/Sound/IPlayback.cs b/Vocaluxe/Lib/Sound/IPlayback.cs index a1fbd9b1..46fe668e 100644 --- a/Vocaluxe/Lib/Sound/IPlayback.cs +++ b/Vocaluxe/Lib/Sound/IPlayback.cs @@ -37,7 +37,8 @@ namespace Vocaluxe.Lib.Sound void Fade(int Stream, float TargetVolume, float Seconds); void FadeAndPause(int Stream, float TargetVolume, float Seconds); void FadeAndStop(int Stream, float TargetVolume, float Seconds); - void SetStreamVolume(int Stream, float Volume); + void SetStreamVolume(int Stream, float Volume); + void SetStreamVolumeMax(int Stream, float Volume); float GetLength(int Stream); float GetPosition(int Stream); diff --git a/Vocaluxe/Menu/Animations/CAnimation.cs b/Vocaluxe/Menu/Animations/CAnimation.cs new file mode 100644 index 00000000..2d062033 --- /dev/null +++ b/Vocaluxe/Menu/Animations/CAnimation.cs @@ -0,0 +1,92 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Base; +using Vocaluxe.Lib.Draw; + +namespace Vocaluxe.Menu.Animations +{ + public class CAnimation:IAnimation + { + private IAnimation _Animation; + + public CAnimation(EAnimationType Type) + { + setAnimation(Type); + } + + public void Init() + { + _Animation.Init(); + } + + public bool LoadAnimation(string item, XPathNavigator navigator) + { + return _Animation.LoadAnimation(item, navigator); + } + + public bool SaveAnimation(XmlWriter writer) + { + return _Animation.SaveAnimation(writer); + } + + public void StartAnimation() + { + _Animation.StartAnimation(); + } + + public void StopAnimation() + { + _Animation.StopAnimation(); + } + + public void ResetAnimation() + { + _Animation.ResetAnimation(); + } + + public bool AnimationActive() + { + return _Animation.AnimationActive(); + } + + public void Update() + { + _Animation.Update(); + } + + public void setRect(SRectF rect) + { + _Animation.setRect(rect); + } + + public SRectF getRect() + { + return _Animation.getRect(); + } + + public void setColor(SColorF color) + { + _Animation.setColor(color); + } + + public SColorF getColor() + { + return _Animation.getColor(); + } + + public void setAnimation(EAnimationType Type) + { + switch (Type) + { + case EAnimationType.Resize: + _Animation = new CAnimationResize(); + break; + } + } + } +} diff --git a/Vocaluxe/Menu/Animations/CAnimationFramework.cs b/Vocaluxe/Menu/Animations/CAnimationFramework.cs new file mode 100644 index 00000000..3ac3d18c --- /dev/null +++ b/Vocaluxe/Menu/Animations/CAnimationFramework.cs @@ -0,0 +1,95 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Base; +using Vocaluxe.Lib.Draw; + +namespace Vocaluxe.Menu.Animations +{ + public enum EAnimationType + { + Resize + } + + public enum EAnimationRepeat + { + None, + Reset, + Repeat, + RepeatWithReset + } + + public abstract class CAnimationFramework:IAnimation + { + public bool _AnimationLoaded; + + public EAnimationType Type; + public EAnimationRepeat Repeat; + public float Speed; + + public Stopwatch Timer = new Stopwatch(); + public bool ResetMode = false; + + public abstract void Init(); + + public virtual bool LoadAnimation(string item, XPathNavigator navigator) + { + _AnimationLoaded = true; + + _AnimationLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Speed", navigator, ref Speed); + _AnimationLoaded &= CHelper.TryGetEnumValueFromXML(item + "/Repeat", navigator, ref Repeat); + + return _AnimationLoaded; + } + + public virtual bool SaveAnimation(XmlWriter writer) + { + return false; + } + + public virtual void StartAnimation() + { + Timer.Start(); + } + + public virtual void StopAnimation() + { + Timer.Stop(); + Timer.Reset(); + } + + public virtual void ResetAnimation() + { + ResetMode = !ResetMode; + } + + public virtual bool AnimationActive() + { + return Timer.IsRunning; + } + + public virtual void setRect(SRectF rect) + { + } + + public virtual SRectF getRect() + { + return new SRectF(); + } + + public virtual void setColor(SColorF color) + { + } + + public virtual SColorF getColor() + { + return new SColorF(); + } + + public abstract void Update(); + } +} diff --git a/Vocaluxe/Menu/Animations/CAnimationResize.cs b/Vocaluxe/Menu/Animations/CAnimationResize.cs new file mode 100644 index 00000000..ecc77feb --- /dev/null +++ b/Vocaluxe/Menu/Animations/CAnimationResize.cs @@ -0,0 +1,106 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Base; +using Vocaluxe.Lib.Draw; + +namespace Vocaluxe.Menu.Animations +{ + public class CAnimationResize : CAnimationFramework + { + public SRectF FinalRect; + public SRectF CurrentRect; + public SRectF OriginalRect; + + public CAnimationResize() + { + } + + public override void Init() + { + Type = EAnimationType.Resize; + } + + public override bool LoadAnimation(string item, XPathNavigator navigator) + { + //Load normal animation-options + _AnimationLoaded &= base.LoadAnimation(item, navigator); + + //Load specific animation-options + _AnimationLoaded &= CHelper.TryGetFloatValueFromXML(item + "/X", navigator, ref FinalRect.X); + _AnimationLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Y", navigator, ref FinalRect.Y); + _AnimationLoaded &= CHelper.TryGetFloatValueFromXML(item + "/W", navigator, ref FinalRect.W); + _AnimationLoaded &= CHelper.TryGetFloatValueFromXML(item + "/H", navigator, ref FinalRect.H); + + return _AnimationLoaded; + } + + public override void setRect(SRectF rect) + { + OriginalRect = rect; + } + + public override SRectF getRect() + { + return CurrentRect; + } + + public override void StartAnimation() + { + base.StartAnimation(); + + CurrentRect = OriginalRect; + } + + public override void Update() + { + //Update CurrentRect + if (!ResetMode) + { + CLog.LogError((CurrentRect.X + ((FinalRect.X - CurrentRect.X) / Speed * Timer.ElapsedMilliseconds)).ToString("#.#####")); + CurrentRect.X = CurrentRect.X + ((FinalRect.X - CurrentRect.X) / Speed * Timer.ElapsedMilliseconds); + CurrentRect.Y = CurrentRect.Y + ((FinalRect.Y - CurrentRect.Y) / Speed * Timer.ElapsedMilliseconds); + CurrentRect.H = CurrentRect.H + ((FinalRect.H - CurrentRect.H) / Speed * Timer.ElapsedMilliseconds); + CurrentRect.W = CurrentRect.W + ((FinalRect.W - CurrentRect.W) / Speed * Timer.ElapsedMilliseconds); + } + else + { + CurrentRect.X = CurrentRect.X + ((OriginalRect.X - CurrentRect.X) / Speed * Timer.ElapsedMilliseconds); + CurrentRect.Y = CurrentRect.Y + ((OriginalRect.Y - CurrentRect.Y) / Speed * Timer.ElapsedMilliseconds); + CurrentRect.H = CurrentRect.H + ((OriginalRect.H - CurrentRect.H) / Speed * Timer.ElapsedMilliseconds); + CurrentRect.W = CurrentRect.W + ((OriginalRect.W - CurrentRect.W) / Speed * Timer.ElapsedMilliseconds); + } + + if (CurrentRect.X == FinalRect.X && CurrentRect.Y == FinalRect.Y && CurrentRect.H == FinalRect.H && CurrentRect.W == FinalRect.W) + { + switch (Repeat) + { + case EAnimationRepeat.Repeat: + StopAnimation(); + CurrentRect = OriginalRect; + StartAnimation(); + break; + + case EAnimationRepeat.RepeatWithReset: + ResetAnimation(); + break; + + case EAnimationRepeat.Reset: + if (!ResetMode) + ResetAnimation(); + else + StopAnimation(); + break; + + case EAnimationRepeat.None: + StopAnimation(); + break; + } + } + } + } +} diff --git a/Vocaluxe/Menu/Animations/IAnimation.cs b/Vocaluxe/Menu/Animations/IAnimation.cs new file mode 100644 index 00000000..444181c7 --- /dev/null +++ b/Vocaluxe/Menu/Animations/IAnimation.cs @@ -0,0 +1,30 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Base; +using Vocaluxe.Lib.Draw; + +namespace Vocaluxe.Menu.Animations +{ + interface IAnimation + { + void Init(); + bool LoadAnimation(string item, XPathNavigator navigator); + bool SaveAnimation(XmlWriter writer); + + void setRect(SRectF rect); + SRectF getRect(); + void setColor(SColorF color); + SColorF getColor(); + + void StartAnimation(); + void StopAnimation(); + void ResetAnimation(); + bool AnimationActive(); + void Update(); + } +} diff --git a/Vocaluxe/Menu/CBackground.cs b/Vocaluxe/Menu/CBackground.cs index cedc4eb5..1b6b0b83 100644 --- a/Vocaluxe/Menu/CBackground.cs +++ b/Vocaluxe/Menu/CBackground.cs @@ -38,6 +38,11 @@ namespace Vocaluxe.Menu public SColorF Color; + public string GetThemeName() + { + return _Theme.Name; + } + #region Constructors public CBackground() { diff --git a/Vocaluxe/Menu/CButton.cs b/Vocaluxe/Menu/CButton.cs index d4b5d231..2e018ffa 100644 --- a/Vocaluxe/Menu/CButton.cs +++ b/Vocaluxe/Menu/CButton.cs @@ -30,7 +30,9 @@ namespace Vocaluxe.Menu public SColorF Color; public SColorF SColor; + public bool SelText; public CText Text; + public CText SText; public bool Reflection; public float ReflectionSpace; @@ -40,8 +42,19 @@ namespace Vocaluxe.Menu public float SReflectionSpace; public float SReflectionHeight; - private bool _Selected; public bool Pressed; + + public bool EditMode + { + get { return Text.EditMode; } + set + { + Text.EditMode = value; + SText.EditMode = value; + } + } + + private bool _Selected; public bool Selected { get { return _Selected; } @@ -53,6 +66,11 @@ namespace Vocaluxe.Menu } public bool Visible; + public string GetThemeName() + { + return _Theme.Name; + } + public CButton() { _Theme = new SThemeButton(); @@ -60,9 +78,12 @@ namespace Vocaluxe.Menu Color = new SColorF(); SColor = new SColorF(); + SelText = false; Text = new CText(); + SText = new CText(); Selected = false; Visible = true; + EditMode = false; Reflection = false; ReflectionSpace = 0f; @@ -113,6 +134,13 @@ namespace Vocaluxe.Menu _ThemeLoaded &= Text.LoadTheme(item, "Text", navigator, SkinIndex, true); Text.Z = Rect.Z; + if (CHelper.ItemExistsInXML(item + "/SText", navigator)) + { + SelText = true; + _ThemeLoaded &= SText.LoadTheme(item, "SText", navigator, SkinIndex, true); + SText.Z = Rect.Z; + } + //Reflections if (CHelper.ItemExistsInXML(item + "/Reflection", navigator)) @@ -189,6 +217,8 @@ namespace Vocaluxe.Menu } Text.SaveTheme(writer); + if (SelText) + SText.SaveTheme(writer); writer.WriteComment(" If exists:"); writer.WriteComment(" : Reflection Space"); @@ -240,28 +270,42 @@ namespace Vocaluxe.Menu { texture = CTheme.GetSkinTexture(_Theme.TextureName); CDraw.DrawTexture(texture, Rect, Color); + Text.DrawRelative(Rect.X, Rect.Y); if (Reflection) { CDraw.DrawTextureReflection(texture, Rect, Color, Rect, ReflectionSpace, ReflectionHeight); + Text.DrawRelative(Rect.X, Rect.Y, ReflectionSpace, ReflectionHeight, Rect.H); } } - else + else if(!SelText) { texture = CTheme.GetSkinTexture(_Theme.STextureName); CDraw.DrawTexture(texture, Rect, SColor); + Text.DrawRelative(Rect.X, Rect.Y); if (Reflection) { CDraw.DrawTextureReflection(texture, Rect, SColor, Rect, ReflectionSpace, ReflectionHeight); + Text.DrawRelative(Rect.X, Rect.Y, ReflectionSpace, ReflectionHeight, Rect.H); } } - - Text.DrawRelative(Rect.X, Rect.Y); - if (Reflection) + else if(SelText) { - Text.DrawRelative(Rect.X, Rect.Y, ReflectionSpace, ReflectionHeight, Rect.H); + texture = CTheme.GetSkinTexture(_Theme.STextureName); + CDraw.DrawTexture(texture, Rect, SColor); + SText.DrawRelative(Rect.X, Rect.Y); + if (Reflection) + { + CDraw.DrawTextureReflection(texture, Rect, SColor, Rect, ReflectionSpace, ReflectionHeight); + SText.DrawRelative(Rect.X, Rect.Y, ReflectionSpace, ReflectionHeight, Rect.H); + } } } + public void ProcessMouseMove(int x, int y) + { + Selected = CHelper.IsInBounds(Rect, x, y); + } + public void UnloadTextures() { Text.UnloadTextures(); diff --git a/Vocaluxe/Menu/CEqualizer.cs b/Vocaluxe/Menu/CEqualizer.cs new file mode 100644 index 00000000..4b8c3997 --- /dev/null +++ b/Vocaluxe/Menu/CEqualizer.cs @@ -0,0 +1,310 @@ +using System; +using System.Collections.Generic; +using System.Drawing; +using System.Text; +using System.Xml; +using System.Xml.XPath; + +using Vocaluxe.Base; +using Vocaluxe.Lib.Draw; + +namespace Vocaluxe.Menu +{ + enum EEqualizerStyle + { + Collums + } + + struct SThemeEqualizer + { + public string Name; + + public string ColorName; + public string MaxColorName; + public string TextureName; + + public int NumBars; + + public EEqualizerStyle Style; + public EOffOn DrawNegative; + } + + class CEqualizer : IMenuElement + { + private SThemeEqualizer _Theme; + private bool _ThemeLoaded; + + public SRectF Rect; + public SColorF Color; + public SColorF MaxColor; + public float Space; + + public bool Reflection; + public float ReflectionSpace; + public float ReflectionHeight; + + public bool Selected; + public bool Visible; + public bool ScreenHandles; + + public string GetThemeName() + { + return _Theme.Name; + } + + private float[] _Bars; + + public CEqualizer() + { + _Theme = new SThemeEqualizer(); + _ThemeLoaded = false; + + Rect = new SRectF(); + Color = new SColorF(); + MaxColor = new SColorF(); + + Selected = false; + Visible = true; + ScreenHandles = false; + + Reflection = false; + ReflectionSpace = 0f; + ReflectionHeight = 0f; + } + + public bool LoadTheme(string XmlPath, string ElementName, XPathNavigator navigator, int SkinIndex) + { + string item = XmlPath + "/" + ElementName; + _ThemeLoaded = true; + + _ThemeLoaded &= CHelper.GetValueFromXML(item + "/Skin", navigator, ref _Theme.TextureName, String.Empty); + + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/X", navigator, ref Rect.X); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Y", navigator, ref Rect.Y); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Z", navigator, ref Rect.Z); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/W", navigator, ref Rect.W); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/H", navigator, ref Rect.H); + + _ThemeLoaded &= CHelper.TryGetIntValueFromXML(item + "/NumBars", navigator, ref _Theme.NumBars); + + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Space", navigator, ref Space); + + _ThemeLoaded &= CHelper.TryGetEnumValueFromXML(item + "/Style", navigator, ref _Theme.Style); + + _ThemeLoaded &= CHelper.TryGetEnumValueFromXML(item + "/DrawNegative", navigator, ref _Theme.DrawNegative); + + if (CHelper.GetValueFromXML(item + "/Color", navigator, ref _Theme.ColorName, String.Empty)) + { + _ThemeLoaded &= CTheme.GetColor(_Theme.ColorName, SkinIndex, ref Color); + } + else + { + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/R", navigator, ref Color.R); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/G", navigator, ref Color.G); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/B", navigator, ref Color.B); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/A", navigator, ref Color.A); + } + + if (CHelper.GetValueFromXML(item + "/MaxColor", navigator, ref _Theme.MaxColorName, String.Empty)) + { + _ThemeLoaded &= CTheme.GetColor(_Theme.ColorName, SkinIndex, ref Color); + } + else + { + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/MaxR", navigator, ref MaxColor.R); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/MaxG", navigator, ref MaxColor.G); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/MaxB", navigator, ref MaxColor.B); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/MaxA", navigator, ref MaxColor.A); + } + + //Reflection + if (CHelper.ItemExistsInXML(item + "/Reflection", navigator)) + { + Reflection = true; + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Reflection/Space", navigator, ref ReflectionSpace); + _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Reflection/Height", navigator, ref ReflectionHeight); + } + else + Reflection = false; + + if (_ThemeLoaded) + { + _Theme.Name = ElementName; + _Bars = new float[_Theme.NumBars]; + for (int i = 0; i < _Bars.Length; i++) + { + _Bars[i] = 0f; + } + LoadTextures(); + } + return _ThemeLoaded; + } + + public bool SaveTheme(XmlWriter writer) + { + if (_ThemeLoaded) + { + writer.WriteStartElement(_Theme.Name); + + writer.WriteComment(": Texture name"); + writer.WriteElementString("Skin", _Theme.TextureName); + + writer.WriteComment(", , , , : Equalizer position, width and height"); + writer.WriteElementString("X", Rect.X.ToString("#0")); + writer.WriteElementString("Y", Rect.Y.ToString("#0")); + writer.WriteElementString("Z", Rect.Z.ToString("#0.00")); + writer.WriteElementString("W", Rect.W.ToString("#0")); + writer.WriteElementString("H", Rect.H.ToString("#0")); + + writer.WriteComment(": Number of equalizer-elements."); + writer.WriteElementString("NumBars", _Theme.NumBars.ToString("#0")); + writer.WriteComment(": Space between equalizer-elements."); + writer.WriteElementString("Space", Space.ToString("#0.00")); + writer.WriteComment("