How to set background of scene view ? #508
-
only model image should display not the white area. Code ` package com.ar_makeup_android_prototype.ar import androidx.compose.foundation.background @composable
// setBackgroundColor(backgroundColor.toArgb())
// sceneView.skybox = Skybox.Builder().color(750f / 255f, 750f / 255f, 750f / 255f, 0.5f).build(sceneView.engine) } ` |
Beta Was this translation helpful? Give feedback.
Replies: 13 comments 1 reply
-
any one can answer? |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
@dinakar-m Have you tried setting the alpha to 0? (the last number in the color) |
Beta Was this translation helpful? Give feedback.
-
yes that also does not work. |
Beta Was this translation helpful? Give feedback.
-
@stackunderflows are you one of contributor to this repo? Just to fix background color to transparent i have to use below library and solution which worked. |
Beta Was this translation helpful? Give feedback.
-
this also does not worked... |
Beta Was this translation helpful? Give feedback.
-
inside below class init method init....
// if (backgroundColor?.a == 1.0f) {
i tried various combination for clearColor attribute which can change the color to anything but can not change to transparent why? |
Beta Was this translation helpful? Give feedback.
-
No, I am not a contributor to this project. I've been playing around with it for a while and haven't ever had a white background like that. I don't know how that could happen. |
Beta Was this translation helpful? Give feedback.
-
There you go! `private fun setupTransparentSceneView() {
|
Beta Was this translation helpful? Give feedback.
-
Hi @jaswant-iotric |
Beta Was this translation helpful? Give feedback.
-
Here is how you can make the skybox background transparent Note: on some emulators can cause the backgrounds to appear black, if you faced that you have to run on real device
|
Beta Was this translation helpful? Give feedback.
-
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. Thank you for your contributions. |
Beta Was this translation helpful? Give feedback.
-
Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information. |
Beta Was this translation helpful? Give feedback.
There you go!
`private fun setupTransparentSceneView() {
sceneView = findViewById(R.id.mSceneView)
sceneView.lifecycle = this.lifecycle