How to use the CSM function from three

Find comprehensive JavaScript three.CSM code examples handpicked from public code repositorys.

39
40
41
42
43
44
45
46
47
48
let renderer = new THREE.WebGLRenderer();

renderer.shadowMap.enabled = true;
renderer.shadowMap.type = THREE.PCFSoftShadowMap; // or any other type of shadowmap
        
let csm = new THREE.CSM({
        maxFar: camera.far,
        cascades: 4,
        shadowMapSize: 1024,
        lightDirection: new THREE.Vector3(1, -1, 1).normalize(),
fork icon16
star icon191
watch icon9

Other functions in three

Sorted by popularity

function icon

three.Vector3 is the most popular function in three (22341 examples)