Skip to content

Commit

Permalink
Examples: Clean up. (#29438)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mugen87 authored Sep 18, 2024
1 parent 1116706 commit 01359e0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
Binary file modified examples/screenshots/webgl_loader_tilt.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 2 additions & 5 deletions examples/webgl_loader_tilt.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,18 @@
renderer = new THREE.WebGLRenderer( { antialias: true } );
renderer.setPixelRatio( window.devicePixelRatio );
renderer.setSize( window.innerWidth, window.innerHeight );
renderer.setAnimationLoop( animate );
document.body.appendChild( renderer.domElement );

const loader = new TiltLoader();
loader.load( './models/tilt/BRUSH_DOME.tilt', function ( object ) {

// console.log( object.children.length );
scene.add( object );
render();

} );

const controls = new OrbitControls( camera, renderer.domElement );
controls.addEventListener( 'change', render );
controls.target.y = camera.position.y;
controls.update();

Expand All @@ -76,11 +75,9 @@

renderer.setSize( window.innerWidth, window.innerHeight );

render();

}

function render() {
function animate() {

renderer.render( scene, camera );

Expand Down

0 comments on commit 01359e0

Please sign in to comment.