-
-
Notifications
You must be signed in to change notification settings - Fork 189
Open
Description
Trying to do smth like this in template below. If use CubeNode - rendering is ok.
val cNode2 = ViewNode2(
engine,
wn.value,
materialLoader,
content = {
MaterialTheme {
Box(Modifier.fillMaxSize()) {
Image(
painterResource(ai.tourly.core.R.drawable.v_ic_microphone),
null,
modifier = Modifier.size(200.dp))
}
}
}
).apply {
isPositionEditable = true
isScaleEditable = true
scale = Scale(2f, 2f, 2f)
isEditable = true
onEditingChanged = {
anchorNode.isVisible = true
isVisible = true
}
}
val boundingBoxNode = CubeNode(
engine,
size = dev.romainguy.kotlin.math.Float3(200f, 200f, 200f),
center = dev.romainguy.kotlin.math.Float3(50f, 50f, 50f),
materialInstance = materialLoader.createColorInstance(
Color.Black.copy(
alpha = 0.5f
)
)
).apply {
isVisible = true
}
anchorNode.addChildNode(cNode2)
anchorNode
}
nodes.addAll(ancors)
bene25
Metadata
Metadata
Assignees
Labels
No labels