We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I have this code
<Border Width="200" Height="200" Loaded="Border_Loaded"/>
private void Border_Loaded(object sender, RoutedEventArgs e) { var color1 = new ColorSourceEffect() { Color = Windows.UI.Color.FromArgb(255, 255, 0, 0) }; var color2 = new ColorSourceEffect() { Color = Windows.UI.Color.FromArgb(255, 0, 255, 0) }; var crossFadeEffect = new CrossFadeEffect() { Source1 = color1, Source2 = color2, CrossFade = 0.0F }; var host = sender as UIElement; var compositor = ElementCompositionPreview.GetElementVisual(host).Compositor; var brush = compositor.CreateEffectFactory(crossFadeEffect).CreateBrush(); var visual = compositor.CreateSpriteVisual(); visual.Size = host.ActualSize; visual.Brush = brush; ElementCompositionPreview.SetElementChildVisual(host, visual); }
So apparently according to doc,
when CrossFade=0, it should outputs color1, which is Red, but it shows me color2 instead. How is this possible?
CrossFade=0
color1
color2
Reproduce here
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I have this code
So apparently according to doc,
when
CrossFade=0
, it should outputscolor1
, which is Red, but it shows mecolor2
instead. How is this possible?Reproduce here
The text was updated successfully, but these errors were encountered: