Skip to content

ScratchSurfaceExtensions.AcquireScratchSurface method

Returns a surface at least pixelWidth x pixelHeight, reusing a pooled one when available. Content is undefined. Hand it back via ReleaseScratchSurface instead of disposing.

public static IRenderSurface AcquireScratchSurface(this IRenderDevice device, int pixelWidth,
int pixelHeight, double dpiScale = 1m, bool hasAlpha = true, string? debugName = null)