Is it possible to make a mirror object cast a shadow on its base? I’ve combined a couple of three.js examples here to illustrate what I want to do.
First, here’s a typical three.js way of casting a shadow:
var boxMesh = new THREE.Mesh( boxGeometry, cubeMat );
boxMesh.position.set( -0.5, 0.25, -1 );
boxMesh.castShadow = true;
scene.add( boxMesh );
And here’s a Reflector.js object:
var geometry = new THREE.CircleBufferGeometry( 0.25, 16 );
var pedestalMirror = new THREE.Reflector( geometry, {
clipBias: 0.003,
textureWidth: WIDTH * window.devicePixelRatio,
textureHeight: HEIGHT * window.devicePixelRatio,
color: 0x777777,
recursion: 1
} );
pedestalMirror.position.y = 1.75;
scene.add( pedestalMirror );
So pedestalMirror.castShadow = true; will not work.
Any suggestions would be greatly appreciated!!