All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.ag.granular.tiff.compression.CompressionEncoder.kt Maven / Gradle / Ivy

The newest version!
package ag.granular.tiff.compression

import ag.granular.io.ByteOrder

/**
 * Compression encoder interface. Encode either on a per row or block basis
 */
interface CompressionEncoder {

    /**
     * True to encode on a per row basis, false to encode on a per block / strip
     * basis
     *
     * @return true for row encoding
     */
    fun rowEncoding(): Boolean

    /**
     * Encode the bytes
     *
     * @param bytes
     * bytes to encode
     * @param byteOrder
     * byte order
     * @return encoded block of bytes
     */
    fun encode(bytes: ByteArray, byteOrder: ByteOrder): ByteArray
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy