Win2D is an easy-to-use Windows Runtime API for immediate mode 2D graphics rendering with GPU acceleration. It is available to C#, C++ and VB developers writing apps for the Windows Universal Platform (UWP). It utilizes the power of Direct2D, and integrates seamlessly with XAML and CoreWindow.
I've disabled page navigation animations on a navigation view and replaced them with my own scheme that fades out the old page and fades in the new one (the novelty of the swipe animation wore off quite quickly; after a thousand times, it started to get quite irritating).
The fading is controlled by a storyboard animation that animates the pages opacity property.
Unfortunately if the page contains a CanvasSwapChainPanel, the swap chain won't draw until the pages opacity has finished animating to 1 and will disappear immediately when the opacity starts decreasing. A CanvasControl works as expected, updating with the animation.
Page1 contains a CanvasSwapChainPanel, Page2 contains a CanvasControl.
The pages opacity value is shown animating on the left hand side of both pages.
The animations duration has been set to 3 seconds so that it's obvious what's happening.
It uses nuget packages:
Project Reunion version 0.8.2
Microsoft.Graphics.Win2D version 0.8.2.23
Hi @DHancock, apologies for the delayed response here. Thank you for the detailed issue! We've filed an internal bug for this and are actively investigating it. We'll keep you posted!
I've disabled page navigation animations on a navigation view and replaced them with my own scheme that fades out the old page and fades in the new one (the novelty of the swipe animation wore off quite quickly; after a thousand times, it started to get quite irritating).
The fading is controlled by a storyboard animation that animates the pages opacity property.
Unfortunately if the page contains a CanvasSwapChainPanel, the swap chain won't draw until the pages opacity has finished animating to 1 and will disappear immediately when the opacity starts decreasing. A CanvasControl works as expected, updating with the animation.
I've attached a min repro project:
SwapChainOpacityIssue.zip
Page1 contains a CanvasSwapChainPanel, Page2 contains a CanvasControl. The pages opacity value is shown animating on the left hand side of both pages. The animations duration has been set to 3 seconds so that it's obvious what's happening.
It uses nuget packages:
I'm running windows 21H1 (19043.1165)