JxrEncodeOptions

class JxrEncodeOptions(val quality: Int = 90, val lossless: Boolean = false, val chroma: JxrChroma = JxrChroma.Auto, val overlap: Int? = null, val chromaQuality: Int? = null, val planarAlpha: Boolean = true, val alphaLossless: Boolean = true, val alphaQuality: Int = 90, val tileSize: Int = 0, tileQualities: List<Int>? = null, val frequencyOrder: Boolean = false)(source)

The settings of a JPEG XR encode (#181), for ImageKodec.encodeJxr, ImageKodec.encodeJxr16 and ImageKodec.encodeJxrCmyk.

Throws

if a value is out of its range

Constructors

Link copied to clipboard
constructor(quality: Int = 90, lossless: Boolean = false, chroma: JxrChroma = JxrChroma.Auto, overlap: Int? = null, chromaQuality: Int? = null, planarAlpha: Boolean = true, alphaLossless: Boolean = true, alphaQuality: Int = 90, tileSize: Int = 0, tileQualities: List<Int>? = null, frequencyOrder: Boolean = false)

Properties

Link copied to clipboard

code alpha exactly, as JxrEncApp does by default; otherwise at alphaQuality.

Link copied to clipboard

0 to 100, the quality of a lossy alpha plane.

Link copied to clipboard

4:4:4 or 4:2:0 colour; lossless and 16-bit encodes always keep it full.

Link copied to clipboard

the quality of the two chroma channels on their own, or null for the offset from quality that the encoder picks: a quantizer per channel.

Link copied to clipboard

write each tile as four packets, DC, lowpass, highpass and flexbits (T.832 FREQUENCY_MODE_CODESTREAM_FLAG), which a decoder can stop reading early, in place of one packet in spatial order.

Link copied to clipboard

code with a quantizer of 1, without overlap filtering: the file decodes to the input exactly, at every depth and channel count.

Link copied to clipboard
val overlap: Int?

the overlap filtering of T.832 (OVERLAP_MODE): 0 for none, 1 for the first level, 2 for both levels; null picks 1 from quality 50 up and 2 below, as JxrEncApp does, and 0 when lossless.

Link copied to clipboard

store alpha as a codestream of its own after the image (T.832 A.7.17), as JxrEncApp does by default, or with false, as a plane interleaved with the colour, macroblock by macroblock.

Link copied to clipboard

0 to 100, higher is better, as JxrEncApp -q reads a value of quality divided by 100: it picks the quantizer of each band and channel. Ignored when lossless.

Link copied to clipboard

a quality for each tile in raster order, overriding quality there: quantizers per tile. Null keeps one quantizer for the whole image.

Link copied to clipboard

the side of a tile in pixels, a multiple of 16, or 0 for one tile. Each tile is a packet of its own that the index table points to; the overlap filter runs across tile edges (soft tiles).