提交 b66ab7df 编写于 作者: M Mr.doob

Updated builds.

上级 b66d8b01
...@@ -12221,7 +12221,9 @@ THREE.SceneLoader.prototype = { ...@@ -12221,7 +12221,9 @@ THREE.SceneLoader.prototype = {
// lights // lights
} else if (objJSON.type === "PointLight" || objJSON.type === "AmbientLight" || objJSON.type === "SpotLight" || objJSON.type === "HemisphereLight" || objJSON.type === "AreaLight") { } else if ( objJSON.type === "AmbientLight" || objJSON.type === "PointLight" ||
objJSON.type === "DirectionalLight" || objJSON.type === "SpotLight" ||
objJSON.type === "HemisphereLight" || objJSON.type === "AreaLight" ) {
var color = objJSON.color; var color = objJSON.color;
var intensity = objJSON.intensity; var intensity = objJSON.intensity;
...@@ -12240,6 +12242,11 @@ THREE.SceneLoader.prototype = { ...@@ -12240,6 +12242,11 @@ THREE.SceneLoader.prototype = {
light.position.fromArray( position ); light.position.fromArray( position );
break; break;
case 'DirectionalLight':
light = new THREE.DirectionalLight( color, intensity );
light.position.fromArray( objJSON.direction );
break;
case 'SpotLight': case 'SpotLight':
light = new THREE.SpotLight( color, intensity, distance, 1 ); light = new THREE.SpotLight( color, intensity, distance, 1 );
light.angle = objJSON.angle; light.angle = objJSON.angle;
......
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册