react-native-rectangle-doc-scanner 3.224.0 → 3.225.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -175,9 +175,9 @@ class CameraController(
|
|
|
175
175
|
|
|
176
176
|
val rotation = previewView.display?.rotation ?: Surface.ROTATION_0
|
|
177
177
|
|
|
178
|
-
// Build Preview ONLY
|
|
178
|
+
// Build Preview ONLY with minimal resolution to reduce HAL load
|
|
179
179
|
preview = Preview.Builder()
|
|
180
|
-
.setTargetResolution(Size(
|
|
180
|
+
.setTargetResolution(Size(640, 480))
|
|
181
181
|
.setTargetRotation(rotation)
|
|
182
182
|
.build()
|
|
183
183
|
.also {
|
|
@@ -199,11 +199,13 @@ class CameraController(
|
|
|
199
199
|
preview
|
|
200
200
|
)
|
|
201
201
|
|
|
202
|
-
Log.d(TAG, "[CAMERAX-
|
|
202
|
+
Log.d(TAG, "[CAMERAX-V9] Preview bound with 640x480 resolution")
|
|
203
|
+
Log.d(TAG, "[CAMERAX-V9] Waiting for capture session to configure...")
|
|
203
204
|
|
|
204
|
-
//
|
|
205
|
-
|
|
206
|
-
|
|
205
|
+
// Log session state after some time
|
|
206
|
+
android.os.Handler(android.os.Looper.getMainLooper()).postDelayed({
|
|
207
|
+
Log.d(TAG, "[CAMERAX-V9] Camera state check - preview should be working now")
|
|
208
|
+
}, 6000)
|
|
207
209
|
|
|
208
210
|
} catch (e: Exception) {
|
|
209
211
|
Log.e(TAG, "[CAMERAX-V8] Failed to bind preview", e)
|
|
@@ -78,7 +78,7 @@ class DocumentScannerView(context: ThemedReactContext) : FrameLayout(context), L
|
|
|
78
78
|
layoutParams = LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT)
|
|
79
79
|
visibility = View.VISIBLE
|
|
80
80
|
keepScreenOn = true
|
|
81
|
-
implementationMode = PreviewView.ImplementationMode.
|
|
81
|
+
implementationMode = PreviewView.ImplementationMode.COMPATIBLE
|
|
82
82
|
scaleType = PreviewView.ScaleType.FILL_CENTER
|
|
83
83
|
}
|
|
84
84
|
Log.d(TAG, "[INIT] PreviewView created: $previewView")
|
package/package.json
CHANGED