three.js 小记

  1. 设置透明背景
var r = new THREE.WebGLRenderer({alpha:true});

r.setClearColor(0x000000,0);
  1. 设置透明材质
new THREE.MeshBasicMaterial({
  transparent: true,
  opacity: 0
}));