@aelionsdk/renderer-worker 0.1.0-beta.1 → 1.1.0-rc.1
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 +25 -4
- package/dist/ir-renderer.d.ts +5 -1
- package/dist/ir-renderer.d.ts.map +1 -1
- package/dist/ir-renderer.js +2 -0
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -1,7 +1,28 @@
|
|
|
1
|
-
#
|
|
1
|
+
# `@aelionsdk/renderer-worker`
|
|
2
2
|
|
|
3
|
-
Off-main-thread WebGL2 and
|
|
3
|
+
Off-main-thread WebGL2/WebGPU composition and Worker protocol for AelionSDK.
|
|
4
4
|
|
|
5
|
-
Install
|
|
5
|
+
## Install
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
```bash
|
|
8
|
+
npm install @aelionsdk/renderer-worker@next
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
`next` currently resolves to `1.1.0-rc.1`. Applications should create preview
|
|
12
|
+
surfaces through `@aelionsdk/sdk`; use this package directly for a custom render
|
|
13
|
+
host or Worker transport.
|
|
14
|
+
|
|
15
|
+
## Public surface
|
|
16
|
+
|
|
17
|
+
- renderer Worker client and protocol;
|
|
18
|
+
- Render IR compositor;
|
|
19
|
+
- WebGL2/WebGPU backend selection;
|
|
20
|
+
- font management and transferable frame results.
|
|
21
|
+
|
|
22
|
+
Frame results have explicit ownership. Close bitmaps that are not presented,
|
|
23
|
+
cancel superseded requests and dispose the Worker client so queued work and GPU
|
|
24
|
+
resources can drain.
|
|
25
|
+
|
|
26
|
+
See the [architecture guide](https://foyonaczy.github.io/AelionSDK/concepts/architecture/)
|
|
27
|
+
and [API reference](https://foyonaczy.github.io/AelionSDK/api/aelionsdk/renderer-worker/overview/).
|
|
28
|
+
Licensed under MIT.
|
package/dist/ir-renderer.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type Disposable } from '@aelionsdk/core';
|
|
2
2
|
import { type RenderIr } from '@aelionsdk/render-ir';
|
|
3
3
|
import { type WorkerCompositorSnapshot } from './client.js';
|
|
4
|
-
import type { RendererWorkerDiagnostic } from './protocol.js';
|
|
4
|
+
import type { RendererWorkerDiagnostic, RendererWorkerResourceSnapshot, RendererWorkerTiming } from './protocol.js';
|
|
5
5
|
export type RenderMode = 'preview' | 'export';
|
|
6
6
|
export interface IrFrameRequest {
|
|
7
7
|
readonly purpose: RenderMode;
|
|
@@ -25,6 +25,10 @@ export interface RenderIrFrameResult {
|
|
|
25
25
|
readonly bitmap: ImageBitmap;
|
|
26
26
|
readonly backend: 'webgpu' | 'webgl2';
|
|
27
27
|
readonly diagnostics?: readonly RendererWorkerDiagnostic[];
|
|
28
|
+
/** Measured Worker and backend-completion time for this frame. */
|
|
29
|
+
readonly timing?: RendererWorkerTiming;
|
|
30
|
+
/** Transient resources after composition; the returned bitmap remains caller-owned. */
|
|
31
|
+
readonly resources?: RendererWorkerResourceSnapshot;
|
|
28
32
|
readonly materialIds: readonly string[];
|
|
29
33
|
readonly width: number;
|
|
30
34
|
readonly height: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ir-renderer.d.ts","sourceRoot":"","sources":["../src/ir-renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,UAAU,EAAkC,MAAM,iBAAiB,CAAC;AAE/F,OAAO,EAWL,KAAK,QAAQ,EACd,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAGL,KAAK,wBAAwB,EAC9B,MAAM,aAAa,CAAC;AACrB,OAAO,KAAK,EAIV,wBAAwB,
|
|
1
|
+
{"version":3,"file":"ir-renderer.d.ts","sourceRoot":"","sources":["../src/ir-renderer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,UAAU,EAAkC,MAAM,iBAAiB,CAAC;AAE/F,OAAO,EAWL,KAAK,QAAQ,EACd,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAGL,KAAK,wBAAwB,EAC9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CAAC,IAAI,CAAC;CA4BhC"}
|
package/dist/ir-renderer.js
CHANGED
|
@@ -1118,6 +1118,8 @@ export class RenderIrFrameRenderer {
|
|
|
1118
1118
|
bitmap: await presentationBitmap(outputFrame, options.signal),
|
|
1119
1119
|
backend: result.backend,
|
|
1120
1120
|
diagnostics: result.diagnostics,
|
|
1121
|
+
timing: result.timing,
|
|
1122
|
+
resources: result.resources,
|
|
1121
1123
|
materialIds: appliedMaterialIds,
|
|
1122
1124
|
width,
|
|
1123
1125
|
height,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aelionsdk/renderer-worker",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "1.1.0-rc.1",
|
|
4
4
|
"description": "Off-main-thread WebGL2 and WebGPU compositor for AelionSDK",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -27,16 +27,16 @@
|
|
|
27
27
|
"!dist/.tsbuildinfo"
|
|
28
28
|
],
|
|
29
29
|
"engines": {
|
|
30
|
-
"node": ">=
|
|
30
|
+
"node": ">=24 <25"
|
|
31
31
|
},
|
|
32
32
|
"publishConfig": {
|
|
33
33
|
"access": "public",
|
|
34
34
|
"provenance": true
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@aelionsdk/core": "
|
|
38
|
-
"@aelionsdk/material-compiler": "
|
|
39
|
-
"@aelionsdk/render-ir": "
|
|
37
|
+
"@aelionsdk/core": "1.1.0-rc.1",
|
|
38
|
+
"@aelionsdk/material-compiler": "1.1.0-rc.1",
|
|
39
|
+
"@aelionsdk/render-ir": "1.1.0-rc.1"
|
|
40
40
|
},
|
|
41
41
|
"scripts": {
|
|
42
42
|
"build": "tsc -b",
|