Click or drag to resize
CanvasVirtualImageSource Constructor (ICanvasResourceCreator, Single, Single, Single, CanvasAlphaMode)
Initializes a new instance of the CanvasVirtualImageSource class.

Namespace:  Microsoft.Graphics.Canvas.UI.Xaml
Assembly:  Microsoft.Graphics.Canvas (in Microsoft.Graphics.Canvas.dll) Version: 0.0.0.0
Syntax
C#
public CanvasVirtualImageSource(
	ICanvasResourceCreator resourceCreator,
	float width,
	float height,
	float dpi,
	CanvasAlphaMode alphaMode
)

Parameters

resourceCreator
Type: Microsoft.Graphics.CanvasICanvasResourceCreator
width
Type: SystemSingle
height
Type: SystemSingle
dpi
Type: SystemSingle
alphaMode
Type: Microsoft.Graphics.CanvasCanvasAlphaMode
Remarks

Size is in device independent pixels (DIPs), using the specified DPI.

The alphaMode parameter determines whether the background of the image source is opaque or not. An opaque image source is slightly more efficient than a transparent image source. CanvasAlphaMode.Ignore indicates an opaque background, while CanvasAlphaMode.Premultiplied indicates a transparent background. Passing CanvasAlphaMode.Straight to this parameter will result in an error.

See Also