Table of Contents

Method SaveAsJpegBytes

Namespace
LMKit.Media.Image
Assembly
LM-Kit.NET.dll

SaveAsJpegBytes(int)

Saves the image as JPEG to a byte array without writing to disk.

public byte[] SaveAsJpegBytes(int quality = 90)

Parameters

quality int

JPEG quality level (0 to 100). Default is 90.

Returns

byte[]

A byte array containing the JPEG-encoded image data.

Exceptions

ObjectDisposedException

Thrown if this instance has been disposed.

InvalidOperationException

Thrown if encoding fails.

Share