private async void Sound_L_SelectionChanged(object sender, SelectionChangedEventArgs e) { if (Sound_L.SelectedIndex == -1 || IsClosing || IsBusy) { return; } Bass.BASS_ChannelStop(Stream); Bass.BASS_StreamFree(Stream); Message_T.Text = "ファイルを変換しています..."; await Task.Delay(50); string To_File = Voice_Set.Special_Path + "/Wwise/BNK_WAV_Special/" + Sound_L.Items[Sound_L.SelectedIndex]; if (IsPCKMode) { Wwise_PCK.Wwise_Extract_To_Ogg_File(uint.Parse(Sound_L.Items[Sound_L.SelectedIndex].ToString()), To_File + ".ogg", true); } else { Wwise_BNK.Wwise_Extract_To_Ogg_File(uint.Parse(Sound_L.Items[Sound_L.SelectedIndex].ToString()), To_File + ".ogg", true); } Message_T.Text = ""; string File_Name = Sub_Code.File_Get_FileName_No_Extension(To_File); Load_Sound(File_Name); Bass.BASS_ChannelPlay(Stream, false); IsPaused = false; }
private async void Sound_List_SelectionChanged(object sender, SelectionChangedEventArgs e) { if (IsClosing) { return; } if (Sound_List.SelectedIndex != -1) { Message_T.Opacity = 1; Message_T.Text = "サウンドファイルに変換しています..."; Bass.BASS_ChannelStop(Stream); Bass.BASS_StreamFree(Stream); await Task.Delay(50); if (IsPCKFile) { if (Wwise_Pck.Wwise_Extract_To_Ogg_File(Sound_List.SelectedIndex, Voice_Set.Special_Path + "/Wwise/Temp_02.ogg", true)) { Message_Feed_Out("変換しました。"); } else { Message_Feed_Out("変換できませんでした。"); } } else { if (Wwise_Bnk.Wwise_Extract_To_Ogg_File(Sound_List.SelectedIndex, Voice_Set.Special_Path + "/Wwise/Temp_02.ogg", true)) { Message_Feed_Out("変換しました。"); } else { Message_Feed_Out("変換できませんでした。"); } } } }