Open kurular4 opened 5 years ago
Custom compress does not apply. Tried in different emulators & real devices and different images.
Without compression;
Image size: 6.1 MB
After default compression;
Image size: 2 MB
After custom compression the way given below;
new Compressor(context).setQuality(50).compressToBitmap(new File(filePath.getPath()));
or
new Compressor(context) .setQuality(75) .setMaxHeight(480) .setMaxWidth(640) .setCompressFormat(Bitmap.CompressFormat.WEBP).compressToBitmap(new File(filePath.getPath()));
Custom compress does not apply. Tried in different emulators & real devices and different images.
Without compression;
Image size: 6.1 MB
After default compression;
Image size: 2 MB
After custom compression the way given below;
Image size: 2 MB
new Compressor(context).setQuality(50).compressToBitmap(new File(filePath.getPath()));
or
new Compressor(context) .setQuality(75) .setMaxHeight(480) .setMaxWidth(640) .setCompressFormat(Bitmap.CompressFormat.WEBP).compressToBitmap(new File(filePath.getPath()));