diff --git a/Output/Languages/Deutsch.xml b/Output/Languages/Deutsch.xml
index be0b28c6..845b01ae 100644
--- a/Output/Languages/Deutsch.xml
+++ b/Output/Languages/Deutsch.xml
@@ -23,6 +23,7 @@
Normal
Duett
Medley
+ Kurz-Version
Vocal Hero
Superstar
@@ -88,6 +89,10 @@
Eigene Musik und Hintergrundmusik
Keine eigene Musik
Nur eigene Musik
+
+ Alle
+ Nur Namen und Avatar
+ Keine
Laden
@@ -101,13 +106,23 @@
Profile
Spielerauswahl
- 1 Spieler
- 2 Spieler
- 3 Spieler
- Warnung: Dem Spieler %v ist kein Mikrofon zugeordnet!
- Warnung: Den Spielern %v sind keine Mikrofone zugeordnet!
+ Spieler
+ 1 Spieler
+ 2 Spieler
+ 3 Spieler
+ 4 Spieler
+ 5 Spieler
+ 6 Spieler
+ Warnung: Dem Spieler %v ist kein Mikrofon zugeordnet!
+ Warnung: Den Spielern %v sind keine Mikrofone zugeordnet!
+ Warnung: Dem Spieler %v ist kein Profil zugeordnet!
+ Warnung: Den Spielern %v sind keine Profile zugeordnet!
Songauswahl
+ Lied singen
+ Zur Playlist hinzufügen
+ Schließen
+ Lied-Optionen
Suche:
Ohne Sprache
Ohne Jahr
@@ -142,6 +157,7 @@
Sound
Aufnahme
Video
+ Songtext
Design
Spieleinstellungen
@@ -174,11 +190,17 @@
Noten-Linien anzeigen
Ton-Helfer anzeigen
Aussehen des Timers
+ Spieler-Infos ein/ausblenden
Cover Ladeverhalten
+
+ Songtexteinstellungen
+ Stil
+ Oben anzeigen
Videoeinstellungen
Video-Hintergründe
Video-Vorschau
Videos während des Singens
+ Videos der Hintergrundmusik
diff --git a/Output/Languages/English.xml b/Output/Languages/English.xml
index 50a87ba8..1639ea9d 100644
--- a/Output/Languages/English.xml
+++ b/Output/Languages/English.xml
@@ -23,6 +23,7 @@
Normal
Duet
Medley
+ Short version
Vocal Hero
Superstar
@@ -88,6 +89,10 @@
Own Music and Background Music
No own Music
Only own Music
+
+ All
+ Only names and avatars
+ Nothing
Loading
@@ -101,13 +106,23 @@
Profiles
Player Selection
- 1 Player
- 2 Player
- 3 Player
- Warning: There is no mic assigned to player %v!
- Warning: There are no mics assigned to players %v!
+ Player
+ 1 Player
+ 2 Player
+ 3 Player
+ 4 Player
+ 5 Player
+ 6 Player
+ Warning: There is no mic assigned to player %v!
+ Warning: There are no mics assigned to players %v!
+ Warning: There is no profile assigned to player %v!
+ Warning: There are no profiles assigned to players %v!
Song Selection
+ Sing
+ Add to playlist
+ Close
+ Song Options
Search:
No Language
No Year
@@ -142,6 +157,7 @@
Sound
Record
Video
+ Lyrics
Theme
Game Options
@@ -174,11 +190,17 @@
Show Note-Lines
Show Tone-Helper
Timer-Look
+ Fade player-info
Cover Loading Behavior
+
+ Lyrics Options
+ Style
+ Lyrics on top
Video Options
Video Backgrounds
Video Preview
Videos while singing
+ Display current backgroundmusic video
diff --git a/Output/Languages/French.xml b/Output/Languages/French.xml
index 2c2f7944..f60e82a3 100644
--- a/Output/Languages/French.xml
+++ b/Output/Languages/French.xml
@@ -101,11 +101,17 @@
Profils
Sélection des joueurs
- 1 joueur
- 2 joueurs
- 3 joueurs
- Attention: Aucun micro n'est assigné au joueur %v!
- Attention: Aucun micro n'est assigné aux joueurs %v!
+ Joueur
+ 1 joueur
+ 2 joueurs
+ 3 joueurs
+ 4 joueurs
+ 5 joueurs
+ 6 joueurs
+ Attention: Aucun micro n'est assigné au joueur %v!
+ Attention: Aucun micro n'est assigné aux joueurs %v!
+ Attention: Aucun profil n'est assigné au joueur %v!
+ Attention: Aucun profils n'est assigné aux joueurs %v!
Choix de la chanson
Rechercher:
@@ -180,5 +186,6 @@
Vidéo en arrière plan
Prévisualisation des Vidéos
Vidéos pendant que l'on chante
+ Afficher la vidéo de la musique de fond
diff --git a/Output/Languages/Spanish.xml b/Output/Languages/Spanish.xml
index d304e24c..483e30a3 100644
--- a/Output/Languages/Spanish.xml
+++ b/Output/Languages/Spanish.xml
@@ -101,11 +101,17 @@
Perfiles
Selección de Jugadores
- Jugador 1
- Jugador 2
- Jugador 3
- Advertencia: ¡No hay micrófonos asignados al jugador %v!
- Advertencia: ¡No hay micrófonos asignados a los jugadores %v!
+ Jugador
+ Jugador 1
+ Jugador 2
+ Jugador 3
+ Jugador 4
+ Jugador 5
+ Jugador 6
+ Advertencia: ¡No hay micrófonos asignados al jugador %v!
+ Advertencia: ¡No hay micrófonos asignados a los jugadores %v!
+ Advertencia: ¡No hay perfil asignados al jugador %v!
+ Advertencia: ¡No hay perfiles asignados a los jugadores %v!
Selección de Canciones
Buscar:
@@ -180,5 +186,6 @@
Videos de Fondo
Previsualización del Video
Videos al Cantar
+ TODO: Display current backgroundmusic video
diff --git a/Output/Playlists/Test.xml b/Output/Playlists/Test.xml
new file mode 100644
index 00000000..8e5b1b98
--- /dev/null
+++ b/Output/Playlists/Test.xml
@@ -0,0 +1,23 @@
+
+
+
+ Test
+
+
+
+ 2raumwohnung
+ 36 grad
+ TR_GAMEMODE_NORMAL
+
+
+ Aura Dione
+ Geronimo
+ TR_GAMEMODE_SHORTSONG
+
+
+ Die Toten Hosen
+ Tage wie diese
+ TR_GAMEMODE_MEDLEY
+
+
+
\ No newline at end of file
diff --git a/Output/Themes/Ambient.xml b/Output/Themes/Ambient.xml
index 25940dca..a1ed18a6 100644
--- a/Output/Themes/Ambient.xml
+++ b/Output/Themes/Ambient.xml
@@ -12,9 +12,6 @@
Cursor
40,000
40,000
- 0,675
- 0,890
- 0,969
- 1,000
+ StaticColor
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/NextIcon.png b/Output/Themes/Ambient/NextIcon.png
new file mode 100644
index 00000000..fb6bf6c4
Binary files /dev/null and b/Output/Themes/Ambient/NextIcon.png differ
diff --git a/Output/Themes/Ambient/PauseIcon.png b/Output/Themes/Ambient/PauseIcon.png
new file mode 100644
index 00000000..6f9c8870
Binary files /dev/null and b/Output/Themes/Ambient/PauseIcon.png differ
diff --git a/Output/Themes/Ambient/PlayIcon.png b/Output/Themes/Ambient/PlayIcon.png
new file mode 100644
index 00000000..5f34140b
Binary files /dev/null and b/Output/Themes/Ambient/PlayIcon.png differ
diff --git a/Output/Themes/Ambient/PlayerSelector.png b/Output/Themes/Ambient/PlayerSelector.png
new file mode 100644
index 00000000..c57ab300
Binary files /dev/null and b/Output/Themes/Ambient/PlayerSelector.png differ
diff --git a/Output/Themes/Ambient/PreviousIcon.png b/Output/Themes/Ambient/PreviousIcon.png
new file mode 100644
index 00000000..9a92bf23
Binary files /dev/null and b/Output/Themes/Ambient/PreviousIcon.png differ
diff --git a/Output/Themes/Ambient/RepeatIcon.png b/Output/Themes/Ambient/RepeatIcon.png
new file mode 100644
index 00000000..6675a41a
Binary files /dev/null and b/Output/Themes/Ambient/RepeatIcon.png differ
diff --git a/Output/Themes/Ambient/Resources/NextIcon.psd b/Output/Themes/Ambient/Resources/NextIcon.psd
new file mode 100644
index 00000000..a6af8829
Binary files /dev/null and b/Output/Themes/Ambient/Resources/NextIcon.psd differ
diff --git a/Output/Themes/Ambient/Resources/PauseIcon.psd b/Output/Themes/Ambient/Resources/PauseIcon.psd
new file mode 100644
index 00000000..2046e471
Binary files /dev/null and b/Output/Themes/Ambient/Resources/PauseIcon.psd differ
diff --git a/Output/Themes/Ambient/Resources/PlayIcon.psd b/Output/Themes/Ambient/Resources/PlayIcon.psd
new file mode 100644
index 00000000..ba63fc5c
Binary files /dev/null and b/Output/Themes/Ambient/Resources/PlayIcon.psd differ
diff --git a/Output/Themes/Ambient/Resources/PreviousIcon.psd b/Output/Themes/Ambient/Resources/PreviousIcon.psd
new file mode 100644
index 00000000..0e5756eb
Binary files /dev/null and b/Output/Themes/Ambient/Resources/PreviousIcon.psd differ
diff --git a/Output/Themes/Ambient/Resources/RepeatIcon.psd b/Output/Themes/Ambient/Resources/RepeatIcon.psd
new file mode 100644
index 00000000..cd1a0637
Binary files /dev/null and b/Output/Themes/Ambient/Resources/RepeatIcon.psd differ
diff --git a/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml b/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml
new file mode 100644
index 00000000..df19d2c3
--- /dev/null
+++ b/Output/Themes/Ambient/Screens/PopupScreenPlayerControl.xml
@@ -0,0 +1,442 @@
+
+
+
+ 1
+
+
+ Menu
+
+ 49
+ 0
+ 0,00
+ 1181
+ 50
+
+
+ Visible
+
+
+
+
+
+
+ CoverBackground
+
+ 50
+ 0
+ 0,00
+ 50
+ 50
+
+
+ Visible
+
+
+
+
+
+
+ PreviousIcon
+
+ PreviousIcon
+
+ 125
+ 0
+ 0,00
+ 50
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 75
+ 2
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ PlayIcon
+
+ PlayIcon
+
+ 200
+ 5
+ 0,00
+ 40
+ 40
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 75
+ 2
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ PauseIcon
+
+ PauseIcon
+
+ 200
+ 5
+ 0,00
+ 40
+ 40
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 75
+ 2
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ NextIcon
+
+ NextIcon
+
+ 265
+ 0
+ 0,00
+ 50
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 190
+ 25
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ RepeatIcon
+
+ RepeatIcon
+
+ 330
+ 0
+ 0,00
+ 50
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 405
+ 25
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ VideoIcon
+
+ VideoIcon
+
+ 405
+ 0
+ 0,00
+ 50
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 315
+ 0
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ VideoIcon
+
+ VideoIcon
+
+ 480
+ 0
+ 0,00
+ 50
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 315
+ 0
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ DuetIcon
+
+ DuetIcon
+
+ 555
+ 0
+ 0,00
+ 50
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 380
+ 0
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+
+
+
+
+ 630
+ 0
+
+ 0,00
+
+ 50
+
+ 650
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Left
+
+
+
+ Outline
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Output/Themes/Ambient/Screens/ScreenNames.xml b/Output/Themes/Ambient/Screens/ScreenNames.xml
index 20a2026b..a16e4651 100644
--- a/Output/Themes/Ambient/Screens/ScreenNames.xml
+++ b/Output/Themes/Ambient/Screens/ScreenNames.xml
@@ -1,7 +1,7 @@
- 1
+ 2
Video
@@ -29,12 +29,204 @@
-
+
+
+ PlayerSelector
+
+ 15
+ 100
+ -2,00
+ 118
+ 118
+
+
+ Player1
+
+
+
+
+
+
+ PlayerSelector
+
+ 15
+ 255
+ -2,00
+ 118
+ 118
+
+
+ Player2
+
+
+
+
+
+
+ PlayerSelector
+
+ 15
+ 410
+ -2,00
+ 118
+ 118
+
+
+ Player3
+
+
+
+
+
+
+ PlayerSelector
+
+ 1147
+ 100
+ -2,00
+ 118
+ 118
+
+
+ Player4
+
+
+
+
+
+
+ PlayerSelector
+
+ 1147
+ 255
+ -2,00
+ 118
+ 118
+
+
+ Player5
+
+
+
+
+
+
+ PlayerSelector
+
+ 1147
+ 410
+ -2,00
+ 118
+ 118
+
+
+ Player6
+
+
+
+
+
+
+ Invisible
+
+ 20
+ 105
+ -3,00
+ 108
+ 108
+
+
+ Visible
+
+
+
+
+
+
+ Invisible
+
+ 20
+ 260
+ -3,00
+ 108
+ 108
+
+
+ Visible
+
+
+
+
+
+
+ Invisible
+
+ 20
+ 415
+ -3,00
+ 108
+ 108
+
+
+ Visible
+
+
+
+
+
+
+ Invisible
+
+ 1152
+ 105
+ -3,00
+ 108
+ 108
+
+
+ Visible
+
+
+
+
+
+
+ Invisible
+
+ 1152
+ 260
+ -3,00
+ 108
+ 108
+
+
+ Visible
+
+
+
+
+
+
+ Invisible
+
+ 1152
+ 415
+ -3,00
+ 108
+ 108
+
+
+ Visible
+
+
+
+
+
Invisible
145
- 660
+ 663
0,00
990
50
@@ -44,7 +236,23 @@
-
+
+
+
+ Invisible
+
+ 145
+ 715
+ 0,00
+ 990
+ 50
+
+
+ StaticWarningColor
+
+
+
+
640
@@ -72,10 +280,10 @@
-
+
640
- 612
+ 615
0,00
@@ -99,7 +307,197 @@
-
+
+
+
+ 640
+ 650
+
+ 0,00
+
+ 32
+
+ 970
+
+
+ TextWarningColor
+
+
+ TextWarningColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 74
+ 219
+
+ 0,00
+
+ 20
+
+
+
+ Player1
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 74
+ 374
+
+ 0,00
+
+ 20
+
+
+
+ Player2
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 74
+ 529
+
+ 0,00
+
+ 20
+
+
+
+ Player3
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1206
+ 219
+
+ 0,00
+
+ 20
+
+
+
+ Player4
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1206
+ 374
+
+ 0,00
+
+ 20
+
+
+
+ Player5
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1206
+ 529
+
+ 0,00
+
+ 20
+
+
+
+ Player6
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
Button
@@ -107,7 +505,7 @@
Button
145
- 600
+ 603
0,00
150
50
@@ -162,7 +560,7 @@
Button
985
- 600
+ 603
0,00
150
50
@@ -210,148 +608,7 @@
26
-
-
- Button
-
- Button
-
- 145
- 150
- 0,00
- 150
- 50
-
-
- ButtonColor
-
-
- ButtonSColor
-
-
- 75
- 10
-
- 32
-
- 142
-
-
- ButtonTextSColor
-
-
- ButtonTextSColor
-
- Center
-
-
-
- Outline
-
- TR_SCREENNAMES_BUTTON_1PLAYER
-
-
-
-
-
-
-
-
-
-
- Button
-
- Button
-
- 145
- 315
- 0,00
- 150
- 50
-
-
- ButtonColor
-
-
- ButtonSColor
-
-
- 75
- 10
-
- 32
-
- 142
-
-
- ButtonTextSColor
-
-
- ButtonTextSColor
-
- Center
-
-
-
- Outline
-
- TR_SCREENNAMES_BUTTON_2PLAYER
-
-
-
-
-
-
-
-
-
-
- Button
-
- Button
-
- 145
- 480
- 0,00
- 150
- 50
-
-
- ButtonColor
-
-
- ButtonSColor
-
-
- 75
- 10
-
- 32
-
- 142
-
-
- ButtonTextSColor
-
-
- ButtonTextSColor
-
- Center
-
-
-
- Outline
-
- TR_SCREENNAMES_BUTTON_3PLAYER
-
-
-
-
-
-
-
-
-
+
Invisible
@@ -367,32 +624,32 @@
SelectSlidePlayer
- 305
- 100
+ 70
+ 548
0,00
- 905
- 150
+ 1140
+ 45
- 305
- 155
+ 75
+ 553
0,00
40
40
- 1180
- 155
+ 1170
+ 553
0,00
40
40
- Player1Dim
+ SelectSlideColor
- Player1Dim
+ SelectSlideSColor
- Player1
+ SelectSlideHColor
ArrowColor
@@ -404,7 +661,7 @@
TextColor
- Player1
+ TextSColor
32,00
@@ -415,136 +672,49 @@
Bold
6
-
-
-
- Invisible
-
- SelectSlideArrowLeft
-
- SelectSlideArrowRight
-
- SelectSlidePlayer
-
- SelectSlideArrowLeft
-
- SelectSlideArrowRight
-
- SelectSlidePlayer
-
- 305
- 265
+
+
+
+ 172
+ 127
0,00
- 905
- 150
-
- 305
- 320
- 0,00
- 40
- 40
-
- 1180
- 320
- 0,00
- 40
- 40
-
+ 945
+ 393
+
+ CoverTile
+
- Player2Dim
-
-
- Player2Dim
-
-
- Player2
-
-
- ArrowColor
-
-
- ArrowSColor
-
-
- TextColor
-
-
- Player2
-
- 32,00
-
- 186,00
-
- Outline
-
- Bold
-
- 6
-
-
-
- Invisible
-
- SelectSlideArrowLeft
-
- SelectSlideArrowRight
-
- SelectSlidePlayer
-
- SelectSlideArrowLeft
-
- SelectSlideArrowRight
-
- SelectSlidePlayer
-
- 305
- 430
- 0,00
- 905
- 150
-
- 305
- 485
- 0,00
- 40
- 40
-
- 1180
- 485
- 0,00
- 40
- 40
-
-
- Player3Dim
-
-
- Player3Dim
-
-
- Player3
-
-
- ArrowColor
-
-
- ArrowSColor
-
-
- TextColor
-
-
- Player3
-
- 32,00
-
- 186,00
-
- Outline
-
- Bold
-
- 6
-
+ 1,00
+ 1,00
+ 1,00
+ 0,20
+
+ PlayerSelector
+
+
+
+ 100
+ 100
+
+ 8
+ 3
+
+ 20,71
+ 30,00
+
+
+
+ 2,0
+
+ Outline
+
+ TextColor
+
+
+
+ 20
+
+
+
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Screens/ScreenOptions.xml b/Output/Themes/Ambient/Screens/ScreenOptions.xml
index 9bf1033a..03cf6f05 100644
--- a/Output/Themes/Ambient/Screens/ScreenOptions.xml
+++ b/Output/Themes/Ambient/Screens/ScreenOptions.xml
@@ -62,7 +62,7 @@
Button
- 145
+ 54,7
600
0,00
150
@@ -117,7 +117,7 @@
Button
- 355
+ 259,4
600
0,00
150
@@ -172,7 +172,7 @@
Button
- 565
+ 464,1
600
0,00
150
@@ -227,7 +227,7 @@
Button
- 775
+ 668,8
600
0,00
150
@@ -276,13 +276,68 @@
26
+
+
+ Button
+
+ Button
+
+ 873,5
+ 600
+ 0,00
+ 150
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 75
+ 10
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_SCREENO_BUTTON_LYRICS
+
+
+
+
+
+ 10
+ 26
+
+
+
+
+
+ 10
+ 26
+
+
Button
Button
- 985
+ 1078,2
600
0,00
150
@@ -332,4 +387,4 @@
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml b/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml
new file mode 100644
index 00000000..bf79c927
--- /dev/null
+++ b/Output/Themes/Ambient/Screens/ScreenOptionsLyrics.xml
@@ -0,0 +1,299 @@
+
+
+
+ 1
+
+
+ Video
+
+
+
+ BG_Options
+
+
+ BackgroundColor
+
+
+
+ Menu
+
+ 40
+ 40
+ 0,00
+ 1200
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ 640
+ 48
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_SCREENOLYRICS_OPTIONS
+
+
+
+
+
+
+ 75
+ 105
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Left
+
+
+
+ Outline
+
+ TR_SCREENOLYRICS_STYLE
+
+
+
+
+
+
+ 75
+ 165
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Left
+
+
+
+ Outline
+
+ TR_SCREENOLYRICS_ONTOP
+
+
+
+
+
+
+ Button
+
+ Button
+
+ 145
+ 600
+ 0,00
+ 150
+ 50
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 75
+ 10
+
+ 32
+
+ 142
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_BUTTON_BACK
+
+
+
+
+
+ 10
+ 26
+
+
+
+
+
+ 10
+ 26
+
+
+
+
+ Invisible
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ 500
+ 100
+ 0,00
+ 700
+ 50
+
+ 505
+ 105
+ 0,00
+ 40
+ 40
+
+ 1170
+ 105
+ 0,00
+ 40
+ 40
+
+
+ SelectSlideColor
+
+
+ SelectSlideSColor
+
+
+ SelectSlideHColor
+
+
+ ArrowColor
+
+
+ ArrowSColor
+
+
+ TextColor
+
+
+ TextSColor
+
+ 32,00
+
+ 205,33
+
+ Outline
+
+ Bold
+
+ 4
+
+
+
+ Invisible
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ 500
+ 160
+ 0,00
+ 700
+ 50
+
+ 505
+ 165
+ 0,00
+ 40
+ 40
+
+ 1170
+ 165
+ 0,00
+ 40
+ 40
+
+
+ SelectSlideColor
+
+
+ SelectSlideSColor
+
+
+ SelectSlideHColor
+
+
+ ArrowColor
+
+
+ ArrowSColor
+
+
+ TextColor
+
+
+ TextSColor
+
+ 32,00
+
+ 205,33
+
+ Outline
+
+ Bold
+
+ 2
+
+
+
diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml b/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml
index 0e43d77c..06cbccf2 100644
--- a/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml
+++ b/Output/Themes/Ambient/Screens/ScreenOptionsRecord.xml
@@ -704,7 +704,7 @@
Bold
- 4
+ 7
@@ -769,7 +769,7 @@
Bold
- 4
+ 7
diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml b/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml
index 35751819..756d6a5c 100644
--- a/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml
+++ b/Output/Themes/Ambient/Screens/ScreenOptionsSound.xml
@@ -40,16 +40,10 @@
- 0,68
- 0,89
- 0,97
- 1,00
+ StaticColor
- 0,68
- 0,89
- 0,97
- 1,00
+ TextSColor
Center
@@ -394,4 +388,4 @@
1
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml b/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml
index ac972646..55ed1267 100644
--- a/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml
+++ b/Output/Themes/Ambient/Screens/ScreenOptionsTheme.xml
@@ -1,7 +1,7 @@
- 2
+ 3
Video
@@ -141,6 +141,22 @@
+
+
+ Invisible
+
+ 50
+ 520
+ 0,00
+ 460
+ 50
+
+
+ StaticColor
+
+
+
+
640
@@ -352,11 +368,38 @@
Outline
- TR_SCREENOTHEME_COVERLOADING
+ TR_SCREENOTHEME_FADEINFO
+
+
+ 75
+ 525
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Left
+
+
+
+ Outline
+
+ TR_SCREENOTHEME_COVERLOADING
+
+
+
+
Button
@@ -802,7 +845,7 @@
2
-
+
Invisible
@@ -865,7 +908,72 @@
Bold
+ 2
+
+
+
+ Invisible
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ 500
+ 520
+ 0,00
+ 700
+ 50
+
+ 505
+ 525
+ 0,00
+ 40
+ 40
+
+ 1170
+ 525
+ 0,00
+ 40
+ 40
+
+
+ SelectSlideColor
+
+
+ SelectSlideSColor
+
+
+ SelectSlideHColor
+
+
+ ArrowColor
+
+
+ ArrowSColor
+
+
+ TextColor
+
+
+ TextSColor
+
+ 32,00
+
+ 616,00
+
+ Outline
+
+ Bold
+
1
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml b/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml
index c74bdfd3..9d8b1bc1 100644
--- a/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml
+++ b/Output/Themes/Ambient/Screens/ScreenOptionsVideo.xml
@@ -1,7 +1,7 @@
- 1
+ 2
Video
@@ -185,6 +185,33 @@
+
+
+ 75
+ 285
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Left
+
+
+
+ Normal
+
+ TR_SCREENO_VIDEO_VIDEOSTOBACKGROUND
+
+
+
+
Button
@@ -435,5 +462,70 @@
3
+
+
+ Invisible
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ SelectSlideArrowLeft
+
+ SelectSlideArrowRight
+
+ SelectSlide
+
+ 500
+ 280
+ 0,00
+ 700
+ 50
+
+ 505
+ 225
+ 0,00
+ 40
+ 40
+
+ 1170
+ 225
+ 0,00
+ 40
+ 40
+
+
+ SelectSlideColor
+
+
+ SelectSlideSColor
+
+
+ SelectSlideHColor
+
+
+ ArrowColor
+
+
+ ArrowSColor
+
+
+ TextColor
+
+
+ TextSColor
+
+ 32,00
+
+ 205,33
+
+ Normal
+
+ Bold
+
+ 3
+
\ No newline at end of file
diff --git a/Output/Themes/Ambient/Screens/ScreenScore.xml b/Output/Themes/Ambient/Screens/ScreenScore.xml
index 1673c63e..b026c327 100644
--- a/Output/Themes/Ambient/Screens/ScreenScore.xml
+++ b/Output/Themes/Ambient/Screens/ScreenScore.xml
@@ -1,7 +1,7 @@
- 1
+ 2
Video
@@ -378,6 +378,831 @@
40
+
+
+ PointsBarBG
+
+ 190
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,00
+ 0,00
+ 1,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 190
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player1
+
+
+
+
+
+
+
+
+ 190
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 422
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 1,00
+ 0,00
+ 0,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 422
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player2
+
+
+
+
+
+
+
+
+ 422
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 654
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,00
+ 1,00
+ 0,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 654
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player3
+
+
+
+
+
+
+
+
+ 654
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 886
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,50
+ 0,00
+ 1,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 886
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player4
+
+
+
+
+
+
+
+
+ 886
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 144
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,00
+ 0,00
+ 1,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 144
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player1
+
+
+
+
+
+
+
+
+ 144
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 352
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 1,00
+ 0,00
+ 0,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 352
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player2
+
+
+
+
+
+
+
+
+ 352
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 560
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,00
+ 1,00
+ 0,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 560
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player3
+
+
+
+
+
+
+
+
+ 560
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 768
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,50
+ 0,00
+ 1,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 768
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player4
+
+
+
+
+
+
+
+
+ 768
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 976
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 1,000
+ 0,800
+ 0,000
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 976
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player5
+
+
+
+
+
+
+
+
+ 976
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 45
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,00
+ 0,00
+ 1,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 45
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player1
+
+
+
+
+
+
+
+
+ 45
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 253
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 1,00
+ 0,00
+ 0,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 253
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player2
+
+
+
+
+
+
+
+
+ 253
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 461
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,00
+ 1,00
+ 0,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 461
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player3
+
+
+
+
+
+
+
+
+ 461
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 669
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 0,50
+ 0,00
+ 1,00
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 669
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player4
+
+
+
+
+
+
+
+
+ 669
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 877
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 1,000
+ 0,800
+ 0,000
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 877
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player5
+
+
+
+
+
+
+
+
+ 877
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
+
+
+ PointsBarBG
+
+ 1085
+ 180
+ 0,00
+ 160
+ 220
+
+
+ 1,00
+ 0,00
+ 0,50
+ 0,75
+
+
+
+
+
+
+ PointsBar
+
+ 1085
+ 180
+ 0,00
+ 160
+ 0
+
+
+ Player6
+
+
+
+
+
+
+
+
+ 1085
+ 410
+ 0,00
+ 160
+ 160
+
+
+ Visible
+
+
+
+
+ 15
+ 40
+
+
60
@@ -1080,5 +1905,1673 @@
+
+
+ 270
+ 630
+
+ 0,00
+
+ 44
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 270
+ 140
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 270
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 270
+ 670
+
+ 0,00
+
+ 28
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 502
+ 630
+
+ 0,00
+
+ 44
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 502
+ 140
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 502
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 502
+ 670
+
+ 0,00
+
+ 28
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 734
+ 630
+
+ 0,00
+
+ 44
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 734
+ 140
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 734
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 734
+ 670
+
+ 0,00
+
+ 28
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 966
+ 630
+
+ 0,00
+
+ 44
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 966
+ 140
+
+ 0,00
+
+ 32
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 966
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 966
+ 670
+
+ 0,00
+
+ 28
+
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 224
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 224
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 224
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 224
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 432
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 432
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 432
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 432
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 640
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 640
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 640
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 640
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 848
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 848
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 848
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 848
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1056
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1056
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1056
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1056
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 125
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 125
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 125
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 125
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 333
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 333
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 333
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 333
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 541
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 541
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 541
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 541
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 749
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 749
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 749
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 749
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 957
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 957
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 957
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 957
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1165
+ 630
+
+ 0,00
+
+ 44
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1165
+ 140
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1165
+ 105
+
+ 0,00
+
+ 32
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1165
+ 670
+
+ 0,00
+
+ 28
+
+ 160
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Screens/ScreenSing.xml b/Output/Themes/Ambient/Screens/ScreenSing.xml
index 5c85960a..19ad9bea 100644
--- a/Output/Themes/Ambient/Screens/ScreenSing.xml
+++ b/Output/Themes/Ambient/Screens/ScreenSing.xml
@@ -1,7 +1,7 @@
- 3
+ 4
None
@@ -49,7 +49,7 @@
Lyrics
40
- 15
+ 7
-0,75
1200
93
@@ -65,7 +65,7 @@
Lyrics
40
- 15
+ 7
-0,75
1200
93
@@ -170,10 +170,7 @@
45
- 0,00
- 0,00
- 1,00
- 0,50
+ LyricHelper
@@ -183,16 +180,13 @@
LyricHelper
40
- 20
+ 12
-1,00
45
45
- 0,00
- 0,00
- 1,00
- 0,50
+ LyricHelper
@@ -202,16 +196,13 @@
LyricHelper
40
- 20
+ 12
-1,00
45
45
- 0,00
- 0,00
- 1,00
- 0,50
+ LyricHelper
@@ -222,7 +213,7 @@
0
0
- -1,10
+ -2,10
1280
720
@@ -232,9 +223,408 @@
+
+
+ Invisible
+
+ 40
+ 360
+ -0,75
+ 190
+ 190
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 160
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 360
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 111
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 274
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 442
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 160
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 360
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 160
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 360
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 111
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 274
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 442
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 160
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 360
+ -0,75
+ 165
+ 165
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 111
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 274
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 40
+ 442
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 111
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 274
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
+
+
+ Invisible
+
+ 1103
+ 442
+ -0,75
+ 140
+ 140
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+
+
- Score
+ Invisible
1150
350
@@ -250,7 +640,7 @@
- Score
+ Invisible
1150
150
@@ -266,7 +656,7 @@
- Score
+ Invisible
1150
350
@@ -282,7 +672,7 @@
- Score
+ Invisible
1150
10
@@ -298,7 +688,7 @@
- Score
+ Invisible
1150
210
@@ -314,7 +704,7 @@
- Score
+ Invisible
1150
410
@@ -328,6 +718,246 @@
+
+
+ Invisible
+
+ 528
+ 150
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 350
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 150
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 350
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 10
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 210
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 410
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 150
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 350
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 10
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 210
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 528
+ 410
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 10
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 210
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
+
+
+ Invisible
+
+ 1150
+ 410
+ -0,75
+ 100
+ 50
+
+
+ StaticColor
+
+
+
+
640
@@ -388,7 +1018,7 @@
640
170
- -1,11
+ -2,11
100
@@ -412,21 +1042,21 @@
- 1200
+ 1240
355
-1,00
- 40
+ 198
- Player1
+ Player1Dim2
TextSColor
- Center
+ Right
@@ -439,21 +1069,21 @@
- 1200
+ 1240
155
-1,00
- 40
+ 173
- Player1
+ Player1Dim2
Player1
- Center
+ Right
@@ -466,21 +1096,21 @@
- 1200
+ 1240
355
-1,00
- 40
+ 173
- Player2
+ Player2Dim2
Player2
- Center
+ Right
@@ -493,16 +1123,97 @@
- 1200
- 15
+ 1240
+ 106
-1,00
- 40
+ 148
- Player1
+ Player1Dim2
+
+
+ Player1
+
+ Right
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 1240
+ 269
+
+ -1,00
+
+ 148
+
+
+
+ Player2Dim2
+
+
+ Player2
+
+ Right
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 1240
+ 437
+
+ -1,00
+
+ 148
+
+
+
+ Player3Dim2
+
+
+ Player3
+
+ Right
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 155
+
+ -1,00
+
+ 173
+
+
+
+ Player1Dim2
Player1
@@ -517,19 +1228,19 @@
-
-
+
+
- 1200
- 215
+ 324
+ 355
-1,00
- 40
+ 173
- Player2
+ Player2Dim2
Player2
@@ -544,19 +1255,19 @@
-
-
+
+
- 1200
- 415
+ 967
+ 155
-1,00
- 40
+ 173
- Player3
+ Player3Dim2
Player3
@@ -571,7 +1282,961 @@
-
+
+
+
+ 967
+ 355
+
+ -1,00
+
+ 173
+
+
+
+ Player4Dim2
+
+
+ Player4
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 106
+
+ -1,00
+
+ 148
+
+
+
+ Player1Dim2
+
+
+ Player1
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 269
+
+ -1,00
+
+ 148
+
+
+
+ Player2Dim2
+
+
+ Player2
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 437
+
+ -1,00
+
+ 148
+
+
+
+ Player3Dim2
+
+
+ Player3
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 967
+ 155
+
+ -1,00
+
+ 173
+
+
+
+ Player4Dim2
+
+
+ Player4
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 967
+ 355
+
+ -1,00
+
+ 173
+
+
+
+ Player5Dim2
+
+
+ Player5
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 106
+
+ -1,00
+
+ 148
+
+
+
+ Player1Dim2
+
+
+ Player1
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 269
+
+ -1,00
+
+ 148
+
+
+
+ Player2Dim2
+
+
+ Player2
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 324
+ 437
+
+ -1,00
+
+ 148
+
+
+
+ Player3Dim2
+
+
+ Player3
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 967
+ 106
+
+ -1,00
+
+ 148
+
+
+
+ Player4Dim2
+
+
+ Player4
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 967
+ 269
+
+ -1,00
+
+ 148
+
+
+
+ Player5Dim2
+
+
+ Player5
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 967
+ 437
+
+ -1,00
+
+ 148
+
+
+
+ Player6Dim2
+
+
+ Player6
+
+ Center
+
+
+
+ Normal
+
+
+
+
+
+
+
+
+ 110
+ 513
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 288
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player1
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 488
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player2
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 219
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player1
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 382
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player2
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 550
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player3
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 288
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player1
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 488
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player2
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 288
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player3
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 488
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player4
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 219
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player1
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 382
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player2
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 550
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player3
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 288
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player4
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 488
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player5
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 219
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player1
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 382
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player2
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 110
+ 550
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player3
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 219
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player4
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 382
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player5
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
+
+
+ 1173
+ 550
+
+ -1,00
+
+ 28
+
+
+
+ 1,000
+ 1,000
+ 1,000
+ 0,400
+
+
+ Player6
+
+ Center
+
+
+
+ Outline
+
+
+
+
+
+
Button
@@ -580,7 +2245,7 @@
670
300
- -1,11
+ -2,11
150
50
@@ -635,7 +2300,7 @@
460
300
- -1,11
+ -2,11
150
50
@@ -713,7 +2378,7 @@
637
- 20
+ 12
-1,00
1200
50
@@ -727,7 +2392,7 @@
637
- 62
+ 54
-1,00
1200
45
@@ -741,7 +2406,7 @@
637
- 20
+ 12
-1,00
1200
50
@@ -755,7 +2420,7 @@
637
- 62
+ 54
-1,00
1200
45
@@ -791,35 +2456,110 @@
35
350
- -0,50
+ -1,50
1210
200
35
150
- -0,50
+ -1,50
1210
175
35
350
- -0,50
+ -1,50
1210
175
35
- 10
- -0,50
+ 105
+ -1,50
1210
150
35
- 210
- -0,50
+ 268
+ -1,50
1210
150
35
- 410
- -0,50
+ 436
+ -1,50
1210
150
+ 35
+ 150
+ -1,50
+ 578
+ 175
+ 35
+ 350
+ -1,50
+ 578
+ 175
+ 678
+ 150
+ -1,50
+ 578
+ 175
+ 678
+ 350
+ -1,50
+ 578
+ 175
+ 35
+ 105
+ -1,50
+ 578
+ 150
+ 35
+ 268
+ -1,50
+ 578
+ 150
+ 35
+ 436
+ -1,50
+ 578
+ 150
+ 678
+ 150
+ -1,50
+ 578
+ 175
+ 678
+ 350
+ -1,50
+ 578
+ 175
+ 35
+ 105
+ -1,50
+ 578
+ 150
+ 35
+ 268
+ -1,50
+ 578
+ 150
+ 35
+ 436
+ -1,50
+ 578
+ 150
+ 678
+ 105
+ -1,50
+ 578
+ 150
+ 678
+ 268
+ -1,50
+ 578
+ 150
+ 678
+ 436
+ -1,50
+ 578
+ 150
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Screens/ScreenSong.xml b/Output/Themes/Ambient/Screens/ScreenSong.xml
index 84bfa297..dbfcc8c4 100644
--- a/Output/Themes/Ambient/Screens/ScreenSong.xml
+++ b/Output/Themes/Ambient/Screens/ScreenSong.xml
@@ -1,7 +1,7 @@
- 2
+ 3
Video
@@ -33,6 +33,25 @@
26
+
+
+ SongMenuBG
+
+ 40
+ 40
+ -2,10
+ 360
+ 360
+
+
+ 1
+ 1
+ 1
+ 1
+
+
+
+
Menu
@@ -53,6 +72,175 @@
26
+
+
+ Button
+
+ Button
+
+ 40
+ 90
+ -2,11
+ 360
+ 40
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 180
+ 5
+
+ 30
+
+ 350
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_SCREENSONG_BUTTON_SING
+
+
+
+
+
+
+
+
+
+
+ Button
+
+ Button
+
+ 40
+ 180
+ -2,11
+ 360
+ 40
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 180
+ 5
+
+ 30
+
+ 350
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_SCREENSONG_BUTTON_PLAYLIST
+
+
+
+
+
+
+
+
+
+
+ Button
+
+ Button
+
+ 40
+ 225
+ -2,11
+ 360
+ 40
+
+
+ ButtonColor
+
+
+ ButtonSColor
+
+
+ 180
+ 5
+
+ 30
+
+ 350
+
+
+ ButtonTextColor
+
+
+ ButtonTextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_SCREENSONG_BUTTON_CANCEL
+
+
+
+
+
+
+
+
+
+
+ 200
+ 45
+
+ -2,11
+
+ 40
+
+ 350
+
+
+ StaticColor
+
+
+ TextSColor
+
+ Center
+
+
+
+ Outline
+
+ TR_SCREENSONG_SONGOPTIONS
+
+
+
+
220
@@ -171,6 +359,71 @@
+
+
+ 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
+
+ 280
+
+ Outline
+
+ Bold
+
+ 1
+
CoverTile
@@ -202,6 +455,10 @@
6
4
+
+ 4
+
+ 4
10,00
@@ -212,6 +469,12 @@
-1,00
830
550
+
+ 410
+ 40
+ -1,00
+ 550
+ 550
222
@@ -395,4 +658,4 @@
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Skin Blue.xml b/Output/Themes/Ambient/Skin Blue.xml
index 7f5b16ab..50a16aa8 100644
--- a/Output/Themes/Ambient/Skin Blue.xml
+++ b/Output/Themes/Ambient/Skin Blue.xml
@@ -33,9 +33,9 @@
1,000
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
1,000
@@ -71,9 +71,9 @@
0,500
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
0,500
@@ -82,6 +82,42 @@
0,500
0,500
+
+ 0,000
+ 0,000
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,000
+ 0,400
+
+
+ 0,000
+ 1,000
+ 0,000
+ 0,400
+
+
+ 0,500
+ 0,000
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,800
+ 0,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,500
+ 0,400
+
0,000
0,000
@@ -214,6 +250,12 @@
0,300
1,000
+
+ 0,00
+ 0,00
+ 1,00
+ 0,50
+
0,800
0,950
@@ -266,6 +308,13 @@
MedleyCalcIcon.png
MedleyTagIcon.png
Invisible.png
+ PlayerSelector.png
+ PreviousIcon.png
+ NextIcon.png
+ PlayIcon.png
+ PauseIcon.png
+ RepeatIcon.png
+ SongMenuBG.png
[Blue]BG_Video.mp4
@@ -273,4 +322,4 @@
[Blue]IntroMid.mp4
[Blue]IntroOut.mp4
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Skin Green.xml b/Output/Themes/Ambient/Skin Green.xml
index bee2b2ba..7aefeb34 100644
--- a/Output/Themes/Ambient/Skin Green.xml
+++ b/Output/Themes/Ambient/Skin Green.xml
@@ -33,9 +33,9 @@
1,000
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
1,000
@@ -71,9 +71,9 @@
0,500
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
0,500
@@ -82,88 +82,124 @@
0,500
0,500
-
+
0,000
0,000
- 0,750
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,000
+ 0,400
+
+
+ 0,000
+ 1,000
+ 0,000
+ 0,400
+
+
+ 0,500
+ 0,000
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,800
+ 0,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,500
+ 0,400
+
+
+ 0,000
+ 0,750
+ 0,000
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
0,300
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
0,300
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,709
+ 0,968
+ 0,674
1,000
@@ -198,8 +234,8 @@
0,000
- 0,000
- 1,000
+ 1,000
+ 0,000
1,000
@@ -214,17 +250,23 @@
0,300
1,000
+
+ 0,00
+ 1,00
+ 0,00
+ 0,50
+
0,800
- 0,950
- 1,000
+ 1,000
+ 0,811
0,500
0,800
- 0,950
- 1,000
- 0,850
+ 1,000
+ 0,811
+ 0,811
@@ -266,6 +308,13 @@
MedleyCalcIcon.png
MedleyTagIcon.png
Invisible.png
+ PlayerSelector.png
+ PreviousIcon.png
+ NextIcon.png
+ PlayIcon.png
+ PauseIcon.png
+ RepeatIcon.png
+ SongMenuBG.png
[Green]BG_Video.mp4
@@ -273,4 +322,4 @@
[Green]IntroMid.mp4
[Green]IntroOut.mp4
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Skin Red.xml b/Output/Themes/Ambient/Skin Red.xml
index 42b71d2c..d7f5ecf2 100644
--- a/Output/Themes/Ambient/Skin Red.xml
+++ b/Output/Themes/Ambient/Skin Red.xml
@@ -33,9 +33,9 @@
1,000
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
1,000
@@ -71,9 +71,9 @@
0,500
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
0,500
@@ -82,88 +82,124 @@
0,500
0,500
-
+
0,000
0,000
- 0,750
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,000
+ 0,400
+
+
+ 0,000
+ 1,000
+ 0,000
+ 0,400
+
+
+ 0,500
+ 0,000
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,800
+ 0,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,500
+ 0,400
+
+
+ 0,750
+ 0,000
+ 0,000
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
0,300
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
0,300
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,674
+ 0,674
1,000
@@ -197,9 +233,9 @@
0,000
- 0,000
+ 1,000
0,000
- 1,000
+ 0,000
1,000
@@ -214,16 +250,22 @@
0,300
1,000
+
+ 1,00
+ 0,00
+ 0,00
+ 0,50
+
- 0,800
- 0,950
- 1,000
+ 1,000
+ 0,800
+ 0,800
0,500
- 0,800
- 0,950
- 1,000
+ 1,000
+ 0,800
+ 0,800
0,850
@@ -266,6 +308,13 @@
MedleyCalcIcon.png
MedleyTagIcon.png
Invisible.png
+ PlayerSelector.png
+ PreviousIcon.png
+ NextIcon.png
+ PlayIcon.png
+ PauseIcon.png
+ RepeatIcon.png
+ SongMenuBG.png
[Red]BG_Video.mp4
@@ -273,4 +322,4 @@
[Red]IntroMid.mp4
[Red]IntroOut.mp4
-
\ No newline at end of file
+
diff --git a/Output/Themes/Ambient/Skin Yellow.xml b/Output/Themes/Ambient/Skin Yellow.xml
index 1207b7fe..d7366abc 100644
--- a/Output/Themes/Ambient/Skin Yellow.xml
+++ b/Output/Themes/Ambient/Skin Yellow.xml
@@ -33,9 +33,9 @@
1,000
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
1,000
@@ -71,9 +71,9 @@
0,500
- 0,000
- 0,500
- 1,000
+ 1,000
+ 0,800
+ 0,000
0,500
@@ -82,88 +82,124 @@
0,500
0,500
-
+
0,000
0,000
- 0,750
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,000
+ 0,400
+
+
+ 0,000
+ 1,000
+ 0,000
+ 0,400
+
+
+ 0,500
+ 0,000
+ 1,000
+ 0,400
+
+
+ 1,000
+ 0,800
+ 0,000
+ 0,400
+
+
+ 1,000
+ 0,000
+ 0,500
+ 0,400
+
+
+ 0,750
+ 0,750
+ 0,000
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
0,300
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
0,300
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
0,500
- 0,675
- 0,890
- 0,969
+ 0,968
+ 0,956
+ 0,674
1,000
@@ -197,9 +233,9 @@
0,000
- 0,000
- 0,000
- 1,000
+ 1,000
+ 1,000
+ 0,000
1,000
@@ -214,16 +250,22 @@
0,300
1,000
+
+ 1,00
+ 1,00
+ 0,00
+ 0,50
+
- 0,800
- 0,950
- 1,000
+ 0,949
+ 1,000
+ 0,800
0,500
- 0,800
- 0,950
- 1,000
+ 0,949
+ 1,000
+ 0,800
0,850
@@ -266,6 +308,13 @@
MedleyCalcIcon.png
MedleyTagIcon.png
Invisible.png
+ PlayerSelector.png
+ PreviousIcon.png
+ NextIcon.png
+ PlayIcon.png
+ PauseIcon.png
+ RepeatIcon.png
+ SongMenuBG.png
[Yellow]BG_Video.mp4
@@ -273,4 +322,4 @@
[Yellow]IntroMid.mp4
[Yellow]IntroOut.mp4
-
\ No newline at end of file
+
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/Changelog/Changelog_ScreenNames.txt b/Output/Themes/Changelog/Changelog_ScreenNames.txt
new file mode 100644
index 00000000..47d04016
--- /dev/null
+++ b/Output/Themes/Changelog/Changelog_ScreenNames.txt
@@ -0,0 +1,22 @@
+SceenNames
+
+++++++++++
+Version 2:
+
+Add:
+
+A new Theme-element for name-selecting.
+
+ (One Static for each player): Static wich is used as drop-area
+ (One Static for each player): Static wich shows the avatar of selected player
+ (One Text for each player): Text wich shows name of selected player
+
+
+
+
+Rename:
+ to
+ to
+
+Remove:
+, , , , ,
diff --git a/Output/Themes/Changelog/Changelog_ScreenOptionsLyrics.txt b/Output/Themes/Changelog/Changelog_ScreenOptionsLyrics.txt
new file mode 100644
index 00000000..8af47a1e
--- /dev/null
+++ b/Output/Themes/Changelog/Changelog_ScreenOptionsLyrics.txt
@@ -0,0 +1,17 @@
+ScreenOptionsSound
+
+++++++++++
+Version 1:
+
+Add:
+
+
+
+
+
+
+and some texts for description (Text1, Text2, Text3)
+TR_SCREENOLYRICS_OPTIONS
+TR_SCREENOLYRICS_STYLE
+TR_SCREENOLYRICS_ONTOP
+++++++++++
diff --git a/Output/Themes/Changelog/Changelog_ScreenOptionsTheme.txt b/Output/Themes/Changelog/Changelog_ScreenOptionsTheme.txt
index a2423088..a8c28341 100644
--- a/Output/Themes/Changelog/Changelog_ScreenOptionsTheme.txt
+++ b/Output/Themes/Changelog/Changelog_ScreenOptionsTheme.txt
@@ -1,5 +1,12 @@
ScreenOptionsTheme
+++++++++++
+Version 3:
+
+Add:
+
+and some texts and statics for description (Text9 and Static9)
+"TR_SCREENOTHEME_FADEINFO"
++++++++++
Version 2:
diff --git a/Output/Themes/Changelog/Changelog_ScreenOptionsVideo.txt b/Output/Themes/Changelog/Changelog_ScreenOptionsVideo.txt
new file mode 100644
index 00000000..a6898ab5
--- /dev/null
+++ b/Output/Themes/Changelog/Changelog_ScreenOptionsVideo.txt
@@ -0,0 +1,10 @@
+ScreenOptionsTheme
+
+++++++++++
+Version 2:
+
+Add:
+
+and some texts and statics for description (Text5)
+"TR_SCREENO_VIDEO_VIDEOSTOBACKGROUND"
+++++++++++
\ No newline at end of file
diff --git a/Output/Themes/Changelog/Changelog_ScreenScore.txt b/Output/Themes/Changelog/Changelog_ScreenScore.txt
new file mode 100644
index 00000000..d050d838
--- /dev/null
+++ b/Output/Themes/Changelog/Changelog_ScreenScore.txt
@@ -0,0 +1,7 @@
+ScreenScore
+
+++++++++++
+Version 2:
+
+Add: Elements for up to 6 players! (Texts and statics!)
+++++++++++
\ No newline at end of file
diff --git a/Output/Themes/Changelog/Changelog_ScreenSing.txt b/Output/Themes/Changelog/Changelog_ScreenSing.txt
index a1ea71f3..22c5fa99 100644
--- a/Output/Themes/Changelog/Changelog_ScreenSing.txt
+++ b/Output/Themes/Changelog/Changelog_ScreenSing.txt
@@ -1,5 +1,14 @@
ScreenSing
+++++++++++
+Version 4:
+Added Elements for 6-player-singing!
+
+Add:
+ (One for each player for each player-number>
+ (One for each player for each player-number>
+
+
++++++++++
Version 3:
diff --git a/Output/x64/acinerella.dll b/Output/x64/acinerella.dll
index 4fa95785..a386c4f5 100644
Binary files a/Output/x64/acinerella.dll and b/Output/x64/acinerella.dll differ
diff --git a/Output/x64/avcodec-54.dll b/Output/x64/avcodec-54.dll
index 37ff648d..c41c69e1 100644
Binary files a/Output/x64/avcodec-54.dll and b/Output/x64/avcodec-54.dll differ
diff --git a/Output/x64/avformat-54.dll b/Output/x64/avformat-54.dll
index 406d4c1f..043f2a4e 100644
Binary files a/Output/x64/avformat-54.dll and b/Output/x64/avformat-54.dll differ
diff --git a/Output/x64/avutil-51.dll b/Output/x64/avutil-51.dll
index 638b40c5..fcf5552e 100644
Binary files a/Output/x64/avutil-51.dll and b/Output/x64/avutil-51.dll differ
diff --git a/Output/x64/swscale-2.dll b/Output/x64/swscale-2.dll
index 2649979b..3a5e5f1e 100644
Binary files a/Output/x64/swscale-2.dll and b/Output/x64/swscale-2.dll differ
diff --git a/Output/x86/acinerella.dll b/Output/x86/acinerella.dll
index 29a05b55..77b069fa 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 1d56751b..a2e1af29 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 76385c1e..063b9dc8 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 6117ea73..fe871cc1 100644
Binary files a/Output/x86/avutil-51.dll and b/Output/x86/avutil-51.dll differ
diff --git a/Output/x86/libacinerella.so b/Output/x86/libacinerella.so
deleted file mode 100644
index eb9aa580..00000000
Binary files a/Output/x86/libacinerella.so and /dev/null differ
diff --git a/Output/x86/swscale-2.dll b/Output/x86/swscale-2.dll
index 50d699f1..1fb3876c 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 403a64f9..31acd203 100644
--- a/Vocaluxe/Base/CBackgroundMusic.cs
+++ b/Vocaluxe/Base/CBackgroundMusic.cs
@@ -6,6 +6,9 @@ using System.IO;
using Vocaluxe.Base;
using System.Diagnostics;
using Vocaluxe.Lib.Song;
+using Vocaluxe.Lib.Draw;
+using System.Drawing;
+using Vocaluxe.Menu;
namespace Vocaluxe.Base
{
@@ -13,31 +16,149 @@ namespace Vocaluxe.Base
{
private static CHelper Helper = new CHelper();
private static int _CurrentMusicStream = -1;
- private static string _CurrentMusicFilePath = String.Empty;
-
- private static List _AllFileNames = new List();
- private static List _NotPlayedFileNames = new List();
- private static List _BGMusicFileNames = new List();
+ private static int _PreviousMusicIndex = 0;
+ private static PlaylistElement _CurrentPlaylistElement = new PlaylistElement();
+
+ private static List _AllFileNames = new List();
+ private static List _NotPlayedFileNames = new List();
+ private static List _BGMusicFileNames = new List();
+ private static List _PreviousFileNames = new List();
+
+ private static int _Video = -1;
+ private static STexture _CurrentVideoTexture = new STexture(-1);
+ private static Stopwatch _FadeTimer = new Stopwatch();
+ private static bool _VideoEnabled;
private static bool _OwnMusicAdded;
private static bool _BackgroundMusicAdded;
private static bool _Playing;
+ private static bool _Disabled;
+ private static bool _CanSing;
+
+ public static bool VideoEnabled
+ {
+ get
+ {
+ return _VideoEnabled;
+ }
+ set
+ {
+ if (_VideoEnabled && value)
+ return;
+ if (!_VideoEnabled && !value)
+ return;
+ if(_VideoEnabled && !value)
+ ToggleVideo();
+ if (!_VideoEnabled && value)
+ ToggleVideo();
+ _VideoEnabled = value;
+ }
+ }
+
+ public static bool CanSing
+ {
+ get
+ {
+ return _CanSing;
+ }
+
+ set
+ {
+ _CanSing = value;
+ }
+ }
+
+ public static bool Disabled
+ {
+ get
+ {
+ return _Disabled;
+ }
+ set
+ {
+ _Disabled = value;
+ if (_Disabled)
+ Pause();
+ else
+ Play();
+ }
+ }
+
+ public static int SongID
+ {
+ get
+ {
+ return _CurrentPlaylistElement._SongID;
+ }
+ }
+
+ public static bool Duet
+ {
+ get
+ {
+ return _CurrentPlaylistElement.Duet;
+ }
+ }
+
+ public static bool SongHasVideo
+ {
+ get
+ {
+ return File.Exists(_CurrentPlaylistElement.VideoFilePath);
+ }
+ }
+
+ public static bool Playing
+ {
+ get
+ {
+ return _Playing;
+ }
+ }
+
+ public static string ArtistAndTitle
+ {
+ get
+ {
+ return _CurrentPlaylistElement.Artist + " - " + _CurrentPlaylistElement.Title;
+ }
+ }
+
+ public static STexture Cover
+ {
+ get
+ {
+ return _CurrentPlaylistElement.Cover;
+ }
+ }
public static void Init()
{
- _BGMusicFileNames.AddRange(Helper.ListFiles(CSettings.sFolderBackgroundMusic, "*.mp3", true, true));
- _BGMusicFileNames.AddRange(Helper.ListFiles(CSettings.sFolderBackgroundMusic, "*.wav", true, true));
- _BGMusicFileNames.AddRange(Helper.ListFiles(CSettings.sFolderBackgroundMusic, "*.ogg", true, true));
- _BGMusicFileNames.AddRange(Helper.ListFiles(CSettings.sFolderBackgroundMusic, "*.wma", true, true));
+ List templist = new List();
+
+ foreach(string ending in CSettings.MusicFileTypes)
+ {
+ templist.AddRange(Helper.ListFiles(CSettings.sFolderBackgroundMusic, ending, true, true));
+ }
+
+ foreach (string path in templist)
+ {
+ _BGMusicFileNames.Add(new PlaylistElement(path));
+ }
if(CConfig.BackgroundMusicSource != EBackgroundMusicSource.TR_CONFIG_ONLY_OWN_MUSIC)
AddBackgroundMusic();
+ if (CConfig.VideoBackgrounds == EOffOn.TR_CONFIG_ON)
+ _VideoEnabled = true;
_Playing = false;
}
public static void Play()
{
+ if (_Playing)
+ return;
+
if (CConfig.BackgroundMusic == EOffOn.TR_CONFIG_ON)
{
if (_AllFileNames.Count > 0)
@@ -46,24 +167,48 @@ namespace Vocaluxe.Base
{
CSound.Fade(_CurrentMusicStream, CConfig.BackgroundMusicVolume, CSettings.BackgroundMusicFadeTime);
CSound.Play(_CurrentMusicStream);
+ if (_VideoEnabled && _Video != -1)
+ CVideo.VdResume(_Video);
_Playing = true;
}
else
Next();
+
+ if (!IsBackgroundFile(_CurrentPlaylistElement))
+ _CanSing = true;
+ else
+ _CanSing = false;
}
}
}
public static void Stop()
{
+ if (!_Playing)
+ return;
+
+ if (_VideoEnabled && _Video != -1)
+ {
+ CVideo.VdClose(_Video);
+ CDraw.RemoveTexture(ref _CurrentVideoTexture);
+ _Video = -1;
+ }
CSound.FadeAndStop(_CurrentMusicStream, 0f, CSettings.BackgroundMusicFadeTime);
- _CurrentMusicFilePath = String.Empty;
+ _CurrentPlaylistElement = new PlaylistElement();
_Playing = false;
}
public static void Pause()
{
+ if (!_Playing)
+ return;
+
+ if (_VideoEnabled && _Video != -1)
+ {
+ CVideo.VdPause(_Video);
+ CVideo.VdSkip(_Video, CSound.GetPosition(_CurrentMusicStream) + CSettings.BackgroundMusicFadeTime, _CurrentPlaylistElement.VideoGap);
+ }
CSound.FadeAndPause(_CurrentMusicStream, 0f, CSettings.BackgroundMusicFadeTime);
_Playing = false;
}
@@ -83,15 +228,28 @@ namespace Vocaluxe.Base
{
if (_AllFileNames.Count > 0)
{
- Stop();
+ if (_PreviousMusicIndex == _PreviousFileNames.Count - 1 || _PreviousFileNames.Count == 0) //We are not currently in the previous list
+ {
+ Stop();
+ if (_NotPlayedFileNames.Count == 0)
+ _NotPlayedFileNames.AddRange(_AllFileNames);
- if (_NotPlayedFileNames.Count == 0)
- _NotPlayedFileNames.AddRange(_AllFileNames);
+ _CurrentPlaylistElement = _NotPlayedFileNames[CGame.Rand.Next(_NotPlayedFileNames.Count)];
+ _NotPlayedFileNames.Remove(_CurrentPlaylistElement);
- _CurrentMusicFilePath = _NotPlayedFileNames[CGame.Rand.Next(_NotPlayedFileNames.Count)];
- _NotPlayedFileNames.Remove(_CurrentMusicFilePath);
+ _PreviousFileNames.Add(_CurrentPlaylistElement);
+ _PreviousMusicIndex = _PreviousFileNames.Count - 1;
+ }
+ else if(_PreviousFileNames.Count > 0) //We are in the previous list
+ {
+ Stop();
+ _PreviousMusicIndex++;
- _CurrentMusicStream = CSound.Load(_CurrentMusicFilePath);
+ _CurrentPlaylistElement = _PreviousFileNames[_PreviousMusicIndex];
+ }
+ _CurrentMusicStream = CSound.Load(_CurrentPlaylistElement.MusicFilePath);
+ if (_VideoEnabled)
+ LoadVideo();
CSound.SetStreamVolume(_CurrentMusicStream, 0f);
Play();
}
@@ -99,6 +257,36 @@ namespace Vocaluxe.Base
Stop();
}
+ public static void Previous()
+ {
+ if (_PreviousFileNames.Count > 0 || _PreviousMusicIndex >= 0)
+ {
+ Stop();
+
+ _PreviousMusicIndex--;
+ if (_PreviousMusicIndex < 0)
+ _PreviousMusicIndex = 0; //No previous songs left, so play the first
+
+ _CurrentPlaylistElement = _PreviousFileNames[_PreviousMusicIndex];
+
+ _CurrentMusicStream = CSound.Load(_CurrentPlaylistElement.MusicFilePath);
+ if (_VideoEnabled)
+ LoadVideo();
+ CSound.SetStreamVolume(_CurrentMusicStream, 0f);
+ Play();
+ }
+ }
+
+ public static void Repeat()
+ {
+ if (_AllFileNames.Count > 0 && _CurrentMusicStream != -1)
+ {
+ CSound.SetPosition(_CurrentMusicStream, 0);
+ if (_VideoEnabled && _Video != -1)
+ CVideo.VdSkip(_Video, 0f, _CurrentPlaylistElement.VideoGap);
+ }
+ }
+
public static void ApplyVolume()
{
CSound.SetStreamVolume(_CurrentMusicStream, CConfig.BackgroundMusicVolume);
@@ -110,8 +298,8 @@ namespace Vocaluxe.Base
{
foreach (CSong song in CSongs.AllSongs)
{
- _AllFileNames.Add(song.GetMP3());
- _NotPlayedFileNames.Add(song.GetMP3());
+ _AllFileNames.Add(new PlaylistElement(song));
+ _NotPlayedFileNames.Add(new PlaylistElement(song));
}
}
_OwnMusicAdded = true;
@@ -128,7 +316,7 @@ namespace Vocaluxe.Base
_NotPlayedFileNames.AddRange(_BGMusicFileNames);
}
- if (IsPlaying() && !IsBackgroundFile(_CurrentMusicFilePath) || _AllFileNames.Count == 0)
+ if (Playing && !IsBackgroundFile(_CurrentPlaylistElement) || _AllFileNames.Count == 0)
Next();
_OwnMusicAdded = false;
@@ -153,7 +341,7 @@ namespace Vocaluxe.Base
AddOwnMusic();
_BackgroundMusicAdded = false;
- if (IsPlaying() && IsBackgroundFile(_CurrentMusicFilePath) || _AllFileNames.Count == 0)
+ if (Playing && IsBackgroundFile(_CurrentPlaylistElement) || _AllFileNames.Count == 0)
Next();
}
}
@@ -207,19 +395,232 @@ namespace Vocaluxe.Base
CConfig.SaveConfig();
}
- public static bool IsPlaying()
+ public static void ToggleVideo()
{
- return CSound.IsPlaying(_CurrentMusicStream);
+ if (_Video != -1)
+ {
+ if (_VideoEnabled)
+ {
+ _VideoEnabled = false;
+ CVideo.VdClose(_Video);
+ _Video = -1;
+ CDraw.RemoveTexture(ref _CurrentVideoTexture);
+ return;
+ }
+ if (CVideo.VdFinished(_Video))
+ {
+ CVideo.VdClose(_Video);
+ CDraw.RemoveTexture(ref _CurrentVideoTexture);
+ _Video = -1;
+ return;
+ }
+ }
+ else
+ LoadVideo();
}
- private static bool IsBackgroundFile(string FilePath)
+ public static STexture GetVideoTexture()
{
- foreach (string file in _BGMusicFileNames)
+ if (_Video != -1)
{
- if (file == FilePath)
+ float vtime = 0f;
+ CVideo.VdGetFrame(_Video, ref _CurrentVideoTexture, CSound.GetPosition(_CurrentMusicStream), ref vtime);
+ if (_FadeTimer.ElapsedMilliseconds <= 3000L)
+ {
+ _CurrentVideoTexture.color.A = (_FadeTimer.ElapsedMilliseconds / 3000f);
+ }
+ else
+ {
+ _CurrentVideoTexture.color.A = 1f;
+ _FadeTimer.Stop();
+ }
+ return _CurrentVideoTexture;
+ }
+ return new STexture(-1);
+ }
+
+ private static bool IsBackgroundFile(PlaylistElement element)
+ {
+ foreach (PlaylistElement elements in _BGMusicFileNames)
+ {
+ if (elements.MusicFilePath == element.MusicFilePath)
return true;
}
return false;
}
+
+ private static void LoadVideo()
+ {
+ if (_Video == -1)
+ {
+ _Video = CVideo.VdLoad(_CurrentPlaylistElement.VideoFilePath);
+ CVideo.VdSkip(_Video, 0f, _CurrentPlaylistElement.VideoGap);
+ _VideoEnabled = true;
+ _FadeTimer.Reset();
+ _FadeTimer.Start();
+ }
+ }
+ }
+}
+
+class PlaylistElement
+{
+ public int _SongID;
+ private string _MusicFilePath;
+
+ public string MusicFilePath
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.GetMP3();
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return _MusicFilePath;
+ }
+
+ set
+ {
+ _MusicFilePath = value;
+ }
+ }
+
+ public string VideoFilePath
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.GetVideo();
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return string.Empty;
+ }
+ }
+
+ public string Title
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.Title;
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return "Unknown";
+ }
+ }
+
+ public string Artist
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.Artist;
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return "Unknown";
+ }
+ }
+
+ public STexture Cover
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.CoverTextureSmall;
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return CCover.NoCover;
+ }
+ }
+
+ public float VideoGap
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.VideoGap;
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return 0;
+ }
+ }
+
+ public bool Duet
+ {
+ get
+ {
+ if (_SongID >= 0)
+ {
+ CSong song = CSongs.GetSong(_SongID);
+ if (song != null)
+ return song.IsDuet;
+ else
+ {
+ _SongID = -1;
+ CLog.LogError("Song not found");
+ }
+ }
+ return false;
+ }
+ }
+
+ public PlaylistElement(CSong song)
+ {
+ MusicFilePath = string.Empty;
+ _SongID = song.ID;
+ }
+
+ public PlaylistElement(string FilePath)
+ {
+ MusicFilePath = FilePath;
+ _SongID = -1;
+ }
+
+ public PlaylistElement()
+ {
+ MusicFilePath = string.Empty;
+ _SongID = -1;
}
}
diff --git a/Vocaluxe/Base/CConfig.cs b/Vocaluxe/Base/CConfig.cs
index 02ad6565..cfe4d154 100644
--- a/Vocaluxe/Base/CConfig.cs
+++ b/Vocaluxe/Base/CConfig.cs
@@ -87,7 +87,8 @@ namespace Vocaluxe.Base
public enum ERecordLib
{
- PortAudio
+ PortAudio,
+ DirectSound
}
public enum EVideoDecoder
@@ -152,6 +153,29 @@ namespace Vocaluxe.Base
TR_CONFIG_ONLY_OWN_MUSIC
}
+ public enum EPlayerInfo
+ {
+ TR_CONFIG_PLAYERINFO_BOTH,
+ TR_CONFIG_PLAYERINFO_NAME,
+ TR_CONFIG_PLAYERINFO_AVATAR,
+ TR_CONFIG_PLAYERINFO_OFF
+ }
+
+ public enum EFadePlayerInfo
+ {
+ TR_CONFIG_FADEPLAYERINFO_ALL,
+ TR_CONFIG_FADEPLAYERINFO_INFO,
+ TR_CONFIG_FADEPLAYERINFO_OFF
+ }
+
+ public enum ELyricStyle
+ {
+ Fill,
+ Jump,
+ Slide,
+ Zoom
+ }
+
#endregion Enums
static class CConfig
@@ -185,7 +209,10 @@ namespace Vocaluxe.Base
public static EOffOn DrawNoteLines = EOffOn.TR_CONFIG_ON;
public static EOffOn DrawToneHelper = EOffOn.TR_CONFIG_ON;
public static ETimerLook TimerLook = ETimerLook.TR_CONFIG_TIMERLOOK_EXPANDED;
+ public static EPlayerInfo PlayerInfo = EPlayerInfo.TR_CONFIG_PLAYERINFO_BOTH;
+ public static EFadePlayerInfo FadePlayerInfo = EFadePlayerInfo.TR_CONFIG_FADEPLAYERINFO_OFF;
public static ECoverLoading CoverLoading = ECoverLoading.TR_CONFIG_COVERLOADING_ATSTART;
+ public static ELyricStyle LyricStyle = ELyricStyle.Slide;
// Sound
public static EPlaybackLib PlayBackLib = EPlaybackLib.PortAudio;
@@ -200,22 +227,25 @@ namespace Vocaluxe.Base
public static List SongFolder = new List();
public static ESongMenu SongMenu = ESongMenu.TR_CONFIG_TILE_BOARD;
public static ESongSorting SongSorting = ESongSorting.TR_CONFIG_ARTIST;
+ public static EOffOn IgnoreArticles = EOffOn.TR_CONFIG_ON;
public static float ScoreAnimationTime = 10;
public static ETimerMode TimerMode = ETimerMode.TR_CONFIG_TIMERMODE_REMAINING;
public static int NumPlayer = 2;
public static EOffOn Tabs = EOffOn.TR_CONFIG_OFF;
public static string Language = "English";
public static EOffOn LyricsOnTop = EOffOn.TR_CONFIG_OFF;
+ public static string[] Players = new string[CSettings.MaxNumPlayer];
// Video
public static EVideoDecoder VideoDecoder = EVideoDecoder.FFmpeg;
public static EOffOn VideoBackgrounds = EOffOn.TR_CONFIG_ON;
public static EOffOn VideoPreview = EOffOn.TR_CONFIG_ON;
public static EOffOn VideosInSongs = EOffOn.TR_CONFIG_ON;
+ public static EOffOn VideosToBackground = EOffOn.TR_CONFIG_OFF;
// Record
public static SMicConfig[] MicConfig;
- public static int MicDelay = 200; //[ms]
+ public static int MicDelay = 300; //[ms]
//Lists to save parameters and values
private static List _Params = new List();
@@ -300,7 +330,10 @@ namespace Vocaluxe.Base
CHelper.TryGetEnumValueFromXML("//root/Theme/DrawNoteLines", navigator, ref DrawNoteLines);
CHelper.TryGetEnumValueFromXML("//root/Theme/DrawToneHelper", navigator, ref DrawToneHelper);
CHelper.TryGetEnumValueFromXML("//root/Theme/TimerLook", navigator, ref TimerLook);
+ CHelper.TryGetEnumValueFromXML("//root/Theme/PlayerInfo", navigator, ref PlayerInfo);
+ CHelper.TryGetEnumValueFromXML("//root/Theme/FadePlayerInfo", navigator, ref FadePlayerInfo);
CHelper.TryGetEnumValueFromXML("//root/Theme/CoverLoading", navigator, ref CoverLoading);
+ CHelper.TryGetEnumValueFromXML("//root/Theme/LyricStyle", navigator, ref LyricStyle);
#endregion Theme
#region Sound
@@ -335,6 +368,7 @@ namespace Vocaluxe.Base
CHelper.TryGetEnumValueFromXML("//root/Game/SongMenu", navigator, ref SongMenu);
CHelper.TryGetEnumValueFromXML("//root/Game/SongSorting", navigator, ref SongSorting);
+ CHelper.TryGetEnumValueFromXML("//root/Game/IgnoreArticles", navigator, ref IgnoreArticles);
CHelper.TryGetFloatValueFromXML("//root/Game/ScoreAnimationTime", navigator, ref ScoreAnimationTime);
CHelper.TryGetEnumValueFromXML("//root/Game/TimerMode", navigator, ref TimerMode);
CHelper.TryGetIntValueFromXML("//root/Game/NumPlayer", navigator, ref NumPlayer);
@@ -370,6 +404,12 @@ namespace Vocaluxe.Base
}
CLanguage.SetLanguage(Language);
+ //Read players from config
+ for (i = 1; i <= CSettings.MaxNumPlayer; i++)
+ {
+ CHelper.GetValueFromXML("//root/Game/Players/Player" + i.ToString(), navigator, ref Players[i-1], string.Empty);
+ }
+
#endregion Game
#region Video
@@ -377,6 +417,7 @@ namespace Vocaluxe.Base
CHelper.TryGetEnumValueFromXML("//root/Video/VideoBackgrounds", navigator, ref VideoBackgrounds);
CHelper.TryGetEnumValueFromXML("//root/Video/VideoPreview", navigator, ref VideoPreview);
CHelper.TryGetEnumValueFromXML("//root/Video/VideosInSongs", navigator, ref VideosInSongs);
+ CHelper.TryGetEnumValueFromXML("//root/Video/VideosToBackground", navigator, ref VideosToBackground);
#endregion Video
#region Record
@@ -496,9 +537,18 @@ namespace Vocaluxe.Base
writer.WriteComment("Look of timer:" + ListStrings(Enum.GetNames(typeof(ETimerLook))));
writer.WriteElementString("TimerLook", Enum.GetName(typeof(ETimerLook), TimerLook));
+ writer.WriteComment("Information about players on SingScreen:" + ListStrings(Enum.GetNames(typeof(EPlayerInfo))));
+ writer.WriteElementString("PlayerInfo", Enum.GetName(typeof(EPlayerInfo), PlayerInfo));
+
+ writer.WriteComment("Fade player-information with lyrics and notebars:" + ListStrings(Enum.GetNames(typeof(EFadePlayerInfo))));
+ writer.WriteElementString("FadePlayerInfo", Enum.GetName(typeof(EFadePlayerInfo), FadePlayerInfo));
+
writer.WriteComment("Cover Loading:" + ListStrings(Enum.GetNames(typeof(ECoverLoading))));
writer.WriteElementString("CoverLoading", Enum.GetName(typeof(ECoverLoading), CoverLoading));
+ writer.WriteComment("Lyric Style:" + ListStrings(Enum.GetNames(typeof(ELyricStyle))));
+ writer.WriteElementString("LyricStyle", Enum.GetName(typeof(ELyricStyle), LyricStyle));
+
writer.WriteEndElement();
#endregion Theme
@@ -562,6 +612,9 @@ namespace Vocaluxe.Base
writer.WriteComment("SongSorting: " + ListStrings(Enum.GetNames(typeof(ESongSorting))));
writer.WriteElementString("SongSorting", Enum.GetName(typeof(ESongSorting), SongSorting));
+ writer.WriteComment("Ignore articles on song-sorting: " + ListStrings(Enum.GetNames(typeof(EOffOn))));
+ writer.WriteElementString("IgnoreArticles", Enum.GetName(typeof(EOffOn), IgnoreArticles));
+
writer.WriteComment("ScoreAnimationTime: Values >= 1 or 0 for no animation. Time is in seconds.");
writer.WriteElementString("ScoreAnimationTime", ScoreAnimationTime.ToString());
@@ -577,6 +630,14 @@ namespace Vocaluxe.Base
writer.WriteComment("Lyrics also on Top of screen: " + ListStrings(Enum.GetNames(typeof(EOffOn))));
writer.WriteElementString("LyricsOnTop", Enum.GetName(typeof(EOffOn), LyricsOnTop));
+ writer.WriteComment("Default profile for players 1..." + CSettings.MaxNumPlayer.ToString() + ":");
+ writer.WriteStartElement("Players");
+ for (int i = 1; i <= CSettings.MaxNumPlayer; i++)
+ {
+ writer.WriteElementString("Player" + i.ToString(), Path.GetFileName(Players[i - 1]));
+ }
+ writer.WriteEndElement();
+
writer.WriteEndElement();
#endregion Game
@@ -595,6 +656,9 @@ namespace Vocaluxe.Base
writer.WriteComment("Show Videos while singing: " + ListStrings(Enum.GetNames(typeof(EOffOn))));
writer.WriteElementString("VideosInSongs", Enum.GetName(typeof(EOffOn), VideosInSongs));
+ writer.WriteComment("Show backgroundmusic videos as background: " + ListStrings(Enum.GetNames(typeof(EOffOn))));
+ writer.WriteElementString("VideosToBackground", Enum.GetName(typeof(EOffOn), VideosToBackground));
+
writer.WriteEndElement();
#endregion Video
@@ -945,6 +1009,33 @@ namespace Vocaluxe.Base
return _Result;
}
+ ///
+ /// Use saved players from config now for games
+ ///
+ public static void UsePlayers()
+ {
+ for (int i = 0; i < CProfiles.Profiles.Length; i++)
+ {
+ for (int j = 0; j < CSettings.MaxNumPlayer; j++)
+ {
+ if (Players[j] != string.Empty)
+ {
+ if (Path.GetFileName(CProfiles.Profiles[i].ProfileFile) == Players[j] && CProfiles.Profiles[i].Active == EOffOn.TR_CONFIG_ON)
+ {
+ //Update Game-infos with player
+ CGame.Player[j].Name = CProfiles.Profiles[i].PlayerName;
+ CGame.Player[j].Difficulty = CProfiles.Profiles[i].Difficulty;
+ CGame.Player[j].ProfileID = i;
+ }
+ }
+ else
+ {
+ CGame.Player[j].ProfileID = -1;
+ }
+ }
+ }
+ }
+
}
diff --git a/Vocaluxe/Base/CDataBase.cs b/Vocaluxe/Base/CDataBase.cs
index e1040bf8..53ef0cc8 100644
--- a/Vocaluxe/Base/CDataBase.cs
+++ b/Vocaluxe/Base/CDataBase.cs
@@ -797,10 +797,16 @@ namespace Vocaluxe.Base
data.id = Sqlite3.sqlite3_column_int(Stmt, 0);
byte[] bytes = Sqlite3.sqlite3_column_rawbytes(Stmt, 1);
- data.str1 = UTF8.GetString(Encoding.Convert(CP1252, UTF8, bytes));
+ if (bytes != null)
+ data.str1 = UTF8.GetString(Encoding.Convert(CP1252, UTF8, bytes));
+ else
+ data.str1 = "Someone";
bytes = Sqlite3.sqlite3_column_rawbytes(Stmt, 2);
- data.str2 = UTF8.GetString(Encoding.Convert(CP1252, UTF8, bytes));
+ if (bytes != null)
+ data.str2 = UTF8.GetString(Encoding.Convert(CP1252, UTF8, bytes));
+ else
+ data.str2 = "Someone";
songs.Add(data);
}
@@ -832,7 +838,10 @@ namespace Vocaluxe.Base
data.id = Sqlite3.sqlite3_column_int(Stmt, 0);
byte[] bytes = Sqlite3.sqlite3_column_rawbytes(Stmt, 1);
- data.str1 = UTF8.GetString(Encoding.Convert(CP1252, UTF8, bytes));
+ if (bytes != null)
+ data.str1 = UTF8.GetString(Encoding.Convert(CP1252, UTF8, bytes));
+ else
+ data.str1 = "Someone";
if (dateExists)
data.ticks = UnixTimeToTicks(Sqlite3.sqlite3_column_int(Stmt, 2));
diff --git a/Vocaluxe/Base/CDraw.cs b/Vocaluxe/Base/CDraw.cs
index 0f6d9e60..180ee03b 100644
--- a/Vocaluxe/Base/CDraw.cs
+++ b/Vocaluxe/Base/CDraw.cs
@@ -239,6 +239,19 @@ namespace Vocaluxe.Base
_Draw.DrawTexture(Texture, rect, color, begin, end);
}
+ public static void DrawTexture(CStatic StaticBounds, STexture Texture, EAspect Aspect)
+ {
+ RectangleF bounds = new RectangleF(StaticBounds.Rect.X, StaticBounds.Rect.Y, StaticBounds.Rect.W, StaticBounds.Rect.H);
+ RectangleF rect = new RectangleF(0f, 0f, Texture.width, Texture.height);
+
+ if (rect.Height <= 0f)
+ return;
+
+ CHelper.SetRect(bounds, ref rect, rect.Width / rect.Height, Aspect);
+ DrawTexture(Texture, new SRectF(rect.X, rect.Y, rect.Width, rect.Height, StaticBounds.Rect.Z),
+ Texture.color, new SRectF(bounds.X, bounds.Y, bounds.Width, bounds.Height, 0f), false);
+ }
+
public static void DrawTextureReflection(STexture Texture, SRectF rect, SColorF color, SRectF bounds, float space, float height)
{
_Draw.DrawTextureReflection(Texture, rect, color, bounds, space, height);
diff --git a/Vocaluxe/Base/CGame.cs b/Vocaluxe/Base/CGame.cs
index 9c2b6c7d..d07275a7 100644
--- a/Vocaluxe/Base/CGame.cs
+++ b/Vocaluxe/Base/CGame.cs
@@ -16,6 +16,8 @@ namespace Vocaluxe.Base
public string Name;
public EGameDifficulty Difficulty;
public double Points;
+ public double PointsLineBonus;
+ public double PointsGoldenNotes;
public int NoteDiff;
public int LineNr;
public List SingLine;
@@ -25,6 +27,7 @@ namespace Vocaluxe.Base
public int SongID;
public bool Medley;
public bool Duet;
+ public bool ShortSong;
public long DateTicks;
public bool SongFinished;
}
@@ -102,40 +105,29 @@ namespace Vocaluxe.Base
_GameMode.Init();
_Player = new SPlayer[CSettings.MaxNumPlayer];
ResetPlayer();
+
+ CConfig.UsePlayers();
}
- public static void SetGameMode(EGameMode Mode)
+ public static void EnterNomalGame()
{
- switch (Mode)
- {
- case EGameMode.Normal:
- _GameMode = new CGameModeNormal();
- break;
- case EGameMode.Medley:
- _GameMode = new CGameModeMedley();
- break;
- case EGameMode.Duet:
- _GameMode = new CGameModeDuet();
- break;
- default:
- break;
- }
+ _GameMode = new CGameModeNormal();
_GameMode.Init();
}
public static EGameMode GameMode
{
- get { return _GameMode.GetGameMode(); }
+ get { return _GameMode.GetCurrentGameMode(); }
}
- public static bool AddVisibleSong(int VisibleIndex)
+ public static bool AddVisibleSong(int VisibleIndex, EGameMode GameMode)
{
- return _GameMode.AddVisibleSong(VisibleIndex);
+ return _GameMode.AddVisibleSong(VisibleIndex, GameMode);
}
- public static bool AddSong(int AbsoluteIndex)
+ public static bool AddSong(int AbsoluteIndex, EGameMode GameMode)
{
- return _GameMode.AddSong(AbsoluteIndex);
+ return _GameMode.AddSong(AbsoluteIndex, GameMode);
}
public static bool RemoveVisibleSong(int VisibleIndex)
@@ -175,7 +167,7 @@ namespace Vocaluxe.Base
public static int RoundNr
{
- get { return _GameMode.GetActualRoundNr(); }
+ get { return _GameMode.GetCurrentRoundNr(); }
}
public static CSong GetSong()
@@ -213,6 +205,8 @@ namespace Vocaluxe.Base
for (int i = 0; i < _Player.Length; i++)
{
_Player[i].Points = 0f;
+ _Player[i].PointsLineBonus = 0f;
+ _Player[i].PointsGoldenNotes = 0f;
_Player[i].LineNr = 0;
_Player[i].NoteDiff = 0;
_Player[i].SingLine = new List();
@@ -221,6 +215,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;
}
@@ -242,7 +237,12 @@ namespace Vocaluxe.Base
_MidBeatD = -0.5f + GetBeatFromTime(Time, song.BPM, song.Gap + CConfig.MicDelay/1000f);
_CurrentBeatD = (int)Math.Floor(_MidBeatD);
- if (_OldBeatD == _CurrentBeatD)
+ for (int p = 0; p < _NumPlayer; p++)
+ {
+ CSound.AnalyzeBuffer(p);
+ }
+
+ if (_OldBeatD >= _CurrentBeatD)
return;
for (int p = 0; p < _NumPlayer; p++)
@@ -298,7 +298,6 @@ namespace Vocaluxe.Base
}
}
- CSound.AnalyzeBuffer(p);
if (notes[Note].PointsForBeat > 0 && (CSound.RecordToneValid(p) || DEBUG_HIT))
{
int Tone = notes[Note].Tone;
@@ -317,8 +316,12 @@ namespace Vocaluxe.Base
if (_Player[p].NoteDiff <= (2 - (int)_Player[p].Difficulty))
{
// valid
- CSound.RecordSetTone(p, Tone);
- _Player[p].Points += (CSettings.MaxScore - CSettings.LinebonusScore) * (double)notes[Note].PointsForBeat / (double)song.Notes.GetLines(_Player[p].LineNr).Points;
+ //CSound.RecordSetTone(p, Tone);
+ double points = (CSettings.MaxScore - CSettings.LinebonusScore) * (double)notes[Note].PointsForBeat / (double)song.Notes.GetLines(_Player[p].LineNr).Points;
+ if (notes[Note].NoteType == ENoteType.Golden)
+ _Player[p].PointsGoldenNotes += points;
+
+ _Player[p].Points += points;
// update player notes (sung notes)
if (_Player[p].SingLine[Line].NoteCount > 0)
@@ -338,11 +341,6 @@ namespace Vocaluxe.Base
_Player[p].SingLine[Line].LastNote.IsPerfect(notes[Note]);
_Player[p].SingLine[Line].IsPerfect(lines[Line]);
-
- if (_Player[p].SingLine[Line].PerfectLine)
- {
- _Player[p].Points += CSettings.LinebonusScore * (double)lines[Line].Points / (double)song.Notes.GetPoints(_Player[p].LineNr);
- }
}
else
{
@@ -350,7 +348,7 @@ namespace Vocaluxe.Base
{
CNote nt = _Player[p].SingLine[Line].LastNote;
if (nt.EndBeat + 1 != beat || nt.Hit)
- _Player[p].SingLine[Line].AddNote(new CNote(beat, 1, TonePlayer, String.Empty, false, notes[Note].NoteType));
+ _Player[p].SingLine[Line].AddNote(new CNote(beat, 1, TonePlayer, String.Empty, false, ENoteType.Freestyle));
else
{
if (nt.Tone == TonePlayer && nt.EndBeat + 1 == beat)
@@ -359,17 +357,41 @@ namespace Vocaluxe.Base
}
else
{
- _Player[p].SingLine[Line].AddNote(new CNote(beat, 1, TonePlayer, String.Empty, false, notes[Note].NoteType));
+ _Player[p].SingLine[Line].AddNote(new CNote(beat, 1, TonePlayer, String.Empty, false, ENoteType.Freestyle));
}
}
}
else
{
- _Player[p].SingLine[Line].AddNote(new CNote(beat, 1, TonePlayer, String.Empty, false, notes[Note].NoteType));
+ _Player[p].SingLine[Line].AddNote(new CNote(beat, 1, TonePlayer, String.Empty, false, ENoteType.Freestyle));
}
}
}
+
+ // Line Bonus
+ int NumLinesWithPoints = song.Notes.GetNumLinesWithPoints(_Player[p].LineNr);
+ if (Note == lines[Line].NoteCount - 1 && NumLinesWithPoints > 0)
+ {
+ if (notes[Note].EndBeat == beat && lines[Line].Points > 0f)
+ {
+ double factor = (double)_Player[p].SingLine[Line].Points / (double)lines[Line].Points;
+ if (factor < 0.4)
+ factor = 0.0;
+ else if (factor > 0.9)
+ factor = 1.0;
+ else
+ {
+ factor -= 0.4;
+ factor *= 2;
+ factor *= factor;
+ }
+
+ double points = CSettings.LinebonusScore * factor * 1f / NumLinesWithPoints;
+ _Player[p].Points += points;
+ _Player[p].PointsLineBonus += points;
+ }
+ }
}
}
diff --git a/Vocaluxe/Base/CPlaylists.cs b/Vocaluxe/Base/CPlaylists.cs
new file mode 100644
index 00000000..a720107a
--- /dev/null
+++ b/Vocaluxe/Base/CPlaylists.cs
@@ -0,0 +1,80 @@
+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 CPlaylist[] Playlists
+ {
+ get { return _Playlists.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)
+ {
+ CPlaylist playlist = new CPlaylist(file);
+ }
+
+ SortPlaylistsByName();
+ }
+
+ #region private methods
+
+ private static void SortPlaylistsByName()
+ {
+ _Playlists.Sort(CompareByPlaylistName);
+ }
+
+ private static int CompareByPlaylistName(CPlaylist a, CPlaylist 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");
+ }
+ }
+ }
+
+ #endregion
+ }
+}
diff --git a/Vocaluxe/Base/CSettings.cs b/Vocaluxe/Base/CSettings.cs
index 7be8e342..7a382cf7 100644
--- a/Vocaluxe/Base/CSettings.cs
+++ b/Vocaluxe/Base/CSettings.cs
@@ -40,14 +40,14 @@ namespace Vocaluxe.Base
public static EGameState GameState = EGameState.Start;
public const string sProgramName = "Vocaluxe";
- public const string sProgramCodeName = "Rising Star";
+ public const string sProgramCodeName = "Test";
public const int iVersionMajor = 0;
- public const int iVersionMinor = 1; // milestones
- public const int iVersionSub = 0; // steps
+ public const int iVersionMinor = 2; // milestones
+ public const int iVersionSub = 0; // patches
public const ERevision VersionRevision = ERevision.Alpha;
- public const int iBuild = 60; // Increase on every published version! Never Reset!
+ public const int iBuild = 66; // 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 const 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;
@@ -103,7 +104,7 @@ namespace Vocaluxe.Base
public static int MouseMoveDiffMin = 2;
public const float MouseMoveOffTime = 3f;
- public const int MaxNumPlayer = 3;
+ public const int MaxNumPlayer = 6;
public const int MaxScore = 10000;
public const int LinebonusScore = 1000;
public const int MinScoreForDB = 100;
@@ -120,6 +121,11 @@ namespace Vocaluxe.Base
public static bool TabNavigation = false;
public const float BackgroundMusicFadeTime = 0.5f;
+
+ public static List MusicFileTypes = new List()
+ {
+ "*.mp3","*.wma","*.ogg","*.wav"
+ };
public static string GetVersionText()
{
diff --git a/Vocaluxe/Base/CSongs.cs b/Vocaluxe/Base/CSongs.cs
index 8473cf25..cc33b1ed 100644
--- a/Vocaluxe/Base/CSongs.cs
+++ b/Vocaluxe/Base/CSongs.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
+using System.Globalization;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
@@ -353,12 +354,24 @@ namespace Vocaluxe.Base
int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
if (res == 0)
{
- res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
- if (res == 0)
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
}
return res;
});
@@ -407,12 +420,24 @@ namespace Vocaluxe.Base
int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
if (res == 0)
{
- res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
- if (res == 0)
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
}
return res;
});
@@ -480,12 +505,24 @@ namespace Vocaluxe.Base
int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
if (res == 0)
{
- res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
- if (res == 0)
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
}
return res;
});
@@ -506,17 +543,29 @@ namespace Vocaluxe.Base
case ESongSorting.TR_CONFIG_ARTIST:
foreach (CSong song in _SongList)
{
- _SortList.Add(new SongPointer(song.ID, song.Artist));
+ _SortList.Add(new SongPointer(song.ID, song.Artist));
}
_SortList.Sort(delegate(SongPointer s1, SongPointer s2)
- {
- int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
- if (res == 0)
+ {
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ int res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
});
_SongsSortList = _SortList.ToArray();
@@ -535,7 +584,10 @@ namespace Vocaluxe.Base
case ESongSorting.TR_CONFIG_ARTIST_LETTER:
foreach (CSong song in _SongList)
{
- _SortList.Add(new SongPointer(song.ID, song.Artist));
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
+ _SortList.Add(new SongPointer(song.ID, song.ArtistSorting));
+ else
+ _SortList.Add(new SongPointer(song.ID, song.Artist));
}
_SortList.Sort(delegate(SongPointer s1, SongPointer s2)
@@ -543,7 +595,14 @@ namespace Vocaluxe.Base
int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
if (res == 0)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ else
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
}
return res;
});
@@ -554,7 +613,7 @@ namespace Vocaluxe.Base
int NotLetterCat = -1;
for (int i=0; i < _SongsSortList.Length; i++)
{
- Char firstLetter = Char.ToUpper(_SongsSortList[i].SortString[0]);
+ Char firstLetter = Char.ToUpper(_SongsSortList[i].SortString.Normalize(NormalizationForm.FormD)[0]);
if (!Char.IsLetter(firstLetter))
{
@@ -583,7 +642,10 @@ namespace Vocaluxe.Base
case ESongSorting.TR_CONFIG_TITLE_LETTER:
foreach (CSong song in _SongList)
{
- _SortList.Add(new SongPointer(song.ID, song.Title));
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
+ _SortList.Add(new SongPointer(song.ID, song.TitleSorting));
+ else
+ _SortList.Add(new SongPointer(song.ID, song.Title));
}
_SortList.Sort(delegate(SongPointer s1, SongPointer s2)
@@ -591,7 +653,14 @@ namespace Vocaluxe.Base
int res = s1.SortString.ToUpper().CompareTo(s2.SortString.ToUpper());
if (res == 0)
{
- return _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
+ {
+ return _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ }
+ else
+ {
+ return _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ }
}
return res;
});
@@ -602,7 +671,7 @@ namespace Vocaluxe.Base
NotLetterCat = -1;
for (int i=0; i < _SongsSortList.Length; i++)
{
- Char firstLetter = Char.ToUpper(_SongsSortList[i].SortString[0]);
+ Char firstLetter = Char.ToUpper(_SongsSortList[i].SortString.Normalize(NormalizationForm.FormD)[0]);
if (!Char.IsLetter(firstLetter))
{
@@ -639,12 +708,24 @@ namespace Vocaluxe.Base
int res = s1.SortString.CompareTo(s2.SortString);
if (res == 0)
{
- res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
- if (res == 0)
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
}
return res;
});
@@ -686,12 +767,24 @@ namespace Vocaluxe.Base
int res = s1.SortString.CompareTo(s2.SortString);
if (res == 0)
{
- res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
- if (res == 0)
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
}
return res;
});
@@ -740,12 +833,24 @@ namespace Vocaluxe.Base
int res = s1.SortString.CompareTo(s2.SortString);
if (res == 0)
{
- res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
- if (res == 0)
+ if (CConfig.IgnoreArticles == EOffOn.TR_CONFIG_ON)
{
- return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ res = _Songs[s1.SongID].ArtistSorting.ToUpper().CompareTo(_Songs[s2.SongID].ArtistSorting.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].TitleSorting.ToUpper().CompareTo(_Songs[s2.SongID].TitleSorting.ToUpper());
+ }
+ return res;
+ }
+ else
+ {
+ res = _Songs[s1.SongID].Artist.ToUpper().CompareTo(_Songs[s2.SongID].Artist.ToUpper());
+ if (res == 0)
+ {
+ return _Songs[s1.SongID].Title.ToUpper().CompareTo(_Songs[s2.SongID].Title.ToUpper());
+ }
+ return res;
}
- return res;
}
return res;
});
diff --git a/Vocaluxe/Base/CSound.cs b/Vocaluxe/Base/CSound.cs
index e7956ecb..71c6fd59 100644
--- a/Vocaluxe/Base/CSound.cs
+++ b/Vocaluxe/Base/CSound.cs
@@ -181,6 +181,9 @@ namespace Vocaluxe.Base
case ERecordLib.PortAudio:
_Record = new CPortAudioRecord();
break;
+ case ERecordLib.DirectSound:
+ _Record = new CDirectSoundRecord();
+ break;
default:
_Record = new CPortAudioRecord();
@@ -237,6 +240,16 @@ namespace Vocaluxe.Base
return _Record.GetMaxVolume(Player);
}
+ public static int NumHalfTones(int Player)
+ {
+ return _Record.NumHalfTones(Player);
+ }
+
+ public static float[] ToneWeigth(int Player)
+ {
+ return _Record.ToneWeigth(Player);
+ }
+
public static SRecordDevice[] RecordGetDevices()
{
SRecordDevice[] devices = _Record.RecordDevices();
@@ -281,9 +294,10 @@ namespace Vocaluxe.Base
class CBuffer
{
- private const double BaseToneFreq = 65.4064;
- private const int NumHalfTones = 47;
+ private const double _BaseToneFreq = 65.4064;
+ private const int _NumHalfTones = 47;
+ private float[] _ToneWeigth;
private Int16[] _AnalysisBuffer = new Int16[4096];
private Object _AnalysisBufferLock = new Object();
@@ -291,37 +305,71 @@ namespace Vocaluxe.Base
private int _Tone = 0;
private int _ToneAbs = 0;
private double _MaxVolume = 0.0;
- private bool _NewSamples = false;
+ private bool _NewSamples;
private MemoryStream _Stream; // full buffer
+ public CBuffer()
+ {
+ _ToneWeigth = new float[_NumHalfTones];
+ _Stream = new MemoryStream();
+ _NewSamples = false;
+ }
+
+ public int NumHalfTones
+ {
+ get { return _NumHalfTones; }
+ }
+
public int ToneAbs
{
- get { return _ToneAbs; }
+ get
+ {
+ lock (_AnalysisBufferLock)
+ {
+ return _ToneAbs;
+ }
+ }
}
public int Tone
{
- get { return _Tone; }
- set { _Tone = value; }
+ get
+ {
+ lock (_AnalysisBufferLock)
+ {
+ return _Tone;
+ }
+ }
+ set
+ {
+ lock (_AnalysisBufferLock)
+ {
+ _Tone = value;
+ }
+ }
}
public float MaxVolume
{
get
{
- return (float)_MaxVolume;
+ lock (_AnalysisBufferLock)
+ {
+ return (float)_MaxVolume;
+ }
}
}
public bool ToneValid
{
- get { return _ToneValid; }
- }
-
- public CBuffer()
- {
- _Stream = new MemoryStream();
+ get
+ {
+ lock (_AnalysisBufferLock)
+ {
+ return _ToneValid;
+ }
+ }
}
public long Length
@@ -334,6 +382,17 @@ namespace Vocaluxe.Base
get { return _Stream.ToArray(); }
}
+ public float[] ToneWeigth
+ {
+ get
+ {
+ lock (_AnalysisBufferLock)
+ {
+ return _ToneWeigth;
+ }
+ }
+ }
+
public void Reset()
{
_Stream.SetLength(0L);
@@ -359,39 +418,8 @@ namespace Vocaluxe.Base
//if (assigned(fVoiceStream)) then
//fVoiceStream.WriteData(Buffer, BufferSize);
- int BufferOffset = 0;
- int SampleCount = (int)Math.Floor(buffer.Length / 2.0);
-
- if (SampleCount > _AnalysisBuffer.Length)
- {
- BufferOffset = (SampleCount - _AnalysisBuffer.Length) * 2;
- SampleCount = _AnalysisBuffer.Length;
- }
-
lock (_AnalysisBufferLock)
{
- try
- {
- // move old samples to the beginning of the array (if necessary)
- for (int i = 0; i < _AnalysisBuffer.Length - SampleCount; i++)
- {
- _AnalysisBuffer[i] = _AnalysisBuffer[i + SampleCount];
- }
-
- byte[] b = new byte[2];
- // copy new samples to analysis buffer
- for (int i = 0; i < SampleCount; i++)
- {
- b[0] = buffer[BufferOffset + i * 2];
- b[1] = buffer[BufferOffset + i * 2 + 1];
-
- _AnalysisBuffer[_AnalysisBuffer.Length - SampleCount + i] = BitConverter.ToInt16(b, 0);
- }
- }
- catch (Exception)
- {
-
- }
Add(buffer);
_NewSamples = true;
}
@@ -399,69 +427,98 @@ namespace Vocaluxe.Base
public void AnalyzeBuffer()
{
+ if (!_NewSamples)
+ return;
+
lock (_AnalysisBufferLock)
{
- if (!_NewSamples)
- return;
-
- try
+ int len = _AnalysisBuffer.Length * 2;
+ if (_Stream.Length >= len)
{
- // find maximum volume
- _MaxVolume = 0;
- for (int i = 0; i < _AnalysisBuffer.Length/4; i++)
- {
- float Volume = Math.Abs((float)_AnalysisBuffer[i]) / (float)Int16.MaxValue;
- if (Volume > MaxVolume)
- _MaxVolume = Volume;
- }
+ byte[] buf = new byte[len];
+ _Stream.Position -= len;
+ _Stream.Read(buf, 0, len);
- if (_MaxVolume >= 0.2f)
+ byte[] b = new byte[2];
+ for (int i = 0; i < _AnalysisBuffer.Length; i++)
{
- // analyse the current voice pitch
- AnalyzeByAutocorrelation();
- _ToneValid = true;
- }
- else
- _ToneValid = false;
+ b[0] = buf[i * 2];
+ b[1] = buf[i * 2 + 1];
- _NewSamples = false;
+ _AnalysisBuffer[i] = BitConverter.ToInt16(b, 0);
+ }
}
- catch (Exception)
+ _NewSamples = false;
+ }
+
+ try
+ {
+ // find maximum volume
+ _MaxVolume = 0;
+ for (int i = 0; i < _AnalysisBuffer.Length / 4; i++)
{
-
+ float Volume = Math.Abs((float)_AnalysisBuffer[i]) / (float)Int16.MaxValue;
+ if (Volume > MaxVolume)
+ _MaxVolume = Volume;
}
+
+ if (_MaxVolume >= 0.02f)
+ AnalyzeByAutocorrelation(true);
+ else
+ AnalyzeByAutocorrelation(false);
+
+ }
+ catch (Exception)
+ {
+
}
}
- private void AnalyzeByAutocorrelation()
+ private void AnalyzeByAutocorrelation(bool valid)
{
const double HalftoneBase = 1.05946309436; // 2^(1/12) -> HalftoneBase^12 = 2 (one octave)
// prepare to analyze
double MaxWeight = -1.0;
- int MaxTone = 0;
+ double MinWeight = 1.0;
+ int MaxTone = -1;
+ float[] Weigth = new float[_NumHalfTones];
// analyze halftones
// Note: at the lowest tone (~65Hz) and a buffer-size of 4096
// at 44.1 (or 48kHz) only 6 (or 5) samples are compared, this might be
// too few samples -> use a bigger buffer-size
- for (int ToneIndex = 0; ToneIndex < NumHalfTones; ToneIndex++)
+ for (int ToneIndex = 0; ToneIndex < _NumHalfTones; ToneIndex++)
{
- double CurFreq = BaseToneFreq * Math.Pow(HalftoneBase, ToneIndex);
+ double CurFreq = _BaseToneFreq * Math.Pow(HalftoneBase, ToneIndex);
double CurWeight = AnalyzeAutocorrelationFreq(CurFreq);
- // TODO: prefer higher frequencies (use >= or use downto)
- if (CurWeight > MaxWeight /* && (Math.Abs(ToneIndex - _ToneAbs) < 5 || _ToneAbs == 0)*/)
+ if (CurWeight > MaxWeight)
{
- // this frequency has a higher weight
MaxWeight = CurWeight;
MaxTone = ToneIndex;
}
+
+ if (CurWeight < MinWeight)
+ MinWeight = CurWeight;
+
+ Weigth[ToneIndex] = (float)CurWeight;
}
- _ToneAbs = MaxTone;
- _Tone = MaxTone % 12;
+ if (valid && MaxWeight - MinWeight > 0.01)
+ {
+ for (int i = 0; i < Weigth.Length; i++)
+ {
+ _ToneWeigth[i] = Weigth[i];
+ }
+
+ _ToneAbs = MaxTone;
+ _Tone = MaxTone % 12;
+ _ToneValid = true;
+ }
+ else
+ _ToneValid = false;
}
private double AnalyzeAutocorrelationFreq(double Freq)
diff --git a/Vocaluxe/Base/CVideo.cs b/Vocaluxe/Base/CVideo.cs
index 496e76b1..718222b4 100644
--- a/Vocaluxe/Base/CVideo.cs
+++ b/Vocaluxe/Base/CVideo.cs
@@ -1,5 +1,7 @@
using System;
using System.Collections.Generic;
+using System.Diagnostics;
+using System.Drawing;
using System.Text;
using Vocaluxe.Lib.Draw;
@@ -95,4 +97,100 @@ namespace Vocaluxe.Base
#endregion VideoDecoder
}
+
+ class VideoPlayer
+ {
+ private STexture _VideoTexture;
+ private int _VideoStream;
+ private Stopwatch _VideoTimer;
+ private bool _Finished;
+ private bool _Loaded;
+
+ public bool IsFinished
+ {
+ get { return _Finished || !_Loaded; }
+ }
+
+ public bool Loop
+ {
+ set { CVideo.VdSetLoop(_VideoStream, value); }
+ }
+
+ public VideoPlayer()
+ {
+ _VideoTimer = new Stopwatch();
+ _VideoTexture = new STexture(-1);
+ _Finished = false;
+ _Loaded = false;
+ }
+
+ public void Load(string VideoName)
+ {
+ _VideoStream = CVideo.VdLoad(CTheme.GetVideoFilePath(VideoName));
+ _Loaded = true;
+ }
+
+ public void Start()
+ {
+ _VideoTimer.Reset();
+ _Finished = false;
+ //CVideo.VdSkip(_VideoStream, 0f, 0f);
+ _VideoTimer.Start();
+ }
+
+ public void Pause()
+ {
+ _VideoTimer.Stop();
+ }
+
+ public void Resume()
+ {
+ _VideoTimer.Start();
+ }
+
+ public void Draw()
+ {
+ if (!_Finished)
+ {
+
+ float VideoTime = _VideoTimer.ElapsedMilliseconds / 1000f;
+ _Finished = CVideo.VdFinished(_VideoStream);
+
+ STexture tex = new STexture(-1);
+ tex.height = 0f;
+ CVideo.VdGetFrame(_VideoStream, ref tex, VideoTime, ref VideoTime);
+
+ if (tex.height > 0)
+ {
+ CDraw.RemoveTexture(ref _VideoTexture);
+ _VideoTexture = tex;
+ }
+ }
+ RectangleF bounds = new RectangleF(0f, 0f, CSettings.iRenderW, CSettings.iRenderH);
+ RectangleF rect = new RectangleF(0f, 0f, _VideoTexture.width, _VideoTexture.height);
+ CHelper.SetRect(bounds, ref rect, rect.Width / rect.Height, EAspect.Crop);
+
+ CDraw.DrawTexture(_VideoTexture, new SRectF(rect.X, rect.Y, rect.Width, rect.Height, CSettings.zFar / 4));
+ }
+
+ public void PreLoad()
+ {
+ float VideoTime = 0f;
+ while (_VideoTexture.index == -1 && VideoTime < 1f)
+ {
+ float dummy = 0f;
+ CVideo.VdGetFrame(_VideoStream, ref _VideoTexture, 0, ref dummy);
+ VideoTime += 0.05f;
+ }
+ }
+
+ public void Close()
+ {
+ CVideo.VdClose(_VideoStream);
+ CDraw.RemoveTexture(ref _VideoTexture);
+ _Loaded = false;
+ _Finished = false;
+ _VideoTimer.Reset();
+ }
+ }
}
diff --git a/Vocaluxe/GameModes/CGameMode.cs b/Vocaluxe/GameModes/CGameMode.cs
index 80e19118..6dfe5ca5 100644
--- a/Vocaluxe/GameModes/CGameMode.cs
+++ b/Vocaluxe/GameModes/CGameMode.cs
@@ -7,6 +7,18 @@ using Vocaluxe.Lib.Song;
namespace Vocaluxe.GameModes
{
+ struct SongQueque
+ {
+ public int SongID;
+ public EGameMode GameMode;
+
+ public SongQueque(int songID, EGameMode gameMode)
+ {
+ SongID = songID;
+ GameMode = gameMode;
+ }
+ }
+
class CPoints
{
private SPlayer[,] _Rounds;
@@ -22,15 +34,18 @@ namespace Vocaluxe.GameModes
_Rounds[round, player].ProfileID = Player[player].ProfileID;
_Rounds[round, player].Name = Player[player].Name;
_Rounds[round, player].Difficulty = Player[player].Difficulty;
- _Rounds[round, player].Points = 0;
+ _Rounds[round, player].Points = 0f;
+ _Rounds[round, player].PointsGoldenNotes = 0f;
+ _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++)
@@ -38,8 +53,11 @@ namespace Vocaluxe.GameModes
_Rounds[Round, player].SongID = SongID;
_Rounds[Round, player].LineNr = Player[player].LineNr;
_Rounds[Round, player].Points = Player[player].Points;
+ _Rounds[Round, player].PointsGoldenNotes = Player[player].PointsGoldenNotes;
+ _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;
}
@@ -68,11 +86,14 @@ namespace Vocaluxe.GameModes
{
player[p].Name = _Rounds[Round, p].Name;
player[p].Points = _Rounds[Round, p].Points;
+ player[p].PointsGoldenNotes = _Rounds[Round, p].PointsGoldenNotes;
+ player[p].PointsLineBonus = _Rounds[Round, p].PointsLineBonus;
player[p].SongID = _Rounds[Round, p].SongID;
player[p].LineNr = _Rounds[Round, p].LineNr;
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;
@@ -84,40 +105,49 @@ namespace Vocaluxe.GameModes
abstract class CGameMode : IGameMode
{
protected bool _Initialized = false;
- protected EGameMode _GameMode;
- protected List _Songs;
- protected int _ActualSong;
+ protected List _SongQueque;
+ protected int _CurrentSong;
protected CPoints _Points;
#region Implementation
public virtual void Init()
{
- _Songs = new List();
+ _SongQueque = new List();
Reset();
}
- public virtual EGameMode GetGameMode()
+ public virtual EGameMode GetCurrentGameMode()
{
- return _GameMode;
+ if (_CurrentSong >= 0 && _CurrentSong < _SongQueque.Count)
+ {
+ return _SongQueque[_CurrentSong].GameMode;
+ }
+ return EGameMode.TR_GAMEMODE_NORMAL;
}
- public virtual bool AddVisibleSong(int VisibleIndex)
+ public virtual bool AddVisibleSong(int VisibleIndex, EGameMode GameMode)
{
if (CSongs.VisibleSongs.Length > VisibleIndex)
{
- _Songs.Add(new CSong(CSongs.VisibleSongs[VisibleIndex]));
- SongManipulation(_Songs.Count - 1);
+ int SongID = CSongs.VisibleSongs[VisibleIndex].ID;
+ if (GameMode == EGameMode.TR_GAMEMODE_DUET && !CSongs.GetSong(SongID).IsDuet)
+ return false;
+
+ _SongQueque.Add(new SongQueque(SongID, GameMode));
return true;
}
return false;
}
- public virtual bool AddSong(int AbsoluteIndex)
+ public virtual bool AddSong(int AbsoluteIndex, EGameMode GameMode)
{
if (CSongs.AllSongs.Length > AbsoluteIndex)
{
- _Songs.Add(CSongs.AllSongs[AbsoluteIndex]);
- SongManipulation(_Songs.Count - 1);
+ int SongID = CSongs.AllSongs[AbsoluteIndex].ID;
+ if (GameMode == EGameMode.TR_GAMEMODE_DUET && !CSongs.GetSong(SongID).IsDuet)
+ return false;
+
+ _SongQueque.Add(new SongQueque(SongID, GameMode));
return true;
}
return false;
@@ -127,24 +157,22 @@ namespace Vocaluxe.GameModes
{
if (CSongs.VisibleSongs.Length > VisibleIndex)
{
- int ID = CSongs.VisibleSongs[VisibleIndex].ID;
int index = -1;
-
- for (int i = 0; i < _Songs.Count; i++)
+ int SongID = CSongs.VisibleSongs[VisibleIndex].ID;
+ for (int i = 0; i < _SongQueque.Count; i++)
{
- if (_Songs[i].ID == ID)
+ if (_SongQueque[i].SongID == SongID)
{
index = i;
break;
}
}
- if (index > -1)
- {
- _Songs.RemoveAt(index);
- return true;
- }
- return false;
+ if (index == -1)
+ return false;
+
+ _SongQueque.RemoveAt(index);
+ return true;
}
return false;
}
@@ -153,83 +181,110 @@ namespace Vocaluxe.GameModes
{
if (CSongs.AllSongs.Length > AbsoluteIndex)
{
- int ID = CSongs.AllSongs[AbsoluteIndex].ID;
int index = -1;
-
- for (int i = 0; i < _Songs.Count; i++)
+ int SongID = CSongs.AllSongs[AbsoluteIndex].ID;
+ for (int i = 0; i < _SongQueque.Count; i++)
{
- if (_Songs[i].ID == ID)
+ if (_SongQueque[i].SongID == SongID)
{
index = i;
break;
}
}
+ if (index == -1)
+ return false;
- if (index > -1)
- {
- _Songs.RemoveAt(index);
- return true;
- }
- return false;
+ _SongQueque.RemoveAt(index);
+ return true;
}
return false;
}
public virtual void ClearSongs()
{
- _Songs.Clear();
+ _SongQueque.Clear();
}
public virtual void Reset()
{
- _ActualSong = -1;
+ _CurrentSong = -1;
}
public virtual void Start(SPlayer[] Player)
{
- _Points = new CPoints(_Songs.Count, Player);
+ _Points = new CPoints(_SongQueque.Count, Player);
}
public virtual void NextRound(SPlayer[] Player)
{
- if (_ActualSong < _Songs.Count && _Songs.Count > 0)
+ if (_CurrentSong < _SongQueque.Count && _SongQueque.Count > 0)
{
- if (_ActualSong > -1)
+ if (_CurrentSong > -1)
{
- _Points.SetPoints(_ActualSong, _Songs[_ActualSong].ID, Player, _GameMode == EGameMode.Medley, _GameMode == EGameMode.Duet);
+ _Points.SetPoints(
+ _CurrentSong,
+ _SongQueque[_CurrentSong].SongID,
+ Player,
+ _SongQueque[_CurrentSong].GameMode == EGameMode.TR_GAMEMODE_MEDLEY,
+ _SongQueque[_CurrentSong].GameMode == EGameMode.TR_GAMEMODE_DUET,
+ _SongQueque[_CurrentSong].GameMode == EGameMode.TR_GAMEMODE_SHORTSONG);
}
- _ActualSong++;
+ _CurrentSong++;
}
}
public virtual bool IsFinished()
{
- return (_ActualSong == _Songs.Count || _Songs.Count == 0);
+ return (_CurrentSong == _SongQueque.Count || _SongQueque.Count == 0);
}
- public virtual int GetActualRoundNr()
+ public virtual int GetCurrentRoundNr()
{
- return _ActualSong + 1;
+ return _CurrentSong + 1;
}
public virtual CSong GetSong()
{
- if (_ActualSong >= 0 && _ActualSong < _Songs.Count)
+ if (_CurrentSong >= 0 && _CurrentSong < _SongQueque.Count)
{
- return _Songs[_ActualSong];
+ CSong song = CSongs.GetSong(_SongQueque[_CurrentSong].SongID);
+
+ 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;
}
public virtual int GetNumSongs()
{
- return _Songs.Count;
+ return _SongQueque.Count;
}
public virtual CSong GetSong(int Num)
{
- if (Num - 1 < _Songs.Count)
- return _Songs[Num - 1];
+ if (Num - 1 < _SongQueque.Count)
+ return CSongs.GetSong(_SongQueque[Num - 1].SongID);
return null;
}
diff --git a/Vocaluxe/GameModes/CGameModeDuet.cs b/Vocaluxe/GameModes/CGameModeDuet.cs
deleted file mode 100644
index cf105151..00000000
--- a/Vocaluxe/GameModes/CGameModeDuet.cs
+++ /dev/null
@@ -1,17 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Text;
-
-namespace Vocaluxe.GameModes
-{
- class CGameModeDuet : CGameMode
- {
- public override void Init()
- {
- base.Init();
-
- _GameMode = EGameMode.Duet;
- _Initialized = true;
- }
- }
-}
diff --git a/Vocaluxe/GameModes/CGameModeMedley.cs b/Vocaluxe/GameModes/CGameModeMedley.cs
deleted file mode 100644
index 7b22f145..00000000
--- a/Vocaluxe/GameModes/CGameModeMedley.cs
+++ /dev/null
@@ -1,35 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Text;
-
-using Vocaluxe.Base;
-using Vocaluxe.Lib.Song;
-
-namespace Vocaluxe.GameModes
-{
- class CGameModeMedley : CGameMode
- {
- public override void Init()
- {
- base.Init();
-
- _GameMode = EGameMode.Medley;
- _Initialized = true;
- }
-
- protected override void SongManipulation(int SongIndex)
- {
- CSong song = _Songs[SongIndex];
-
- // 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);
- }
- }
-}
diff --git a/Vocaluxe/GameModes/CGameModeNormal.cs b/Vocaluxe/GameModes/CGameModeNormal.cs
index 6a27341b..5f05bd6c 100644
--- a/Vocaluxe/GameModes/CGameModeNormal.cs
+++ b/Vocaluxe/GameModes/CGameModeNormal.cs
@@ -4,13 +4,13 @@ using System.Text;
namespace Vocaluxe.GameModes
{
+ // Nomal singing
class CGameModeNormal : CGameMode
{
public override void Init()
{
base.Init();
- _GameMode = EGameMode.Normal;
_Initialized = true;
}
}
diff --git a/Vocaluxe/GameModes/IGameMode.cs b/Vocaluxe/GameModes/IGameMode.cs
index e7d69afb..4d83391f 100644
--- a/Vocaluxe/GameModes/IGameMode.cs
+++ b/Vocaluxe/GameModes/IGameMode.cs
@@ -9,19 +9,20 @@ namespace Vocaluxe.GameModes
{
public enum EGameMode
{
- Normal,
- Medley,
- Duet
+ TR_GAMEMODE_NORMAL,
+ TR_GAMEMODE_MEDLEY,
+ TR_GAMEMODE_DUET,
+ TR_GAMEMODE_SHORTSONG
}
interface IGameMode
{
void Init();
- EGameMode GetGameMode();
+ EGameMode GetCurrentGameMode();
- bool AddVisibleSong(int VisibleIndex);
- bool AddSong(int AbsoluteIndex);
+ bool AddVisibleSong(int VisibleIndex, EGameMode GameMode);
+ bool AddSong(int AbsoluteIndex, EGameMode GameMode);
bool RemoveVisibleSong(int VisibleIndex);
bool RemoveSong(int AbsoluteIndex);
void ClearSongs();
@@ -30,11 +31,12 @@ namespace Vocaluxe.GameModes
void Start(SPlayer[] Player);
void NextRound(SPlayer[] Player);
bool IsFinished();
- int GetActualRoundNr();
- CSong GetSong();
+ int GetCurrentRoundNr();
+
CPoints GetPoints();
int GetNumSongs();
+ CSong GetSong();
CSong GetSong(int Num);
}
}
diff --git a/Vocaluxe/Lib/Playlist/CPlaylist.cs b/Vocaluxe/Lib/Playlist/CPlaylist.cs
new file mode 100644
index 00000000..54b654ad
--- /dev/null
+++ b/Vocaluxe/Lib/Playlist/CPlaylist.cs
@@ -0,0 +1,204 @@
+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.Base;
+
+
+namespace Vocaluxe.Lib.Playlist
+{
+ public class CPlaylistSong
+ {
+ public int SongID;
+ public GameModes.EGameMode gm;
+
+ public CPlaylistSong(int SongID, GameModes.EGameMode gm)
+ {
+ this.SongID = SongID;
+ this.gm = gm;
+ }
+
+ public CPlaylistSong()
+ {
+ gm = GameModes.EGameMode.TR_GAMEMODE_NORMAL;
+ }
+ }
+
+ public class CPlaylist
+ {
+ private static XmlWriterSettings _settings = new XmlWriterSettings();
+ private static CHelper Helper = new CHelper();
+
+ public string PlaylistName;
+ public string PlaylistFile;
+ public List Songs;
+
+ public CPlaylist()
+ {
+ Init();
+ }
+
+ public CPlaylist(string file)
+ {
+ Init();
+ PlaylistName = file;
+ LoadPlaylist();
+ }
+
+ private void Init()
+ {
+ _settings.Indent = true;
+ _settings.Encoding = System.Text.Encoding.UTF8;
+ _settings.ConformanceLevel = ConformanceLevel.Document;
+ }
+
+
+ private void SavePlaylist()
+ {
+ 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 (i = 0; i < Songs.Count; i++)
+ {
+ CSong[] songs = CSongs.AllSongs;
+ CSong song = new CSong();
+ for (int s = 0; i <= songs.Length; s++)
+ {
+ if (songs[s].ID == Songs[i].SongID)
+ {
+ song = songs[s];
+ break;
+ }
+ }
+ writer.WriteStartElement("Song" + (i + 1).ToString());
+ writer.WriteElementString("Artist", song.Artist);
+ writer.WriteElementString("Title", song.Title);
+ writer.WriteElementString("GameMode", Enum.GetName(typeof(GameModes.EGameMode), Songs[i].gm));
+ writer.WriteEndElement();
+ }
+ 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;
+ GameModes.EGameMode gm = GameModes.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();
+ 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;
+ }
+ }
+
+ song.gm = gm;
+
+ Songs.Add(song);
+ }
+ }
+ else
+ {
+ CLog.LogError("Can't find PlaylistName in Playlist File: " + PlaylistFile);
+ }
+ }
+ }
+ }
+}
diff --git a/Vocaluxe/Lib/Song/CNotes.cs b/Vocaluxe/Lib/Song/CNotes.cs
index cda4cc48..d38dc820 100644
--- a/Vocaluxe/Lib/Song/CNotes.cs
+++ b/Vocaluxe/Lib/Song/CNotes.cs
@@ -45,6 +45,14 @@ namespace Vocaluxe.Lib.Song
return _Lines[Index].Points;
}
+ public int GetNumLinesWithPoints(int Index)
+ {
+ if (Index >= _Lines.Count)
+ return 0;
+
+ return _Lines[Index].NumLinesWithPoints;
+ }
+
public void AddLines(CLines Lines)
{
_Lines.Add(Lines);
@@ -614,6 +622,20 @@ namespace Vocaluxe.Lib.Song
}
}
+ public int NumLinesWithPoints
+ {
+ get
+ {
+ int num = 0;
+ foreach (CLine line in _Lines)
+ {
+ if (line.Points > 0f)
+ num++;
+ }
+ return num;
+ }
+ }
+
#region Methods
public void AddLine(CLine Line)
{
diff --git a/Vocaluxe/Lib/Song/CSong.cs b/Vocaluxe/Lib/Song/CSong.cs
index 7a5da546..eefcbbc7 100644
--- a/Vocaluxe/Lib/Song/CSong.cs
+++ b/Vocaluxe/Lib/Song/CSong.cs
@@ -59,6 +59,8 @@ namespace Vocaluxe.Lib.Song
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;
@@ -115,6 +117,9 @@ namespace Vocaluxe.Lib.Song
public string Title = String.Empty;
public string Artist = String.Empty;
+ public string TitleSorting = String.Empty;
+ public string ArtistSorting = String.Empty;
+
public float Start = 0f;
public float Finish = 0f;
@@ -161,6 +166,8 @@ namespace Vocaluxe.Lib.Song
this.CalculateMedley = song.CalculateMedley;
this.PreviewStart = song.PreviewStart;
+ this.ShortEnd = song.ShortEnd;
+
this.Encoding = song.Encoding;
this.Folder = song.Folder;
this.FolderName = song.FolderName;
@@ -224,6 +231,11 @@ namespace Vocaluxe.Lib.Song
return Path.Combine(Folder, MP3FileName);
}
+ public string GetVideo()
+ {
+ return Path.Combine(Folder, VideoFileName);
+ }
+
public bool ReadTXTSong(string FilePath)
{
if (!File.Exists(FilePath))
@@ -337,6 +349,18 @@ namespace Vocaluxe.Lib.Song
HeaderFlags |= EHeaderFlags.Artist;
}
break;
+ case "TITLE-ON-SORTING":
+ if (Value != String.Empty)
+ {
+ this.TitleSorting = Value;
+ }
+ break;
+ case "ARTIST-ON-SORTING":
+ if (Value != String.Empty)
+ {
+ this.ArtistSorting = Value;
+ }
+ break;
case "MP3":
if (File.Exists(Path.Combine(this.Folder, Value)))
{
@@ -508,6 +532,17 @@ namespace Vocaluxe.Lib.Song
CheckFiles();
+ //Before saving this tags to .txt: Check, if ArtistSorting and Artist are equal, then don't save this tag.
+ if (this.ArtistSorting == "")
+ {
+ this.ArtistSorting = this.Artist;
+ }
+
+ if (this.TitleSorting == "")
+ {
+ this.TitleSorting = this.Title;
+ }
+
return true;
}
@@ -557,9 +592,9 @@ namespace Vocaluxe.Lib.Song
TempC = (char)sr.Read();
} while ((TempC.CompareTo(':') != 0) && (TempC.CompareTo('F') != 0) && (TempC.CompareTo('*') != 0) && (TempC.CompareTo('P') != 0));
- FileLineNo++;
while (!sr.EndOfStream && (TempC.CompareTo('E') != 0))
{
+ FileLineNo++;
if (TempC.CompareTo('P') == 0)
{
char chr = (char)sr.Read();
@@ -634,7 +669,7 @@ namespace Vocaluxe.Lib.Song
{
c = sr.Read();
TempC = (char)c;
- } while ((TempC.CompareTo('E') != 0) && !sr.EndOfStream && (c == 19 || c == 16 || c == 13));
+ } while ((TempC.CompareTo('E') != 0) && !sr.EndOfStream && (c == 19 || c == 16 || c == 13 || c==10));
}
foreach(CLines lines in this.Notes.Lines)
{
@@ -647,6 +682,7 @@ namespace Vocaluxe.Lib.Song
return false;
}
FindRefrain();
+ FindShortEnd();
_NotesLoaded = true;
return true;
@@ -831,5 +867,88 @@ namespace Vocaluxe.Lib.Song
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;
+
+ }
}
}
diff --git a/Vocaluxe/Lib/Sound/CDirectSoundRecord.cs b/Vocaluxe/Lib/Sound/CDirectSoundRecord.cs
new file mode 100644
index 00000000..c8abe845
--- /dev/null
+++ b/Vocaluxe/Lib/Sound/CDirectSoundRecord.cs
@@ -0,0 +1,437 @@
+using System;
+using System.Collections.Generic;
+using System.Threading;
+using SlimDX.DirectSound;
+using SlimDX.Multimedia;
+using Vocaluxe.Base;
+
+namespace Vocaluxe.Lib.Sound
+{
+ class CDirectSoundRecord : IRecord
+ {
+ private bool _initialized = false;
+ private List _Devices = null;
+ private SRecordDevice[] _DeviceConfig = null;
+ private List _Sources = null;
+
+ private CBuffer[] _Buffer;
+
+ public CDirectSoundRecord()
+ {
+ _Buffer = new CBuffer[CSettings.MaxNumPlayer];
+ for (int i = 0; i < _Buffer.Length; i++)
+ {
+ _Buffer[i] = new CBuffer();
+ }
+
+ Init();
+ }
+
+ public bool Init()
+ {
+ DeviceCollection devices = DirectSoundCapture.GetDevices();
+ _Devices = new List();
+ _Sources = new List();
+
+ int id = 0;
+ foreach (DeviceInformation dev in devices)
+ {
+ DirectSoundCapture ds = new DirectSoundCapture(dev.DriverGuid);
+
+ SRecordDevice device = new SRecordDevice();
+ device.Driver = dev.DriverGuid.ToString();
+ device.ID = id;
+ device.Name = dev.Description;
+ device.Inputs = new List();
+
+ SInput inp = new SInput();
+ inp.Name = "Default";
+ inp.Channels = ds.Capabilities.Channels;
+
+ if (inp.Channels > 2)
+ inp.Channels = 2; //more are not supported in vocaluxe
+
+ device.Inputs.Add(inp);
+ _Devices.Add(device);
+
+ id++;
+ ds.Dispose();
+ }
+
+ _DeviceConfig = _Devices.ToArray();
+ _initialized = true;
+
+ return true;
+ }
+
+ public void CloseAll()
+ {
+ if (_initialized)
+ {
+ foreach (SoundCardSource source in _Sources)
+ {
+ source.Stop();
+ source.Dispose();
+ }
+ _initialized = false;
+ }
+ //System.IO.File.WriteAllBytes("test0.raw", _Buffer[0].Buffer);
+ }
+
+ public bool Start(SRecordDevice[] DeviceConfig)
+ {
+ if (!_initialized)
+ return false;
+
+ for (int i = 0; i < _Buffer.Length; i++)
+ {
+ _Buffer[i].Reset();
+ }
+
+ _DeviceConfig = DeviceConfig;
+ bool[] active = new bool[DeviceConfig.Length];
+ Guid[] guid = new Guid[DeviceConfig.Length];
+ short[] channels = new short[DeviceConfig.Length];
+ for (int dev = 0; dev < DeviceConfig.Length; dev++)
+ {
+ active[dev] = false;
+ for (int inp = 0; inp < DeviceConfig[dev].Inputs.Count; inp++)
+ {
+ if (DeviceConfig[dev].Inputs[inp].PlayerChannel1 > 0 ||
+ DeviceConfig[dev].Inputs[inp].PlayerChannel2 > 0)
+ active[dev] = true;
+ guid[dev] = new Guid(DeviceConfig[dev].Driver);
+ channels[dev] = (short)DeviceConfig[dev].Inputs[0].Channels;
+ }
+ }
+
+ for (int i = 0; i < _Devices.Count; i++)
+ {
+ if (active[i])
+ {
+ SoundCardSource source = new SoundCardSource(guid[i], channels[i]);
+ source.SampleRateKHz = 44.1;
+ source.SampleDataReady += this.OnDataReady;
+ source.Start();
+
+ _Sources.Add(source);
+
+ }
+ }
+
+ _DeviceConfig = DeviceConfig;
+ return true;
+ }
+
+ public bool Stop()
+ {
+ if (!_initialized)
+ return false;
+
+ foreach (SoundCardSource source in _Sources)
+ {
+ source.Stop();
+ }
+ return true;
+ }
+ public void AnalyzeBuffer(int Player)
+ {
+ if (!_initialized)
+ return;
+
+ _Buffer[Player].AnalyzeBuffer();
+ }
+
+ public int GetToneAbs(int Player)
+ {
+ if (!_initialized)
+ return 0;
+
+ return _Buffer[Player].ToneAbs;
+ }
+
+ public int GetTone(int Player)
+ {
+ if (!_initialized)
+ return 0;
+
+ return _Buffer[Player].Tone;
+ }
+
+ public void SetTone(int Player, int Tone)
+ {
+ if (!_initialized)
+ return;
+
+ _Buffer[Player].Tone = Tone;
+ }
+
+ public float GetMaxVolume(int Player)
+ {
+ if (!_initialized)
+ return 0f;
+
+ return _Buffer[Player].MaxVolume;
+ }
+
+ public bool ToneValid(int Player)
+ {
+ if (!_initialized)
+ return false;
+
+ return _Buffer[Player].ToneValid;
+ }
+
+ public SRecordDevice[] RecordDevices()
+ {
+ if (!_initialized)
+ return null;
+
+ if (_Devices.Count == 0)
+ return null;
+
+ return _Devices.ToArray();
+ }
+
+ public int NumHalfTones(int Player)
+ {
+ if (!_initialized)
+ return 0;
+
+ return _Buffer[Player].NumHalfTones;
+ }
+
+ public float[] ToneWeigth(int Player)
+ {
+ if (!_initialized)
+ return null;
+
+ return _Buffer[Player].ToneWeigth;
+ }
+
+ private void OnDataReady(object sender, SampleDataEventArgs e)
+ {
+ if (_initialized)
+ {
+ byte[] _leftBuffer = new byte[e.Data.Length / 2];
+ byte[] _rightBuffer = new byte[e.Data.Length / 2];
+
+ //[]: Sample, L: Left channel R: Right channel
+ //[LR][LR][LR][LR][LR][LR]
+ //The data is interleaved and needs to be demultiplexed
+ for (int i = 0; i < e.Data.Length / 2; i++)
+ {
+ _leftBuffer[i] = e.Data[i * 2 - (i % 2)];
+ _rightBuffer[i] = e.Data[i * 2 - (i % 2) + 2];
+ }
+
+ for (int i = 0; i < _DeviceConfig.Length; i++)
+ {
+ if (_DeviceConfig[i].Driver == e.Guid.ToString())
+ {
+ if (_DeviceConfig[i].Inputs[0].PlayerChannel1 > 0)
+ _Buffer[_DeviceConfig[i].Inputs[0].PlayerChannel1 - 1].ProcessNewBuffer(_leftBuffer);
+
+ if (_DeviceConfig[i].Inputs[0].PlayerChannel2 > 0)
+ _Buffer[_DeviceConfig[i].Inputs[0].PlayerChannel2 - 1].ProcessNewBuffer(_rightBuffer);
+ }
+ }
+ }
+ }
+
+ public class SampleDataEventArgs : EventArgs
+ {
+ public SampleDataEventArgs(byte[] data, Guid guid)
+ {
+ this.Data = data;
+ this.Guid = guid;
+ }
+
+ public byte[] Data { get; private set; }
+ public Guid Guid { get; private set; }
+ }
+
+ public class SoundCardSource : IDisposable
+ {
+ private volatile bool running;
+ private int bufferSize;
+ private CaptureBuffer buffer;
+ private CaptureBufferDescription bufferDescription;
+ private DirectSoundCapture captureDevice;
+ private WaveFormat waveFormat;
+ private Thread captureThread;
+ private List notifications;
+ private int bufferPortionCount;
+ private int bufferPortionSize;
+ private WaitHandle[] waitHandles;
+ private double sampleRate;
+ private Guid guid;
+ private short channels;
+
+ public SoundCardSource(Guid guid, short channels)
+ {
+ this.guid = guid;
+ this.channels = channels;
+ this.waveFormat = new WaveFormat();
+ this.SampleRateKHz = 44.1;
+ this.bufferSize = 2048;
+ }
+
+ public event EventHandler SampleDataReady = delegate { };
+
+ public double SampleRateKHz
+ {
+ get
+ {
+ return this.sampleRate;
+ }
+
+ set
+ {
+ this.sampleRate = value;
+
+ if (this.running)
+ {
+ this.Restart();
+ }
+ }
+ }
+
+ public void Start()
+ {
+ if (this.running)
+ {
+ throw new InvalidOperationException();
+ }
+
+ if (this.captureDevice == null)
+ {
+ this.captureDevice = new DirectSoundCapture(guid);
+ }
+
+ this.waveFormat.FormatTag = WaveFormatTag.Pcm; // Change to WaveFormatTag.IeeeFloat for float
+ this.waveFormat.BitsPerSample = 16; // Set this to 32 for float
+ this.waveFormat.BlockAlignment = (short)(channels * (waveFormat.BitsPerSample / 8));
+ this.waveFormat.Channels = this.channels;
+ this.waveFormat.SamplesPerSecond = (int)(this.SampleRateKHz * 1000D);
+ this.waveFormat.AverageBytesPerSecond =
+ this.waveFormat.SamplesPerSecond *
+ this.waveFormat.BlockAlignment;
+
+ this.bufferPortionCount = 2;
+
+ this.bufferDescription.BufferBytes = this.bufferSize * sizeof(short) * bufferPortionCount * this.channels;
+ this.bufferDescription.Format = this.waveFormat;
+ this.bufferDescription.WaveMapped = false;
+
+ this.buffer = new CaptureBuffer(this.captureDevice, this.bufferDescription);
+
+ this.bufferPortionSize = this.buffer.SizeInBytes / this.bufferPortionCount;
+ this.notifications = new List();
+
+ for (int i = 0; i < this.bufferPortionCount; i++)
+ {
+ NotificationPosition notification = new NotificationPosition();
+ notification.Offset = this.bufferPortionCount - 1 + (bufferPortionSize * i);
+ notification.Event = new AutoResetEvent(false);
+ this.notifications.Add(notification);
+ }
+
+ this.buffer.SetNotificationPositions(this.notifications.ToArray());
+ this.waitHandles = new WaitHandle[this.notifications.Count];
+
+ for (int i = 0; i < this.notifications.Count; i++)
+ {
+ this.waitHandles[i] = this.notifications[i].Event;
+ }
+
+ this.captureThread = new Thread(new ThreadStart(this.CaptureThread));
+ this.captureThread.IsBackground = true;
+
+ this.running = true;
+ this.captureThread.Start();
+ }
+
+ public void Stop()
+ {
+ this.running = false;
+
+ if (this.captureThread != null)
+ {
+ this.captureThread.Join();
+ this.captureThread = null;
+ }
+
+ if (this.buffer != null)
+ {
+ this.buffer.Dispose();
+ this.buffer = null;
+ }
+
+ if (this.notifications != null)
+ {
+ for (int i = 0; i < this.notifications.Count; i++)
+ {
+ this.notifications[i].Event.Close();
+ }
+
+ this.notifications.Clear();
+ this.notifications = null;
+ }
+ }
+
+ public void Restart()
+ {
+ this.Stop();
+ this.Start();
+ }
+
+ private void CaptureThread()
+ {
+ int bufferPortionSamples = this.bufferPortionSize / sizeof(byte);
+
+ // Buffer type must match this.waveFormat.FormatTag and this.waveFormat.BitsPerSample
+ byte[] bufferPortion = new byte[bufferPortionSamples];
+ int bufferPortionIndex;
+
+ this.buffer.Start(true);
+
+ while (this.running)
+ {
+ bufferPortionIndex = WaitHandle.WaitAny(this.waitHandles);
+
+ this.buffer.Read(
+ bufferPortion,
+ 0,
+ bufferPortionSamples,
+ bufferPortionSize * Math.Abs((bufferPortionIndex - 1) % bufferPortionCount));
+
+ this.SampleDataReady(this, new SampleDataEventArgs(bufferPortion, guid));
+ }
+
+ this.buffer.Stop();
+ }
+
+ public void Dispose()
+ {
+ this.Dispose(true);
+ GC.SuppressFinalize(this);
+ }
+
+ protected virtual void Dispose(bool disposing)
+ {
+ if (disposing)
+ {
+ this.Stop();
+
+ if (this.captureDevice != null)
+ {
+ this.captureDevice.Dispose();
+ this.captureDevice = null;
+ }
+ }
+ }
+ }
+
+ }
+}
diff --git a/Vocaluxe/Lib/Sound/CPortAudioPlay.cs b/Vocaluxe/Lib/Sound/CPortAudioPlay.cs
index ad2122f0..6c7ebc7c 100644
--- a/Vocaluxe/Lib/Sound/CPortAudioPlay.cs
+++ b/Vocaluxe/Lib/Sound/CPortAudioPlay.cs
@@ -422,10 +422,10 @@ namespace Vocaluxe.Lib.Sound
private Thread _DecoderThread;
- AutoResetEvent EventDecode = new AutoResetEvent(false);
+ private AutoResetEvent EventDecode = new AutoResetEvent(false);
- Object MutexData = new Object();
- Object MutexSyncSignals = new Object();
+ private Object _LockData = new Object();
+ private Object _LockSyncSignals = new Object();
public PortAudioStream()
{
@@ -456,7 +456,7 @@ namespace Vocaluxe.Lib.Sound
{
get
{
- lock (MutexData)
+ lock (_LockData)
{
return _NoMoreData && _data.BytesNotRead == 0L;
}
@@ -468,7 +468,7 @@ namespace Vocaluxe.Lib.Sound
get { return _Volume * 100f; }
set
{
- lock (MutexData)
+ lock (_LockData)
{
_Volume = value / 100f;
if (_Volume < 0f)
@@ -484,7 +484,7 @@ namespace Vocaluxe.Lib.Sound
{
get
{
- lock (MutexData)
+ lock (_LockData)
{
if (Finished)
_SyncTimer.Pause();
@@ -500,7 +500,7 @@ namespace Vocaluxe.Lib.Sound
set
{
_Paused = value;
- lock (MutexSyncSignals)
+ lock (_LockData)
{
if (_Paused)
_SyncTimer.Pause();
@@ -615,12 +615,13 @@ namespace Vocaluxe.Lib.Sound
outputParams.sampleFormat = PortAudio.PaSampleFormat.paInt16;
outputParams.suggestedLatency = _outputDeviceInfo.defaultLowOutputLatency;
+ uint bufsize = (uint)CConfig.AudioBufferSize;
errorCheck("OpenDefaultStream", PortAudio.Pa_OpenStream(
out _Ptr,
IntPtr.Zero,
ref outputParams,
format.SamplesPerSecond,
- (uint)CConfig.AudioBufferSize,
+ bufsize,
PortAudio.PaStreamFlags.paNoFlag,
_paStreamCallback,
data));
@@ -645,7 +646,7 @@ namespace Vocaluxe.Lib.Sound
public bool Skip(float Time)
{
- lock (MutexSyncSignals)
+ lock (_LockSyncSignals)
{
_SetStart = Time;
_SetSkip = true;
@@ -658,7 +659,7 @@ namespace Vocaluxe.Lib.Sound
#region Threading
private void DoSkip()
{
- lock (MutexData)
+ lock (_LockData)
{
_Decoder.SetPosition(_Start);
_CurrentTime = _Start;
@@ -677,7 +678,7 @@ namespace Vocaluxe.Lib.Sound
{
if (EventDecode.WaitOne(10))
{
- lock (MutexSyncSignals)
+ lock (_LockSyncSignals)
{
if (_SetSkip)
{
@@ -724,7 +725,7 @@ namespace Vocaluxe.Lib.Sound
byte[] Buffer;
bool DoIt = false;
- lock (MutexData)
+ lock (_LockData)
{
if (!_skip && BUFSIZE - 10000L > _data.BytesNotRead)
DoIt = true;
@@ -739,7 +740,7 @@ namespace Vocaluxe.Lib.Sound
{
if (_Loop)
{
- lock (MutexSyncSignals)
+ lock (_LockSyncSignals)
{
_CurrentTime = 0f;
_Start = 0f;
@@ -754,7 +755,7 @@ namespace Vocaluxe.Lib.Sound
return;
}
- lock (MutexData)
+ lock (_LockData)
{
_data.Write(Buffer);
_TimeCode = Timecode;
@@ -804,7 +805,7 @@ namespace Vocaluxe.Lib.Sound
return PortAudio.PaStreamCallbackResult.paContinue;
}
- lock (MutexData)
+ lock (_LockData)
{
if (_NoMoreData || _data.BytesNotRead >= buf.Length)
{
diff --git a/Vocaluxe/Lib/Sound/CPortAudioRecord.cs b/Vocaluxe/Lib/Sound/CPortAudioRecord.cs
index 87bff1ab..884886cb 100644
--- a/Vocaluxe/Lib/Sound/CPortAudioRecord.cs
+++ b/Vocaluxe/Lib/Sound/CPortAudioRecord.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using System.Diagnostics;
using System.IO;
using System.Runtime.InteropServices;
using System.Text;
@@ -90,6 +91,7 @@ namespace Vocaluxe.Lib.Sound
CLog.LogError("Error initializing PortAudio: " + e.Message);
return false;
}
+
return true;
}
@@ -103,6 +105,15 @@ namespace Vocaluxe.Lib.Sound
if (!_initialized)
return false;
+ if (DeviceConfig == null)
+ return false;
+
+ if (_recHandle == null)
+ return false;
+
+ if (_recHandle.Length == 0)
+ return false;
+
for (int i = 0; i < _Buffer.Length; i++)
{
_Buffer[i].Reset();
@@ -142,7 +153,7 @@ namespace Vocaluxe.Lib.Sound
ref inputParams,
IntPtr.Zero,
44100,
- PortAudio.paFramesPerBufferUnspecified,
+ 882,
PortAudio.PaStreamFlags.paNoFlag,
_myRecProc,
new IntPtr(i))))
@@ -152,7 +163,6 @@ namespace Vocaluxe.Lib.Sound
return false;
}
}
-
return result;
}
@@ -240,6 +250,22 @@ namespace Vocaluxe.Lib.Sound
return _Buffer[Player].ToneValid;
}
+ public int NumHalfTones(int Player)
+ {
+ if (!_initialized)
+ return 0;
+
+ return _Buffer[Player].NumHalfTones;
+ }
+
+ public float[] ToneWeigth(int Player)
+ {
+ if (!_initialized)
+ return null;
+
+ return _Buffer[Player].ToneWeigth;
+ }
+
public SRecordDevice[] RecordDevices()
{
if (!_initialized)
diff --git a/Vocaluxe/Lib/Sound/IRecord.cs b/Vocaluxe/Lib/Sound/IRecord.cs
index e4b9cc2b..3b664a71 100644
--- a/Vocaluxe/Lib/Sound/IRecord.cs
+++ b/Vocaluxe/Lib/Sound/IRecord.cs
@@ -51,6 +51,8 @@ namespace Vocaluxe.Lib.Sound
void SetTone(int Player, int Tone);
float GetMaxVolume(int Player);
bool ToneValid(int Player);
+ int NumHalfTones(int Player);
+ float[] ToneWeigth(int Player);
SRecordDevice[] RecordDevices();
}
diff --git a/Vocaluxe/Lib/Video/Acinerella/acinerella.c b/Vocaluxe/Lib/Video/Acinerella/acinerella.c
index c5b23ef7..3550bc07 100644
--- a/Vocaluxe/Lib/Video/Acinerella/acinerella.c
+++ b/Vocaluxe/Lib/Video/Acinerella/acinerella.c
@@ -167,21 +167,6 @@ static int64_t io_seek(void *opaque, int64_t pos, int whence)
return -1;
}
-//uint64_t global_video_pkt_pts = AV_NOPTS_VALUE;
-
-int ac_get_buffer(struct AVCodecContext *c, AVFrame *pic) {
- int ret = avcodec_default_get_buffer(c, pic);
- uint64_t *pts = av_malloc(sizeof(uint64_t));
- *pts = AV_NOPTS_VALUE;
- pic->opaque = pts;
- return ret;
-}
-
-void ac_release_buffer(struct AVCodecContext *c, AVFrame *pic){
- if (pic) av_freep(&pic->opaque);
- avcodec_default_release_buffer(c, pic);
-}
-
lp_ac_proberesult CALL_CONVT ac_probe_input_buffer(
void* buf,
int bufsize,
@@ -533,7 +518,10 @@ void* ac_create_video_decoder(lp_ac_instance pacInstance, lp_ac_stream_info info
if (!(pDecoder->pCodec = avcodec_find_decoder(pDecoder->pCodecCtx->codec_id))) {
return NULL; //Codec could not have been found
}
-
+
+ pDecoder->pCodecCtx->thread_count = 1; //this is for HT CPUs, it should be
+ // tested if there is a better solution
+
//Open codec
if (avcodec_open2(pDecoder->pCodecCtx, pDecoder->pCodec, NULL) < 0) {
return NULL; //Codec could not have been opened
@@ -635,36 +623,34 @@ double ac_sync_video(lp_ac_package pPackage, lp_ac_decoder pDec, AVFrame *src_fr
return pts;
}
-int ac_decode_video_package(lp_ac_package pPackage, lp_ac_video_decoder pDecoder, lp_ac_decoder pDec) {
- if (((lp_ac_package_data)pPackage)->ffpackage.size <= 0)
- return 0;
-
+int ac_decode_video_package(lp_ac_package pPackage, lp_ac_video_decoder pDecoder, lp_ac_decoder pDec)
+{
int finished = 0;
double pts = 0;
+ int len = 0;
+
+ AVPacket pkt_tmp = ((lp_ac_package_data)pPackage)->ffpackage;
+
+ while (pkt_tmp.size > 0) {
+ len = avcodec_decode_video2(
+ pDecoder->pCodecCtx, pDecoder->pFrame,
+ &finished, &pkt_tmp);
+
+ if (len < 0) {
+ return 0;
+ }
+ pkt_tmp.size -= len;
+ pkt_tmp.data += len;
+ }
+
+ /*
avcodec_decode_video2(
pDecoder->pCodecCtx, pDecoder->pFrame, &finished,
&(((lp_ac_package_data)pPackage)->ffpackage));
+ */
- if (finished) {
- if(((lp_ac_package_data)pPackage)->ffpackage.dts == AV_NOPTS_VALUE &&
- *(uint64_t*)pDecoder->pFrame->opaque != AV_NOPTS_VALUE ){
- pts = *(uint64_t*)pDecoder->pFrame->opaque;
- } else if(((lp_ac_package_data)pPackage)->ffpackage.dts != AV_NOPTS_VALUE){
- pts = ((lp_ac_package_data)pPackage)->ffpackage.dts;
- } else {
- pts = 0;
- }
-
- if(((lp_ac_data)pDec->pacInstance)->pFormatCtx->streams[pPackage->stream_index]->start_time != AV_NOPTS_VALUE){
- pts -= ((lp_ac_data)pDec->pacInstance)->pFormatCtx->streams[pPackage->stream_index]->start_time;
- }
-
- pts *= av_q2d(((lp_ac_data)pDec->pacInstance)->pFormatCtx->streams[pPackage->stream_index]->time_base);
-
- pts = ac_sync_video(pPackage, pDec, pDecoder->pFrame, pts);
- pDec->timecode = pts;
-
+ if (finished != 0) {
pDecoder->pSwsCtx = sws_getCachedContext(pDecoder->pSwsCtx,
pDecoder->pCodecCtx->width, pDecoder->pCodecCtx->height, pDecoder->pCodecCtx->pix_fmt,
pDecoder->pCodecCtx->width, pDecoder->pCodecCtx->height, convert_pix_format(pDecoder->decoder.pacInstance->output_format),
@@ -678,6 +664,24 @@ int ac_decode_video_package(lp_ac_package pPackage, lp_ac_video_decoder pDecoder
pDecoder->pCodecCtx->height,
pDecoder->pFrameRGB->data,
pDecoder->pFrameRGB->linesize);
+
+
+ if(pkt_tmp.dts == AV_NOPTS_VALUE &&
+ *(uint64_t*)pDecoder->pFrame->opaque != AV_NOPTS_VALUE ){
+ pts = *(uint64_t*)pDecoder->pFrame->opaque;
+ } else if(pkt_tmp.dts != AV_NOPTS_VALUE){
+ pts = pkt_tmp.dts;
+ }
+
+ if(((lp_ac_data)pDec->pacInstance)->pFormatCtx->streams[pPackage->stream_index]->start_time != AV_NOPTS_VALUE){
+ pts -= ((lp_ac_data)pDec->pacInstance)->pFormatCtx->streams[pPackage->stream_index]->start_time;
+ }
+
+ pts *= av_q2d(((lp_ac_data)pDec->pacInstance)->pFormatCtx->streams[pPackage->stream_index]->time_base);
+
+ pts = ac_sync_video(pPackage, pDec, pDecoder->pFrame, pts);
+ pDec->timecode = pts;
+
return 1;
}
return 0;
@@ -795,11 +799,23 @@ int CALL_CONVT ac_drop_decode_package(lp_ac_package pPackage, lp_ac_decoder pDec
int ac_drop_decode_video_package(lp_ac_package pPackage, lp_ac_video_decoder pDecoder, lp_ac_decoder pDec) {
int finished;
double pts;
+ int len = 0;
- avcodec_decode_video2(
- pDecoder->pCodecCtx, pDecoder->pFrame, &finished,
- &(((lp_ac_package_data)pPackage)->ffpackage));
+ AVPacket pkt_tmp = ((lp_ac_package_data)pPackage)->ffpackage;
+
+ while (pkt_tmp.size > 0) {
+ len = avcodec_decode_video2(
+ pDecoder->pCodecCtx, pDecoder->pFrame,
+ &finished, &pkt_tmp);
+
+ if (len < 0) {
+ return 0;
+ }
+ pkt_tmp.size -= len;
+ pkt_tmp.data += len;
+ }
+
if (finished) {
pts=0;
//global_video_pkt_pts = ((lp_ac_package_data)pPackage)->ffpackage.pts;
@@ -860,11 +876,12 @@ int CALL_CONVT ac_get_frame(lp_ac_instance pacInstance, lp_ac_decoder pDecoder)
lp_ac_package pPackage = ac_read_package(pacInstance);
int done = 0;
+ int pcount = 0;
while(done == 0 && pPackage != NULL){
if (((lp_ac_package_data)pPackage)->package.stream_index == pDecoder->stream_index){
done = ac_decode_package(pPackage, pDecoder);
ac_free_package(pPackage);
-
+ pcount++;
if (done == 0)
pPackage = ac_read_package(pacInstance);
} else {
@@ -876,7 +893,7 @@ int CALL_CONVT ac_get_frame(lp_ac_instance pacInstance, lp_ac_decoder pDecoder)
if (done == 0)
return 0;
else
- return 1;
+ return pcount;
}
int CALL_CONVT ac_skip_frames(lp_ac_instance pacInstance, lp_ac_decoder pDecoder, int num) {
diff --git a/Vocaluxe/Lib/Video/CVideoDecoderFFmpeg.cs b/Vocaluxe/Lib/Video/CVideoDecoderFFmpeg.cs
index 4756ae06..a9cacb6d 100644
--- a/Vocaluxe/Lib/Video/CVideoDecoderFFmpeg.cs
+++ b/Vocaluxe/Lib/Video/CVideoDecoderFFmpeg.cs
@@ -258,8 +258,9 @@ namespace Vocaluxe.Lib.Video
private bool _terminated = false;
private Thread _thread;
- AutoResetEvent EventDecode = new AutoResetEvent(false);
+ //AutoResetEvent EventDecode = new AutoResetEvent(false);
SFrameBuffer[] _FrameBuffer = new SFrameBuffer[5];
+ private bool _NewFrame = false;
Object MutexFramebuffer = new Object();
Object MutexSyncSignals = new Object();
@@ -359,7 +360,7 @@ namespace Vocaluxe.Lib.Video
UploadNewFrame(ref frame);
- EventDecode.Set();
+ //EventDecode.Set();
return true;
}
@@ -367,11 +368,11 @@ namespace Vocaluxe.Lib.Video
{
lock (MutexSyncSignals)
{
- _SetTime = Time;
- VideoTime = _CurrentVideoTime;
+ _SetTime = Time;
}
UploadNewFrame(ref frame);
- EventDecode.Set();
+ VideoTime = _CurrentVideoTime;
+ //EventDecode.Set();
return true;
}
return false;
@@ -387,7 +388,7 @@ namespace Vocaluxe.Lib.Video
_NoMoreFrames = false;
_Finished = false;
}
- EventDecode.Set();
+ //EventDecode.Set();
return true;
}
@@ -441,17 +442,18 @@ namespace Vocaluxe.Lib.Video
_BufferFull = false;
_skip = false;
- EventDecode.Set();
+ _NewFrame = false;
+ //EventDecode.Set();
}
private void Execute()
{
DoOpen();
- EventDecode.Set();
+ //EventDecode.Set();
while (!_terminated)
{
- if (EventDecode.WaitOne(10))
+ //if (EventDecode.WaitOne(10))
{
lock (MutexSyncSignals)
{
@@ -468,11 +470,12 @@ namespace Vocaluxe.Lib.Video
if (_skip)
DoSkip();
- if (!_BufferFull)
+ if (!_NewFrame)
DoDecode();
- if (_BufferFull)
- Copy();
+ if (_NewFrame)
+ Copy();
+ Thread.Sleep(1);
}
}
@@ -555,7 +558,7 @@ namespace Vocaluxe.Lib.Video
{
const int FRAMEDROPCOUNT = 4;
- if (!_FileOpened)
+ if (!_FileOpened || _NewFrame)
return;
if (_Paused || _NoMoreFrames || _BufferFull)
@@ -641,12 +644,18 @@ namespace Vocaluxe.Lib.Video
}
return;
}
-
- Copy();
+ else
+ {
+ _NewFrame = true;
+ Copy();
+ }
}
private void Copy()
{
+ if (!_NewFrame)
+ return;
+
int num = -1;
lock (MutexFramebuffer)
@@ -687,11 +696,13 @@ namespace Vocaluxe.Lib.Video
if (numfull < _FrameBuffer.Length)
_BufferFull = false;
+
+ _NewFrame = false;
}
}
- if (!_BufferFull)
- EventDecode.Set();
+ //if (!_BufferFull)
+ // EventDecode.Set();
}
private void UploadNewFrame(ref STexture frame)
@@ -720,7 +731,7 @@ namespace Vocaluxe.Lib.Video
_CurrentVideoTime = _FrameBuffer[num].time;
}
_Finished = false;
- EventDecode.Set();
+ //EventDecode.Set();
}
else
{
@@ -739,7 +750,7 @@ namespace Vocaluxe.Lib.Video
{
float td = _SetTime + _VideoSkipTime - _FrameBuffer[i].time;
- if (td > _VideoTimeBase * 2)
+ if (td > _VideoTimeBase * 2f)
{
_FrameBuffer[i].displayed = true;
}
@@ -754,6 +765,7 @@ namespace Vocaluxe.Lib.Video
if (Result != -1)
{
_FrameBuffer[Result].displayed = true;
+ _BufferFull = false;
}
return Result;
diff --git a/Vocaluxe/Menu/CBackground.cs b/Vocaluxe/Menu/CBackground.cs
index c6adfa33..cedc4eb5 100644
--- a/Vocaluxe/Menu/CBackground.cs
+++ b/Vocaluxe/Menu/CBackground.cs
@@ -137,8 +137,16 @@ namespace Vocaluxe.Menu
public bool Draw()
{
bool ok = false;
- if (_Theme.Type == EBackgroundTypes.Video && CConfig.VideoBackgrounds == EOffOn.TR_CONFIG_ON)
+ if (_Theme.Type == EBackgroundTypes.Video && CConfig.VideoBackgrounds == EOffOn.TR_CONFIG_ON && CConfig.VideosToBackground == EOffOn.TR_CONFIG_ON && CBackgroundMusic.Playing && CBackgroundMusic.SongHasVideo && CBackgroundMusic.VideoEnabled && !CBackgroundMusic.Disabled)
+ {
+ Pause();
+ ok = DrawBackgroundMusicVideo();
+ }
+ else if (_Theme.Type == EBackgroundTypes.Video && CConfig.VideoBackgrounds == EOffOn.TR_CONFIG_ON)
+ {
+ Resume();
ok = DrawVideo();
+ }
if (_Theme.TextureName != String.Empty &&
(_Theme.Type == EBackgroundTypes.Texture ||
@@ -206,6 +214,21 @@ namespace Vocaluxe.Menu
}
return false;
}
+
+ private bool DrawBackgroundMusicVideo()
+ {
+ STexture VideoTexture = CBackgroundMusic.GetVideoTexture();
+ if (VideoTexture.height > 0)
+ {
+ RectangleF bounds = new RectangleF(0f, 0f, CSettings.iRenderW, CSettings.iRenderH);
+ RectangleF rect = new RectangleF(0f, 0f, VideoTexture.width, VideoTexture.height);
+ CHelper.SetRect(bounds, ref rect, rect.Width / rect.Height, EAspect.Crop);
+
+ CDraw.DrawTexture(VideoTexture, new SRectF(rect.X, rect.Y, rect.Width, rect.Height, CSettings.zFar / 4));
+ return true;
+ }
+ return false;
+ }
#endregion internal
#region ThemeEdit
diff --git a/Vocaluxe/Menu/CButton.cs b/Vocaluxe/Menu/CButton.cs
index 0341bf03..d4b5d231 100644
--- a/Vocaluxe/Menu/CButton.cs
+++ b/Vocaluxe/Menu/CButton.cs
@@ -41,6 +41,7 @@ namespace Vocaluxe.Menu
public float SReflectionHeight;
private bool _Selected;
+ public bool Pressed;
public bool Selected
{
get { return _Selected; }
@@ -234,7 +235,8 @@ namespace Vocaluxe.Menu
return;
STexture texture = new STexture(-1);
- if (!Selected)
+
+ if (!Selected && !Pressed)
{
texture = CTheme.GetSkinTexture(_Theme.TextureName);
CDraw.DrawTexture(texture, Rect, Color);
diff --git a/Vocaluxe/Menu/CGraphics.cs b/Vocaluxe/Menu/CGraphics.cs
index cd3148de..d0363134 100644
--- a/Vocaluxe/Menu/CGraphics.cs
+++ b/Vocaluxe/Menu/CGraphics.cs
@@ -27,15 +27,23 @@ namespace Vocaluxe.Menu
ScreenOptionsSound = 10,
ScreenOptionsRecord = 11,
ScreenOptionsVideo = 12,
- ScreenOptionsTheme = 13,
+ ScreenOptionsLyrics = 13,
+ ScreenOptionsTheme = 14,
- ScreenNames = 14,
+ ScreenNames = 15,
- ScreenCredits = 15,
+ ScreenCredits = 16,
ScreenNull = -1
}
+ enum EPopupScreens
+ {
+ PopupPlayerControl = 0,
+
+ NoPopup = -1
+ }
+
class CCursor
{
private Stopwatch _CursorFadingTimer;
@@ -185,11 +193,12 @@ namespace Vocaluxe.Menu
private static float _GlobalAlpha;
private static float _ZOffset;
- private static EScreens ActualScreen;
- private static EScreens NextScreen;
+ private static EScreens _CurrentScreen;
+ private static EScreens _NextScreen;
+ private static EPopupScreens _CurrentPopupScreen;
- private static List ScreenList = new List();
- private static CMenu[] Screens;
+ private static List _Screens = new List();
+ private static List _PopupScreens = new List();
public static float GlobalAlpha
{
@@ -206,28 +215,32 @@ namespace Vocaluxe.Menu
{
// Add Screens, must be the same order as in EScreens!
CLog.StartBenchmark(1, "Build Screen List");
- ScreenList.Add(new CScreenTest());
- ScreenList.Add(new CScreenLoad());
- ScreenList.Add(new CScreenMain());
- ScreenList.Add(new CScreenSong());
- ScreenList.Add(new CScreenOptions());
- ScreenList.Add(new CScreenSing());
- ScreenList.Add(new CScreenProfiles());
- ScreenList.Add(new CScreenScore());
- ScreenList.Add(new CScreenHighscore());
- ScreenList.Add(new CScreenOptionsGame());
- ScreenList.Add(new CScreenOptionsSound());
- ScreenList.Add(new CScreenOptionsRecord());
- ScreenList.Add(new CScreenOptionsVideo());
- ScreenList.Add(new CScreenOptionsTheme());
- ScreenList.Add(new CScreenNames());
- ScreenList.Add(new CScreenCredits());
- CLog.StopBenchmark(1, "Build Screen List");
- Screens = ScreenList.ToArray();
+ _Screens.Add(new CScreenTest());
+ _Screens.Add(new CScreenLoad());
+ _Screens.Add(new CScreenMain());
+ _Screens.Add(new CScreenSong());
+ _Screens.Add(new CScreenOptions());
+ _Screens.Add(new CScreenSing());
+ _Screens.Add(new CScreenProfiles());
+ _Screens.Add(new CScreenScore());
+ _Screens.Add(new CScreenHighscore());
+ _Screens.Add(new CScreenOptionsGame());
+ _Screens.Add(new CScreenOptionsSound());
+ _Screens.Add(new CScreenOptionsRecord());
+ _Screens.Add(new CScreenOptionsVideo());
+ _Screens.Add(new CScreenOptionsLyrics());
+ _Screens.Add(new CScreenOptionsTheme());
+ _Screens.Add(new CScreenNames());
+ _Screens.Add(new CScreenCredits());
+
+ _PopupScreens.Add(new CPopupScreenPlayerControl());
+
+ CLog.StopBenchmark(1, "Build Screen List");
- ActualScreen = EScreens.ScreenLoad;
- NextScreen = EScreens.ScreenNull;
+ _CurrentScreen = EScreens.ScreenLoad;
+ _NextScreen = EScreens.ScreenNull;
+ _CurrentPopupScreen = EPopupScreens.NoPopup;
_FadingTimer = new Stopwatch();
_GlobalAlpha = 1f;
@@ -247,50 +260,65 @@ namespace Vocaluxe.Menu
CTheme.Cursor.h,
CSettings.zNear);
- for (int i = 0; i < Screens.Length; i++)
+ for (int i = 0; i < _Screens.Count; i++)
{
CLog.StartBenchmark(1, "Load Theme " + Enum.GetNames(typeof(EScreens))[i]);
- Screens[i].LoadTheme();
+ _Screens[i].LoadTheme();
CLog.StopBenchmark(1, "Load Theme " + Enum.GetNames(typeof(EScreens))[i]);
}
+
+ for (int i = 0; i < _PopupScreens.Count; i++)
+ {
+ _PopupScreens[i].LoadTheme();
+ }
}
public static void ReloadTheme()
{
ReloadCursor();
- for (int i = 0; i < Screens.Length; i++)
+ for (int i = 0; i < _Screens.Count; i++)
{
- Screens[i].ReloadTheme();
+ _Screens[i].ReloadTheme();
}
+
+ for (int i = 0; i < _PopupScreens.Count; i++)
+ {
+ _PopupScreens[i].ReloadTheme();
+ }
}
public static void ReloadSkin()
{
ReloadCursor();
- for (int i = 0; i < Screens.Length; i++)
+ for (int i = 0; i < _Screens.Count; i++)
{
- Screens[i].ReloadTextures();
+ _Screens[i].ReloadTextures();
}
+
+ for (int i = 0; i < _PopupScreens.Count; i++)
+ {
+ _PopupScreens[i].ReloadTextures();
+ }
}
public static void SaveTheme()
{
CTheme.SaveTheme();
- for (int i = 0; i < Screens.Length; i++)
+ for (int i = 0; i < _Screens.Count; i++)
{
- Screens[i].SaveTheme();
+ _Screens[i].SaveTheme();
}
+
+ for (int i = 0; i < _PopupScreens.Count; i++)
+ {
+ _PopupScreens[i].SaveTheme();
+ }
}
public static void InitFirstScreen()
{
- Screens[(int)ActualScreen].OnShow();
- Screens[(int)ActualScreen].OnShowFinish();
- }
-
- public static CMenu GetScreen(int Index)
- {
- return Screens[Index];
+ _Screens[(int)_CurrentScreen].OnShow();
+ _Screens[(int)_CurrentScreen].OnShowFinish();
}
public static bool UpdateGameLogic(CKeys Keys, CMouse Mouse)
@@ -304,7 +332,7 @@ namespace Vocaluxe.Menu
CSound.Update();
CBackgroundMusic.Update();
- if (CConfig.CoverLoading == ECoverLoading.TR_CONFIG_COVERLOADING_DYNAMIC && ActualScreen != EScreens.ScreenSing)
+ if (CConfig.CoverLoading == ECoverLoading.TR_CONFIG_COVERLOADING_DYNAMIC && _CurrentScreen != EScreens.ScreenSing)
CSongs.LoadCover(30L, 1);
if (CSettings.GameState != EGameState.EditTheme)
@@ -323,12 +351,13 @@ namespace Vocaluxe.Menu
public static bool Draw()
{
- if ((NextScreen != EScreens.ScreenNull) && !_Fading)
+ if ((_NextScreen != EScreens.ScreenNull) && !_Fading)
{
_Fading = true;
_FadingTimer.Reset();
_FadingTimer.Start();
- Screens[(int)NextScreen].OnShow();
+ _Screens[(int)_NextScreen].OnShow();
+ HidePopup(EPopupScreens.PopupPlayerControl);
}
if (_Fading)
@@ -345,30 +374,38 @@ namespace Vocaluxe.Menu
_GlobalAlpha = 1f;// -factor / 100f;
_ZOffset = CSettings.zFar/2;
- Screens[(int)ActualScreen].Draw();
+ _Screens[(int)_CurrentScreen].Draw();
_GlobalAlpha = factor;
_ZOffset = 0f;
- Screens[(int)NextScreen].Draw();
+ _Screens[(int)_NextScreen].Draw();
_GlobalAlpha = 1f;
}
else
{
- Screens[(int)ActualScreen].OnClose();
- ActualScreen = NextScreen;
- NextScreen = EScreens.ScreenNull;
- Screens[(int)ActualScreen].OnShowFinish();
- Screens[(int)ActualScreen].ProcessMouseMove(_Cursor.X, _Cursor.Y);
- Screens[(int)ActualScreen].Draw();
+ _Screens[(int)_CurrentScreen].OnClose();
+ _CurrentScreen = _NextScreen;
+ _NextScreen = EScreens.ScreenNull;
+ if(CBackgroundMusic.Playing)
+ CBackgroundMusic.Play();
+ _Screens[(int)_CurrentScreen].OnShowFinish();
+ _Screens[(int)_CurrentScreen].ProcessMouseMove(_Cursor.X, _Cursor.Y);
+ _Screens[(int)_CurrentScreen].Draw();
_Fading = false;
_FadingTimer.Stop();
}
}
else
{
- Screens[(int)ActualScreen].Draw();
+ _Screens[(int)_CurrentScreen].Draw();
}
+
+ for (int i = 0; i < _PopupScreens.Count; i++)
+ {
+ _PopupScreens[i].Draw();
+ }
+
_Cursor.Draw();
DrawDebugInfos();
@@ -377,7 +414,23 @@ namespace Vocaluxe.Menu
public static void FadeTo(EScreens Screen)
{
- NextScreen = Screen;
+ _NextScreen = Screen;
+ }
+
+ public static void ShowPopup(EPopupScreens PopupScreen)
+ {
+ _PopupScreens[(int)PopupScreen].OnShow();
+ _PopupScreens[(int)PopupScreen].OnShowFinish();
+ _CurrentPopupScreen = PopupScreen;
+ }
+
+ public static void HidePopup(EPopupScreens PopupScreen)
+ {
+ if (_CurrentPopupScreen != PopupScreen)
+ return;
+
+ _PopupScreens[(int)PopupScreen].OnClose();
+ _CurrentPopupScreen = EPopupScreens.NoPopup;
}
public static void HideCursor()
@@ -398,6 +451,8 @@ namespace Vocaluxe.Menu
KeyEvent KeyEvent = new KeyEvent();
MouseEvent MouseEvent = new MouseEvent();
+ bool PopupPlayerControlAllowed = _CurrentScreen != EScreens.ScreenOptionsRecord && _CurrentScreen != EScreens.ScreenSing && _CurrentScreen != EScreens.ScreenSong;
+
bool Resume = true;
while (keys.PollEvent(ref KeyEvent))
{
@@ -406,6 +461,14 @@ namespace Vocaluxe.Menu
CSettings.MouseInacive();
_Cursor.FadeOut();
}
+
+ if (PopupPlayerControlAllowed && KeyEvent.Key == Keys.Tab)
+ {
+ if (_CurrentPopupScreen == EPopupScreens.NoPopup)
+ ShowPopup(EPopupScreens.PopupPlayerControl);
+ else
+ HidePopup(EPopupScreens.PopupPlayerControl);
+ }
if (KeyEvent.ModSHIFT && (KeyEvent.Key == Keys.F1))
{
@@ -422,7 +485,14 @@ namespace Vocaluxe.Menu
else
{
if (!_Fading)
- Resume &= Screens[(int)ActualScreen].HandleInput(KeyEvent);
+ {
+ bool handled = false;
+ if (_CurrentPopupScreen != EPopupScreens.NoPopup)
+ handled = _PopupScreens[(int)_CurrentPopupScreen].HandleInput(KeyEvent);
+
+ if (!handled)
+ Resume &= _Screens[(int)_CurrentScreen].HandleInput(KeyEvent);
+ }
}
}
@@ -436,8 +506,22 @@ namespace Vocaluxe.Menu
UpdateMousePosition(MouseEvent.X, MouseEvent.Y);
- if (!_Fading && (_Cursor.IsActive || MouseEvent.LB || MouseEvent.RB))
- Resume &= Screens[(int)ActualScreen].HandleMouse(MouseEvent);
+ bool isOverPopupPlayerControl = CHelper.IsInBounds(_PopupScreens[(int)EPopupScreens.PopupPlayerControl].ScreenArea, MouseEvent);
+ if (PopupPlayerControlAllowed && isOverPopupPlayerControl)
+ {
+ if (_CurrentPopupScreen == EPopupScreens.NoPopup)
+ ShowPopup(EPopupScreens.PopupPlayerControl);
+ }
+
+ if (!isOverPopupPlayerControl && _CurrentPopupScreen == EPopupScreens.PopupPlayerControl)
+ HidePopup(EPopupScreens.PopupPlayerControl);
+
+ bool handled = false;
+ if (_CurrentPopupScreen != EPopupScreens.NoPopup)
+ handled = _PopupScreens[(int)_CurrentPopupScreen].HandleMouse(MouseEvent);
+
+ if (!handled && !_Fading && (_Cursor.IsActive || MouseEvent.LB || MouseEvent.RB))
+ Resume &= _Screens[(int)_CurrentScreen].HandleMouse(MouseEvent);
}
return Resume;
}
@@ -452,7 +536,7 @@ namespace Vocaluxe.Menu
if (KeyEvent.ModSHIFT && (KeyEvent.Key == Keys.F1))
{
CSettings.GameState = EGameState.Normal;
- Screens[(int)ActualScreen].NextInteraction();
+ _Screens[(int)_CurrentScreen].NextInteraction();
}
else if (KeyEvent.ModALT && (KeyEvent.Key == Keys.Enter))
{
@@ -465,14 +549,14 @@ namespace Vocaluxe.Menu
else
{
if (!_Fading)
- Screens[(int)ActualScreen].HandleInputThemeEditor(KeyEvent);
+ _Screens[(int)_CurrentScreen].HandleInputThemeEditor(KeyEvent);
}
}
while (Mouse.PollEvent(ref MouseEvent))
{
if (!_Fading)
- Screens[(int)ActualScreen].HandleMouseThemeEditor(MouseEvent);
+ _Screens[(int)_CurrentScreen].HandleMouseThemeEditor(MouseEvent);
UpdateMousePosition(MouseEvent.X, MouseEvent.Y);
}
@@ -486,7 +570,9 @@ namespace Vocaluxe.Menu
private static bool Update()
{
- return Screens[(int)ActualScreen].UpdateGame();
+ if (_CurrentPopupScreen != EPopupScreens.NoPopup)
+ _PopupScreens[(int)_CurrentPopupScreen].UpdateGame();
+ return _Screens[(int)_CurrentScreen].UpdateGame();
}
private static void DrawDebugInfos()
@@ -606,6 +692,16 @@ namespace Vocaluxe.Menu
{
_Cursor.UnloadTextures();
+ if (CTheme.Cursor.color != string.Empty)
+ {
+ SColorF color;
+ color = CTheme.GetColor(CTheme.Cursor.color);
+ CTheme.Cursor.r = color.R;
+ CTheme.Cursor.g = color.G;
+ CTheme.Cursor.b = color.B;
+ CTheme.Cursor.a = color.A;
+ }
+
_Cursor = new CCursor(
CTheme.Cursor.SkinName,
new SColorF(CTheme.Cursor.r, CTheme.Cursor.g, CTheme.Cursor.b, CTheme.Cursor.a),
diff --git a/Vocaluxe/Menu/CInteraction.cs b/Vocaluxe/Menu/CInteraction.cs
index 87cae837..5e21fdd9 100644
--- a/Vocaluxe/Menu/CInteraction.cs
+++ b/Vocaluxe/Menu/CInteraction.cs
@@ -13,7 +13,8 @@ namespace Vocaluxe.Menu
TStatic,
TSongMenu,
TLyric,
- TSingNote
+ TSingNote,
+ TNameSelection
}
class CInteraction
diff --git a/Vocaluxe/Menu/CLyric.cs b/Vocaluxe/Menu/CLyric.cs
index 8a70e0ab..bc4bbbab 100644
--- a/Vocaluxe/Menu/CLyric.cs
+++ b/Vocaluxe/Menu/CLyric.cs
@@ -11,14 +11,6 @@ using Vocaluxe.Lib.Song;
namespace Vocaluxe.Menu
{
- enum ELyricStyle
- {
- Fill,
- Jump,
- Slide,
- Zoom
- }
-
struct SNote
{
public string Text;
@@ -84,6 +76,12 @@ namespace Vocaluxe.Menu
}
}
+ public ELyricStyle LyricStyle
+ {
+ get { return _Style; }
+ set { _Style = value; }
+ }
+
public CLyric()
{
_Theme = new SThemeLyrics();
@@ -100,7 +98,7 @@ namespace Vocaluxe.Menu
_Notes = new List();
_Text = new CText();
- _Style = ELyricStyle.Slide;
+ _Style = ELyricStyle.Fill;
}
public bool LoadTheme(string XmlPath, string ElementName, XPathNavigator navigator, int SkinIndex)
@@ -319,32 +317,36 @@ namespace Vocaluxe.Menu
}
int zoom_note = -1;
+ int end_beat = -1;
float zoomx = 0f;
- int current_note = -1;
- foreach (SNote note in _Notes)
+ for (int note = 0; note < _Notes.Count; note++)
{
- current_note++;
-
_Text.X = x;
_Text.Style = EStyle.Bold;
- _Text.Text = note.Text;
+ _Text.Text = _Notes[note].Text;
RectangleF rect = CDraw.GetTextBounds(_Text);
- if (note.Type == ENoteType.Freestyle)
+ if (_Notes[note].Type == ENoteType.Freestyle)
_Text.Style = EStyle.BoldItalic;
- if (CurrentBeat >= note.StartBeat)
+ if (CurrentBeat >= _Notes[note].StartBeat)
{
- if (CurrentBeat <= note.EndBeat)
+ bool last = note == _Notes.Count -1;
+ int endbeat = _Notes[note].EndBeat;
+ if (note < _Notes.Count -1)
+ endbeat = _Notes[note + 1].StartBeat - 1;
+
+ if (CurrentBeat <= endbeat)
{
- zoom_note = current_note;
+ zoom_note = note;
+ end_beat = endbeat;
zoomx = _Text.X;
}
else
{
// already passed
- if (current_note == last_note)
+ if (note == last_note)
_Text.Color = ColorProcessed;
else
_Text.Color = Color;
@@ -378,9 +380,11 @@ namespace Vocaluxe.Menu
RectangleF rect = CDraw.GetTextBounds(_Text);
- float diff = _Notes[zoom_note].EndBeat - _Notes[zoom_note].StartBeat;
+ float diff = end_beat - _Notes[zoom_note].StartBeat;
+ if (diff <= 0f)
+ diff = 1f;
- float p = (CurrentBeat - _Notes[zoom_note].StartBeat) / _Notes[zoom_note].Duration;
+ float p = (CurrentBeat - _Notes[zoom_note].StartBeat) / diff;
if (p > 1f)
p = 1f;
@@ -440,37 +444,49 @@ namespace Vocaluxe.Menu
{
float x = _X - _width / 2; // most left position
- foreach (SNote note in _Notes)
+ //find last active note
+ int last_note = -1;
+ for (int i = 0; i < _Notes.Count; i++)
+ {
+ if (CurrentBeat >= _Notes[i].StartBeat)
+ last_note = i;
+ }
+
+ int jump_note = -1;
+ int end_beat = -1;
+ float jumpx = 0f;
+
+ for (int note = 0; note < _Notes.Count; note++)
{
_Text.X = x;
_Text.Style = EStyle.Bold;
- _Text.Text = note.Text;
+ _Text.Text = _Notes[note].Text;
RectangleF rect = CDraw.GetTextBounds(_Text);
- if (note.Type == ENoteType.Freestyle)
+ if (_Notes[note].Type == ENoteType.Freestyle)
_Text.Style = EStyle.BoldItalic;
- if (CurrentBeat >= note.StartBeat)
+ if (CurrentBeat >= _Notes[note].StartBeat)
{
- if (CurrentBeat <= note.EndBeat)
+ bool last = note == _Notes.Count - 1;
+ int endbeat = _Notes[note].EndBeat;
+ if (note < _Notes.Count - 1)
+ endbeat = _Notes[note + 1].StartBeat - 1;
+
+ if (CurrentBeat <= _Notes[note].EndBeat)
{
- _Text.Color = ColorProcessed;
-
- float diff = note.EndBeat - note.StartBeat;
- if (diff == 0)
- _Text.Draw();
- else
- {
- float y = _Text.Y;
- _Text.Y -= _Text.Height * 0.1f;
- _Text.Draw();
- _Text.Y = y;
- }
+ jump_note = note;
+ end_beat = endbeat;
+ jumpx = _Text.X;
}
else
{
// already passed
- _Text.Color = Color;
+ if (note == last_note)
+ _Text.Color = ColorProcessed;
+ else
+ _Text.Color = Color;
+
_Text.Draw();
}
@@ -484,6 +500,40 @@ namespace Vocaluxe.Menu
x += rect.Width;
}
+
+ if (jump_note > 0)
+ {
+ if (_Notes[jump_note].Duration == 0)
+ return;
+
+ _Text.X = jumpx;
+ _Text.Text = _Notes[jump_note].Text;
+ _Text.Color = ColorProcessed;
+ _Text.Style = EStyle.Bold;
+
+ if (_Notes[jump_note].Type == ENoteType.Freestyle)
+ _Text.Style = EStyle.BoldItalic;
+
+ float diff = _Notes[jump_note].EndBeat - _Notes[jump_note].StartBeat;
+ if (diff <= 0f)
+ diff = 1f;
+
+ float p = (CurrentBeat - _Notes[jump_note].StartBeat) / diff;
+ if (p > 1f)
+ p = 1f;
+
+ p = 1f - p;
+
+ if (diff == 1)
+ _Text.Draw();
+ else
+ {
+ float y = _Text.Y;
+ _Text.Y -= _Text.Height * 0.1f * p;
+ _Text.Draw();
+ _Text.Y = y;
+ }
+ }
}
#endregion draw
diff --git a/Vocaluxe/Menu/CMenu.cs b/Vocaluxe/Menu/CMenu.cs
index 282fb865..2e11171d 100644
--- a/Vocaluxe/Menu/CMenu.cs
+++ b/Vocaluxe/Menu/CMenu.cs
@@ -16,6 +16,12 @@ using Vocaluxe.Menu.SongMenu;
namespace Vocaluxe.Menu
{
+ struct ZSort
+ {
+ public int ID;
+ public float z;
+ }
+
abstract class CMenu
{
private List _Interactions;
@@ -29,6 +35,7 @@ namespace Vocaluxe.Menu
private List _SongMenus;
private List _Lyrics;
private List _SingNotes;
+ private List _NameSelections;
private Hashtable _htBackgrounds;
private Hashtable _htStatics;
@@ -38,6 +45,7 @@ namespace Vocaluxe.Menu
private Hashtable _htLyrics;
private Hashtable _htSelectSlides;
private Hashtable _htSingNotes;
+ private Hashtable _htNameSelections;
private int _PrevMouseX;
@@ -58,6 +66,14 @@ namespace Vocaluxe.Menu
protected string[] _ThemeLyrics;
protected string[] _ThemeSelectSlides;
protected string[] _ThemeSingNotes;
+ protected string[] _ThemeNameSelections;
+
+ protected SRectF _ScreenArea;
+
+ public SRectF ScreenArea
+ {
+ get { return _ScreenArea; }
+ }
public int ThemeScreenVersion
{
@@ -82,6 +98,7 @@ namespace Vocaluxe.Menu
_SongMenus = new List();
_Lyrics = new List();
_SingNotes = new List();
+ _NameSelections = new List();
_htBackgrounds = new Hashtable();
_htStatics = new Hashtable();
@@ -91,6 +108,7 @@ namespace Vocaluxe.Menu
_htLyrics = new Hashtable();
_htSelectSlides = new Hashtable();
_htSingNotes = new Hashtable();
+ _htNameSelections = new Hashtable();
_PrevMouseX = 0;
_PrevMouseY = 0;
@@ -99,6 +117,7 @@ namespace Vocaluxe.Menu
_MouseDY = 0;
_Active = false;
+ _ScreenArea = new SRectF(0f, 0f, CSettings.iRenderW, CSettings.iRenderH, 0f);
_ThemeName = String.Empty;
_ThemeBackgrounds = null;
@@ -109,6 +128,7 @@ namespace Vocaluxe.Menu
_ThemeLyrics = null;
_ThemeSelectSlides = null;
_ThemeSingNotes = null;
+ _ThemeNameSelections = null;
}
#region ThemeHandler
@@ -275,6 +295,22 @@ namespace Vocaluxe.Menu
}
}
}
+
+ if (_ThemeNameSelections != null)
+ {
+ for (int i = 0; i < _ThemeNameSelections.Length; i++)
+ {
+ CNameSelection nsel = new CNameSelection();
+ if (nsel.LoadTheme("//root/" + _ThemeName, _ThemeNameSelections[i], navigator, SkinIndex))
+ {
+ _htNameSelections.Add(_ThemeNameSelections[i], AddNameSelection(nsel));
+ }
+ else
+ {
+ CLog.LogError("Can't load NameSelection \"" + _ThemeNameSelections[i] + "\" in screen " + _ThemeName);
+ }
+ }
+ }
}
else
{
@@ -344,6 +380,12 @@ namespace Vocaluxe.Menu
_SingNotes[i].SaveTheme(writer);
}
+ // NameSelections
+ for (int i = 0; i < _NameSelections.Count; i++)
+ {
+ _NameSelections[i].SaveTheme(writer);
+ }
+
writer.WriteEndElement();
// End of File
@@ -395,6 +437,11 @@ namespace Vocaluxe.Menu
{
sn.ReloadTextures();
}
+
+ foreach (CNameSelection ns in _NameSelections)
+ {
+ ns.ReloadTextures();
+ }
}
public virtual void UnloadTextures()
@@ -438,6 +485,13 @@ namespace Vocaluxe.Menu
{
sn.UnloadTextures();
}
+
+ foreach (CNameSelection ns in _NameSelections)
+ {
+ ns.UnloadTextures();
+ }
+
+
}
public virtual void ReloadTheme()
@@ -488,6 +542,11 @@ namespace Vocaluxe.Menu
{
return _SingNotes;
}
+
+ public List GetNameSelections()
+ {
+ return _NameSelections;
+ }
#endregion GetLists
#region ElementHandler
@@ -555,6 +614,14 @@ namespace Vocaluxe.Menu
return _SingNotes.ToArray();
}
}
+
+ public CNameSelection[] NameSelections
+ {
+ get
+ {
+ return _NameSelections.ToArray();
+ }
+ }
#endregion Get Arrays
#region Hashtables
@@ -661,6 +728,19 @@ namespace Vocaluxe.Menu
throw;
}
}
+
+ public int htNameSelections(string key)
+ {
+ try
+ {
+ return (int)_htNameSelections[key];
+ }
+ catch (Exception)
+ {
+ CLog.LogError("Can't find NameSelection Element \"" + key + "\" in Screen " + _ThemeName);
+ throw;
+ }
+ }
#endregion Hashtables
#endregion ElementHandler
@@ -862,13 +942,12 @@ namespace Vocaluxe.Menu
{
ResumeBG();
_Active = true;
- CBackgroundMusic.Play();
}
public virtual void OnClose()
{
PauseBG();
- CBackgroundMusic.Pause();
+ _Active = false;
}
#endregion MenuHandler
@@ -906,22 +985,39 @@ namespace Vocaluxe.Menu
public void DrawFG()
{
- foreach (CStatic stat in _Statics)
- stat.Draw();
+ if (_Interactions.Count <= 0)
+ return;
+
+ List items = new List();
- foreach (CSingNotes sn in _SingNotes)
+ for (int i = 0; i < _Interactions.Count; i++)
{
- // TODO!!!!!
+ if (_IsVisible(i) && (
+ _Interactions[i].Type == EType.TButton ||
+ _Interactions[i].Type == EType.TSelectSlide ||
+ _Interactions[i].Type == EType.TStatic ||
+ _Interactions[i].Type == EType.TNameSelection ||
+ _Interactions[i].Type == EType.TText ||
+ _Interactions[i].Type == EType.TSongMenu))
+ {
+ ZSort zs = new ZSort();
+ zs.ID = i;
+ zs.z = _GetZValue(i);
+ items.Add(zs);
+ }
}
- foreach (CButton button in _Buttons)
- button.Draw();
+ if (items.Count <= 0)
+ return;
- foreach (CSelectSlide slide in _SelectSlides)
- slide.Draw();
+
+ items.Sort(delegate(ZSort s1, ZSort s2) { return (s2.z.CompareTo(s1.z)); });
+
+ for (int i = 0; i < items.Count; i++)
+ {
+ _DrawInteraction(items[i].ID);
+ }
- foreach (CText text in _Texts)
- text.Draw();
}
#endregion Drawing
@@ -929,58 +1025,65 @@ namespace Vocaluxe.Menu
public int AddBackground(CBackground bg)
{
_Backgrounds.Add(bg);
- AddInteraction(_Backgrounds.Count - 1, EType.TBackground);
+ _AddInteraction(_Backgrounds.Count - 1, EType.TBackground);
return _Backgrounds.Count - 1;
}
public int AddButton(CButton button)
{
_Buttons.Add(button);
- AddInteraction(_Buttons.Count - 1, EType.TButton);
+ _AddInteraction(_Buttons.Count - 1, EType.TButton);
return _Buttons.Count - 1;
}
public int AddSelectSlide(CSelectSlide slide)
{
_SelectSlides.Add(slide);
- AddInteraction(_SelectSlides.Count - 1, EType.TSelectSlide);
+ _AddInteraction(_SelectSlides.Count - 1, EType.TSelectSlide);
return _SelectSlides.Count - 1;
}
public int AddStatic(CStatic stat)
{
_Statics.Add(stat);
- AddInteraction(_Statics.Count - 1, EType.TStatic);
+ _AddInteraction(_Statics.Count - 1, EType.TStatic);
return _Statics.Count - 1;
}
public int AddText(CText text)
{
_Texts.Add(text);
- AddInteraction(_Texts.Count - 1, EType.TText);
+ _AddInteraction(_Texts.Count - 1, EType.TText);
return _Texts.Count - 1;
}
public int AddSongMenu(CSongMenu songmenu)
{
_SongMenus.Add(songmenu);
- AddInteraction(_SongMenus.Count - 1, EType.TSongMenu);
+ _AddInteraction(_SongMenus.Count - 1, EType.TSongMenu);
return _SongMenus.Count - 1;
}
public int AddLyric(CLyric lyric)
{
_Lyrics.Add(lyric);
- AddInteraction(_Lyrics.Count - 1, EType.TLyric);
+ _AddInteraction(_Lyrics.Count - 1, EType.TLyric);
return _Lyrics.Count - 1;
}
public int AddSingNote(CSingNotes sn)
{
_SingNotes.Add(sn);
- AddInteraction(_SingNotes.Count - 1, EType.TSingNote);
+ _AddInteraction(_SingNotes.Count - 1, EType.TSingNote);
return _SingNotes.Count - 1;
}
+
+ public int AddNameSelection(CNameSelection ns)
+ {
+ _NameSelections.Add(ns);
+ _AddInteraction(_NameSelections.Count - 1, EType.TNameSelection);
+ return _NameSelections.Count - 1;
+ }
#endregion Elements
#region InteractionHandling
@@ -1125,6 +1228,10 @@ namespace Vocaluxe.Menu
if (CHelper.IsInBounds(_Lyrics[interact.Num].Rect, x, y))
return true;
break;
+ case EType.TNameSelection:
+ if (CHelper.IsInBounds(_NameSelections[interact.Num].Rect, x, y))
+ return true;
+ break;
}
return false;
}
@@ -1145,10 +1252,41 @@ namespace Vocaluxe.Menu
return _Texts[interact.Num].Z;
case EType.TLyric:
return _Lyrics[interact.Num].Rect.Z;
+ case EType.TNameSelection:
+ return _NameSelections[interact.Num].Rect.Z;
}
return CSettings.zFar;
}
+ private float _GetZValue(int interaction)
+ {
+ switch (_Interactions[interaction].Type)
+ {
+ case EType.TButton:
+ return _Buttons[_Interactions[interaction].Num].Rect.Z;
+
+ case EType.TSelectSlide:
+ return _SelectSlides[_Interactions[interaction].Num].Rect.Z;
+
+ case EType.TStatic:
+ return _Statics[_Interactions[interaction].Num].Rect.Z;
+
+ case EType.TText:
+ return _Texts[_Interactions[interaction].Num].Z;
+
+ case EType.TSongMenu:
+ return _SongMenus[_Interactions[interaction].Num].Rect.Z;
+
+ case EType.TLyric:
+ return _Lyrics[_Interactions[interaction].Num].Rect.Z;
+
+ case EType.TNameSelection:
+ return _NameSelections[_Interactions[interaction].Num].Rect.Z;
+ }
+
+ return CSettings.zFar;
+ }
+
private void _NextInteraction()
{
_UnsetSelected();
@@ -1459,6 +1597,9 @@ namespace Vocaluxe.Menu
case EType.TLyric:
_Lyrics[_Interactions[_Selection].Num].Selected = true;
break;
+ case EType.TNameSelection:
+ _NameSelections[_Interactions[_Selection].Num].Selected = true;
+ break;
}
}
@@ -1484,6 +1625,9 @@ namespace Vocaluxe.Menu
case EType.TLyric:
_Lyrics[_Interactions[_Selection].Num].Selected = false;
break;
+ case EType.TNameSelection:
+ _NameSelections[_Interactions[_Selection].Num].Selected = false;
+ break;
}
}
@@ -1512,6 +1656,9 @@ namespace Vocaluxe.Menu
case EType.TLyric:
//_Lyrics[_Interactions[selection].Num].Selected = true;
break;
+ case EType.TNameSelection:
+ //_NameSelections[_Interactions[selection].Num].Selected = true;
+ break;
}
}
@@ -1540,6 +1687,9 @@ namespace Vocaluxe.Menu
case EType.TLyric:
//_Lyrics[_Interactions[selection].Num].Selected = false;
break;
+ case EType.TNameSelection:
+ //_NameSelections[_Interactions[selection].Num].Selected = false;
+ break;
}
}
@@ -1567,7 +1717,6 @@ namespace Vocaluxe.Menu
private bool _IsVisible(int interaction)
{
- bool Result = false;
switch (_Interactions[interaction].Type)
{
case EType.TButton:
@@ -1587,9 +1736,12 @@ namespace Vocaluxe.Menu
case EType.TLyric:
return _Lyrics[_Interactions[interaction].Num].Visible;
+
+ case EType.TNameSelection:
+ return _NameSelections[_Interactions[interaction].Num].Visible;
}
- return Result;
+ return false;
}
private SRectF _GetRect(int interaction)
@@ -1614,12 +1766,15 @@ namespace Vocaluxe.Menu
case EType.TLyric:
return _Lyrics[_Interactions[interaction].Num].Rect;
+
+ case EType.TNameSelection:
+ return _NameSelections[_Interactions[interaction].Num].Rect;
}
return Result;
}
- private void AddInteraction(int num, EType type)
+ private void _AddInteraction(int num, EType type)
{
_Interactions.Add(new CInteraction(num, type));
if (!_Interactions[_Selection].ThemeEditorOnly)
@@ -1628,6 +1783,41 @@ namespace Vocaluxe.Menu
_NextInteraction();
}
+ private void _DrawInteraction(int interaction)
+ {
+ switch (_Interactions[interaction].Type)
+ {
+ case EType.TButton:
+ _Buttons[_Interactions[interaction].Num].Draw();
+ break;
+
+ case EType.TSelectSlide:
+ _SelectSlides[_Interactions[interaction].Num].Draw();
+ break;
+
+ case EType.TStatic:
+ _Statics[_Interactions[interaction].Num].Draw();
+ break;
+
+ case EType.TText:
+ _Texts[_Interactions[interaction].Num].Draw();
+ break;
+
+ case EType.TSongMenu:
+ _SongMenus[_Interactions[interaction].Num].Draw();
+ break;
+
+ case EType.TNameSelection:
+ _NameSelections[_Interactions[interaction].Num].Draw();
+ break;
+
+ //TODO:
+ //case EType.TLyric:
+ // _Lyrics[_Interactions[interaction].Num].Draw(0);
+ // break;
+ }
+ }
+
#endregion InteractionHandling
#region Theme Handling
@@ -1660,6 +1850,10 @@ namespace Vocaluxe.Menu
case EType.TLyric:
_Lyrics[_Interactions[_Selection].Num].MoveElement(stepX, stepY);
break;
+
+ case EType.TNameSelection:
+ _NameSelections[_Interactions[_Selection].Num].MoveElement(stepX, stepY);
+ break;
}
}
}
@@ -1693,6 +1887,10 @@ namespace Vocaluxe.Menu
case EType.TLyric:
_Lyrics[_Interactions[_Selection].Num].ResizeElement(stepW, stepH);
break;
+
+ case EType.TNameSelection:
+ _NameSelections[_Interactions[_Selection].Num].ResizeElement(stepW, stepH);
+ break;
}
}
}
diff --git a/Vocaluxe/Menu/CNameSelection.cs b/Vocaluxe/Menu/CNameSelection.cs
new file mode 100644
index 00000000..5a539c7c
--- /dev/null
+++ b/Vocaluxe/Menu/CNameSelection.cs
@@ -0,0 +1,552 @@
+using System;
+using System.Collections.Generic;
+using System.Drawing;
+using System.Text;
+using System.Xml;
+using System.Xml.XPath;
+using System.Windows.Forms;
+
+using Vocaluxe.Base;
+using Vocaluxe.Lib.Draw;
+
+namespace Vocaluxe.Menu
+{
+ struct SThemeNameSelection
+ {
+ public string Name;
+ public string TextureEmptyTileName;
+ public string ColorEmptyTileName;
+ public string TextureTileSelectedName;
+ public float NameSpace;
+ public float NameHeight;
+ public string NameFont;
+ public EStyle NameStyle;
+ public SColorF NameColor;
+ public string NameColorName;
+ }
+
+ class CNameSelection : IMenuElement
+ {
+
+ class CTile
+ {
+ public int PlayerNr;
+ public CStatic Avatar;
+ public CText Name;
+
+ public CTile()
+ {
+ }
+
+ public CTile(CStatic av, CText tex, int pl)
+ {
+ Avatar = av;
+ Name = tex;
+ PlayerNr = pl;
+ }
+ }
+
+ private SThemeNameSelection _Theme;
+ private bool _ThemeLoaded;
+
+ public bool Selected = false;
+ public bool Visible = true;
+
+ public SRectF Rect;
+ private List _Tiles;
+
+ private STexture _TextureEmptyTile;
+ private STexture _TextureTileSelected;
+
+ public SColorF ColorEmptyTile;
+
+ private int _NumW;
+ private int _NumH;
+
+ private float _SpaceW;
+ private float _SpaceH;
+
+ private int _TileW;
+ private int _TileH;
+
+ public int _Offset = 0;
+ private int _actualSelection = -1;
+ public int Selection = -1;
+
+ int _player = -1;
+
+ private List VisibleProfiles;
+
+ private CStatic PlayerSelector;
+
+
+ public CNameSelection()
+ {
+ _Theme = new SThemeNameSelection();
+
+ _Tiles = new List();
+ VisibleProfiles = new List();
+ }
+
+ public void Init()
+ {
+ PrepareTiles();
+
+ PlayerSelector = new CStatic();
+ PlayerSelector.Texture = _TextureTileSelected;
+ PlayerSelector.Rect = new SRectF(0, 0, (_TileW + 6), (_TileH + 6), (Rect.Z - 0.5f));
+ PlayerSelector.Visible = false;
+
+ UpdateVisibleProfiles();
+
+ UpdateList(0);
+ }
+
+ public bool LoadTheme(string XmlPath, string ElementName, XPathNavigator navigator, int SkinIndex)
+ {
+ string item = XmlPath + "/" + ElementName;
+ _ThemeLoaded = true;
+
+ _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.GetValueFromXML(item + "/SkinEmptyTile", navigator, ref _Theme.TextureEmptyTileName, String.Empty);
+
+ if (CHelper.GetValueFromXML(item + "/ColorEmptyTile", navigator, ref _Theme.ColorEmptyTileName, String.Empty))
+ {
+ _ThemeLoaded &= CTheme.GetColor(_Theme.ColorEmptyTileName, SkinIndex, ref ColorEmptyTile);
+ }
+ else
+ {
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/R", navigator, ref ColorEmptyTile.R);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/G", navigator, ref ColorEmptyTile.G);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/B", navigator, ref ColorEmptyTile.B);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/A", navigator, ref ColorEmptyTile.A);
+ }
+
+ _ThemeLoaded &= CHelper.GetValueFromXML(item + "/SkinTileSelected", navigator, ref _Theme.TextureTileSelectedName, String.Empty);
+
+ _ThemeLoaded &= CHelper.TryGetIntValueFromXML(item + "/Tiles/W", navigator, ref _TileW);
+ _ThemeLoaded &= CHelper.TryGetIntValueFromXML(item + "/Tiles/H", navigator, ref _TileH);
+ _ThemeLoaded &= CHelper.TryGetIntValueFromXML(item + "/Tiles/NumW", navigator, ref _NumW);
+ _ThemeLoaded &= CHelper.TryGetIntValueFromXML(item + "/Tiles/NumH", navigator, ref _NumH);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/SpaceW", navigator, ref _SpaceW);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/SpaceH", navigator, ref _SpaceH);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/Name/Space", navigator, ref _Theme.NameSpace);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/Name/H", navigator, ref _Theme.NameHeight);
+ _ThemeLoaded &= CHelper.GetValueFromXML(item + "/Tiles/Name/Font", navigator, ref _Theme.NameFont, "Normal");
+ _ThemeLoaded &= CHelper.TryGetEnumValueFromXML(item + "/Tiles/Name/Style", navigator, ref _Theme.NameStyle);
+ if (CHelper.GetValueFromXML(item + "/Tiles/Name/Color", navigator, ref _Theme.NameColorName, String.Empty))
+ {
+ _ThemeLoaded &= CTheme.GetColor(_Theme.NameColorName, SkinIndex, ref _Theme.NameColor);
+ }
+ else
+ {
+ if (CHelper.TryGetFloatValueFromXML(item + "/Tiles/Name/R", navigator, ref _Theme.NameColor.R))
+ {
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/Name/G", navigator, ref _Theme.NameColor.G);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/Name/B", navigator, ref _Theme.NameColor.B);
+ _ThemeLoaded &= CHelper.TryGetFloatValueFromXML(item + "/Tiles/Name/A", navigator, ref _Theme.NameColor.A);
+ }
+ }
+
+
+ if (_ThemeLoaded)
+ {
+ _Theme.Name = ElementName;
+ LoadTextures();
+ }
+ return _ThemeLoaded;
+ }
+
+ public bool SaveTheme(XmlWriter writer)
+ {
+ if (_ThemeLoaded)
+ {
+ writer.WriteStartElement(_Theme.Name);
+
+ writer.WriteComment(", , , , : NameSelection 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(": Texture name");
+ writer.WriteElementString("SkinEmptyTile", _Theme.TextureEmptyTileName);
+
+ writer.WriteComment(": Static color from ColorScheme (high priority)");
+ writer.WriteComment("or , , , (lower priority)");
+ if (_Theme.ColorEmptyTileName != String.Empty)
+ {
+ writer.WriteElementString("ColorEmptyTile", _Theme.ColorEmptyTileName);
+ }
+ else
+ {
+ writer.WriteElementString("R", ColorEmptyTile.R.ToString("#0.00"));
+ writer.WriteElementString("G", ColorEmptyTile.G.ToString("#0.00"));
+ writer.WriteElementString("B", ColorEmptyTile.B.ToString("#0.00"));
+ writer.WriteElementString("A", ColorEmptyTile.A.ToString("#0.00"));
+ }
+
+ writer.WriteComment(": Texture name");
+ writer.WriteElementString("SkinTileSelected", _Theme.TextureTileSelectedName);
+
+ writer.WriteComment(": Options for tiles");
+ writer.WriteStartElement("Tiles");
+ writer.WriteComment(", : Width and height of tile");
+ writer.WriteElementString("W", _TileW.ToString());
+ writer.WriteElementString("H", _TileH.ToString());
+ writer.WriteComment(", : Number of tiles");
+ writer.WriteElementString("NumW", _NumW.ToString());
+ writer.WriteElementString("NumH", _NumH.ToString());
+ writer.WriteComment(", : Space between tiles");
+ writer.WriteElementString("SpaceW", _SpaceW.ToString("#0.00"));
+ writer.WriteElementString("SpaceH", _SpaceH.ToString("#0.00"));
+ writer.WriteComment(": Options for player-name");
+ writer.WriteStartElement("Name");
+ writer.WriteComment(": Space between name and tile");
+ writer.WriteElementString("Space", _Theme.NameSpace.ToString("#0.0"));
+ writer.WriteComment(": Text font name");
+ writer.WriteElementString("Font", _Theme.NameFont);
+ writer.WriteComment(": Text color from ColorScheme (high priority)");
+ if (_Theme.NameColorName != String.Empty)
+ {
+ writer.WriteElementString("Color", _Theme.NameColorName);
+ }
+ else
+ {
+ writer.WriteElementString("R", _Theme.NameColor.R.ToString("#0.00"));
+ writer.WriteElementString("G", _Theme.NameColor.G.ToString("#0.00"));
+ writer.WriteElementString("B", _Theme.NameColor.B.ToString("#0.00"));
+ writer.WriteElementString("A", _Theme.NameColor.A.ToString("#0.00"));
+ }
+ writer.WriteComment("