Open AmitParmar2005 opened 1 month ago
You should not install any other ANGLE library - it is included in the package.
Let me know if removing ANGLE and rebuilding after deleting the bin/obj fixes this.
I'm running into the same problem. All I did was: create a new WinUI-project (in this case a Uno-App), add the SkiaSharp.Views.Uno.WinUI
-package and the following code:
xmlns:skia="using:SkiaSharp.Views.Windows"
<skia:SKSwapChainPanel PaintSurface="SKSwapChainPanel_PaintSurface" Height="200" Width="200"/>
Then I get the exact same error as mentioned above.
I was able to make it running. Dont install Uno package. Install WinUI Package. Here's the screenshot. Please let me know if you want me to upload entire project.
Thanks @AmitParmar2005 - but that does not seem to help in my case. I don't get the SKSwapChainPanel
to work on Uno. I tried adding SkiaSharp itself, switchting to preview 2.1 (like you have above) - but none works. I always get the error above as soon as I add an SKSwapChainPanel
-Control to my page.
Try the attached zip file. Its very simple working sample. Let me know if you still have any issues.
That works here, too. But I don't get it to work together with Uno-platform.
I am not sure about Uno-Platform. I never worked on it. I will check it out and get back to you.
Awesome, thanks!
Description
Hi Friends,
First of all thank you so much for porting SKSwapChainPanel to WinUI3. I have been waiting for it for very long time.
To test new functionalities, I created a simple program which uses SKSwapChainPanel. I have installed Skiasharp.Views.WinUI (3.0.0-preview 2.1) nuget package. But, when I run the application, I get System.AccessViolationException: 'Attempted to read or write protected memory.
Seems, I have installed all required packages.
I have also build and install angle with vcpkg. Without any luck.
Can somebody please help me what I am missing here? Please let me know if you want me to upload project.
Thanks and Regards, Amit
Code
The best way to share code for larger projects is a link to a GitHub repository: https://github.com/user/repo/tree/bug-123
But, you can also share a short block of code here:
You can also share some XAML:
<Window x:Class="WINUI_SkiaSharp_SKSwap_Test.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:local="using:WINUI_SkiaSharp_SKSwap_Test" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:skia="using:SkiaSharp.Views.Windows" mc:Ignorable="d">
Expected Behavior
I should not throw an expception
Actual Behavior
Throws an exception
Version of SkiaSharp
3.x (Alpha)
Last Known Good Version of SkiaSharp
2.88.2 (Previous)
IDE / Editor
Visual Studio (Windows)
Platform / Operating System
Windows
Platform / Operating System Version
Windows 10
Devices
Windows 10 Laptop
Relevant Screenshots
No response
Relevant Log Output
No response
Code of Conduct