Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: temporary solution for the audio stuttering issue #433

Merged
merged 1 commit into from
Aug 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Screenbox.Core/Screenbox.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@
<Version>8.2.2</Version>
</PackageReference>
<PackageReference Include="LibVLCSharp">
<Version>3.9.0</Version>
<Version>3.7.0</Version>
</PackageReference>
<PackageReference Include="Microsoft.UI.Xaml">
<Version>2.8.6</Version>
Expand Down
6 changes: 3 additions & 3 deletions Screenbox.Core/packages.lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@
},
"LibVLCSharp": {
"type": "Direct",
"requested": "[3.9.0, )",
"resolved": "3.9.0",
"contentHash": "wydvN5kotK5y/ZRC04/F6YUqesJCzdixaItRkR8L0/nOLSs2/BJ7rKRbU7BxkxpKIBqlN8EpuXxH/fQEZEHtuw==",
"requested": "[3.7.0, )",
"resolved": "3.7.0",
"contentHash": "N9NV+BamKr+1YiRktX9JroE4m9C+pEszUNW4qa3A5mychhCWBvvoDolZKWk2yxhZvHewgaXXahBcw5ivCXjKYA==",
"dependencies": {
"System.Memory": "4.5.4"
}
Expand Down
2 changes: 0 additions & 2 deletions Screenbox/Controls/PlayerElement.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@
xmlns:vlcSharp="using:LibVLCSharp.Platforms.Windows"
d:DesignHeight="300"
d:DesignWidth="400"
Loaded="PlayerElement_OnLoaded"
Unloaded="PlayerElement_OnUnloaded"
mc:Ignorable="d">

<Grid
Expand Down
29 changes: 14 additions & 15 deletions Screenbox/Controls/PlayerElement.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using CommunityToolkit.Mvvm.DependencyInjection;
using LibVLCSharp.Platforms.Windows;
using Screenbox.Core.ViewModels;
using System;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI.Xaml.Input;
Expand Down Expand Up @@ -55,19 +54,19 @@ private void VideoViewButton_OnDoubleTapped(object sender, DoubleTappedRoutedEve
Click?.Invoke(sender, e);
}

private void PlayerElement_OnLoaded(object sender, RoutedEventArgs e)
{
ViewModel.ClearViewRequested += ViewModelOnClearViewRequested;
}

private void PlayerElement_OnUnloaded(object sender, RoutedEventArgs e)
{
ViewModel.ClearViewRequested -= ViewModelOnClearViewRequested;
}

private void ViewModelOnClearViewRequested(object sender, EventArgs e)
{
VlcVideoView.Clear();
}
// private void PlayerElement_OnLoaded(object sender, RoutedEventArgs e)
// {
// ViewModel.ClearViewRequested += ViewModelOnClearViewRequested;
// }
//
// private void PlayerElement_OnUnloaded(object sender, RoutedEventArgs e)
// {
// ViewModel.ClearViewRequested -= ViewModelOnClearViewRequested;
// }
//
// private void ViewModelOnClearViewRequested(object sender, EventArgs e)
// {
// VlcVideoView.Clear();
// }
}
}
6 changes: 3 additions & 3 deletions Screenbox/packages.lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,8 @@
},
"LibVLCSharp": {
"type": "Transitive",
"resolved": "3.9.0",
"contentHash": "wydvN5kotK5y/ZRC04/F6YUqesJCzdixaItRkR8L0/nOLSs2/BJ7rKRbU7BxkxpKIBqlN8EpuXxH/fQEZEHtuw==",
"resolved": "3.7.0",
"contentHash": "N9NV+BamKr+1YiRktX9JroE4m9C+pEszUNW4qa3A5mychhCWBvvoDolZKWk2yxhZvHewgaXXahBcw5ivCXjKYA==",
"dependencies": {
"SharpDX.Direct3D11": "4.2.0",
"System.Memory": "4.5.4",
Expand Down Expand Up @@ -521,7 +521,7 @@
"CommunityToolkit.Diagnostics": "[8.2.2, )",
"CommunityToolkit.Mvvm": "[8.2.2, )",
"CommunityToolkit.Uwp.Extensions": "[8.1.240821, )",
"LibVLCSharp": "[3.9.0, )",
"LibVLCSharp": "[3.7.0, )",
"Microsoft.AppCenter.Analytics": "[5.0.5, )",
"Microsoft.AppCenter.Crashes": "[5.0.5, )",
"Microsoft.Extensions.DependencyInjection.Abstractions": "[8.0.1, )",
Expand Down