Module: stdgo.image.png
Overview
Index
-
function decode(_r:stdgo._internal.io.Reader):stdgo.Tuple<stdgo._internal.image.Image, stdgo.Error>
-
function encode(_w:stdgo._internal.io.Writer, _m:stdgo._internal.image.Image):stdgo.Error
Constants
import stdgo.image.png.Png
final bestCompression:stdgo.image.png.CompressionLevel = stdgo._internal.image.png.Png_bestCompression.bestCompression
final bestSpeed:stdgo.image.png.CompressionLevel = stdgo._internal.image.png.Png_bestSpeed.bestSpeed
final defaultCompression:stdgo.image.png.CompressionLevel = stdgo._internal.image.png.Png_defaultCompression.defaultCompression
final noCompression:stdgo.image.png.CompressionLevel = stdgo._internal.image.png.Png_noCompression.noCompression
Classes
import stdgo.image.png.*
class Png
Package png implements a PNG image decoder and encoder.
The PNG specification is at https://www.w3.org/TR/PNG/.
Png function decode
function decode(_r:stdgo._internal.io.Reader):stdgo.Tuple<stdgo._internal.image.Image, stdgo.Error>
Decode reads a PNG image from r and returns it as an image.Image.
The type of Image returned depends on the PNG contents.
Png function decodeConfig
function decodeConfig(_r:stdgo._internal.io.Reader):stdgo.Tuple<stdgo._internal.image.Config, stdgo.Error>
DecodeConfig returns the color model and dimensions of a PNG image without
decoding the entire image.
Png function encode
function encode(_w:stdgo._internal.io.Writer, _m:stdgo._internal.image.Image):stdgo.Error
Encode writes the Image m to w in PNG format. Any Image may be
encoded, but images that are not image.NRGBA might be encoded lossily.
Typedefs
import stdgo.image.png.*
typedef CompressionLevel
typedef CompressionLevel = stdgo._internal.image.png.CompressionLevel;
typedef EncoderBuffer
typedef EncoderBuffer = stdgo._internal.image.png.EncoderBuffer;
typedef EncoderBufferPool
typedef EncoderBufferPool = stdgo._internal.image.png.EncoderBufferPool;
typedef FormatError
typedef FormatError = stdgo._internal.image.png.FormatError;
typedef T_opaquer
typedef T_opaquer = stdgo._internal.image.png.T_opaquer;
typedef UnsupportedError
typedef UnsupportedError = stdgo._internal.image.png.UnsupportedError;