I saw this example: three.js examples that uses THREE.Reflector but couldn’t find how to control the reflection intensity (so it won’t be like a mirror) or the reflective object color.
As you can see below, changing the color doesn’t decrease the intensity of the reflection. I’m wondering if their is a way in the fragment-shader code of the THREE.Reflector to do so. Is their any performant work around I can do?
A constant attenuation over the entire reflector. I have looked at the fading example and its not the desired effect. I’d like as if I can change the intensity of the reflection over the entire reflector. Like make the intensity of the reflection range from 0 to 1.
Just do this. On top of the reflector ( just a little bit of transformation in the y axis ) create a plane that would match the size of the reflector object, and give it a material like this one :
var planeMat = new THREE.MeshLambertMaterial({
color: 0x00008b, // dark blue
transparent: true,
opacity: 0.5,
reflectivity: 0
});
… and there you go. It is not something I would call perfect, but in my case did the job.