Skip to content

Commit f5fb077

Browse files
authored
Merge pull request #12 from Uralstech/unstable
UXR.QuestCamera v3.1.3
2 parents 5f7f097 + e7b2183 commit f5fb077

13 files changed

Lines changed: 50 additions & 24 deletions

File tree

UCamera/UCamera/src/main/java/com/uralstech/ucamera/CaptureSessionWrapper.kt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -250,20 +250,21 @@ abstract class CaptureSessionWrapper private constructor(private val callbacks:
250250
protected open fun closeWork() {
251251
if (captureSession != null) {
252252
captureSession?.stopRepeating()
253+
captureSession?.close()
254+
captureSession = null
255+
256+
Log.i(TAG, "Closing capture session.")
253257

254258
try {
255-
if (!requestCompletionLatch.await(1, TimeUnit.SECONDS)) {
259+
if (!requestCompletionLatch.await(5, TimeUnit.SECONDS)) {
256260
Log.w(TAG, "Could not wait for total request completion due to timeout.")
257261
}
258262
} catch (e: InterruptedException) {
259263
Log.e(TAG, "Interrupted while trying to stop captureSession", e)
260264
}
261265
}
262266

263-
captureSession?.close()
264-
captureSession = null
265-
266-
if (executorSemaphore.tryAcquire(1, TimeUnit.SECONDS))
267+
if (executorSemaphore.tryAcquire(5, TimeUnit.SECONDS))
267268
{
268269
captureSessionExecutor.shutdown()
269270
executorSemaphore.release()

UCamera/UCamera/src/main/java/com/uralstech/ucamera/STCaptureSessionWrapper.kt

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -237,19 +237,21 @@ class STCaptureSessionWrapper(
237237
private fun closeWork() {
238238
if (captureSession != null) {
239239
captureSession?.stopRepeating()
240+
captureSession?.close()
241+
captureSession = null
242+
243+
Log.i(TAG, "Closing capture session.")
244+
240245
try {
241-
if (!requestCompletionLatch.await(1, TimeUnit.SECONDS)) {
246+
if (!requestCompletionLatch.await(5, TimeUnit.SECONDS)) {
242247
Log.w(TAG, "Could not wait for total request completion due to timeout.")
243248
}
244249
} catch (e: InterruptedException) {
245250
Log.e(TAG, "Interrupted while trying to stop captureSession", e)
246251
}
247252
}
248253

249-
captureSession?.close()
250-
captureSession = null
251-
252-
if (executorSemaphore.tryAcquire(1, TimeUnit.SECONDS)) {
254+
if (executorSemaphore.tryAcquire(5, TimeUnit.SECONDS)) {
253255
captureSessionExecutor.shutdown()
254256
executorSemaphore.release()
255257
} else {

UCamera/gradle/libs.versions.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[versions]
2-
agp = "8.10.0"
3-
camera2 = "1.5.1"
2+
agp = "8.10.1"
3+
camera2 = "1.5.2"
44
kotlin = "2.2.21"
55
coreKtx = "1.17.0"
66

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<dependencies>
22
<androidPackages>
3-
<androidPackage spec="androidx.camera:camera-camera2:1.5.1" />
3+
<androidPackage spec="androidx.camera:camera-camera2:1.5.2" />
44
</androidPackages>
55
</dependencies>

UXR.QuestCamera/Packages/com.uralstech.uxr.questcamera/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"displayName": "UXR.QuestCamera",
44
"description": "A Unity package to use the new Meta Quest Passthrough Camera API.",
55
"keywords": [],
6-
"version": "3.1.2",
6+
"version": "3.1.3",
77
"unity": "2022.3",
88
"hideInEditor": false,
99
"documentationUrl": "https://uralstech.github.io/UXR.QuestCamera/",

UXR.QuestCamera/Packages/packages-lock.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"url": "https://packages.unity.com"
2121
},
2222
"com.unity.burst": {
23-
"version": "1.8.25",
23+
"version": "1.8.26",
2424
"depth": 1,
2525
"source": "registry",
2626
"dependencies": {

UXR.QuestCamera/ProjectSettings/AndroidResolverDependencies.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<dependencies>
22
<packages>
3-
<package>androidx.camera:camera-camera2:1.5.1</package>
3+
<package>androidx.camera:camera-camera2:1.5.2</package>
44
</packages>
55
<files />
66
<settings>

UXR.QuestCamera/ProjectSettings/EditorBuildSettings.asset

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ EditorBuildSettings:
99
path: Assets/test.unity
1010
guid: b5a0a63e0e2a441d9bece1500fac12ab
1111
- enabled: 0
12-
path: Assets/Samples/UXR.QuestCamera/3.1.1/Digit Recognition with Unity Inference
12+
path: Assets/Samples/UXR.QuestCamera/3.1.2/Digit Recognition with Unity Inference
1313
Engine/Scenes/Main.unity
1414
guid: d21f9028511979e4bbe9142830c1ea80
1515
m_configObjects:
16+
com.unity.dt.app-ui: {fileID: 11400000, guid: 1b1c20d82303e4b5781c3ef50ac1449f, type: 2}
1617
com.unity.input.settings.actions: {fileID: -944628639613478452, guid: 289c1b55c9541489481df5cc06664110, type: 3}
1718
m_UseUCBPForAssetBundles: 0
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
%YAML 1.1
2+
%TAG !u! tag:unity3d.com,2011:
3+
--- !u!114 &1
4+
MonoBehaviour:
5+
m_ObjectHideFlags: 53
6+
m_CorrespondingSourceObject: {fileID: 0}
7+
m_PrefabInstance: {fileID: 0}
8+
m_PrefabAsset: {fileID: 0}
9+
m_GameObject: {fileID: 0}
10+
m_Enabled: 1
11+
m_EditorHideFlags: 0
12+
m_Script: {fileID: 15023, guid: 0000000000000000e000000000000000, type: 0}
13+
m_Name:
14+
m_EditorClassIdentifier: UnityEditor.MultiplayerModule.dll::UnityEditor.Multiplayer.Internal.MultiplayerRolesSettings
15+
m_MultiplayerRoleForClassicProfile:
16+
m_Keys: []
17+
m_Values:

0 commit comments

Comments
 (0)