Browse Source
Merge pull request #1697 from AvaloniaUI/ghosting-fix
Fix ghosting artifacts
pull/1863/head
Jeremy Koritzinsky
8 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
5 additions and
1 deletions
-
src/Avalonia.Visuals/Rendering/DeferredRenderer.cs
-
src/Avalonia.Visuals/Rendering/ImmediateRenderer.cs
-
src/Windows/Avalonia.Direct2D1/SwapChainRenderTarget.cs
|
|
|
@ -337,6 +337,8 @@ namespace Avalonia.Rendering |
|
|
|
|
|
|
|
private void RenderComposite(Scene scene, IDrawingContextImpl context) |
|
|
|
{ |
|
|
|
context.Clear(Colors.Transparent); |
|
|
|
|
|
|
|
var clientRect = new Rect(scene.Size); |
|
|
|
|
|
|
|
foreach (var layer in scene.Layers) |
|
|
|
|
|
|
|
@ -54,6 +54,8 @@ namespace Avalonia.Rendering |
|
|
|
{ |
|
|
|
using (var context = new DrawingContext(_renderTarget.CreateDrawingContext(this))) |
|
|
|
{ |
|
|
|
context.PlatformImpl.Clear(Colors.Transparent); |
|
|
|
|
|
|
|
using (context.PushTransformContainer()) |
|
|
|
{ |
|
|
|
Render(context, _root, _root.Bounds); |
|
|
|
|
|
|
|
@ -118,7 +118,7 @@ namespace Avalonia.Direct2D1 |
|
|
|
new BitmapProperties1( |
|
|
|
new PixelFormat |
|
|
|
{ |
|
|
|
AlphaMode = AlphaMode.Ignore, |
|
|
|
AlphaMode = AlphaMode.Premultiplied, |
|
|
|
Format = Format.B8G8R8A8_UNorm |
|
|
|
}, |
|
|
|
_savedDpi.Width, |
|
|
|
|