CompositionVirtualDrawingSurface CompositionVirtualDrawingSurface CompositionVirtualDrawingSurface Class


Represents sparsely allocated bitmaps that can be associated with visuals for composition in a visual tree.�

public class CompositionVirtualDrawingSurface : CompositionDrawingSurface, ICompositionVirtualDrawingSurfacepublic class CompositionVirtualDrawingSurface : CompositionDrawingSurface, ICompositionVirtualDrawingSurfacePublic Class CompositionVirtualDrawingSurface Inherits CompositionDrawingSurface Implements ICompositionVirtualDrawingSurface
Windows 10 requirements
Device family
Windows 10 Creators Update (introduced v10.0.15063.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v4)

Inherited Members

Inherited properties

Inherited methods


The virtual drawing surface is designed for usage in scenarios where an application needs to define a large amount of content but only expects a small portion of content to be visible to a user at a given time. For example, think of a long scrolling document or webpage.� In such cases, the app only needs to draw the part of the surface that is currently visible to the user, and can defer drawing portions that are not visible until later when they become visible.


Trim(RectInt32[]) Trim(RectInt32[]) Trim(RectInt32[])

Clears portions of a virtual drawing surface that were previously defined. Areas that are cleared will be treated as empty once again, and video memory that was previously backing them will be reclaimed.

public void Trim(RectInt32[] rects)public void Trim(RectInt32[] rects)Public Function Trim(rects As RectInt32[]) As void
Windows.Graphics.RectInt32[] Windows.Graphics.RectInt32[] Windows.Graphics.RectInt32[]

The region of the drawing surface to trim.