@flighthq/lighting 0.3.0-next.906.07cea63 → 0.3.0

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.
@@ -1,7 +1,7 @@
1
1
  import { createEntity } from '@flighthq/entity/contract';
2
2
  import { EnvironmentKind } from '@flighthq/types/contract';
3
3
  // Independent copy of the environment's data. The `environment` cubemap reference is shared, not
4
- // deep-copied: a CubeTexture is a GPU-backed resource, so the copy aliases the same source.
4
+ // deep-copied: a Texture is a GPU-backed resource, so the copy aliases the same source.
5
5
  export function cloneEnvironment(source) {
6
6
  return createEnvironment({ environment: source.environment, intensity: source.intensity });
7
7
  }
@@ -1 +1 @@
1
- {"version":3,"file":"environment.js","sourceRoot":"","sources":["../src/environment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE3D,iGAAiG;AACjG,4FAA4F;AAC5F,MAAM,UAAU,gBAAgB,CAAC,MAA6B;IAC5D,OAAO,iBAAiB,CAAC,EAAE,WAAW,EAAE,MAAM,CAAC,WAAW,EAAE,SAAS,EAAE,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC;AAC7F,CAAC;AAED,+FAA+F;AAC/F,iGAAiG;AACjG,mDAAmD;AACnD,MAAM,UAAU,iBAAiB,CAAC,OAAsC;IACtE,OAAO,YAAY,CAAC;QAClB,WAAW,EAAE,OAAO,EAAE,WAAW,IAAI,IAAI;QACzC,SAAS,EAAE,OAAO,EAAE,SAAS,IAAI,CAAC;QAClC,IAAI,EAAE,eAAe;KACtB,CAAC,CAAC;AACL,CAAC"}
1
+ {"version":3,"file":"environment.js","sourceRoot":"","sources":["../src/environment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEzD,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAE3D,iGAAiG;AACjG,wFAAwF;AACxF,MAAM,UAAU,gBAAgB,CAAC,MAA6B;IAC5D,OAAO,iBAAiB,CAAC,EAAE,WAAW,EAAE,MAAM,CAAC,WAAW,EAAE,SAAS,EAAE,MAAM,CAAC,SAAS,EAAE,CAAC,CAAC;AAC7F,CAAC;AAED,+FAA+F;AAC/F,iGAAiG;AACjG,mDAAmD;AACnD,MAAM,UAAU,iBAAiB,CAAC,OAAsC;IACtE,OAAO,YAAY,CAAC;QAClB,WAAW,EAAE,OAAO,EAAE,WAAW,IAAI,IAAI;QACzC,SAAS,EAAE,OAAO,EAAE,SAAS,IAAI,CAAC;QAClC,IAAI,EAAE,eAAe;KACtB,CAAC,CAAC;AACL,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,8 @@
1
1
  {
2
2
  "name": "@flighthq/lighting",
3
- "version": "0.3.0-next.906.07cea63",
3
+ "version": "0.3.0",
4
+ "author": "Joshua Granick and other contributors",
5
+ "license": "MIT",
4
6
  "repository": {
5
7
  "type": "git",
6
8
  "url": "https://github.com/flighthq/flight.git",
@@ -36,10 +38,10 @@
36
38
  "clean:dist": "tsx ../../scripts/clean-package-dist.ts"
37
39
  },
38
40
  "dependencies": {
39
- "@flighthq/color": "0.3.0-next.906.07cea63",
40
- "@flighthq/entity": "0.3.0-next.906.07cea63",
41
- "@flighthq/geometry": "0.3.0-next.906.07cea63",
42
- "@flighthq/types": "0.3.0-next.906.07cea63"
41
+ "@flighthq/color": "0.3.0",
42
+ "@flighthq/entity": "0.3.0",
43
+ "@flighthq/geometry": "0.3.0",
44
+ "@flighthq/types": "0.3.0"
43
45
  },
44
46
  "devDependencies": {
45
47
  "typescript": "^5.3.0"
@@ -1,10 +1,11 @@
1
1
  import { createEntity } from '@flighthq/entity/contract';
2
- import type { CubeTexture, Sampler } from '@flighthq/types/contract';
2
+ import { createVector2 } from '@flighthq/geometry/contract';
3
+ import type { Texture, Sampler } from '@flighthq/types/contract';
3
4
  import { EnvironmentKind } from '@flighthq/types/contract';
4
5
 
5
6
  import { cloneEnvironment, createEnvironment } from './environment';
6
7
 
7
- function createTestCubeTexture(): CubeTexture {
8
+ function createTestCubeTexture(): Texture {
8
9
  const sampler: Sampler = createEntity({
9
10
  anisotropy: 1,
10
11
  magFilter: 'linear',
@@ -15,8 +16,15 @@ function createTestCubeTexture(): CubeTexture {
15
16
  });
16
17
  return createEntity({
17
18
  colorSpace: 'linear',
18
- faces: [null, null, null, null, null, null],
19
+ flipX: false,
20
+ flipY: false,
19
21
  sampler,
22
+ dimension: 'cube',
23
+ sources: [null, null, null, null, null, null],
24
+ uvOffset: createVector2(),
25
+ uvRotation: 0,
26
+ uvScale: createVector2(1, 1),
27
+ version: 0,
20
28
  });
21
29
  }
22
30