CompressedImage.CreateFromStream Method (Stream)

Creates a CompressedImage directly from a stream, keeping a PNG or JPEG source's encoded bytes as is instead of decoding and recompressing them.

Namespace: Aurigma.GraphicsMill
Assembly: Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)

Syntax

C#
public static CompressedImage CreateFromStream(
	Stream stream
)

Parameters

stream

Type: System.IO.Stream

A Stream containing the source image.

Return Value

A new CompressedImage instance. Its ColorStream reports Png or Jpeg to match the source; any other format falls back to decoding and re-compressing with Zip.

See Also

Reference