mirror of
https://github.com/troisjs/trois.git
synced 2024-11-24 04:12:02 +08:00
use color.set
This commit is contained in:
parent
291444eac6
commit
6c37b1e1cd
@ -11,7 +11,7 @@ export default {
|
||||
setup(props) {
|
||||
const scene = new Scene();
|
||||
if (props.background) scene.background = new Color(props.background);
|
||||
watch(() => props.background, (value) => { scene.background = new Color(value); });
|
||||
watch(() => props.background, (value) => { scene.background.set(value); });
|
||||
return { scene };
|
||||
},
|
||||
provide() {
|
||||
|
Loading…
Reference in New Issue
Block a user