I need to create a QR Code following configuration below:
- Model 2
- Version 10
- Size 57 x 57
- Level H (30%)
- Max 174 alphanumeric characters or 119 binary
- Modules size 0.03 inch
Actually, I'm using zxing to create the QR but I can't figure out how to set these 3 configurations
- Model 2
- Max 174 alphanumeric characters or 119 binary
- Modules size 0.03 inch
And this the code I'm using (Kotlin)
imgQrCode.run{setImageBitmap(BarcodeEncoder().createBitmap(
MultiFormatWriter().encode(content,
BarcodeFormat.QR_CODE,
57, 57,
mapOf<EncodeHintType, Any>(
Pair(EncodeHintType.QR_VERSION, 10),
Pair(EncodeHintType.ERROR_CORRECTION, ErrorCorrectionLevel.H)
))))}
Any idea how can I set those configurations with zxing or is there any alternative option to archive all the factors above?
Model 2
ZXing appears to be supporting Model 2 QR Code as the code: https://github.com/zxing/zxing/blob/master/core/src/main/java/com/google/zxing/qrcode/encoder/Encoder.java#L280
seems to handle versions 1 through 40. Model 1 only goes up to version 14.
Max 174 alphanumeric characters or 119 binary
Modules size 0.03 inch