Opait PDF Library
Static Public Member Functions | List of all members
Opait.Pdf.Api.GdiUtil Class Reference

Utility functions using GDI classes More...

Static Public Member Functions

static ImageCodecInfo GetImageEncoder (string extension)
 Gets the image encoder based on the file extension. More...
 
static ImageCodecInfo GetImageEncoder (ImageFormat format)
 Gets the GDI+ encoder for the specified image format. More...
 

Detailed Description

Utility functions using GDI classes

Member Function Documentation

◆ GetImageEncoder() [1/2]

static ImageCodecInfo Opait.Pdf.Api.GdiUtil.GetImageEncoder ( ImageFormat  format)
static

Gets the GDI+ encoder for the specified image format.

Parameters
formatThe image format.
Returns
The corresponding image encoder, or null if not supported.

◆ GetImageEncoder() [2/2]

static ImageCodecInfo Opait.Pdf.Api.GdiUtil.GetImageEncoder ( string  extension)
static

Gets the image encoder based on the file extension.

Parameters
extensionThe file extension of the image file.
Returns
The corresponding image encoder, or null if not supported.