| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205 |
- <!DOCTYPE html>
- <html lang="ko">
- <head>
- <meta charset="utf-8" />
- <base href="../../../" />
- <script src="page.js"></script>
- <link type="text/css" rel="stylesheet" href="page.css" />
- </head>
- <body>
- [page:EventDispatcher] →
- <h1>[name]</h1>
- <p class="desc">
- <p>
- [name] 는 [page:OrbitControls] 와 유사하지만, 카메라의 일정한 [page:Object3D.up up] vector 값을 유지하지 않습니다.
- 이 말인즉슨, 카메라가 위쪽 방향이나 아럐쪽 방향으로 회전할 경우, "오른쪽을 위로" 유지하기 위해 뒤집을 수 없습니다.
- </p>
- </p>
- <h2>예시</h2>
- <p>[example:misc_controls_trackball misc / controls / trackball ]</p>
- <h2>생성자</h2>
- <h3>[name]( [param:Camera camera], [param:HTMLDOMElement domElement] )</h3>
- <p>
- <p>
- [page:Camera camera]: 렌더링 된 장면의 카메라입니다.
- </p>
- <p>
- [page:HTMLDOMElement domElement]: 이벤트 리스너에 사용되는 HTML 엘리먼트입니다.
- </p>
- <p>
- 새로운 [name] 객체를 생성합니다.
- </p>
- </p>
- <h2>이벤트</h2>
- <h3>change</h3>
- <p>
- 컨트롤에 의해 카메라가 변환될 경우 호출됩니다.
- </p>
- <h3>start</h3>
- <p>
- 처음으로 상호 작용이 실행되면 호출됩니다. (e.g. 터치패드)
- </p>
- <h3>end</h3>
- <p>
- 상호 작용이 완료되면 호출됩니다.
- </p>
- <h2>특성</h2>
- <h3>[property:HTMLDOMElement domElement]</h3>
- <p>
- 마우스 / 터치 이벤트를 수신하는 데 사용되는 HTMLDOMElement입니다. 이것은 생성자에 의해 설정되어야 합니다; 생성자를 통해 설정되지 않을 경우 새 이벤트 리스너에 설정되지 않습니다.
- </p>
- <h3>[property:Number dynamicDampingFactor]</h3>
- <p>
- 댐핑의 강도를 조절합니다. [page:.staticMoving staticMoving] 이 * false * 로 설정된 경우에만 고려됩니다. 기본값은 *0.2* 입니다.
- </p>
- <h3>[property:Boolean enabled]</h3>
- <p>
- 컨트롤이 활성화인지 비활성화인지 나타냅니다.
- </p>
- <h3>[property:Array keys]</h3>
- <p>
- 이 배열은 상호 작용을 제어하기위한 키 코드를 보유합니다.
- <ul>
- <li>처음 정의 된 키를 누르면 모든 마우스 상호 작용 (왼쪽, 가운데, 오른쪽)이 궤도를 회전합니다.</li>
- <li>두 번째로 정의 된 키를 누르면 모든 마우스 상호 작용 (왼쪽, 가운데, 오른쪽)이 확대 / 축소를 수행합니다.</li>
- <li>세 번째로 정의 된 키를 누르면 모든 마우스 상호 작용 (왼쪽, 가운데, 오른쪽)이 패닝을 수행합니다.</li>
- </ul>
- 기본값은 A, S, D를 나타내는 * 65, 83, 68 *입니다.
- </p>
- <h3>[property:Number maxDistance]</h3>
- <p>
- How far you can zoom out. Default is *Infinity*.
- </p>
- <h3>[property:Number minDistance]</h3>
- <p>
- How far you can zoom in. Default is *0*.
- </p>
- <h3>
- [property:Object mouseButtons]</h3>
- <p>
- This object contains references to the mouse actions used by the controls.
- <ul>
- <li>.LEFT is assigned with *THREE.MOUSE.ROTATE*</li>
- <li>.MIDDLE is assigned with *THREE.MOUSE.ZOOM*</li>
- <li>.RIGHT is assigned with *THREE.MOUSE.PAN*</li>
- </ul>
- </p>
- <h3>[property:Boolean noPan]</h3>
- <p>
- Whether or not panning is disabled. Default is *false*.
- </p>
- <h3>[property:Boolean noRotate]</h3>
- <p>
- Whether or not rotation is disabled. Default is *false*.
- </p>
- <h3>[property:Boolean noZoom]</h3>
- <p>
- Whether or not zooming is disabled. Default is *false*.
- </p>
- <h3>[property:Camera object]</h3>
- <p>
- The camera being controlled.
- </p>
- <h3>[property:Number panSpeed]</h3>
- <p>
- The zoom speed. Default is *0.3*.
- </p>
- <h3>[property:Number rotateSpeed]</h3>
- <p>
- The rotation speed. Default is *1.0*.
- </p>
- <h3>[property:Object screen]</h3>
- <p>
- Represents the properties of the screen. Automatically set when [page:.handleResize handleResize]() is called.
- <ul>
- <li>left: Represents the offset in pixels to the screen's left boundary.</li>
- <li>top: Represents the offset in pixels to the screen's top boundary.</li>
- <li>width: Represents the screen width in pixels.</li>
- <li>height: Represents the screen height in pixels.</li>
- </ul>
- </p>
- <h3>[property:Boolean staticMoving]</h3>
- <p>
- Whether or not damping is disabled. Default is *false*.
- </p>
- <h3>[property:Number zoomSpeed]</h3>
- <p>
- The zoom speed. Default is *1.2*.
- </p>
- <h2>Methods</h2>
- <h3>[method:null checkDistances] ()</h3>
- <p>
- Ensures the controls stay in the range [minDistance, maxDistance]. Called by [page:.update update]().
- </p>
- <h3>[method:null dispose] ()</h3>
- <p>
- Should be called if the controls is no longer required.
- </p>
- <h3>[method:null handleResize] ()</h3>
- <p>
- Should be called if the application window is resized.
- </p>
- <h3>[method:null panCamera] ()</h3>
- <p>
- Performs panning if necessary. Called by [page:.update update]().
- </p>
- <h3>[method:null reset] ()</h3>
- <p>
- Resets the controls to its initial state.
- </p>
- <h3>[method:null rotateCamera] ()</h3>
- <p>
- Rotates the camera if necessary. Called by [page:.update update]().
- </p>
- <h3>[method:null update] ()</h3>
- <p>
- Updates the controls. Usually called in the animation loop.
- </p>
- <h3>[method:null zoomCamera] ()</h3>
- <p>
- Performs zooming if necessary. Called by [page:.update update]().
- </p>
- <h2>Source</h2>
- <p>
- [link:https://github.com/mrdoob/three.js/blob/master/examples/jsm/controls/TrackballControls.js examples/jsm/controls/TrackballControls.js]
- </p>
- </body>
- </html>
|