@mateuszjs/magic-render 0.1.0-next.11 → 0.1.0-next.13
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/lib/index.mjs +1 -1
- package/lib/index.mjs.map +1 -1
- package/lib/types/src/WebGPU/pick.d.ts.map +1 -1
- package/lib/types/src/WebGPU/pointer.d.ts.map +1 -1
- package/lib/types/src/index.d.ts +12 -5
- package/lib/types/src/index.d.ts.map +1 -1
- package/lib/types/src/loadingTexture.d.ts +2 -0
- package/lib/types/src/loadingTexture.d.ts.map +1 -0
- package/lib/types/src/run.d.ts.map +1 -1
- package/lib/types/src/utils/getDefaultPoints.d.ts +1 -1
- package/lib/types/src/utils/getDefaultPoints.d.ts.map +1 -1
- package/package.json +2 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pick.d.ts","sourceRoot":"","sources":["../../../../src/WebGPU/pick.ts"],"names":[],"mappings":"AAMA,MAAM,CAAC,OAAO,OAAO,WAAW;IAC9B,OAAO,CAAC,UAAU,CAAW;IAC7B,OAAO,CAAC,WAAW,CAAY;IAC/B,OAAO,CAAC,gBAAgB,CAAY;IACpC,OAAO,CAAC,kBAAkB,CAAO;gBAErB,MAAM,EAAE,SAAS;IAmB7B;;;;OAIG;IACH,YAAY,CAAC,OAAO,EAAE,iBAAiB,GAAG;QAAE,IAAI,EAAE,oBAAoB,CAAC;QAAC,GAAG,EAAE,YAAY,CAAA;KAAE;IAkD3F,YAAY,CAAC,MAAM,EAAE,iBAAiB,EAAE,YAAY,EAAE,YAAY;IAkB5D,SAAS;
|
|
1
|
+
{"version":3,"file":"pick.d.ts","sourceRoot":"","sources":["../../../../src/WebGPU/pick.ts"],"names":[],"mappings":"AAMA,MAAM,CAAC,OAAO,OAAO,WAAW;IAC9B,OAAO,CAAC,UAAU,CAAW;IAC7B,OAAO,CAAC,WAAW,CAAY;IAC/B,OAAO,CAAC,gBAAgB,CAAY;IACpC,OAAO,CAAC,kBAAkB,CAAO;gBAErB,MAAM,EAAE,SAAS;IAmB7B;;;;OAIG;IACH,YAAY,CAAC,OAAO,EAAE,iBAAiB,GAAG;QAAE,IAAI,EAAE,oBAAoB,CAAC;QAAC,GAAG,EAAE,YAAY,CAAA;KAAE;IAkD3F,YAAY,CAAC,MAAM,EAAE,iBAAiB,EAAE,YAAY,EAAE,YAAY;IAkB5D,SAAS;CA0BhB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pointer.d.ts","sourceRoot":"","sources":["../../../../src/WebGPU/pointer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"pointer.d.ts","sourceRoot":"","sources":["../../../../src/WebGPU/pointer.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,OAAO;;;0BAGU,KAAK,CAAC;QAAE,cAAc,EAAE,OAAO,CAAC;QAAC,EAAE,EAAE,YAAY,CAAA;KAAE,CAAC;CAMjF,CAAA;AAED,MAAM,CAAC,OAAO,UAAU,mBAAmB,CACzC,MAAM,EAAE,iBAAiB,EACzB,iBAAiB,EAAE,YAAY,QAwEhC"}
|
package/lib/types/src/index.d.ts
CHANGED
|
@@ -1,17 +1,24 @@
|
|
|
1
|
-
export type
|
|
1
|
+
export type SerializedInputAsset = {
|
|
2
|
+
id?: number;
|
|
3
|
+
points?: PointUV[];
|
|
4
|
+
url: string;
|
|
5
|
+
textureId?: number;
|
|
6
|
+
};
|
|
7
|
+
export type SerializedOutputAsset = {
|
|
2
8
|
id: number;
|
|
9
|
+
points: PointUV[];
|
|
3
10
|
url: string;
|
|
4
11
|
textureId: number;
|
|
5
12
|
};
|
|
6
13
|
export interface CreatorAPI {
|
|
7
|
-
addImage: (
|
|
8
|
-
resetAssets: (assets:
|
|
14
|
+
addImage: (url: string) => void;
|
|
15
|
+
resetAssets: (assets: SerializedInputAsset[], withSnapshot?: boolean) => void;
|
|
9
16
|
removeAsset: VoidFunction;
|
|
10
17
|
destroy: VoidFunction;
|
|
11
18
|
}
|
|
12
19
|
export interface TextureSource {
|
|
13
20
|
url: string;
|
|
14
|
-
texture
|
|
21
|
+
texture?: GPUTexture;
|
|
15
22
|
}
|
|
16
|
-
export default function initCreator(canvas: HTMLCanvasElement,
|
|
23
|
+
export default function initCreator(canvas: HTMLCanvasElement, onAssetsUpdate: (assets: SerializedOutputAsset[]) => void, onAssetSelect: (assetId: number) => void, onProcessingUpdate: (inProgress: boolean) => void): Promise<CreatorAPI>;
|
|
17
24
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAoBA,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAoBA,MAAM,MAAM,oBAAoB,GAAG;IACjC,EAAE,CAAC,EAAE,MAAM,CAAA;IACX,MAAM,CAAC,EAAE,OAAO,EAAE,CAAA;IAClB,GAAG,EAAE,MAAM,CAAA;IACX,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,qBAAqB,GAAG;IAClC,EAAE,EAAE,MAAM,CAAA;IACV,MAAM,EAAE,OAAO,EAAE,CAAA;IACjB,GAAG,EAAE,MAAM,CAAA;IACX,SAAS,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAA;IAC/B,WAAW,EAAE,CAAC,MAAM,EAAE,oBAAoB,EAAE,EAAE,YAAY,CAAC,EAAE,OAAO,KAAK,IAAI,CAAA;IAC7E,WAAW,EAAE,YAAY,CAAA;IACzB,OAAO,EAAE,YAAY,CAAA;CACtB;AAED,MAAM,WAAW,aAAa;IAC5B,GAAG,EAAE,MAAM,CAAA;IACX,OAAO,CAAC,EAAE,UAAU,CAAA;CACrB;AAED,wBAA8B,WAAW,CACvC,MAAM,EAAE,iBAAiB,EACzB,cAAc,EAAE,CAAC,MAAM,EAAE,qBAAqB,EAAE,KAAK,IAAI,EACzD,aAAa,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,EACxC,kBAAkB,EAAE,CAAC,UAAU,EAAE,OAAO,KAAK,IAAI,GAChD,OAAO,CAAC,UAAU,CAAC,CAyJrB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loadingTexture.d.ts","sourceRoot":"","sources":["../../../src/loadingTexture.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,iBAAiB,CAAC,MAAM,EAAE,SAAS,GAAG,UAAU,CA+BvE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../../src/run.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,aAAa,EAAE,MAAM,GAAG,CAAA;
|
|
1
|
+
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../../src/run.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,aAAa,EAAE,MAAM,GAAG,CAAA;AAIjC,eAAO,MAAM,eAAe,2BAAqB,CAAA;AACjD,eAAO,MAAM,oBAAoB,OAAO,CAAA;AAExC,MAAM,CAAC,OAAO,UAAU,UAAU,CAChC,MAAM,EAAE,iBAAiB,EACzB,OAAO,EAAE,gBAAgB,EACzB,MAAM,EAAE,SAAS,EACjB,kBAAkB,EAAE,gBAAgB,EACpC,QAAQ,EAAE,aAAa,EAAE,EACzB,aAAa,EAAE,YAAY,GAC1B,YAAY,CAgFd"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export default function getDefaultPoints(
|
|
1
|
+
export default function getDefaultPoints(texWidth: number, texHeight: number, projectWidth: number, projectHeight: number): PointUV[];
|
|
2
2
|
//# sourceMappingURL=getDefaultPoints.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getDefaultPoints.d.ts","sourceRoot":"","sources":["../../../../src/utils/getDefaultPoints.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO,UAAU,gBAAgB,CACtC,
|
|
1
|
+
{"version":3,"file":"getDefaultPoints.d.ts","sourceRoot":"","sources":["../../../../src/utils/getDefaultPoints.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,OAAO,UAAU,gBAAgB,CACtC,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,MAAM,EACpB,aAAa,EAAE,MAAM,GACpB,OAAO,EAAE,CAaX"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mateuszjs/magic-render",
|
|
3
3
|
"description": "Initial version of visual editor",
|
|
4
|
-
"version": "0.1.0-next.
|
|
4
|
+
"version": "0.1.0-next.13",
|
|
5
5
|
"author": "Mateusz Walendzik",
|
|
6
6
|
"engines": {
|
|
7
7
|
"node": ">=20.8.1"
|
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"@webgpu/types": "^0.1.54",
|
|
39
39
|
"eslint": "^9.28.0",
|
|
40
40
|
"html-webpack-plugin": "^5.6.3",
|
|
41
|
+
"http-server": "^14.1.1",
|
|
41
42
|
"jest": "^29.7.0",
|
|
42
43
|
"jest-environment-jsdom": "^29.7.0",
|
|
43
44
|
"msdf-bmfont-xml": "^2.7.0",
|