PeachImage
PeachImage.Formats.Png
PngAlphaSplit Class
Splits a PNG’s interleaved color+alpha IDAT data into two independent, ready-to-embed zlib
(RFC 1950) streams — a color-only plane and a DeviceGray alpha-only plane — for callers that want
to build a PDF color XObject + /SMask pair without doing a full Rgba32
pixel decode. See TrySplit(PngPassthroughInfo, PngAlphaSplitInfo).
public static class PngAlphaSplit
Inheritance System.Object → PngAlphaSplit
| Methods | |
|---|---|
| TryRead(Stream, PngAlphaSplitInfo) | Reads a PNG from stream (via TryRead(Stream, PngPassthroughInfo)) and splits it. Never throws. |
| TrySplit(PngPassthroughInfo, PngAlphaSplitInfo) | Attempts to split the alpha channel out of an already-read passthrough (e.g. from TryRead(Stream, PngPassthroughInfo)). Returns false (never throws) when the source isn’t eligible. |