babylon.arcRotateCamera.js 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493
  1. var __extends = this.__extends || function (d, b) {
  2. for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
  3. function __() { this.constructor = d; }
  4. __.prototype = b.prototype;
  5. d.prototype = new __();
  6. };
  7. var BABYLON;
  8. (function (BABYLON) {
  9. var eventPrefix = BABYLON.Tools.GetPointerPrefix();
  10. var ArcRotateCamera = (function (_super) {
  11. __extends(ArcRotateCamera, _super);
  12. function ArcRotateCamera(name, alpha, beta, radius, target, scene) {
  13. var _this = this;
  14. _super.call(this, name, BABYLON.Vector3.Zero(), scene);
  15. this.alpha = alpha;
  16. this.beta = beta;
  17. this.radius = radius;
  18. this.target = target;
  19. this.inertialAlphaOffset = 0;
  20. this.inertialBetaOffset = 0;
  21. this.inertialRadiusOffset = 0;
  22. this.lowerAlphaLimit = null;
  23. this.upperAlphaLimit = null;
  24. this.lowerBetaLimit = 0.01;
  25. this.upperBetaLimit = Math.PI;
  26. this.lowerRadiusLimit = null;
  27. this.upperRadiusLimit = null;
  28. this.angularSensibility = 1000.0;
  29. this.wheelPrecision = 3.0;
  30. this.pinchPrecision = 2.0;
  31. this.keysUp = [38];
  32. this.keysDown = [40];
  33. this.keysLeft = [37];
  34. this.keysRight = [39];
  35. this.zoomOnFactor = 1;
  36. this.targetScreenOffset = BABYLON.Vector2.Zero();
  37. this.pinchInwards = true;
  38. this.allowUpsideDown = true;
  39. this._keys = [];
  40. this._viewMatrix = new BABYLON.Matrix();
  41. this.checkCollisions = false;
  42. this.collisionRadius = new BABYLON.Vector3(0.5, 0.5, 0.5);
  43. this._collider = new BABYLON.Collider();
  44. this._previousPosition = BABYLON.Vector3.Zero();
  45. this._collisionVelocity = BABYLON.Vector3.Zero();
  46. this._newPosition = BABYLON.Vector3.Zero();
  47. this._onCollisionPositionChange = function (collisionId, newPosition, collidedMesh) {
  48. if (collidedMesh === void 0) { collidedMesh = null; }
  49. if (_this.getScene().workerCollisions && _this.checkCollisions) {
  50. newPosition.multiplyInPlace(_this._collider.radius);
  51. }
  52. if (!collidedMesh) {
  53. _this._previousPosition.copyFrom(_this.position);
  54. }
  55. else {
  56. _this.setPosition(_this.position);
  57. if (_this.onCollide) {
  58. _this.onCollide(collidedMesh);
  59. }
  60. }
  61. // Recompute because of constraints
  62. var cosa = Math.cos(_this.alpha);
  63. var sina = Math.sin(_this.alpha);
  64. var cosb = Math.cos(_this.beta);
  65. var sinb = Math.sin(_this.beta);
  66. var target = _this._getTargetPosition();
  67. target.addToRef(new BABYLON.Vector3(_this.radius * cosa * sinb, _this.radius * cosb, _this.radius * sina * sinb), _this._newPosition);
  68. _this.position.copyFrom(_this._newPosition);
  69. var up = _this.upVector;
  70. if (_this.allowUpsideDown && _this.beta < 0) {
  71. var up = up.clone();
  72. up = up.negate();
  73. }
  74. BABYLON.Matrix.LookAtLHToRef(_this.position, target, up, _this._viewMatrix);
  75. _this._viewMatrix.m[12] += _this.targetScreenOffset.x;
  76. _this._viewMatrix.m[13] += _this.targetScreenOffset.y;
  77. _this._collisionTriggered = false;
  78. };
  79. if (!this.target) {
  80. this.target = BABYLON.Vector3.Zero();
  81. }
  82. this.getViewMatrix();
  83. }
  84. ArcRotateCamera.prototype._getTargetPosition = function () {
  85. return this.target.position || this.target;
  86. };
  87. // Cache
  88. ArcRotateCamera.prototype._initCache = function () {
  89. _super.prototype._initCache.call(this);
  90. this._cache.target = new BABYLON.Vector3(Number.MAX_VALUE, Number.MAX_VALUE, Number.MAX_VALUE);
  91. this._cache.alpha = undefined;
  92. this._cache.beta = undefined;
  93. this._cache.radius = undefined;
  94. this._cache.targetScreenOffset = undefined;
  95. };
  96. ArcRotateCamera.prototype._updateCache = function (ignoreParentClass) {
  97. if (!ignoreParentClass) {
  98. _super.prototype._updateCache.call(this);
  99. }
  100. this._cache.target.copyFrom(this._getTargetPosition());
  101. this._cache.alpha = this.alpha;
  102. this._cache.beta = this.beta;
  103. this._cache.radius = this.radius;
  104. this._cache.targetScreenOffset = this.targetScreenOffset.clone();
  105. };
  106. // Synchronized
  107. ArcRotateCamera.prototype._isSynchronizedViewMatrix = function () {
  108. if (!_super.prototype._isSynchronizedViewMatrix.call(this))
  109. return false;
  110. return this._cache.target.equals(this._getTargetPosition())
  111. && this._cache.alpha === this.alpha
  112. && this._cache.beta === this.beta
  113. && this._cache.radius === this.radius
  114. && this._cache.targetScreenOffset.equals(this.targetScreenOffset);
  115. };
  116. // Methods
  117. ArcRotateCamera.prototype.attachControl = function (element, noPreventDefault) {
  118. var _this = this;
  119. var cacheSoloPointer; // cache pointer object for better perf on camera rotation
  120. var previousPinchDistance = 0;
  121. var pointers = new BABYLON.SmartCollection();
  122. if (this._attachedElement) {
  123. return;
  124. }
  125. this._attachedElement = element;
  126. var engine = this.getEngine();
  127. if (this._onPointerDown === undefined) {
  128. this._onPointerDown = function (evt) {
  129. pointers.add(evt.pointerId, { x: evt.clientX, y: evt.clientY, type: evt.pointerType });
  130. cacheSoloPointer = pointers.item(evt.pointerId);
  131. if (!noPreventDefault) {
  132. evt.preventDefault();
  133. }
  134. };
  135. this._onPointerUp = function (evt) {
  136. cacheSoloPointer = null;
  137. previousPinchDistance = 0;
  138. //would be better to use pointers.remove(evt.pointerId) for multitouch gestures,
  139. //but emptying completly pointers collection is required to fix a bug on iPhone :
  140. //when changing orientation while pinching camera, one pointer stay pressed forever if we don't release all pointers
  141. //will be ok to put back pointers.remove(evt.pointerId); when iPhone bug corrected
  142. pointers.empty();
  143. if (!noPreventDefault) {
  144. evt.preventDefault();
  145. }
  146. };
  147. this._onPointerMove = function (evt) {
  148. if (!noPreventDefault) {
  149. evt.preventDefault();
  150. }
  151. switch (pointers.count) {
  152. case 1:
  153. var offsetX = evt.clientX - cacheSoloPointer.x;
  154. var offsetY = evt.clientY - cacheSoloPointer.y;
  155. _this.inertialAlphaOffset -= offsetX / _this.angularSensibility;
  156. _this.inertialBetaOffset -= offsetY / _this.angularSensibility;
  157. cacheSoloPointer.x = evt.clientX;
  158. cacheSoloPointer.y = evt.clientY;
  159. break;
  160. case 2:
  161. //if (noPreventDefault) { evt.preventDefault(); } //if pinch gesture, could be usefull to force preventDefault to avoid html page scroll/zoom in some mobile browsers
  162. pointers.item(evt.pointerId).x = evt.clientX;
  163. pointers.item(evt.pointerId).y = evt.clientY;
  164. var direction = _this.pinchInwards ? 1 : -1;
  165. var distX = pointers.getItemByIndex(0).x - pointers.getItemByIndex(1).x;
  166. var distY = pointers.getItemByIndex(0).y - pointers.getItemByIndex(1).y;
  167. var pinchSquaredDistance = (distX * distX) + (distY * distY);
  168. if (previousPinchDistance === 0) {
  169. previousPinchDistance = pinchSquaredDistance;
  170. return;
  171. }
  172. if (pinchSquaredDistance !== previousPinchDistance) {
  173. _this.inertialRadiusOffset += (pinchSquaredDistance - previousPinchDistance) / (_this.pinchPrecision * _this.wheelPrecision * _this.angularSensibility * direction);
  174. previousPinchDistance = pinchSquaredDistance;
  175. }
  176. break;
  177. default:
  178. if (pointers.item(evt.pointerId)) {
  179. pointers.item(evt.pointerId).x = evt.clientX;
  180. pointers.item(evt.pointerId).y = evt.clientY;
  181. }
  182. }
  183. };
  184. this._onMouseMove = function (evt) {
  185. if (!engine.isPointerLock) {
  186. return;
  187. }
  188. var offsetX = evt.movementX || evt.mozMovementX || evt.webkitMovementX || evt.msMovementX || 0;
  189. var offsetY = evt.movementY || evt.mozMovementY || evt.webkitMovementY || evt.msMovementY || 0;
  190. _this.inertialAlphaOffset -= offsetX / _this.angularSensibility;
  191. _this.inertialBetaOffset -= offsetY / _this.angularSensibility;
  192. if (!noPreventDefault) {
  193. evt.preventDefault();
  194. }
  195. };
  196. this._wheel = function (event) {
  197. var delta = 0;
  198. if (event.wheelDelta) {
  199. delta = event.wheelDelta / (_this.wheelPrecision * 40);
  200. }
  201. else if (event.detail) {
  202. delta = -event.detail / _this.wheelPrecision;
  203. }
  204. if (delta)
  205. _this.inertialRadiusOffset += delta;
  206. if (event.preventDefault) {
  207. if (!noPreventDefault) {
  208. event.preventDefault();
  209. }
  210. }
  211. };
  212. this._onKeyDown = function (evt) {
  213. if (_this.keysUp.indexOf(evt.keyCode) !== -1 ||
  214. _this.keysDown.indexOf(evt.keyCode) !== -1 ||
  215. _this.keysLeft.indexOf(evt.keyCode) !== -1 ||
  216. _this.keysRight.indexOf(evt.keyCode) !== -1) {
  217. var index = _this._keys.indexOf(evt.keyCode);
  218. if (index === -1) {
  219. _this._keys.push(evt.keyCode);
  220. }
  221. if (evt.preventDefault) {
  222. if (!noPreventDefault) {
  223. evt.preventDefault();
  224. }
  225. }
  226. }
  227. };
  228. this._onKeyUp = function (evt) {
  229. if (_this.keysUp.indexOf(evt.keyCode) !== -1 ||
  230. _this.keysDown.indexOf(evt.keyCode) !== -1 ||
  231. _this.keysLeft.indexOf(evt.keyCode) !== -1 ||
  232. _this.keysRight.indexOf(evt.keyCode) !== -1) {
  233. var index = _this._keys.indexOf(evt.keyCode);
  234. if (index >= 0) {
  235. _this._keys.splice(index, 1);
  236. }
  237. if (evt.preventDefault) {
  238. if (!noPreventDefault) {
  239. evt.preventDefault();
  240. }
  241. }
  242. }
  243. };
  244. this._onLostFocus = function () {
  245. _this._keys = [];
  246. pointers.empty();
  247. previousPinchDistance = 0;
  248. cacheSoloPointer = null;
  249. };
  250. this._onGestureStart = function (e) {
  251. if (window.MSGesture === undefined) {
  252. return;
  253. }
  254. if (!_this._MSGestureHandler) {
  255. _this._MSGestureHandler = new MSGesture();
  256. _this._MSGestureHandler.target = element;
  257. }
  258. _this._MSGestureHandler.addPointer(e.pointerId);
  259. };
  260. this._onGesture = function (e) {
  261. _this.radius *= e.scale;
  262. if (e.preventDefault) {
  263. if (!noPreventDefault) {
  264. e.stopPropagation();
  265. e.preventDefault();
  266. }
  267. }
  268. };
  269. this._reset = function () {
  270. _this._keys = [];
  271. _this.inertialAlphaOffset = 0;
  272. _this.inertialBetaOffset = 0;
  273. _this.inertialRadiusOffset = 0;
  274. pointers.empty();
  275. previousPinchDistance = 0;
  276. cacheSoloPointer = null;
  277. };
  278. }
  279. element.addEventListener(eventPrefix + "down", this._onPointerDown, false);
  280. element.addEventListener(eventPrefix + "up", this._onPointerUp, false);
  281. element.addEventListener(eventPrefix + "out", this._onPointerUp, false);
  282. element.addEventListener(eventPrefix + "move", this._onPointerMove, false);
  283. element.addEventListener("mousemove", this._onMouseMove, false);
  284. element.addEventListener("MSPointerDown", this._onGestureStart, false);
  285. element.addEventListener("MSGestureChange", this._onGesture, false);
  286. element.addEventListener('mousewheel', this._wheel, false);
  287. element.addEventListener('DOMMouseScroll', this._wheel, false);
  288. BABYLON.Tools.RegisterTopRootEvents([
  289. { name: "keydown", handler: this._onKeyDown },
  290. { name: "keyup", handler: this._onKeyUp },
  291. { name: "blur", handler: this._onLostFocus }
  292. ]);
  293. };
  294. ArcRotateCamera.prototype.detachControl = function (element) {
  295. if (this._attachedElement !== element) {
  296. return;
  297. }
  298. element.removeEventListener(eventPrefix + "down", this._onPointerDown);
  299. element.removeEventListener(eventPrefix + "up", this._onPointerUp);
  300. element.removeEventListener(eventPrefix + "out", this._onPointerUp);
  301. element.removeEventListener(eventPrefix + "move", this._onPointerMove);
  302. element.removeEventListener("mousemove", this._onMouseMove);
  303. element.removeEventListener("MSPointerDown", this._onGestureStart);
  304. element.removeEventListener("MSGestureChange", this._onGesture);
  305. element.removeEventListener('mousewheel', this._wheel);
  306. element.removeEventListener('DOMMouseScroll', this._wheel);
  307. BABYLON.Tools.UnregisterTopRootEvents([
  308. { name: "keydown", handler: this._onKeyDown },
  309. { name: "keyup", handler: this._onKeyUp },
  310. { name: "blur", handler: this._onLostFocus }
  311. ]);
  312. this._MSGestureHandler = null;
  313. this._attachedElement = null;
  314. if (this._reset) {
  315. this._reset();
  316. }
  317. };
  318. ArcRotateCamera.prototype._checkInputs = function () {
  319. //if (async) collision inspection was triggered, don't update the camera's position - until the collision callback was called.
  320. if (this._collisionTriggered) {
  321. return;
  322. }
  323. // Keyboard
  324. for (var index = 0; index < this._keys.length; index++) {
  325. var keyCode = this._keys[index];
  326. if (this.keysLeft.indexOf(keyCode) !== -1) {
  327. this.inertialAlphaOffset -= 0.01;
  328. }
  329. else if (this.keysUp.indexOf(keyCode) !== -1) {
  330. this.inertialBetaOffset -= 0.01;
  331. }
  332. else if (this.keysRight.indexOf(keyCode) !== -1) {
  333. this.inertialAlphaOffset += 0.01;
  334. }
  335. else if (this.keysDown.indexOf(keyCode) !== -1) {
  336. this.inertialBetaOffset += 0.01;
  337. }
  338. }
  339. // Inertia
  340. if (this.inertialAlphaOffset !== 0 || this.inertialBetaOffset !== 0 || this.inertialRadiusOffset != 0) {
  341. this.alpha += this.beta <= 0 ? -this.inertialAlphaOffset : this.inertialAlphaOffset;
  342. this.beta += this.inertialBetaOffset;
  343. this.radius -= this.inertialRadiusOffset;
  344. this.inertialAlphaOffset *= this.inertia;
  345. this.inertialBetaOffset *= this.inertia;
  346. this.inertialRadiusOffset *= this.inertia;
  347. if (Math.abs(this.inertialAlphaOffset) < BABYLON.Engine.Epsilon)
  348. this.inertialAlphaOffset = 0;
  349. if (Math.abs(this.inertialBetaOffset) < BABYLON.Engine.Epsilon)
  350. this.inertialBetaOffset = 0;
  351. if (Math.abs(this.inertialRadiusOffset) < BABYLON.Engine.Epsilon)
  352. this.inertialRadiusOffset = 0;
  353. }
  354. // Limits
  355. this._checkLimits();
  356. _super.prototype._checkInputs.call(this);
  357. };
  358. ArcRotateCamera.prototype._checkLimits = function () {
  359. if (this.lowerBetaLimit === null || this.lowerBetaLimit === undefined) {
  360. if (this.allowUpsideDown && this.beta > Math.PI) {
  361. this.beta = this.beta - (2 * Math.PI);
  362. }
  363. }
  364. else {
  365. if (this.beta < this.lowerBetaLimit) {
  366. this.beta = this.lowerBetaLimit;
  367. }
  368. }
  369. if (this.upperBetaLimit === null || this.upperBetaLimit === undefined) {
  370. if (this.allowUpsideDown && this.beta < -Math.PI) {
  371. this.beta = this.beta + (2 * Math.PI);
  372. }
  373. }
  374. else {
  375. if (this.beta > this.upperBetaLimit) {
  376. this.beta = this.upperBetaLimit;
  377. }
  378. }
  379. if (this.lowerAlphaLimit && this.alpha < this.lowerAlphaLimit) {
  380. this.alpha = this.lowerAlphaLimit;
  381. }
  382. if (this.upperAlphaLimit && this.alpha > this.upperAlphaLimit) {
  383. this.alpha = this.upperAlphaLimit;
  384. }
  385. if (this.lowerRadiusLimit && this.radius < this.lowerRadiusLimit) {
  386. this.radius = this.lowerRadiusLimit;
  387. }
  388. if (this.upperRadiusLimit && this.radius > this.upperRadiusLimit) {
  389. this.radius = this.upperRadiusLimit;
  390. }
  391. };
  392. ArcRotateCamera.prototype.setPosition = function (position) {
  393. var radiusv3 = position.subtract(this._getTargetPosition());
  394. this.radius = radiusv3.length();
  395. // Alpha
  396. this.alpha = Math.acos(radiusv3.x / Math.sqrt(Math.pow(radiusv3.x, 2) + Math.pow(radiusv3.z, 2)));
  397. if (radiusv3.z < 0) {
  398. this.alpha = 2 * Math.PI - this.alpha;
  399. }
  400. // Beta
  401. this.beta = Math.acos(radiusv3.y / this.radius);
  402. this._checkLimits();
  403. };
  404. ArcRotateCamera.prototype._getViewMatrix = function () {
  405. // Compute
  406. var cosa = Math.cos(this.alpha);
  407. var sina = Math.sin(this.alpha);
  408. var cosb = Math.cos(this.beta);
  409. var sinb = Math.sin(this.beta);
  410. var target = this._getTargetPosition();
  411. target.addToRef(new BABYLON.Vector3(this.radius * cosa * sinb, this.radius * cosb, this.radius * sina * sinb), this._newPosition);
  412. if (this.getScene().collisionsEnabled && this.checkCollisions) {
  413. this._collider.radius = this.collisionRadius;
  414. this._newPosition.subtractToRef(this.position, this._collisionVelocity);
  415. this._collisionTriggered = true;
  416. this.getScene().collisionCoordinator.getNewPosition(this.position, this._collisionVelocity, this._collider, 3, null, this._onCollisionPositionChange, this.uniqueId);
  417. }
  418. else {
  419. this.position.copyFrom(this._newPosition);
  420. var up = this.upVector;
  421. if (this.allowUpsideDown && this.beta < 0) {
  422. var up = up.clone();
  423. up = up.negate();
  424. }
  425. BABYLON.Matrix.LookAtLHToRef(this.position, target, up, this._viewMatrix);
  426. this._viewMatrix.m[12] += this.targetScreenOffset.x;
  427. this._viewMatrix.m[13] += this.targetScreenOffset.y;
  428. }
  429. return this._viewMatrix;
  430. };
  431. ArcRotateCamera.prototype.zoomOn = function (meshes) {
  432. meshes = meshes || this.getScene().meshes;
  433. var minMaxVector = BABYLON.Mesh.MinMax(meshes);
  434. var distance = BABYLON.Vector3.Distance(minMaxVector.min, minMaxVector.max);
  435. this.radius = distance * this.zoomOnFactor;
  436. this.focusOn({ min: minMaxVector.min, max: minMaxVector.max, distance: distance });
  437. };
  438. ArcRotateCamera.prototype.focusOn = function (meshesOrMinMaxVectorAndDistance) {
  439. var meshesOrMinMaxVector;
  440. var distance;
  441. if (meshesOrMinMaxVectorAndDistance.min === undefined) {
  442. meshesOrMinMaxVector = meshesOrMinMaxVectorAndDistance || this.getScene().meshes;
  443. meshesOrMinMaxVector = BABYLON.Mesh.MinMax(meshesOrMinMaxVector);
  444. distance = BABYLON.Vector3.Distance(meshesOrMinMaxVector.min, meshesOrMinMaxVector.max);
  445. }
  446. else {
  447. meshesOrMinMaxVector = meshesOrMinMaxVectorAndDistance;
  448. distance = meshesOrMinMaxVectorAndDistance.distance;
  449. }
  450. this.target = BABYLON.Mesh.Center(meshesOrMinMaxVector);
  451. this.maxZ = distance * 2;
  452. };
  453. /**
  454. * @override
  455. * Override Camera.createRigCamera
  456. */
  457. ArcRotateCamera.prototype.createRigCamera = function (name, cameraIndex) {
  458. switch (this.cameraRigMode) {
  459. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_ANAGLYPH:
  460. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL:
  461. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED:
  462. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_OVERUNDER:
  463. case BABYLON.Camera.RIG_MODE_VR:
  464. var alphaShift = this._cameraRigParams.stereoHalfAngle * (cameraIndex === 0 ? 1 : -1);
  465. return new ArcRotateCamera(name, this.alpha + alphaShift, this.beta, this.radius, this.target, this.getScene());
  466. }
  467. };
  468. /**
  469. * @override
  470. * Override Camera._updateRigCameras
  471. */
  472. ArcRotateCamera.prototype._updateRigCameras = function () {
  473. switch (this.cameraRigMode) {
  474. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_ANAGLYPH:
  475. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_PARALLEL:
  476. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_SIDEBYSIDE_CROSSEYED:
  477. case BABYLON.Camera.RIG_MODE_STEREOSCOPIC_OVERUNDER:
  478. case BABYLON.Camera.RIG_MODE_VR:
  479. var camLeft = this._rigCameras[0];
  480. var camRight = this._rigCameras[1];
  481. camLeft.alpha = this.alpha - this._cameraRigParams.stereoHalfAngle;
  482. camRight.alpha = this.alpha + this._cameraRigParams.stereoHalfAngle;
  483. camLeft.beta = camRight.beta = this.beta;
  484. camLeft.radius = camRight.radius = this.radius;
  485. break;
  486. }
  487. _super.prototype._updateRigCameras.call(this);
  488. };
  489. return ArcRotateCamera;
  490. })(BABYLON.Camera);
  491. BABYLON.ArcRotateCamera = ArcRotateCamera;
  492. })(BABYLON || (BABYLON = {}));
  493. //# sourceMappingURL=babylon.arcRotateCamera.js.map