ThalesGroup / WSQForAndroid

A WSQ image encoder/decoder for Android
BSD 2-Clause "Simplified" License
18 stars 14 forks source link

WSQ for Android


An open-source WSQ image encoder/decoder for Android based on NBIS v5.0.0.

Usage

Decoding an image:

Bitmap bmp = WSQDecoder.decode(wsqData).getBitmap();
imgView.setImageBitmap(bmp);

Encoding an image:

Bitmap bmp = ...;
//higher-quality encode
byte[] wsqData = new WSQEncoder(bmp)
                     .setBitrate(WSQEncoder.BITRATE_5_TO_1)
                     .encode();
//lower-quality encode
byte[] wsqData = new WSQEncoder(bmp)
                     .setBitrate(WSQEncoder.BITRATE_15_TO_1)
                     .encode();

Set up

Add dependency to your build.gradle

implementation 'com.gemalto.wsq:wsq-android:1.2'