iOS Guides | Samples

CoreGraphics.CGLayer Class

A hardware accelerated context.

See Also: CGLayer

Syntax

public class CGLayer : INativeObject, IDisposable

Remarks

CGLayers can be hardware accelerated and developers are encouraged to use this instead of CGBitmaps for off-screen rendering operations.

To create CGLayers, use the CGLayer.Create method.

Once you create a CGLayer, you extract the CGContext instance by accessing the Context property.

Related content

Requirements

Namespace: CoreGraphics
Assembly: Xamarin.iOS (in Xamarin.iOS.dll)
Assembly Versions: 0.0.0.0

The members of CoreGraphics.CGLayer are listed below.

See Also: Object

Public Properties

[read-only]
ContextCGContext. Returns the graphics context associated with this layer.
[read-only]
HandleIntPtr. Handle (pointer) to the unmanaged object representation.
[read-only]
SizeCGSize. The size of the CGLayer

Public Methods

static
Create(CGContext, CGSize) : CGLayer
Creates a new CGLayer object with the specified graphics context and size
Dispose()
Releases the resources used by the CGLayer object.
Finalize()
Finalizer for the CGLayer object

Protected Methods

Dispose(Boolean)
Releases the resources used by the CGLayer object.