I've a Barcode Scanner app that using (Barcode Detection with the Google Mobile Vision API) in camera activity i want to set a frame so the app just read barcodes or QRcodes which is in that frame (like all scanner apps) how can i customize it?
here is camera xml layout:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".ScanBarcodeActivity">
<SurfaceView
android:id="@+id/cammeraPreview"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</LinearLayout>