Closed MatHeartGaming closed 1 year ago
Jetpack Compose has been added in v0.93 You can use it like this:
@Composable
fun ARScreen() {
val nodes = remember { mutableStateListOf<ArNode>() }
Box(modifier = Modifier.fillMaxSize()) {
ARScene(
modifier = Modifier.fillMaxSize(),
nodes = nodes,
planeRenderer = true,
onCreate = { arSceneView ->
// Apply your configuration
},
onSessionCreate = { session ->
// Configure the ARCore session
},
onFrame = { arFrame ->
// Retrieve ARCore frame update
},
onTap = { hitResult ->
// User tapped in the AR view
}
)
}
}
Hi, I'm trying to use this library into a pure Jetpack Compose app and so far I've been facing some troubles. I only have a black screen. The code I'm using to initialize the ArScene class is the following:
and then I try to call this View like this:
Any idea on how to render the camera? Thanks.