소스 검색

fixed furnace test

Emmett Lalish 5 년 전
부모
커밋
72fc07b9b4
2개의 변경된 파일9개의 추가작업 그리고 7개의 파일을 삭제
  1. 8 6
      examples/webgl_furnace_test.html
  2. 1 1
      examples/webgl_materials_envmaps_hdr.html

+ 8 - 6
examples/webgl_furnace_test.html

@@ -74,8 +74,8 @@
 
 				// camera
 
-				camera = new THREE.OrthographicCamera( - right, right, right / aspect, - right / aspect, 1, 30 );
-				camera.position.set( 0, 0, 9 );
+				camera = new THREE.PerspectiveCamera( 40, aspect, 1, 30 );
+				camera.position.set( 0, 0, 18 );
 
 			}
 
@@ -128,11 +128,13 @@
 
 			function onResize() {
 
-				var aspect = window.innerWidth / window.innerHeight;
-				camera.top = right / aspect;
-				camera.bottom = - camera.top;
+				var width = window.innerWidth;
+				var height = window.innerHeight;
+
+				camera.aspect = width / height;
 				camera.updateProjectionMatrix();
-				renderer.setSize( window.innerWidth, window.innerHeight );
+
+				renderer.setSize( width, height );
 
 			}
 

+ 1 - 1
examples/webgl_materials_envmaps_hdr.html

@@ -81,7 +81,7 @@
 				THREE.DefaultLoadingManager.onLoad = function ( ) {
 
 					pmremGenerator.dispose();
-					
+
 				}
 
 				var hdrUrls = [ 'px.hdr', 'nx.hdr', 'py.hdr', 'ny.hdr', 'pz.hdr', 'nz.hdr' ];