Skip to content

PDFRenderingSurface

Namespace: O2S.Components.PDF4NET.Rendering.RenderingSurfaces

Defines an abstract rendering surface.

public abstract class PDFRenderingSurface : O2S.Components.PDF4NET.Content.IImageDataProvider

Inheritance ObjectPDFRenderingSurface
Implements IImageDataProvider

Fields

Constructors

PDFRenderingSurface()

Initializes a new PDFRenderingSurface object.

public PDFRenderingSurface()

Properties

Height

Gets or sets the surface height.

public int Height { get; }

Property Value

Int32
The height of the surface in pixels.


Width

Gets the surface width.

public int Width { get; }

Property Value

Int32
The width of the surface in pixels.


Methods

ConvertFromBgra()

Converts the surface from BGRA to its native format.

public void ConvertFromBgra()

Remarks

Aurora Native and GDI+ engines use BGRA format, Aurora Managed uses ARGB int and BGRA byte.


ConvertFromRgba()

Converts the surface from BGRA to its native format.

public void ConvertFromRgba()

Remarks

Aurora CoreGraphics uses RGBA byte format.


FlipVertical()

Flips the surface bottom-up

public void FlipVertical()

Save(String, PDFPageImageFormat)

Saves the rendering surface to the specified file.

public void Save(string fileName, PDFPageImageFormat format)

Parameters

fileName String
Path to file where the rendering surface is saved.

format PDFPageImageFormat
Image format for saving the rendering surface


Save(String, PDFRendererSettings, PDFPageImageFormat)

Saves the rendering surface to the specified file.

public void Save(string fileName, PDFRendererSettings settings, PDFPageImageFormat format)

Parameters

fileName String
Path to file where the rendering surface is saved.

settings PDFRendererSettings
The settings that were used when the rendering surface was generated

format PDFPageImageFormat
Image format for saving the rendering surface


Save(Stream, PDFPageImageFormat)

Saves the rendering surface to the specified stream.

public void Save(Stream stream, PDFPageImageFormat format)

Parameters

stream Stream
Stream where the rendering surface is saved.

format PDFPageImageFormat
Image format for saving the rendering surface


Save(Stream, PDFRendererSettings, PDFPageImageFormat)

Saves the rendering surface to the specified stream.

public void Save(Stream stream, PDFRendererSettings settings, PDFPageImageFormat format)

Parameters

stream Stream
Stream where the rendering surface is saved.

settings PDFRendererSettings
The settings that were used when the rendering surface was generated

format PDFPageImageFormat
Image format for saving the rendering surface