Gameplay support for #VOCALS (#788)

* Add Vocals Volume

* ScreenVersion 13

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add HasVocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Headers for Song Options

* Add AudioMode Vocals

* Screen Version 13

* Headers for Song Options

* Headers for Song Options

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add AudioMode Vocals

* Add Audio Mode Vocals
This commit is contained in:
Edi316 authored and GitHub committed 2025-05-09 06:46:58 +02:00
1 parent e44cdced09
commit 53e82284ac
10 files changed
+319 -68

No files matched your search

+6
View File
@@ -22,6 +22,7 @@
<string name="TR_GAMEMODE_SHORTSONG">Short version</string> <string name="TR_GAMEMODE_SHORTSONG">Short version</string>
<string name="TR_AUDIOMODE_NORMAL">Normal</string> <string name="TR_AUDIOMODE_NORMAL">Normal</string>
<string name="TR_AUDIOMODE_INSTRUMENTAL">Instrumental</string> <string name="TR_AUDIOMODE_INSTRUMENTAL">Instrumental</string>
<string name="TR_AUDIOMODE_VOCALS">Instrumental/Vocals</string>
<string name="TR_AUDIOMODE_KARAOKE">Karaoke</string> <string name="TR_AUDIOMODE_KARAOKE">Karaoke</string>
<string name="TR_RATING_KARAOKE">Karaoke</string> <string name="TR_RATING_KARAOKE">Karaoke</string>
<string name="TR_RATING_VOCAL_HERO">Vocal Hero</string> <string name="TR_RATING_VOCAL_HERO">Vocal Hero</string>
@@ -148,6 +149,10 @@
<string name="TR_SCREENSONG_BUTTON_STARTMEDLEY">Sing medley-songs</string> <string name="TR_SCREENSONG_BUTTON_STARTMEDLEY">Sing medley-songs</string>
<string name="TR_SCREENSONG_NEWPLAYLIST">New playlist</string> <string name="TR_SCREENSONG_NEWPLAYLIST">New playlist</string>
<string name="TR_SCREENSONG_SONGOPTIONS">Song Options</string> <string name="TR_SCREENSONG_SONGOPTIONS">Song Options</string>
<string name="TR_SCREENSONG_LENGTH">Song length</string>
<string name="TR_SCREENSONG_AUDIOMODE">Audio mode</string>
<string name="TR_SCREENSONG_PLAYLIST">Playlist</string>
<string name="TR_SCREENSONG_PLAYERSELECT">Player selection</string>
<string name="TR_SCREENSONG_PLAYERSELECT_ON">Show player selection</string> <string name="TR_SCREENSONG_PLAYERSELECT_ON">Show player selection</string>
<string name="TR_SCREENSONG_PLAYERSELECT_OFF">Skip player selection</string> <string name="TR_SCREENSONG_PLAYERSELECT_OFF">Skip player selection</string>
<string name="TR_SCREENSONG_SEARCH">Search:</string> <string name="TR_SCREENSONG_SEARCH">Search:</string>
@@ -171,6 +176,7 @@
<string name="TR_SCREENSING_BUTTON_SKIP">Skip this song</string> <string name="TR_SCREENSING_BUTTON_SKIP">Skip this song</string>
<string name="TR_SCREENSING_BUTTON_RESTART_ROUND">Restart round</string> <string name="TR_SCREENSING_BUTTON_RESTART_ROUND">Restart round</string>
<string name="TR_SCREENSING_BUTTON_RESTART_GAME">Restart game</string> <string name="TR_SCREENSING_BUTTON_RESTART_GAME">Restart game</string>
<string name="TR_SCREENSING_VOCALSVOLUME">Vocals track volume</string>
<string name="TR_SCREENSING_NOMORESONGS">No more songs in playlist!</string> <string name="TR_SCREENSING_NOMORESONGS">No more songs in playlist!</string>
<string name="TR_SCREENSING_NOWEBCAM">No webcam available!</string> <string name="TR_SCREENSING_NOWEBCAM">No webcam available!</string>
<string name="TR_SCREENSING_ASPECTRATIO">Aspect Ratio: %a</string> <string name="TR_SCREENSING_ASPECTRATIO">Aspect Ratio: %a</string>
@@ -1,4 +1,11 @@
ScreenSing ScreenSing
+++++++++
Version 13
Add:
<SelectSlidePauseVocalsVolume>
<TextPauseVocalsVolume>
+++++++++ +++++++++
Version 12 Version 12
@@ -1,5 +1,17 @@
ScreenSong ScreenSong
++++++++++
Version 13:
Headers for Song Options
Add:
<TextOptionsTitle>
<TextOptionsLenght>
<TextOptionsAudioMode>
<TextOptionsPlayerSelect>
<TextOptionsPlaylist>
++++++++++ ++++++++++
Version 12: Version 12:
@@ -2,7 +2,7 @@
<Screen xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <Screen xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Informations> <Informations>
<ScreenName>ScreenSing</ScreenName> <ScreenName>ScreenSing</ScreenName>
<ScreenVersion>11</ScreenVersion> <ScreenVersion>13</ScreenVersion>
</Informations> </Informations>
<Backgrounds> <Backgrounds>
<Background Name="Background1"> <Background Name="Background1">
@@ -708,6 +708,20 @@
<Font>Normal</Font> <Font>Normal</Font>
<Text /> <Text />
</Text> </Text>
<Text Name="TextPauseVocalsVolume">
<X>217.5</X>
<Y>818</Y>
<Z>-2.11</Z>
<H>40.5</H>
<MaxW>520</MaxW>
<Color Name="TextColor" />
<SelColor Name="TextSelColor" />
<Align>Left</Align>
<ResizeAlign>Center</ResizeAlign>
<Style>Bold</Style>
<Font>Outline</Font>
<Text>TR_SCREENSING_VOCALSVOLUME</Text>
</Text>
<Text Name="TextDuetName1"> <Text Name="TextDuetName1">
<X>15</X> <X>15</X>
<Y>82.5</Y> <Y>82.5</Y>
@@ -1582,7 +1596,50 @@
<ProcessedColor Name="LyricProcessedColor" /> <ProcessedColor Name="LyricProcessedColor" />
</Lyric> </Lyric>
</Lyrics> </Lyrics>
<SelectSlides /> <SelectSlides>
<SelectSlide Name="SelectSlidePauseVocalsVolume">
<Skin />
<SkinArrowLeft>SelectSlideArrowLeft</SkinArrowLeft>
<SkinArrowRight>SelectSlideArrowRight</SkinArrowRight>
<SkinSelected>SelectSlide</SkinSelected>
<SkinArrowLeftSelected>SelectSlideArrowLeft</SkinArrowLeftSelected>
<SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected>
<Rect>
<X>752</X>
<Y>820</Y>
<W>958</W>
<H>40</H>
<Z>-2.11</Z>
</Rect>
<RectArrowLeft>
<X>757.5</X>
<Y>822.5</Y>
<W>35</W>
<H>35</H>
<Z>-2.11</Z>
</RectArrowLeft>
<RectArrowRight>
<X>1667.5</X>
<Y>822.5</Y>
<W>35</W>
<H>35</H>
<Z>-2.11</Z>
</RectArrowRight>
<Color Name="SelectSlideColor" />
<SelColor Name="SelectSlideSelColor" />
<ArrowColor Name="ArrowColor" />
<ArrowSelColor Name="ArrowSelColor" />
<TextColor Name="TextColorAlpha" />
<TextSelColor Name="TextSelColor" />
<TextH>40.5</TextH>
<TextRelativeX>75</TextRelativeX>
<TextRelativeY>0</TextRelativeY>
<TextMaxW>300</TextMaxW>
<TextFont>Outline</TextFont>
<TextStyle>Bold</TextStyle>
<NumVisible>5</NumVisible>
</SelectSlide>
</SelectSlides>
<SingNotes> <SingNotes>
<SingBar Name="SingBars"> <SingBar Name="SingBars">
<SkinLeft>NoteLeft</SkinLeft> <SkinLeft>NoteLeft</SkinLeft>
@@ -2,7 +2,7 @@
<Screen xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <Screen xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Informations> <Informations>
<ScreenName>ScreenSong</ScreenName> <ScreenName>ScreenSong</ScreenName>
<ScreenVersion>12</ScreenVersion> <ScreenVersion>13</ScreenVersion>
</Informations> </Informations>
<Backgrounds> <Backgrounds>
<Background Name="Background1"> <Background Name="Background1">
@@ -253,7 +253,7 @@
<X>330</X> <X>330</X>
<Y>60</Y> <Y>60</Y>
<Z>-2.11</Z> <Z>-2.11</Z>
<H>45</H> <H>40</H>
<MaxW>525</MaxW> <MaxW>525</MaxW>
<Color Name="TextColor" /> <Color Name="TextColor" />
<SelColor Name="TextSelColor" /> <SelColor Name="TextSelColor" />
@@ -263,6 +263,62 @@
<Font>Outline</Font> <Font>Outline</Font>
<Text>TR_SCREENSONG_SONGOPTIONS</Text> <Text>TR_SCREENSONG_SONGOPTIONS</Text>
</Text> </Text>
<Text Name="TextOptionsLength">
<X>330</X>
<Y>155</Y>
<Z>-2.11</Z>
<H>30</H>
<MaxW>525</MaxW>
<Color Name="TextColor" />
<SelColor Name="TextSelColor" />
<Align>Center</Align>
<ResizeAlign>Center</ResizeAlign>
<Style>Bold</Style>
<Font>Outline</Font>
<Text>TR_SCREENSONG_LENGTH</Text>
</Text>
<Text Name="TextOptionsAudioMode">
<X>330</X>
<Y>230</Y>
<Z>-2.11</Z>
<H>30</H>
<MaxW>525</MaxW>
<Color Name="TextColor" />
<SelColor Name="TextSelColor" />
<Align>Center</Align>
<ResizeAlign>Center</ResizeAlign>
<Style>Bold</Style>
<Font>Outline</Font>
<Text>TR_SCREENSONG_AUDIOMODE</Text>
</Text>
<Text Name="TextOptionsPlayerSelect">
<X>330</X>
<Y>305</Y>
<Z>-2.11</Z>
<H>30</H>
<MaxW>525</MaxW>
<Color Name="TextColor" />
<SelColor Name="TextSelColor" />
<Align>Center</Align>
<ResizeAlign>Center</ResizeAlign>
<Style>Bold</Style>
<Font>Outline</Font>
<Text>TR_SCREENSONG_PLAYERSELECT</Text>
</Text>
<Text Name="TextOptionsPlaylist">
<X>330</X>
<Y>380</Y>
<Z>-2.11</Z>
<H>30</H>
<MaxW>525</MaxW>
<Color Name="TextColor" />
<SelColor Name="TextSelColor" />
<Align>Center</Align>
<ResizeAlign>Center</ResizeAlign>
<Style>Bold</Style>
<Font>Outline</Font>
<Text>TR_SCREENSONG_PLAYLIST</Text>
</Text>
<Text Name="TextHelpBar"> <Text Name="TextHelpBar">
<X>60</X> <X>60</X>
<Y>1050</Y> <Y>1050</Y>
@@ -486,16 +542,16 @@
<SkinSelected>SongSelectButton</SkinSelected> <SkinSelected>SongSelectButton</SkinSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>546</Y> <Y>554</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>45</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
<SelColor Name="ButtonSelColor" /> <SelColor Name="ButtonSelColor" />
<Text Name="Text"> <Text Name="Text">
<X>270</X> <X>270</X>
<Y>10.5</Y> <Y>2</Y>
<Z>0</Z> <Z>0</Z>
<H>37.5</H> <H>37.5</H>
<MaxW>525</MaxW> <MaxW>525</MaxW>
@@ -513,18 +569,18 @@
<SkinSelected>SongSelectButton</SkinSelected> <SkinSelected>SongSelectButton</SkinSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>415</Y> <Y>451</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>35</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
<SelColor Name="ButtonSelColor" /> <SelColor Name="ButtonSelColor" />
<Text Name="Text"> <Text Name="Text">
<X>270</X> <X>270</X>
<Y>10.5</Y> <Y>2</Y>
<Z>0</Z> <Z>0</Z>
<H>37.5</H> <H>35</H>
<MaxW>525</MaxW> <MaxW>525</MaxW>
<Color Name="ButtonTextColor" /> <Color Name="ButtonTextColor" />
<SelColor Name="ButtonTextSelColor" /> <SelColor Name="ButtonTextSelColor" />
@@ -542,14 +598,14 @@
<X>60</X> <X>60</X>
<Y>104</Y> <Y>104</Y>
<W>540</W> <W>540</W>
<H>57</H> <H>45</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
<SelColor Name="ButtonSelColor" /> <SelColor Name="ButtonSelColor" />
<Text Name="Text"> <Text Name="Text">
<X>270</X> <X>270</X>
<Y>10.5</Y> <Y>3</Y>
<Z>0</Z> <Z>0</Z>
<H>37.5</H> <H>37.5</H>
<MaxW>525</MaxW> <MaxW>525</MaxW>
@@ -818,16 +874,16 @@
<SkinSelected>SongSelectButton</SkinSelected> <SkinSelected>SongSelectButton</SkinSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>486.5</Y> <Y>497.5</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>45</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
<SelColor Name="ButtonSelColor" /> <SelColor Name="ButtonSelColor" />
<Text Name="Text"> <Text Name="Text">
<X>270</X> <X>270</X>
<Y>10.5</Y> <Y>2</Y>
<Z>0</Z> <Z>0</Z>
<H>37.5</H> <H>37.5</H>
<MaxW>525</MaxW> <MaxW>525</MaxW>
@@ -907,7 +963,7 @@
</TextTitle> </TextTitle>
<TextSongLength Name="TextSongLength"> <TextSongLength Name="TextSongLength">
<X>586.5</X> <X>586.5</X>
<Y>735</Y> <Y>743</Y>
<Z>-11</Z> <Z>-11</Z>
<H>42</H> <H>42</H>
<MaxW>150</MaxW> <MaxW>150</MaxW>
@@ -1176,23 +1232,23 @@
<SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected> <SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>167.5</Y> <Y>186</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>35</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<RectArrowLeft> <RectArrowLeft>
<X>67.5</X> <X>67.5</X>
<Y>172.5</Y> <Y>188,5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowLeft> </RectArrowLeft>
<RectArrowRight> <RectArrowRight>
<X>547.5</X> <X>560</X>
<Y>172.5</Y> <Y>188,5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowRight> </RectArrowRight>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
@@ -1201,7 +1257,7 @@
<ArrowSelColor Name="ArrowSelColor" /> <ArrowSelColor Name="ArrowSelColor" />
<TextColor Name="TextColorAlpha" /> <TextColor Name="TextColorAlpha" />
<TextSelColor Name="TextColorAlpha" /> <TextSelColor Name="TextColorAlpha" />
<TextH>37.5</TextH> <TextH>35</TextH>
<TextRelativeX>75</TextRelativeX> <TextRelativeX>75</TextRelativeX>
<TextRelativeY>0</TextRelativeY> <TextRelativeY>0</TextRelativeY>
<TextMaxW>420</TextMaxW> <TextMaxW>420</TextMaxW>
@@ -1218,23 +1274,23 @@
<SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected> <SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>286</Y> <Y>336</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>35</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<RectArrowLeft> <RectArrowLeft>
<X>67.5</X> <X>67.5</X>
<Y>291</Y> <Y>338.5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowLeft> </RectArrowLeft>
<RectArrowRight> <RectArrowRight>
<X>547.5</X> <X>560</X>
<Y>291</Y> <Y>338.5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowRight> </RectArrowRight>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
@@ -1243,7 +1299,7 @@
<ArrowSelColor Name="ArrowSelColor" /> <ArrowSelColor Name="ArrowSelColor" />
<TextColor Name="TextColorAlpha" /> <TextColor Name="TextColorAlpha" />
<TextSelColor Name="TextColorAlpha" /> <TextSelColor Name="TextColorAlpha" />
<TextH>37.5</TextH> <TextH>35</TextH>
<TextRelativeX>175</TextRelativeX> <TextRelativeX>175</TextRelativeX>
<TextRelativeY>0</TextRelativeY> <TextRelativeY>0</TextRelativeY>
<TextMaxW>420</TextMaxW> <TextMaxW>420</TextMaxW>
@@ -1260,23 +1316,23 @@
<SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected> <SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>227</Y> <Y>261</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>35</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<RectArrowLeft> <RectArrowLeft>
<X>67.5</X> <X>67.5</X>
<Y>232</Y> <Y>263.5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowLeft> </RectArrowLeft>
<RectArrowRight> <RectArrowRight>
<X>547.5</X> <X>560</X>
<Y>232</Y> <Y>263.5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowRight> </RectArrowRight>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
@@ -1285,7 +1341,7 @@
<ArrowSelColor Name="ArrowSelColor" /> <ArrowSelColor Name="ArrowSelColor" />
<TextColor Name="TextColorAlpha" /> <TextColor Name="TextColorAlpha" />
<TextSelColor Name="TextColorAlpha" /> <TextSelColor Name="TextColorAlpha" />
<TextH>37.5</TextH> <TextH>35</TextH>
<TextRelativeX>75</TextRelativeX> <TextRelativeX>75</TextRelativeX>
<TextRelativeY>0</TextRelativeY> <TextRelativeY>0</TextRelativeY>
<TextMaxW>420</TextMaxW> <TextMaxW>420</TextMaxW>
@@ -1302,23 +1358,23 @@
<SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected> <SkinArrowRightSelected>SelectSlideArrowRight</SkinArrowRightSelected>
<Rect> <Rect>
<X>60</X> <X>60</X>
<Y>355.5</Y> <Y>411</Y>
<W>540</W> <W>540</W>
<H>53</H> <H>35</H>
<Z>-2.11</Z> <Z>-2.11</Z>
</Rect> </Rect>
<RectArrowLeft> <RectArrowLeft>
<X>67.5</X> <X>67.5</X>
<Y>360.5</Y> <Y>413.5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowLeft> </RectArrowLeft>
<RectArrowRight> <RectArrowRight>
<X>547.5</X> <X>560</X>
<Y>360.5</Y> <Y>413.5</Y>
<W>45</W> <W>30</W>
<H>45</H> <H>30</H>
<Z>-2.12</Z> <Z>-2.12</Z>
</RectArrowRight> </RectArrowRight>
<Color Name="ButtonColor" /> <Color Name="ButtonColor" />
@@ -1327,7 +1383,7 @@
<ArrowSelColor Name="ArrowSelColor" /> <ArrowSelColor Name="ArrowSelColor" />
<TextColor Name="TextColorAlpha" /> <TextColor Name="TextColorAlpha" />
<TextSelColor Name="TextColorAlpha" /> <TextSelColor Name="TextColorAlpha" />
<TextH>37.5</TextH> <TextH>35</TextH>
<TextRelativeX>75</TextRelativeX> <TextRelativeX>75</TextRelativeX>
<TextRelativeY>0</TextRelativeY> <TextRelativeY>0</TextRelativeY>
<TextMaxW>420</TextMaxW> <TextMaxW>420</TextMaxW>
+14
View File
@@ -153,6 +153,8 @@ namespace Vocaluxe.Base
public int GameMusicVolume; public int GameMusicVolume;
[XmlRanged(0, 100), DefaultValue(80)] [XmlRanged(0, 100), DefaultValue(80)]
public int SoundEffectVolume; public int SoundEffectVolume;
[XmlRanged(0, 100), DefaultValue(50)]
public int VocalsVolume;
[DefaultValue(EOffOn.TR_CONFIG_OFF)] [DefaultValue(EOffOn.TR_CONFIG_OFF)]
public EOffOn KaraokeEffect; public EOffOn KaraokeEffect;
[XmlRanged(0, 1), DefaultValue(1.0f)] [XmlRanged(0, 1), DefaultValue(1.0f)]
@@ -338,6 +340,16 @@ namespace Vocaluxe.Base
} }
} }
public static int VocalsVolume
{
get { return Config.Sound.VocalsVolume; }
set
{
Config.Sound.VocalsVolume = value.Clamp(0, 100);
SaveConfig();
}
}
public static int PreviewMusicVolume public static int PreviewMusicVolume
{ {
get { return Config.Sound.PreviewMusicVolume; } get { return Config.Sound.PreviewMusicVolume; }
@@ -511,6 +523,8 @@ namespace Vocaluxe.Base
return "Game Volume from 0 to 100"; return "Game Volume from 0 to 100";
case "SoundEffectVolume": case "SoundEffectVolume":
return "Sound Effect Volume from 0 to 100"; return "Sound Effect Volume from 0 to 100";
case "VocalsVolume":
return "Vocals Volume from 0 to 100";
case "KaraokeEffect": case "KaraokeEffect":
return "Apply a karaoke effect to song playback (EPlaybackLib.GstreamerSharp only)"; return "Apply a karaoke effect to song playback (EPlaybackLib.GstreamerSharp only)";
case "KaraokeEffectLevel": case "KaraokeEffectLevel":
+71 -4
View File
@@ -41,7 +41,7 @@ namespace Vocaluxe.Screens
// Version number for theme files. Increment it, if you've changed something on the theme files! // Version number for theme files. Increment it, if you've changed something on the theme files!
protected override int _ScreenVersion protected override int _ScreenVersion
{ {
get { return 12; } get { return 13; }
} }
private struct STimeRect private struct STimeRect
@@ -58,6 +58,7 @@ namespace Vocaluxe.Screens
private const string _TextDuetName2 = "TextDuetName2"; private const string _TextDuetName2 = "TextDuetName2";
private const string _TextMedleyCountdown = "TextMedleyCountdown"; private const string _TextMedleyCountdown = "TextMedleyCountdown";
private const string _TextPauseSongName = "TextPauseSongName"; private const string _TextPauseSongName = "TextPauseSongName";
private const string _TextPauseVocalsVolume = "TextPauseVocalsVolume";
private string[,,] _TextScores; private string[,,] _TextScores;
private string[,,] _TextNames; private string[,,] _TextNames;
private List<string> _TextsPause; private List<string> _TextsPause;
@@ -89,6 +90,9 @@ namespace Vocaluxe.Screens
private const string _ButtonRestartGame = "ButtonRestartGame"; private const string _ButtonRestartGame = "ButtonRestartGame";
private const string _ButtonSkip = "ButtonSkip"; private const string _ButtonSkip = "ButtonSkip";
private const string _SelectSlidePauseVocalsVolume = "SelectSlidePauseVocalsVolume";
private List<string> _SelectSlidesPause;
private const string _LyricMain = "LyricMain"; private const string _LyricMain = "LyricMain";
private const string _LyricSub = "LyricSub"; private const string _LyricSub = "LyricSub";
private const string _LyricMainDuet = "LyricMainDuet"; private const string _LyricMainDuet = "LyricMainDuet";
@@ -116,6 +120,7 @@ namespace Vocaluxe.Screens
private int _CurrentBeat; private int _CurrentBeat;
private int _CurrentStream = -1; private int _CurrentStream = -1;
private int _CurrentStreamVocals = -1;
private float _Length = -1f; private float _Length = -1f;
private CVideoStream _CurrentVideo; private CVideoStream _CurrentVideo;
@@ -126,6 +131,8 @@ namespace Vocaluxe.Screens
private float _CurrentTime; private float _CurrentTime;
private float _FinishTime; private float _FinishTime;
private float _PausePosition;
private float _TimeToFirstNote; private float _TimeToFirstNote;
private float _RemainingTimeToFirstNote; private float _RemainingTimeToFirstNote;
private float _TimeToFirstNoteDuet; private float _TimeToFirstNoteDuet;
@@ -193,6 +200,7 @@ namespace Vocaluxe.Screens
_ThemeButtons = new string[] { _ButtonCancel, _ButtonContinue, _ButtonRestartGame, _ButtonRestartRound, _ButtonSkip }; _ThemeButtons = new string[] { _ButtonCancel, _ButtonContinue, _ButtonRestartGame, _ButtonRestartRound, _ButtonSkip };
_ThemeLyrics = new string[] { _LyricMain, _LyricSub, _LyricMainDuet, _LyricSubDuet, _LyricMainTop, _LyricSubTop }; _ThemeLyrics = new string[] { _LyricMain, _LyricSub, _LyricMainDuet, _LyricSubDuet, _LyricMainTop, _LyricSubTop };
_ThemeSingNotes = new string[] { _SingBars }; _ThemeSingNotes = new string[] { _SingBars };
_ThemeSelectSlides = new string[] { _SelectSlidePauseVocalsVolume };
_TimeRects = new List<STimeRect>(); _TimeRects = new List<STimeRect>();
_TimerSongText = new Stopwatch(); _TimerSongText = new Stopwatch();
@@ -225,6 +233,11 @@ namespace Vocaluxe.Screens
_StaticsPause = new List<string>(); _StaticsPause = new List<string>();
_TextsPause = new List<string>(); _TextsPause = new List<string>();
_SelectSlidesPause = new List<string>();
_SelectSlides[_SelectSlidePauseVocalsVolume].AddValues(new string[]
{"0", "5", "10", "15", "20", "25", "30", "35", "40", "45", "50", "55", "60", "65", "70", "75", "80", "85", "90", "95", "100"});
_SelectSlides[_SelectSlidePauseVocalsVolume].Selection = CConfig.VocalsVolume / 5;
//Automatically find statics and texts with pause prefix //Automatically find statics and texts with pause prefix
foreach (CStatic s in _Statics.Where(s => s.ThemeLoaded && s.GetThemeName().StartsWith("StaticPause"))) foreach (CStatic s in _Statics.Where(s => s.ThemeLoaded && s.GetThemeName().StartsWith("StaticPause")))
@@ -232,6 +245,9 @@ namespace Vocaluxe.Screens
foreach (CText t in _Texts.Where(s => s.ThemeLoaded && s.GetThemeName().StartsWith("TextPause"))) foreach (CText t in _Texts.Where(s => s.ThemeLoaded && s.GetThemeName().StartsWith("TextPause")))
_TextsPause.Add(t.GetThemeName()); _TextsPause.Add(t.GetThemeName());
foreach (CText t in _Texts.Where(s => s.ThemeLoaded && s.GetThemeName().StartsWith("SelectSlidePause")))
_SelectSlidesPause.Add(t.GetThemeName());
} }
public override bool HandleInput(SKeyEvent keyEvent) public override bool HandleInput(SKeyEvent keyEvent)
@@ -366,6 +382,11 @@ namespace Vocaluxe.Screens
newTime = CSound.GetLength(_CurrentStream) - 1f; newTime = CSound.GetLength(_CurrentStream) - 1f;
CSound.SetPosition(_CurrentStream, newTime); CSound.SetPosition(_CurrentStream, newTime);
if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_VOCALS)
{
CSound.SetPosition(_CurrentStreamVocals, newTime);
}
_ShowInfoText(CBase.Language.Translate("TR_SCREENSING_SKIPPEDSECONDS").Replace("%s", (keyEvent.Mod == EModifier.Shift ? "10" : "30"))); _ShowInfoText(CBase.Language.Translate("TR_SCREENSING_SKIPPEDSECONDS").Replace("%s", (keyEvent.Mod == EModifier.Shift ? "10" : "30")));
} }
break; break;
@@ -1070,6 +1091,12 @@ namespace Vocaluxe.Screens
{ {
_PrepareTimeLine(); _PrepareTimeLine();
CSound.Play(_CurrentStream); CSound.Play(_CurrentStream);
if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_VOCALS)
{
CSound.Play(_CurrentStreamVocals);
}
CRecord.Start(); CRecord.Start();
if (_Webcam) if (_Webcam)
CWebcam.Start(); CWebcam.Start();
@@ -1175,12 +1202,18 @@ namespace Vocaluxe.Screens
foreach (String s in _TextsPause) foreach (String s in _TextsPause)
_Texts[s].Visible = _Pause; _Texts[s].Visible = _Pause;
foreach (String s in _SelectSlidesPause)
_SelectSlides[s].Visible = _Pause;
_Buttons[_ButtonCancel].Visible = _Pause; _Buttons[_ButtonCancel].Visible = _Pause;
_Buttons[_ButtonContinue].Visible = _Pause; _Buttons[_ButtonContinue].Visible = _Pause;
_Buttons[_ButtonSkip].Visible = _Pause && CGame.NumRounds > CGame.RoundNr && CGame.NumRounds > 1; _Buttons[_ButtonSkip].Visible = _Pause && CGame.NumRounds > CGame.RoundNr && CGame.NumRounds > 1;
_Buttons[_ButtonRestartGame].Visible = _Pause; _Buttons[_ButtonRestartGame].Visible = _Pause;
_Buttons[_ButtonRestartRound].Visible = _Pause && CGame.NumRounds > 1; _Buttons[_ButtonRestartRound].Visible = _Pause && CGame.NumRounds > 1;
_SelectSlides[_SelectSlidePauseVocalsVolume].Visible = _Pause && (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_VOCALS);
_Texts[_TextPauseVocalsVolume].Visible = _Pause && (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_VOCALS);
if (_Pause && _TimerSongText.IsRunning) if (_Pause && _TimerSongText.IsRunning)
_TimerSongText.Stop(); _TimerSongText.Stop();
else else
@@ -1188,10 +1221,35 @@ namespace Vocaluxe.Screens
_Texts[_TextSongName].Visible = !_Pause; _Texts[_TextSongName].Visible = !_Pause;
if (_Pause) if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_VOCALS)
CSound.Pause(_CurrentStream); {
if (_Pause)
{
// Store current position before pausing
_PausePosition = CSound.GetPosition(_CurrentStream);
CSound.Pause(_CurrentStream);
CSound.Pause(_CurrentStreamVocals);
}
else
{
// Reset both streams to stored position to keep them in sync and update vocals volume
CConfig.VocalsVolume = _SelectSlides[_SelectSlidePauseVocalsVolume].Selection * 5;
CConfig.SaveConfig();
CSound.SetStreamVolume(_CurrentStreamVocals, CConfig.VocalsVolume);
CSound.SetPosition(_CurrentStream, _PausePosition);
CSound.SetPosition(_CurrentStreamVocals, _PausePosition);
// Start both streams simultaneously
CSound.Play(_CurrentStream);
CSound.Play(_CurrentStreamVocals);
}
}
else else
CSound.Play(_CurrentStream); {
if (_Pause)
CSound.Pause(_CurrentStream);
else
CSound.Play(_CurrentStream);
}
} }
#endregion #endregion
@@ -1229,6 +1287,13 @@ namespace Vocaluxe.Screens
{ {
_CurrentStream = CSound.Load(song.GetInstrumental(), false, true, EAudioEffect.None); _CurrentStream = CSound.Load(song.GetInstrumental(), false, true, EAudioEffect.None);
} }
else if (CScreenSong.GetAudioMode() == EAudioMode.TR_AUDIOMODE_VOCALS)
{
_CurrentStream = CSound.Load(song.GetInstrumental(), false, true, EAudioEffect.None);
_CurrentStreamVocals = CSound.Load(song.GetVocals(), false, true, EAudioEffect.None);
CSound.SetStreamVolume(_CurrentStreamVocals, CConfig.VocalsVolume);
CSound.SetPosition(_CurrentStreamVocals, song.Start);
}
else else
{ {
_CurrentStream = CSound.Load(song.GetMP3(), false, true, CConfig.Config.Sound.KaraokeEffect == EOffOn.TR_CONFIG_ON ? EAudioEffect.Karaoke : EAudioEffect.None); _CurrentStream = CSound.Load(song.GetMP3(), false, true, CConfig.Config.Sound.KaraokeEffect == EOffOn.TR_CONFIG_ON ? EAudioEffect.Karaoke : EAudioEffect.None);
@@ -1341,7 +1406,9 @@ namespace Vocaluxe.Screens
if (_CurrentStream > -1) if (_CurrentStream > -1)
{ {
CSound.FadeAndClose(_CurrentStream, 0, 0.5f); CSound.FadeAndClose(_CurrentStream, 0, 0.5f);
CSound.FadeAndClose(_CurrentStreamVocals, 0, 0.5f);
_CurrentStream = -1; _CurrentStream = -1;
_CurrentStreamVocals = -1;
} }
CRecord.Stop(); CRecord.Stop();
if (_CurrentVideo != null) if (_CurrentVideo != null)
+32 -6
View File
@@ -43,7 +43,7 @@ namespace Vocaluxe.Screens
// Version number for theme files. Increment it, if you've changed something on the theme files! // Version number for theme files. Increment it, if you've changed something on the theme files!
protected override int _ScreenVersion protected override int _ScreenVersion
{ {
get { return 12; } get { return 13; }
} }
private const string _TextCategory = "TextCategory"; private const string _TextCategory = "TextCategory";
@@ -54,6 +54,10 @@ namespace Vocaluxe.Screens
private const string _TextHelpBarSearch = "TextHelpBarSearch"; private const string _TextHelpBarSearch = "TextHelpBarSearch";
private const string _TextHelpBarParty = "TextHelpBarParty"; private const string _TextHelpBarParty = "TextHelpBarParty";
private const string _TextOptionsTitle = "TextOptionsTitle"; private const string _TextOptionsTitle = "TextOptionsTitle";
private const string _TextOptionsLength = "TextOptionsLength";
private const string _TextOptionsAudioMode = "TextOptionsAudioMode";
private const string _TextOptionsPlayerSelect = "TextOptionsPlayerSelect";
private const string _TextOptionsPlaylist = "TextOptionsPlaylist";
private const string _TextShortInfoTop = "TextShortInfoTop"; private const string _TextShortInfoTop = "TextShortInfoTop";
private const string _ButtonOpenOptions = "ButtonOpenOptions"; private const string _ButtonOpenOptions = "ButtonOpenOptions";
@@ -179,6 +183,11 @@ namespace Vocaluxe.Screens
tlist.Add(_TextHelpBarSearch); tlist.Add(_TextHelpBarSearch);
tlist.Add(_TextHelpBarParty); tlist.Add(_TextHelpBarParty);
tlist.Add(_TextOptionsTitle); tlist.Add(_TextOptionsTitle);
tlist.Add(_TextOptionsLength);
tlist.Add(_TextOptionsAudioMode);
tlist.Add(_TextOptionsPlayerSelect);
tlist.Add(_TextOptionsPlaylist);
tlist.Add(_TextShortInfoTop); tlist.Add(_TextShortInfoTop);
_ThemeStatics = new string[] {_StaticSearchBar, _StaticOptionsBG, _StaticShortInfoTop}; _ThemeStatics = new string[] {_StaticSearchBar, _StaticOptionsBG, _StaticShortInfoTop};
@@ -1030,7 +1039,7 @@ namespace Vocaluxe.Screens
else else
gm = CSongs.VisibleSongs[songNr].IsDuet ? EGameMode.TR_GAMEMODE_DUET : EGameMode.TR_GAMEMODE_NORMAL; gm = CSongs.VisibleSongs[songNr].IsDuet ? EGameMode.TR_GAMEMODE_DUET : EGameMode.TR_GAMEMODE_NORMAL;
_AudioMode = (EAudioMode)_SelectSlides[_SelectSlideOptionsAudioMode].Selection; _AudioMode = (EAudioMode)_SelectSlides[_SelectSlideOptionsAudioMode].SelectedTag;
_PlayerSelect = (EPlayerSelect)_SelectSlides[_SelectSlideOptionsPlayerSelect].Selection; _PlayerSelect = (EPlayerSelect)_SelectSlides[_SelectSlideOptionsPlayerSelect].Selection;
CGame.Reset(); CGame.Reset();
@@ -1409,6 +1418,10 @@ namespace Vocaluxe.Screens
_Buttons[_ButtonOptionsStartMedley].Visible = false; _Buttons[_ButtonOptionsStartMedley].Visible = false;
_Buttons[_ButtonOptionsHighscore].Visible = false; _Buttons[_ButtonOptionsHighscore].Visible = false;
_Texts[_TextOptionsTitle].Visible = false; _Texts[_TextOptionsTitle].Visible = false;
_Texts[_TextOptionsLength].Visible = false;
_Texts[_TextOptionsAudioMode].Visible = false;
_Texts[_TextOptionsPlayerSelect].Visible = false;
_Texts[_TextOptionsPlaylist].Visible = false;
_Statics[_StaticOptionsBG].Visible = false; _Statics[_StaticOptionsBG].Visible = false;
_Buttons[_ButtonOpenOptions].Visible = true; _Buttons[_ButtonOpenOptions].Visible = true;
@@ -1426,6 +1439,9 @@ namespace Vocaluxe.Screens
_UpdatePlaylistNames(); _UpdatePlaylistNames();
_Texts[_TextOptionsTitle].Visible = true; _Texts[_TextOptionsTitle].Visible = true;
_Texts[_TextOptionsLength].Visible = true;
_Texts[_TextOptionsPlayerSelect].Visible = true;
_Texts[_TextOptionsPlaylist].Visible = true;
_Buttons[_ButtonOptionsClose].Visible = true; _Buttons[_ButtonOptionsClose].Visible = true;
_Statics[_StaticOptionsBG].Visible = true; _Statics[_StaticOptionsBG].Visible = true;
_Buttons[_ButtonOpenOptions].Visible = false; _Buttons[_ButtonOpenOptions].Visible = false;
@@ -1463,17 +1479,27 @@ namespace Vocaluxe.Screens
_SelectSlides[_SelectSlideOptionsAudioMode].Clear(); _SelectSlides[_SelectSlideOptionsAudioMode].Clear();
CSong currentSong = CSongs.VisibleSongs[_SongMenu.GetPreviewSongNr()]; CSong currentSong = CSongs.VisibleSongs[_SongMenu.GetPreviewSongNr()];
if (currentSong.HasInstrumental()) if (currentSong.HasInstrumental())
{ {
_SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_NORMAL"); _SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_NORMAL", tag: (int)EAudioMode.TR_AUDIOMODE_NORMAL);
_SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_INSTRUMENTAL"); _SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_INSTRUMENTAL", tag: (int)EAudioMode.TR_AUDIOMODE_INSTRUMENTAL);
_SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_KARAOKE");
_SelectSlides[_SelectSlideOptionsAudioMode].Visible = true; if (currentSong.HasVocals())
{
_SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_VOCALS", tag: (int)EAudioMode.TR_AUDIOMODE_VOCALS);
}
_SelectSlides[_SelectSlideOptionsAudioMode].AddValue("TR_AUDIOMODE_KARAOKE", tag: (int)EAudioMode.TR_AUDIOMODE_KARAOKE);
_SelectSlides[_SelectSlideOptionsAudioMode].Visible = true;
_Texts[_TextOptionsAudioMode].Visible = true;
} }
else else
{ {
_SelectSlides[_SelectSlideOptionsAudioMode].Visible = false; _SelectSlides[_SelectSlideOptionsAudioMode].Visible = false;
_Texts[_TextOptionsAudioMode].Visible = false;
} }
_SelectSlides[_SelectSlideOptionsAudioMode].Selection = (int)_AudioMode; _SelectSlides[_SelectSlideOptionsAudioMode].Selection = (int)_AudioMode;
_SelectSlides[_SelectSlideOptionsPlayerSelect].Clear(); _SelectSlides[_SelectSlideOptionsPlayerSelect].Clear();
+1
View File
@@ -368,6 +368,7 @@ namespace VocaluxeLib
{ {
TR_AUDIOMODE_NORMAL, TR_AUDIOMODE_NORMAL,
TR_AUDIOMODE_INSTRUMENTAL, TR_AUDIOMODE_INSTRUMENTAL,
TR_AUDIOMODE_VOCALS,
TR_AUDIOMODE_KARAOKE TR_AUDIOMODE_KARAOKE
} }
+6 -1
View File
@@ -1,4 +1,4 @@
#region license #region license
// This file is part of Vocaluxe. // This file is part of Vocaluxe.
// //
// Vocaluxe is free software: you can redistribute it and/or modify // Vocaluxe is free software: you can redistribute it and/or modify
@@ -339,6 +339,11 @@ namespace VocaluxeLib.Songs
return Path.Combine(Folder, VocalsFileName); return Path.Combine(Folder, VocalsFileName);
} }
public bool HasVocals()
{
return !string.IsNullOrEmpty(VocalsFileName);
}
public string GetVideo() public string GetVideo()
{ {
return Path.Combine(Folder, VideoFileName); return Path.Combine(Folder, VideoFileName);