gsdsdk / com.gsd.software.sdk.imageCompression / ImageCompressor

ImageCompressor

class ImageCompressor

Created by jmielczarek on 10.10.2018.

Constructors

Name Summary
<init> ImageCompressor()
Created by jmielczarek on 10.10.2018.

Functions

Name Summary
calculateDimensions fun calculateDimensions(compressionLevel:Int, originalWidth:Int, originalHeight:Int):ImageDimension
compressImage fun compressImage(context:Context, file:File, compressionLevel:CompressionLevel):File
getNormalizationMultiplier fun getNormalizationMultiplier(resolutionMultiplier:Double, maxWidth:Int, maxHeight:Int):Double

Companion Object Properties

Name Summary
JPEG_EXTENSIONS val JPEG_EXTENSIONS: <ERROR CLASS>
MAX_COMPRESSION_LEVEL const val MAX_COMPRESSION_LEVEL:Int
MIN_SIZE const val MIN_SIZE:Int
MULTIPLIER_INITIAL_VALUE const val MULTIPLIER_INITIAL_VALUE:Double
NORMALIZATION_FACTOR const val NORMALIZATION_FACTOR:Double
PNG_EXTENSION const val PNG_EXTENSION:String
QUALITY_THRESHOLD const val QUALITY_THRESHOLD:Int
REDUCTION_FACTOR const val REDUCTION_FACTOR:Double
WEBP_EXTENSION const val WEBP_EXTENSION:String