Fix: Set USB Camera resolution to 1920x1080 and crop to 3:2 aspect ratio, bump version to 23.01.68

This commit is contained in:
Jannik committed 2026-08-24 20:35:54 +02:00
1 parent b3a3db7ac4
commit 8fc9a4e487
10 files changed
+82 -46

No files matched your search

@@ -58,3 +58,6 @@
5 45 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/arm64-v8a/CMakeFiles/cmake.verify_globs 5250f1b80cb55465
6 52 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/arm64-v8a/CMakeFiles/cmake.verify_globs 5250f1b80cb55465
3 27 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/arm64-v8a/CMakeFiles/cmake.verify_globs 5250f1b80cb55465
4 45 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/arm64-v8a/CMakeFiles/cmake.verify_globs 5250f1b80cb55465
5 42 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/arm64-v8a/CMakeFiles/cmake.verify_globs 5250f1b80cb55465
5 34 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/arm64-v8a/CMakeFiles/cmake.verify_globs 5250f1b80cb55465
@@ -2,41 +2,41 @@ C/C++ Structured Logg
e
cC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\additional_project_files.txtC
A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ꓺ¢ƒ4Å, Üû—ö‚4d
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  æž¹¨ƒ4Å, Üû—ö‚4d
b
`C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\android_gradle_build.json  ꓺ¢ƒ4û" Þû—ö‚4i
`C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\android_gradle_build.json  æž¹¨ƒ4û" Þû—ö‚4i
g
eC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\android_gradle_build_mini.json  ꓺ¢ƒ4ï —ü—ö‚4V
eC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\android_gradle_build_mini.json  æž¹¨ƒ4ï —ü—ö‚4V
T
RC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\build.ninja  ꓺ¢ƒ4œÞ Íø—ö‚4Z
RC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\build.ninja  æž¹¨ƒ4œÞ Íø—ö‚4Z
X
VC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\build.ninja.txt  ꓺ¢ƒ4_
VC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\build.ninja.txt  æž¹¨ƒ4_
]
[C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\build_file_index.txt  ꓺ¢ƒ4� ™ü—ö‚4`
[C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\build_file_index.txt  æž¹¨ƒ4� ™ü—ö‚4`
^
\C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\compile_commands.json  ꓺ¢ƒ4‘Ø Ëø—ö‚4d
\C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\compile_commands.json  æž¹¨ƒ4‘Ø Ëø—ö‚4d
b
`C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\compile_commands.json.bin  ꓺ¢ƒ4 Ê„ Ëø—ö‚4j
`C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\compile_commands.json.bin  æž¹¨ƒ4 Ê„ Ëø—ö‚4j
h
fC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\metadata_generation_command.txt  ꓺ¢ƒ4
fC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\metadata_generation_command.txt  æž¹¨ƒ4
¸ ˜ü—ö‚4]
[
YC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\prefab_config.json  ꓺ¢ƒ4 € ˜ü—ö‚4b
YC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\prefab_config.json  æž¹¨ƒ4 € ˜ü—ö‚4b
`
^C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\symbol_folder_index.txt  ꓺ¢ƒ4␍ ] ˜ü—ö‚4{
^C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\arm64-v8a\symbol_folder_index.txt  æž¹¨ƒ4␍ ] ˜ü—ö‚4{
y
wC:\GitHub\Schnappix\node_modules\react-native-gesture-handler\android\build\generated\source\codegen\jni\CMakeLists.txt  ꓺ¢ƒ4␍¾ ‡•‚ö‚4v
wC:\GitHub\Schnappix\node_modules\react-native-gesture-handler\android\build\generated\source\codegen\jni\CMakeLists.txt  æž¹¨ƒ4␍¾ ‡•‚ö‚4v
t
rC:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\generated\source\codegen\jni\CMakeLists.txt  ꓺ¢ƒ4ö ’•‚ö‚4µ
rC:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\generated\source\codegen\jni\CMakeLists.txt  æž¹¨ƒ4ö ’•‚ö‚4µ
²
¯C:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  듺¢ƒ4Y
¯C:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  æž¹¨ƒ4Y
W
UC:\GitHub\Schnappix\node_modules\react-native-svg\android\src\main\jni\CMakeLists.txt  듺¢ƒ4½ œ§ØÖç3u
UC:\GitHub\Schnappix\node_modules\react-native-svg\android\src\main\jni\CMakeLists.txt  æž¹¨ƒ4½ œ§ØÖç3u
s
qC:\GitHub\Schnappix\node_modules\react-native-view-shot\android\build\generated\source\codegen\jni\CMakeLists.txt  듺¢ƒ4ê û”‚ö‚4t
qC:\GitHub\Schnappix\node_modules\react-native-view-shot\android\build\generated\source\codegen\jni\CMakeLists.txt  æž¹¨ƒ4ê û”‚ö‚4t
r
pC:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\generated\source\codegen\jni\CMakeLists.txt  듺¢ƒ4ê Ÿ•‚ö‚4³
pC:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\generated\source\codegen\jni\CMakeLists.txt  æž¹¨ƒ4ê Ÿ•‚ö‚4³
°
­C:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  듺¢ƒ4k
­C:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  æž¹¨ƒ4k
i
gC:\GitHub\Schnappix\node_modules\react-native\ReactAndroid\cmake-utils\default-app-setup\CMakeLists.txt  듺¢ƒ4ð ®¡ÈÑç3
gC:\GitHub\Schnappix\node_modules\react-native\ReactAndroid\cmake-utils\default-app-setup\CMakeLists.txt  æž¹¨ƒ4ð ®¡ÈÑç3
@@ -58,3 +58,6 @@
3 42 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/armeabi-v7a/CMakeFiles/cmake.verify_globs 1eb2d1da6ebc2e74
4 42 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/armeabi-v7a/CMakeFiles/cmake.verify_globs 1eb2d1da6ebc2e74
4 37 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/armeabi-v7a/CMakeFiles/cmake.verify_globs 1eb2d1da6ebc2e74
5 45 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/armeabi-v7a/CMakeFiles/cmake.verify_globs 1eb2d1da6ebc2e74
4 35 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/armeabi-v7a/CMakeFiles/cmake.verify_globs 1eb2d1da6ebc2e74
3 33 0 C:/GitHub/Schnappix/android/app/.cxx/RelWithDebInfo/3x5j4n2e/armeabi-v7a/CMakeFiles/cmake.verify_globs 1eb2d1da6ebc2e74
@@ -2,41 +2,41 @@ C/C++ Structured Logi
g
eC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\additional_project_files.txtC
A
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  ‚•º¢ƒ4ý, Óì™ö‚4f
?com.android.build.gradle.internal.cxx.io.EncodedFileFingerPrint  »Ÿ¹¨ƒ4ý, Óì™ö‚4f
d
bC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\android_gradle_build.json  ‚•º¢ƒ4�# Øì™ö‚4k
bC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\android_gradle_build.json  »Ÿ¹¨ƒ4�# Øì™ö‚4k
i
gC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\android_gradle_build_mini.json  ‚•º¢ƒ4‘ ˆí™ö‚4X
gC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\android_gradle_build_mini.json  »Ÿ¹¨ƒ4‘ ˆí™ö‚4X
V
TC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\build.ninja  ‚•º¢ƒ4Áå  é™ö‚4\
TC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\build.ninja  »Ÿ¹¨ƒ4Áå  é™ö‚4\
Z
XC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\build.ninja.txt  ‚•º¢ƒ4a
XC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\build.ninja.txt  »Ÿ¹¨ƒ4a
_
]C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\build_file_index.txt  ‚•º¢ƒ4� �í™ö‚4b
]C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\build_file_index.txt  »Ÿ¹¨ƒ4� �í™ö‚4b
`
^C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\compile_commands.json  ‚•º¢ƒ4´à žé™ö‚4f
^C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\compile_commands.json  »Ÿ¹¨ƒ4´à žé™ö‚4f
d
bC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\compile_commands.json.bin  ‚•º¢ƒ4 ò„ žé™ö‚4l
bC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\compile_commands.json.bin  »Ÿ¹¨ƒ4 ò„ žé™ö‚4l
j
hC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\metadata_generation_command.txt  ‚•º¢ƒ4
hC:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\metadata_generation_command.txt  »Ÿ¹¨ƒ4
Ä Ší™ö‚4_
]
[C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\prefab_config.json  ‚•º¢ƒ4 € ‹í™ö‚4d
[C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\prefab_config.json  »Ÿ¹¨ƒ4 € ‹í™ö‚4d
b
`C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\symbol_folder_index.txt  ‚•º¢ƒ4␍ _ Œí™ö‚4{
`C:\GitHub\Schnappix\android\app\.cxx\RelWithDebInfo\3x5j4n2e\armeabi-v7a\symbol_folder_index.txt  »Ÿ¹¨ƒ4␍ _ Œí™ö‚4{
y
wC:\GitHub\Schnappix\node_modules\react-native-gesture-handler\android\build\generated\source\codegen\jni\CMakeLists.txt  ‚•º¢ƒ4␍¾ ‡•‚ö‚4v
wC:\GitHub\Schnappix\node_modules\react-native-gesture-handler\android\build\generated\source\codegen\jni\CMakeLists.txt  »Ÿ¹¨ƒ4␍¾ ‡•‚ö‚4v
t
rC:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\generated\source\codegen\jni\CMakeLists.txt  ‚•º¢ƒ4ö ’•‚ö‚4µ
rC:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\generated\source\codegen\jni\CMakeLists.txt  »Ÿ¹¨ƒ4ö ’•‚ö‚4µ
²
¯C:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  ‚•º¢ƒ4Y
¯C:\GitHub\Schnappix\node_modules\react-native-reanimated\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  »Ÿ¹¨ƒ4Y
W
UC:\GitHub\Schnappix\node_modules\react-native-svg\android\src\main\jni\CMakeLists.txt  ‚•º¢ƒ4½ œ§ØÖç3u
UC:\GitHub\Schnappix\node_modules\react-native-svg\android\src\main\jni\CMakeLists.txt  »Ÿ¹¨ƒ4½ œ§ØÖç3u
s
qC:\GitHub\Schnappix\node_modules\react-native-view-shot\android\build\generated\source\codegen\jni\CMakeLists.txt  ‚•º¢ƒ4ê û”‚ö‚4t
qC:\GitHub\Schnappix\node_modules\react-native-view-shot\android\build\generated\source\codegen\jni\CMakeLists.txt  »Ÿ¹¨ƒ4ê û”‚ö‚4t
r
pC:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\generated\source\codegen\jni\CMakeLists.txt  ‚•º¢ƒ4ê Ÿ•‚ö‚4³
pC:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\generated\source\codegen\jni\CMakeLists.txt  »Ÿ¹¨ƒ4ê Ÿ•‚ö‚4³
°
­C:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  ƒ•º¢ƒ4k
­C:\GitHub\Schnappix\node_modules\react-native-worklets\android\build\intermediates\prefab_package_configuration\release\prefabReleaseConfigurePackage\prefab_publication.json  »Ÿ¹¨ƒ4k
i
gC:\GitHub\Schnappix\node_modules\react-native\ReactAndroid\cmake-utils\default-app-setup\CMakeLists.txt  ƒ•º¢ƒ4ð ®¡ÈÑç3
gC:\GitHub\Schnappix\node_modules\react-native\ReactAndroid\cmake-utils\default-app-setup\CMakeLists.txt  »Ÿ¹¨ƒ4ð ®¡ÈÑç3
+2 -2
View File
@@ -92,8 +92,8 @@ android {
applicationId 'de.orfel.schnappix'
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 67
versionName "23.01.67"
versionCode 68
versionName "23.01.68"
buildConfigField "String", "REACT_NATIVE_RELEASE_LEVEL", "\"${findProperty('reactNativeReleaseLevel') ?: 'stable'}\""
}
Binary file not shown.
Binary file not shown.
+2 -2
View File
@@ -3,7 +3,7 @@
"newArchEnabled": true,
"name": "Schnappix",
"slug": "Schnappix",
"version": "23.01.67",
"version": "23.01.68",
"orientation": "landscape",
"icon": "./Icon.png",
"userInterfaceStyle": "dark",
@@ -13,7 +13,7 @@
},
"android": {
"package": "de.orfel.schnappix",
"versionCode": 67,
"versionCode": 68,
"usesCleartextTraffic": true,
"adaptiveIcon": {
"backgroundColor": "#050510",
@@ -137,6 +137,8 @@ class UsbCameraView(context: Context, appContext: AppContext) : ExpoView(context
if (sharedCameraClient == null) {
val cameraRequest = CameraRequest.Builder()
.setFrontCamera(false)
.setPreviewWidth(1920)
.setPreviewHeight(1080)
.create()
sharedCameraClient = CameraClient.newBuilder(safeContextVal)
@@ -227,15 +229,40 @@ class UsbCameraView(context: Context, appContext: AppContext) : ExpoView(context
// Bypass ausbc's captureImage and its MediaStore logic
// which crashes on Android 13+ due to DATA column usage.
val bitmap = textureView.bitmap
if (bitmap != null) {
val originalBitmap = textureView.bitmap
if (originalBitmap != null) {
Thread {
try {
// Crop to 3:2 aspect ratio (1.5)
val targetRatio = 1.5f
val currentRatio = originalBitmap.width.toFloat() / originalBitmap.height.toFloat()
var finalBitmap = originalBitmap
if (Math.abs(currentRatio - targetRatio) > 0.05f) {
if (currentRatio > targetRatio) {
// Too wide (e.g. 16:9), crop width
val newWidth = (originalBitmap.height * targetRatio).toInt()
val startX = (originalBitmap.width - newWidth) / 2
finalBitmap = android.graphics.Bitmap.createBitmap(originalBitmap, startX, 0, newWidth, originalBitmap.height)
} else {
// Too tall (e.g. 4:3), crop height
val newHeight = (originalBitmap.width / targetRatio).toInt()
val startY = (originalBitmap.height - newHeight) / 2
finalBitmap = android.graphics.Bitmap.createBitmap(originalBitmap, 0, startY, originalBitmap.width, newHeight)
}
}
val file = java.io.File(cleanPath)
val out = java.io.FileOutputStream(file)
bitmap.compress(android.graphics.Bitmap.CompressFormat.JPEG, 90, out)
finalBitmap.compress(android.graphics.Bitmap.CompressFormat.JPEG, 90, out)
out.flush()
out.close()
// Clean up
if (finalBitmap != originalBitmap) {
finalBitmap.recycle()
}
promise.resolve("file://$cleanPath")
} catch (e: Exception) {
promise.reject("ERR_CAPTURE_FAILED", e.message, e)
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "schnappix",
"version": "23.01.67",
"version": "23.01.68",
"main": "index.ts",
"dependencies": {
"@fortawesome/fontawesome-svg-core": "^6.7.2",