[]
        
(Showing Draft Content)

GrapeCity.Documents.Imaging.GcBitmap.Load

Load Method

Load(Stream, int, Rectangle?)

Loads the image from a stream. JPEG, PNG, WEBP, GIF, BMP, TIFF, ICO, JPEG 2000 formats are supported.

Declaration
public void Load(Stream stream, int frameIndex = 0, Rectangle? imageRect = null)
Public Sub Load(stream As Stream, Optional frameIndex As Integer = 0, Optional imageRect As Rectangle? = Nothing)
Parameters
Type Name Description
Stream stream

The source stream.

int frameIndex

Index of an image frame to read, pass 0 for image formats not supporting multiple frames.

Rectangle? imageRect

Clipping rectangle of the image to be loaded.

Load(string, int, Rectangle?)

Loads the image from a file. JPEG, PNG, WEBP, GIF, BMP, TIFF, ICO, JPEG 2000 formats are supported.

Declaration
public void Load(string path, int frameIndex = 0, Rectangle? imageRect = null)
Public Sub Load(path As String, Optional frameIndex As Integer = 0, Optional imageRect As Rectangle? = Nothing)
Parameters
Type Name Description
string path

The file path to the image.

int frameIndex

Index of an image frame to read, pass 0 for image formats not supporting multiple frames.

Rectangle? imageRect

Clipping rectangle of the image to be loaded.

Load(byte[], int, Rectangle?)

Loads the image from a byte array. JPEG, PNG, WEBP, GIF, BMP, TIFF, ICO, JPEG 2000 formats are supported.

Declaration
public void Load(byte[] bytes, int frameIndex = 0, Rectangle? imageRect = null)
Public Sub Load(bytes As Byte(), Optional frameIndex As Integer = 0, Optional imageRect As Rectangle? = Nothing)
Parameters
Type Name Description
byte[] bytes

The image data.

int frameIndex

Index of an image frame to read, pass 0 for image formats not supporting multiple frames.

Rectangle? imageRect

Clipping rectangle of the image to be loaded.