extract bits from qr image