nestedSpheres = {
const group = new THREE.Group();
for (let i = 1; i <= 30; i += 2) {
const geometry = new THREE.SphereGeometry(i / 30, 48, 24);
const material = new THREE.MeshLambertMaterial({
color: new THREE.Color().setHSL(
Math.random(),
0.5,
0.5,
THREE.SRGBColorSpace
),
side: THREE.DoubleSide,
clippingPlanes: clipPlanes,
clipIntersection: clipIntersection
});
group.add(new THREE.Mesh(geometry, material));
}
return group;
}