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

Examples: Clean up.

上级 82c81329
import { OrbitControls } from 'three/addons/controls/OrbitControls.js';
import { ViewHelper } from 'three/addons/helpers/ViewHelper.js';
import { OrbitControls } from 'three-addons/controls/OrbitControls.js';
import { ViewHelper } from 'three-addons/helpers/ViewHelper.js';
import { Element, LabelElement, SelectInput } from '../../libs/flow.module.js';
import { BaseNode } from '../core/BaseNode.js';
import { MeshBasicNodeMaterial, FloatNode } from 'three-nodes/Nodes.js';
......
......@@ -43,7 +43,7 @@
{
"imports": {
"three": "../build/three.module.js",
"three/addons/": "./jsm/",
"three-addons/": "./jsm/",
"three-nodes/": "./jsm/nodes/"
}
}
......@@ -133,22 +133,22 @@
const defaultMaterial = new Nodes.MeshBasicNodeMaterial();
defaultMaterial.colorNode = new Nodes.FloatNode( 0 );
const sphere = new THREE.Mesh( new THREE.SphereGeometry( 200, 32, 16 ), defaultMaterial ) ;
const sphere = new THREE.Mesh( new THREE.SphereGeometry( 200, 32, 16 ), defaultMaterial );
sphere.name = 'Sphere';
sphere.position.set( 500, 0, -500 );
sphere.position.set( 500, 0, - 500 );
scene.add( sphere );
const box = new THREE.Mesh( new THREE.BoxGeometry( 200, 200, 200 ), defaultMaterial ) ;
const box = new THREE.Mesh( new THREE.BoxGeometry( 200, 200, 200 ), defaultMaterial );
box.name = 'Box';
box.position.set( -500, 0, -500 );
box.position.set( - 500, 0, - 500 );
scene.add( box );
const defaultPointsMaterial = new Nodes.PointsNodeMaterial();
defaultPointsMaterial.colorNode = new Nodes.FloatNode( 0 );
const torusKnot = new THREE.Points( new THREE.TorusKnotGeometry( 100, 30, 100, 16 ), defaultPointsMaterial ) ;
const torusKnot = new THREE.Points( new THREE.TorusKnotGeometry( 100, 30, 100, 16 ), defaultPointsMaterial );
torusKnot.name = 'Torus Knot ( Points )';
torusKnot.position.set( 0, 0, -500 );
torusKnot.position.set( 0, 0, - 500 );
scene.add( torusKnot );
model = object.children[ 0 ];
......
......@@ -45,7 +45,7 @@
{
"imports": {
"three": "../build/three.module.js",
"three/addons/": "./jsm/",
"three-addons/": "./jsm/",
"three-nodes/": "./jsm/nodes/"
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册