PngDevice

Overview

PngDevice is a class in Aspose.PDF FOSS for .NET. Inherits from: ImageDevice.

Renders PDF document pages into PNG image format.

This class provides 11 methods for working with PngDevice objects in .NET programs. Available methods include: GetBitmap, ImageDevice, PngDevice, Process. All public members are accessible to any .NET application after installing the Aspose.PDF FOSS for .NET package. Properties: CoordinateType, FormPresentationMode, Height, RenderingOptions, Resolution, TransparentBackground, and 1 more.

Properties

NameTypeAccessDescription
TransparentBackgroundboolRead/WriteWhen true, the rendered PNG keeps the page background transparent.
ResolutionResolutionReadOutput resolution in DPI.
RenderingOptionsAspose.Pdf.RenderingOptionsRead/WriteRendering options for advanced control of page-to-image rendering.
CoordinateTypePageCoordinateTypeRead/WriteWhich page box drives the rendered image extents.
WidthintReadConfigured target pixel width (0 = follow the page’s natural size at Resolution).
HeightintReadConfigured target pixel height (0 = follow the page’s natural size at Resolution).
FormPresentationModeFormPresentationModeRead/WriteHow form fields render (Production vs Editor).

Methods

SignatureDescription
PngDevice(renderer: IPageRenderer)Calls PngDevice on this PngDevice instance.
PngDevice(renderer: IPageRenderer, resolution: Resolution)
PngDevice()
PngDevice(resolution: Resolution)
PngDevice(width: int, height: int)
PngDevice(width: int, height: int, resolution: Resolution)
PngDevice(pageSize: Aspose.Pdf.PageSize)Construct sized to the given pageSize at 150 DPI.
PngDevice(pageSize: Aspose.Pdf.PageSize, resolution: Resolution)Construct sized to pageSize at the requested resolution.
Process(page: Page, output: Stream)Calls Process on this PngDevice instance.
ImageDevice(resolution: Resolution)Initializes a new ImageDevice with a Resolution using the built-in SoftwarePageRenderer.
GetBitmap(page: Page)Render a page to a Bitmap.

See Also