-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
5,000 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio Version 17 | ||
VisualStudioVersion = 17.4.33205.214 | ||
MinimumVisualStudioVersion = 10.0.40219.1 | ||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "VRCSongWiz", "VRCSongWiz\VRCSongWiz.csproj", "{3F132C57-7DD2-43BA-83B5-86A336CD90E6}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{3F132C57-7DD2-43BA-83B5-86A336CD90E6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{3F132C57-7DD2-43BA-83B5-86A336CD90E6}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{3F132C57-7DD2-43BA-83B5-86A336CD90E6}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{3F132C57-7DD2-43BA-83B5-86A336CD90E6}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
GlobalSection(ExtensibilityGlobals) = postSolution | ||
SolutionGuid = {0CAFF4BF-972A-4F0C-955F-14E07E2C7A04} | ||
EndGlobalSection | ||
EndGlobal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<configuration> | ||
<configSections> | ||
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" > | ||
<section name="TTSVoiceWizard3._0.Settings1" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" /> | ||
</sectionGroup> | ||
</configSections> | ||
<userSettings> | ||
<TTSVoiceWizard3._0.Settings1> | ||
<setting name="DisplaySong" serializeAs="String"> | ||
<value>True</value> | ||
</setting> | ||
<setting name="SongChangeOnly" serializeAs="String"> | ||
<value>True</value> | ||
</setting> | ||
</TTSVoiceWizard3._0.Settings1> | ||
</userSettings> | ||
</configuration> |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
namespace TTSVoiceWizard3._0 | ||
{ | ||
internal static class Program | ||
{ | ||
/// <summary> | ||
/// The main entry point for the application. | ||
/// </summary> | ||
[STAThread] | ||
static void Main() | ||
{ | ||
// To customize application configuration such as set high DPI settings or default font, | ||
// see https://aka.ms/applicationconfiguration. | ||
ApplicationConfiguration.Initialize(); | ||
Application.Run(new VRCSongWiz()); | ||
} | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<?xml version='1.0' encoding='utf-8'?> | ||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="TTSVoiceWizard3._0" GeneratedClassName="Settings1"> | ||
<Profiles /> | ||
<Settings> | ||
<Setting Name="DisplaySong" Type="System.Boolean" Scope="User"> | ||
<Value Profile="(Default)">True</Value> | ||
</Setting> | ||
<Setting Name="SongChangeOnly" Type="System.Boolean" Scope="User"> | ||
<Value Profile="(Default)">True</Value> | ||
</Setting> | ||
</Settings> | ||
</SettingsFile> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
using CoreOSC; | ||
using MaterialSkin; | ||
using MaterialSkin.Controls; | ||
|
||
namespace TTSVoiceWizard3._0 | ||
{ | ||
public partial class VRCSongWiz : MaterialForm | ||
{ | ||
public static CoreOSC.UDPSender OSCSender = new CoreOSC.UDPSender("127.0.0.1", 9000); | ||
public static System.Threading.Timer spotifyTimer; | ||
public static VRCSongWiz MainFormGlobal; | ||
public VRCSongWiz() | ||
{ | ||
InitializeComponent(); | ||
MainFormGlobal = this; | ||
|
||
var materialSkinManager = MaterialSkinManager.Instance; | ||
materialSkinManager.AddFormToManage(this); | ||
materialSkinManager.Theme = MaterialSkinManager.Themes.DARK; | ||
// materialSkinManager.ColorScheme = new ColorScheme(Primary.DeepPurple800, Primary.DeepPurple900, Primary.DeepPurple800, Accent.DeepPurple700, TextShade.WHITE); | ||
materialSkinManager.ColorScheme = new ColorScheme(Primary.Green800, Primary.Green900, Primary.Green800, Accent.Green700, TextShade.WHITE); | ||
|
||
|
||
|
||
|
||
} | ||
|
||
// MaterialSkinManager TManager = MaterialSkinManager.Instance; | ||
public void spotifytimertick(object sender) | ||
{ | ||
|
||
Thread t = new Thread(doSpotifyTimerTick); | ||
t.Start(); | ||
} | ||
private void doSpotifyTimerTick() | ||
{ | ||
|
||
|
||
|
||
if (materialSwitchDisplaySong.Checked==true&& materialSwitchChangeOnly.Checked==false) | ||
{ | ||
windowsMediaGetSongInfo(); | ||
} | ||
|
||
spotifyTimer.Change(5000, 0); | ||
|
||
|
||
} | ||
|
||
public async Task windowsMediaGetSongInfo() | ||
{ | ||
var theString = ""; | ||
this.Invoke((MethodInvoker)delegate () | ||
{ | ||
theString = materialTextBox1.Text.ToString(); | ||
|
||
|
||
theString = theString.Replace("{title}", WindowsMedia.mediaTitle); | ||
theString = theString.Replace("{artist}", WindowsMedia.mediaArtist); | ||
theString = theString.Replace("{progressMinutes}", WindowsMedia.getMediaProgress()); | ||
theString = theString.Replace("{durationMinutes}", WindowsMedia.getMediaDuration()); | ||
}); | ||
|
||
|
||
var messageSpeechBubble = new OscMessage("/chatbox/input", theString, true, false); | ||
OSCSender.Send(messageSpeechBubble); | ||
|
||
|
||
} | ||
|
||
private void VRCSongWiz_Load(object sender, EventArgs e) | ||
{ | ||
label1.ForeColor = Color.Red; | ||
materialSwitchDisplaySong.Checked = Settings1.Default.DisplaySong; | ||
materialSwitchChangeOnly.Checked = Settings1.Default.SongChangeOnly; | ||
WindowsMedia.getWindowsMedia(); | ||
spotifyTimer = new System.Threading.Timer(spotifytimertick); | ||
spotifyTimer.Change(5000, 0); | ||
|
||
} | ||
|
||
private void materialSwitchDisplaySong_CheckedChanged(object sender, EventArgs e) | ||
{ | ||
Settings1.Default.DisplaySong = materialSwitchDisplaySong.Checked; | ||
Settings1.Default.Save(); | ||
|
||
} | ||
|
||
private void materialSwitchChangeOnly_CheckedChanged(object sender, EventArgs e) | ||
{ | ||
Settings1.Default.SongChangeOnly = materialSwitchChangeOnly.Checked; | ||
Settings1.Default.Save(); | ||
} | ||
} | ||
} |
Oops, something went wrong.