oneHamidreza/barcodescanner ? reverse-engineered prompt

Reverse engineered prompt

Build me an Android barcode scanner app and reusable scanner view library like the one in this repo, with both ZXing and ZBar options.

I want a simple screen that opens the camera, shows a live preview, and scans common codes like QR codes, UPC, EAN, Code 128, PDF417, and Data Matrix. When a code is found, show the text and barcode type clearly, then let the user keep scanning if they want. Please include basic controls for flash, autofocus, and switching between front and rear camera.

Make it easy to drop into an Activity or Fragment, with a straightforward sample app that demonstrates the full flow from camera permission to scanning to showing results. Keep the UI clean and minimal, similar to a practical scanner demo. If you need to look up current Android camera or permission best practices online, go ahead and do that.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab