immersive-web / webxr-samples

Samples to demonstrate use of the WebXR Device API
https://immersive-web.github.io/webxr-samples/
MIT License
995 stars 479 forks source link

can't work out getter method on baseColorFactor #84

Open andysc opened 3 years ago

andysc commented 3 years ago

according to https://github.com/immersive-web/webxr-samples/blob/master/js/render/core/material.js MaterialUniform has a getter and a setter. Looking at input-selection.html as an example in onSqueeze()

          uniforms.baseColorFactor.value = [Math.random(), Math.random(), Math.random(), 1.0];
          console.log("random colour:")
          console.log(uniforms.baseColorFactor.value)

uniforms.baseColorFactor.value is undefined

What is the correct getter method for a baseColorFactor? I've found _value but that seems like it should be hidden behind a getter method.