@flighthq/camera-controls 0.5.1-next.903.f434bc2 → 0.5.1-next.905.5fbf787

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -13,5 +13,5 @@ Import the supported application-facing API from `@flighthq/camera-controls`. Th
13
13
  This package is part of the locked-version Flight SDK graph. Applications may instead install and import `@flighthq/sdk` when package-level tree shaking is sufficient.
14
14
 
15
15
  - [Flight project](https://github.com/flighthq/flight)
16
- - [Source for @flighthq/camera-controls@0.5.1-next.903.f434bc2](https://github.com/flighthq/flight/tree/f434bc233778d75aeea61995df3a8cfaec459a85/packages/camera-controls)
17
- - [License](https://github.com/flighthq/flight/blob/f434bc233778d75aeea61995df3a8cfaec459a85/LICENSE.md)
16
+ - [Source for @flighthq/camera-controls@0.5.1-next.905.5fbf787](https://github.com/flighthq/flight/tree/5fbf7874064c384307542d68b4dcb6a895ff0dcf/packages/camera-controls)
17
+ - [License](https://github.com/flighthq/flight/blob/5fbf7874064c384307542d68b4dcb6a895ff0dcf/LICENSE.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flighthq/camera-controls",
3
- "version": "0.5.1-next.903.f434bc2",
3
+ "version": "0.5.1-next.905.5fbf787",
4
4
  "author": "Joshua Granick and other contributors",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -38,11 +38,11 @@
38
38
  "clean:dist": "tsx ../../scripts/clean-package-dist.ts"
39
39
  },
40
40
  "dependencies": {
41
- "@flighthq/camera": "0.5.1-next.903.f434bc2",
42
- "@flighthq/entity": "0.5.1-next.903.f434bc2",
43
- "@flighthq/geometry": "0.5.1-next.903.f434bc2",
44
- "@flighthq/math": "0.5.1-next.903.f434bc2",
45
- "@flighthq/types": "0.5.1-next.903.f434bc2"
41
+ "@flighthq/camera": "0.5.1-next.905.5fbf787",
42
+ "@flighthq/entity": "0.5.1-next.905.5fbf787",
43
+ "@flighthq/geometry": "0.5.1-next.905.5fbf787",
44
+ "@flighthq/math": "0.5.1-next.905.5fbf787",
45
+ "@flighthq/types": "0.5.1-next.905.5fbf787"
46
46
  },
47
47
  "devDependencies": {
48
48
  "typescript": "^5.3.0"
@@ -4,6 +4,8 @@ import {
4
4
  addCameraShakeTrauma,
5
5
  createCameraShake,
6
6
  createCameraShakeOffset,
7
+ initializeCameraShake,
8
+ initializeCameraShakeOffset,
7
9
  resetCameraShake,
8
10
  updateCameraShake,
9
11
  } from './cameraShake';
@@ -58,6 +60,17 @@ describe('createCameraShakeOffset', () => {
58
60
  });
59
61
  });
60
62
 
63
+ describe('initializeCameraShake', () => {
64
+ it('is the construction initializer of createCameraShake', () => {
65
+ expect(typeof initializeCameraShake).toBe('function');
66
+ });
67
+ });
68
+
69
+ describe('initializeCameraShakeOffset', () => {
70
+ it('is the construction initializer of createCameraShakeOffset', () => {
71
+ expect(typeof initializeCameraShakeOffset).toBe('function');
72
+ });
73
+ });
61
74
  describe('resetCameraShake', () => {
62
75
  it('zeros trauma and time', () => {
63
76
  const shake = createCameraShake();
@@ -11,6 +11,7 @@ import {
11
11
  cloneFlyCameraController,
12
12
  copyFlyCameraController,
13
13
  createFlyCameraController,
14
+ initializeFlyCameraController,
14
15
  lookFlyCameraController,
15
16
  moveFlyCameraController,
16
17
  resetFlyCameraController,
@@ -69,6 +70,12 @@ describe('createFlyCameraController', () => {
69
70
  });
70
71
  });
71
72
 
73
+ describe('initializeFlyCameraController', () => {
74
+ it('is the construction initializer of createFlyCameraController', () => {
75
+ expect(typeof initializeFlyCameraController).toBe('function');
76
+ });
77
+ });
78
+
72
79
  describe('lookFlyCameraController', () => {
73
80
  it('adds to the goal angles and clamps pitch', () => {
74
81
  const c = createFlyCameraController({ minPitch: -1, maxPitch: 1 });
@@ -107,7 +114,6 @@ describe('snapFlyCameraController', () => {
107
114
  expect(c.yaw).toBe(3);
108
115
  });
109
116
  });
110
-
111
117
  describe('updateFlyCameraController', () => {
112
118
  it('snaps to the goal when smoothTime is 0 and writes the look-at view', () => {
113
119
  const c = createFlyCameraController({ position: createVector3(0, 0, 5) }); // yaw/pitch 0 => looks toward -Z
@@ -12,10 +12,11 @@ import {
12
12
  copyOrbitCameraController,
13
13
  createOrbitCameraController,
14
14
  dollyOrbitCameraController,
15
- rotateOrbitCameraController,
15
+ initializeOrbitCameraController,
16
16
  panOrbitCameraController,
17
17
  panOrbitCameraControllerInViewPlane,
18
18
  resetOrbitCameraController,
19
+ rotateOrbitCameraController,
19
20
  snapOrbitCameraController,
20
21
  updateOrbitCameraController,
21
22
  } from './orbitCameraController';
@@ -86,6 +87,12 @@ describe('dollyOrbitCameraController', () => {
86
87
  });
87
88
  });
88
89
 
90
+ describe('initializeOrbitCameraController', () => {
91
+ it('is the construction initializer of createOrbitCameraController', () => {
92
+ expect(typeof initializeOrbitCameraController).toBe('function');
93
+ });
94
+ });
95
+
89
96
  describe('panOrbitCameraController', () => {
90
97
  it('slides the target along right (at azimuth 0) and world up', () => {
91
98
  const c = createOrbitCameraController();
@@ -141,7 +148,6 @@ describe('snapOrbitCameraController', () => {
141
148
  expect(c.polar).toBe(0.5);
142
149
  });
143
150
  });
144
-
145
151
  describe('updateOrbitCameraController', () => {
146
152
  it('snaps to the goal when smoothTime is 0 and writes the look-at view', () => {
147
153
  const c = createOrbitCameraController({ distance: 10 }); // azimuth 0, polar 0 => eye (0,0,10)