提交 14268afb 编写于 作者: S sunag

progressive download

上级 1122dbea
......@@ -78,7 +78,8 @@
loader = new THREE.SEA3D( {
autoPlay : true, // Auto play animations
container : scene // Container to add models
container : scene, // Container to add models
progressive : true // Progressive download
} );
......@@ -87,13 +88,11 @@
// Get camera from SEA3D Studio
// use loader.get... to get others objects
var cam = loader.getCamera( "Camera007" );
camera.position.copy( cam.position );
camera.rotation.copy( cam.rotation );
//var cam = loader.getCamera( "Camera007" );
//camera.position.copy( cam.position );
//camera.rotation.copy( cam.rotation );
controls = new THREE.OrbitControls( camera );
animate();
console.log("SEA3D asset loaded!");
};
......@@ -110,7 +109,10 @@
document.body.appendChild( container );
camera = new THREE.PerspectiveCamera( 45, window.innerWidth / window.innerHeight, 1, 10000 );
camera.position.set( 1000, - 300, 1000 );
camera.position.set( 1000, 1000, 1000 );
camera.lookAt( new THREE.Vector3() );
controls = new THREE.OrbitControls( camera );
renderer = new THREE.WebGLRenderer();
renderer.setPixelRatio( window.devicePixelRatio );
......@@ -185,6 +187,8 @@
}
animate();
</script>
</body>
</html>
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册