Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ android {

defaultConfig {
applicationId = "com.example.helloandroidxr"
minSdk = 23
minSdk = 24
targetSdk = 35
versionCode = 1
versionName = "1.0"
Expand Down
3 changes: 0 additions & 3 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">

<!-- This is necessary due to a known issue causing a higher minSDK than intended-->
<uses-sdk tools:overrideLibrary="androidx.xr.scenecore, androidx.xr.compose"/>

<application
android:allowBackup="true"
android:dataExtractionRules="@xml/data_extraction_rules"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ class EnvironmentController(private val xrSession: Session, private val coroutin
private val assetCache: HashMap<String, Any> = HashMap()
private var activeEnvironmentModelName: String? = null

fun requestHomeSpaceMode() = xrSession.requestHomeSpaceMode()
fun requestHomeSpaceMode() = xrSession.spatialEnvironment.requestHomeSpaceMode()

fun requestFullSpaceMode() = xrSession.requestFullSpaceMode()
fun requestFullSpaceMode() = xrSession.spatialEnvironment.requestFullSpaceMode()

fun requestPassthrough() = xrSession.spatialEnvironment.setPassthroughOpacityPreference(1f)

Expand Down Expand Up @@ -73,8 +73,7 @@ class EnvironmentController(private val xrSession: Session, private val coroutin
//load the asset if it hasn't been loaded previously
if (!assetCache.containsKey(modelName)){
try {
val gltfModel =
xrSession.createGltfResourceAsync(modelName).await()
val gltfModel = GltfModel.create(xrSession, modelName).await()

assetCache[modelName] = gltfModel

Expand Down
22 changes: 11 additions & 11 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
[versions]
androidx-runtime = "1.8.0-alpha06"
agp = "8.6.1"
arcore = "1.0.0-alpha01"
compose = "1.0.0-alpha01"
impress = "0.0.1"
androidx-runtime = "1.8.0-beta02"
agp = "8.8.1"
arcore = "1.0.0-alpha02"
compose = "1.0.0-alpha02"
impress = "0.0.2"
kotlinxCoroutinesGuava = "1.9.0"
scenecore = "1.0.0-alpha01"
kotlin = "2.0.21"
scenecore = "1.0.0-alpha02"
kotlin = "2.1.0"
concurrentFuturesKtx = "1.2.0"
activityCompose = "1.10.0-beta01"
composeBom = "2024.11.00"
activityCompose = "1.10.0"
composeBom = "2025.02.00"
material = "1.12.0"
screenshot = "0.0.1-alpha08"
screenshot = "0.0.1-alpha09"
adaptiveAndroid = "1.0.0"

[libraries]
Expand All @@ -31,6 +31,6 @@ androidx-adaptive-android = { group = "androidx.compose.material3.adaptive", nam

[plugins]
android-application = { id = "com.android.application", version.ref = "agp" }
kotlin-android = { id = "org.jetbrains.kotlin.android", version = "2.0.21" }
kotlin-android = { id = "org.jetbrains.kotlin.android", version = "2.1.0" }
kotlin-compose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
screenshot = { id = "com.android.compose.screenshot", version.ref = "screenshot" }
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@
#Mon Aug 26 16:14:13 PDT 2024
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading