PeachDrawing

PeachDrawing.RasterSurfaceEncoding

RasterSurfaceEncoding.EncodePng(RasterSurface, bool) Method

Encodes surface as a lossless PNG (byte-for-byte IDAT the PDF writer’s existing PNG pass-through can embed directly, with a split-out alpha plane when there is alpha). A fully opaque surface is encoded without an alpha channel.

public static byte[] EncodePng(PeachDrawing.Core.RasterSurface surface, bool opaque);

Parameters

surface RasterSurface

opaque System.Boolean

Returns

System.Byte[]