ImageDevice

Overview

ImageDevice is a class in Aspose.PDF FOSS for .NET.

Abstract base class for image rendering devices (PNG, JPEG, BMP, TIFF).

This class provides 10 methods for working with ImageDevice objects in .NET programs. Available methods include: GetBitmap, ImageDevice, 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, Width.

Properties

NameTypeAccessDescription
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
ImageDevice(resolution: Resolution)Initializes a new ImageDevice with a Resolution using the built-in SoftwarePageRenderer.
ImageDevice()Initializes a new ImageDevice with default resolution and built-in SoftwarePageRenderer.
ImageDevice(width: int, height: int)Initializes a new ImageDevice with explicit output pixel dimensions using the built-in SoftwarePageRenderer at default resolution (150 DPI).
ImageDevice(width: int, height: int, resolution: Resolution)Initializes a new ImageDevice with explicit output pixel dimensions and rendering resolution using the built-in SoftwarePageRenderer.
ImageDevice(pageSize: Aspose.Pdf.PageSize)Initialize from a PageSize (in points; converted to integer pixel dimensions at the default 150 DPI).
ImageDevice(pageSize: Aspose.Pdf.PageSize, resolution: Resolution)Initialize from a PageSize and rendering Resolution.
GetBitmap(page: Page)Render a page to a Bitmap.
Process(page: Page, output: Stream)Convert a page to image bytes and write to stream.
Process(page: Page, outputFileName: string)Convert a page to an image file.
Process(page: Page)Convert a page to image bytes.

See Also