react-native-rectangle-doc-scanner 3.205.0 → 3.206.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.
|
@@ -269,7 +269,11 @@ class CameraController(
|
|
|
269
269
|
|
|
270
270
|
previewSize = choosePreviewSize(previewChoices, targetRatio)
|
|
271
271
|
analysisSize = chooseAnalysisSize(analysisChoices, targetRatio)
|
|
272
|
-
Log.d(
|
|
272
|
+
Log.d(
|
|
273
|
+
TAG,
|
|
274
|
+
"[CAMERA2] chooseCamera view=${viewWidth}x${viewHeight} ratio=$targetRatio " +
|
|
275
|
+
"sensorOrientation=$sensorOrientation preview=$previewSize analysis=$analysisSize"
|
|
276
|
+
)
|
|
273
277
|
}
|
|
274
278
|
|
|
275
279
|
private fun openCamera() {
|
|
@@ -320,6 +324,12 @@ class CameraController(
|
|
|
320
324
|
val previewSize = sizes.first ?: return
|
|
321
325
|
val analysisSize = sizes.second ?: previewSize
|
|
322
326
|
|
|
327
|
+
Log.d(
|
|
328
|
+
TAG,
|
|
329
|
+
"[CAMERA2] createPreviewSession view=${previewView.width}x${previewView.height} " +
|
|
330
|
+
"preview=${previewSize.width}x${previewSize.height} analysis=${analysisSize.width}x${analysisSize.height}"
|
|
331
|
+
)
|
|
332
|
+
|
|
323
333
|
texture.setDefaultBufferSize(previewSize.width, previewSize.height)
|
|
324
334
|
val previewSurface = Surface(texture)
|
|
325
335
|
|
|
@@ -396,6 +406,11 @@ class CameraController(
|
|
|
396
406
|
analysisSize = newAnalysis
|
|
397
407
|
}
|
|
398
408
|
|
|
409
|
+
Log.d(
|
|
410
|
+
TAG,
|
|
411
|
+
"[CAMERA2] ensurePreviewSizes view=${viewWidth}x${viewHeight} ratio=$targetRatio " +
|
|
412
|
+
"preview=${previewSize?.width}x${previewSize?.height} analysis=${analysisSize?.width}x${analysisSize?.height}"
|
|
413
|
+
)
|
|
399
414
|
return Pair(previewSize, analysisSize)
|
|
400
415
|
}
|
|
401
416
|
|
|
@@ -439,6 +454,11 @@ class CameraController(
|
|
|
439
454
|
matrix.postTranslate(viewWidth / 2f, viewHeight / 2f)
|
|
440
455
|
|
|
441
456
|
previewView.setTransform(matrix)
|
|
457
|
+
Log.d(
|
|
458
|
+
TAG,
|
|
459
|
+
"[CAMERA2] transform view=${viewWidth}x${viewHeight} buffer=${bufferWidth}x${bufferHeight} " +
|
|
460
|
+
"rotated=${rotatedBufferWidth}x${rotatedBufferHeight} rotation=$rotationDegrees scale=$scale"
|
|
461
|
+
)
|
|
442
462
|
}
|
|
443
463
|
|
|
444
464
|
private fun ensureMatchParent() {
|
|
@@ -462,6 +482,7 @@ class CameraController(
|
|
|
462
482
|
layoutParams.gravity = Gravity.CENTER
|
|
463
483
|
previewView.layoutParams = layoutParams
|
|
464
484
|
}
|
|
485
|
+
Log.d(TAG, "[CAMERA2] parent=${parentWidth}x${parentHeight} previewView=${previewView.width}x${previewView.height}")
|
|
465
486
|
}
|
|
466
487
|
|
|
467
488
|
private fun handleImage(image: Image) {
|
package/package.json
CHANGED