Ver Fonte

Merge pull request #18734 from mrdoob/revert-18637-patch-1

Revert "Do not require a camera for DeviceOrientationControls"
Mr.doob há 5 anos atrás
pai
commit
e9eda9bced

+ 5 - 5
docs/examples/en/controls/DeviceOrientationControls.html

@@ -12,7 +12,7 @@
 		<h1>[name]</h1>
 		<h1>[name]</h1>
 
 
 		<p class="desc">
 		<p class="desc">
-			Can be used to orient an object based on the mobile device's orientation.
+			Can be used to orient the camera based on the mobile device's orientation.
 		</p>
 		</p>
 
 
 		<h2>Example</h2>
 		<h2>Example</h2>
@@ -21,10 +21,10 @@
 
 
 		<h2>Constructor</h2>
 		<h2>Constructor</h2>
 
 
-		<h3>[name]( [param:Object3D object] )</h3>
+		<h3>[name]( [param:Camera object] )</h3>
 		<p>
 		<p>
 			<p>
 			<p>
-				[page:Object3D object]: The object to be controlled.
+				[page:Camera object]: The camera to be controlled.
 			</p>
 			</p>
 			<p>
 			<p>
 				Creates a new instance of [name].
 				Creates a new instance of [name].
@@ -48,9 +48,9 @@
 			Whether or not the controls are enabled.
 			Whether or not the controls are enabled.
 		</p>
 		</p>
 
 
-		<h3>[property:Object3D object]</h3>
+		<h3>[property:Camera object]</h3>
 		<p>
 		<p>
-			The object to be controlled.
+			The camera to be controlled.
 		</p>
 		</p>
 
 
 		<h3>[property:Number screenOrientation]</h3>
 		<h3>[property:Number screenOrientation]</h3>

+ 3 - 3
examples/jsm/controls/DeviceOrientationControls.d.ts

@@ -1,12 +1,12 @@
 import {
 import {
-	Object3D
+	Camera
 } from '../../../src/Three';
 } from '../../../src/Three';
 
 
 export class DeviceOrientationControls {
 export class DeviceOrientationControls {
 
 
-	constructor( object: Object3D );
+	constructor( object: Camera );
 
 
-	object: Object3D;
+	object: Camera;
 
 
 	// API
 	// API