PageRenderAsInts Method (Int32, Int32, Int32, RenderingSettings, ErrorLogger)

Apitron PDF Rasterizer help
Apitron.PDF.Rasterizer library for .NET
Renders the specified page to an image represented by array of integers with pixel format ARGB8888(hence one array element represents one pixel), the stride width would be desiredWidth in this case.

Namespace:  Apitron.PDF.Rasterizer
Assembly:  Apitron.PDF.Rasterizer (in Apitron.PDF.Rasterizer.dll) Version: 3.0.154.0 (3.0.154.0)
Syntax

public int[] RenderAsInts(
	int desiredWidth,
	int desiredHeight,
	int[] bitmap,
	RenderingSettings settings,
	ErrorLogger errorLogger = null
)

Parameters

desiredWidth
Type: SystemInt32
Width of the resulting image, should be greater than zero.
desiredHeight
Type: SystemInt32
Height of the resulting image, should be greater than zero.
bitmap
Type: SystemInt32
The bitmap data. This data should have the size equal to desiredWidth * desiredHeight
settings
Type: Apitron.PDF.Rasterizer.ConfigurationRenderingSettings
The rendering settings, can't be null.
errorLogger (Optional)
Type: Apitron.PDF.Rasterizer.ErrorHandlingErrorLogger
An optional error logger object.

Return Value

Type: Int32
A bitmap representing content of the page, any errors encountered will be logged to errorLogger if present. If rendering fails null will be returned.
Exceptions

ExceptionCondition
ArgumentExceptionWidth and Height can't be negative or zero.
ArgumentNullExceptionsettings
ArgumentExceptionIf desiredWidth or desiredHeight are zero or less.
ArgumentNullExceptionIf bitmap is null.
ArgumentNullExceptionIf settings is null.
See Also

Reference