Summary
Creates a new
IRenderTargetBitmapImpl
that can be used as a render layer
for the current render target.
- Namespace
- Avalonia
.Platform - Containing Type
- IDrawingContextImpl
Syntax
IDrawingContextLayerImpl CreateLayer(Size size)
Remarks
Depending on the rendering backend used, a layer created via this method may be more
performant than a standard render target bitmap. In particular the Direct2D backend
has to do a format conversion each time a standard render target bitmap is rendered,
but a layer created via this method has no such overhead.
Parameters
Name | Type | Description |
---|---|---|
size | Size | The size of the layer in DIPs. |
Return Value
Type | Description |
---|---|
I |
An IRenderTargetBitmapImpl |