@thi.ng/webgl 6.6.11 → 6.6.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/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Change Log
2
2
 
3
- - **Last updated**: 2023-12-09T19:12:04Z
3
+ - **Last updated**: 2023-12-11T10:07:09Z
4
4
  - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
5
 
6
6
  All notable changes to this project will be documented in this file.
package/README.md CHANGED
@@ -96,7 +96,7 @@ For Node.js REPL:
96
96
  const webgl = await import("@thi.ng/webgl");
97
97
  ```
98
98
 
99
- Package sizes (brotli'd, pre-treeshake): ESM: 11.60 KB
99
+ Package sizes (brotli'd, pre-treeshake): ESM: 11.48 KB
100
100
 
101
101
  ## Dependencies
102
102
 
package/api/blend.js CHANGED
@@ -1,33 +1,37 @@
1
- export var Blend;
2
- (function (Blend) {
3
- Blend[Blend["ZERO"] = 0] = "ZERO";
4
- Blend[Blend["ONE"] = 1] = "ONE";
5
- Blend[Blend["SRC_COLOR"] = 768] = "SRC_COLOR";
6
- Blend[Blend["ONE_MINUS_SRC_COLOR"] = 769] = "ONE_MINUS_SRC_COLOR";
7
- Blend[Blend["DST_COLOR"] = 774] = "DST_COLOR";
8
- Blend[Blend["ONE_MINUS_DST_COLOR"] = 775] = "ONE_MINUS_DST_COLOR";
9
- Blend[Blend["SRC_ALPHA"] = 770] = "SRC_ALPHA";
10
- Blend[Blend["ONE_MINUS_SRC_ALPHA"] = 771] = "ONE_MINUS_SRC_ALPHA";
11
- Blend[Blend["DST_ALPHA"] = 772] = "DST_ALPHA";
12
- Blend[Blend["ONE_MINUS_DST_ALPHA"] = 773] = "ONE_MINUS_DST_ALPHA";
13
- Blend[Blend["CONSTANT_COLOR"] = 32769] = "CONSTANT_COLOR";
14
- Blend[Blend["ONE_MINUS_CONSTANT_COLOR"] = 32770] = "ONE_MINUS_CONSTANT_COLOR";
15
- Blend[Blend["CONSTANT_ALPHA"] = 32771] = "CONSTANT_ALPHA";
16
- Blend[Blend["ONE_MINUS_CONSTANT_ALPHA"] = 32772] = "ONE_MINUS_CONSTANT_ALPHA";
17
- Blend[Blend["SRC_ALPHA_SATURATE"] = 776] = "SRC_ALPHA_SATURATE";
18
- })(Blend || (Blend = {}));
19
- export var BlendEquation;
20
- (function (BlendEquation) {
21
- BlendEquation[BlendEquation["FUNC_ADD"] = 32774] = "FUNC_ADD";
22
- BlendEquation[BlendEquation["FUNC_REVERSE_SUBTRACT"] = 32779] = "FUNC_REVERSE_SUBTRACT";
23
- BlendEquation[BlendEquation["FUNC_SUBTRACT"] = 32778] = "FUNC_SUBTRACT";
24
- BlendEquation[BlendEquation["MAX"] = 32776] = "MAX";
25
- BlendEquation[BlendEquation["MIN"] = 32775] = "MIN";
26
- })(BlendEquation || (BlendEquation = {}));
27
- // TODO blend func presets
28
- // https://www.andersriggelsen.dk/glblendfunc.php
29
- export const BLEND_NORMAL = [
30
- Blend.SRC_ALPHA,
31
- Blend.ONE_MINUS_SRC_ALPHA,
1
+ var Blend = /* @__PURE__ */ ((Blend2) => {
2
+ Blend2[Blend2["ZERO"] = 0] = "ZERO";
3
+ Blend2[Blend2["ONE"] = 1] = "ONE";
4
+ Blend2[Blend2["SRC_COLOR"] = 768] = "SRC_COLOR";
5
+ Blend2[Blend2["ONE_MINUS_SRC_COLOR"] = 769] = "ONE_MINUS_SRC_COLOR";
6
+ Blend2[Blend2["DST_COLOR"] = 774] = "DST_COLOR";
7
+ Blend2[Blend2["ONE_MINUS_DST_COLOR"] = 775] = "ONE_MINUS_DST_COLOR";
8
+ Blend2[Blend2["SRC_ALPHA"] = 770] = "SRC_ALPHA";
9
+ Blend2[Blend2["ONE_MINUS_SRC_ALPHA"] = 771] = "ONE_MINUS_SRC_ALPHA";
10
+ Blend2[Blend2["DST_ALPHA"] = 772] = "DST_ALPHA";
11
+ Blend2[Blend2["ONE_MINUS_DST_ALPHA"] = 773] = "ONE_MINUS_DST_ALPHA";
12
+ Blend2[Blend2["CONSTANT_COLOR"] = 32769] = "CONSTANT_COLOR";
13
+ Blend2[Blend2["ONE_MINUS_CONSTANT_COLOR"] = 32770] = "ONE_MINUS_CONSTANT_COLOR";
14
+ Blend2[Blend2["CONSTANT_ALPHA"] = 32771] = "CONSTANT_ALPHA";
15
+ Blend2[Blend2["ONE_MINUS_CONSTANT_ALPHA"] = 32772] = "ONE_MINUS_CONSTANT_ALPHA";
16
+ Blend2[Blend2["SRC_ALPHA_SATURATE"] = 776] = "SRC_ALPHA_SATURATE";
17
+ return Blend2;
18
+ })(Blend || {});
19
+ var BlendEquation = /* @__PURE__ */ ((BlendEquation2) => {
20
+ BlendEquation2[BlendEquation2["FUNC_ADD"] = 32774] = "FUNC_ADD";
21
+ BlendEquation2[BlendEquation2["FUNC_REVERSE_SUBTRACT"] = 32779] = "FUNC_REVERSE_SUBTRACT";
22
+ BlendEquation2[BlendEquation2["FUNC_SUBTRACT"] = 32778] = "FUNC_SUBTRACT";
23
+ BlendEquation2[BlendEquation2["MAX"] = 32776] = "MAX";
24
+ BlendEquation2[BlendEquation2["MIN"] = 32775] = "MIN";
25
+ return BlendEquation2;
26
+ })(BlendEquation || {});
27
+ const BLEND_NORMAL = [
28
+ 770 /* SRC_ALPHA */,
29
+ 771 /* ONE_MINUS_SRC_ALPHA */
32
30
  ];
33
- export const BLEND_ADD = [Blend.SRC_ALPHA, Blend.DST_ALPHA];
31
+ const BLEND_ADD = [770 /* SRC_ALPHA */, 772 /* DST_ALPHA */];
32
+ export {
33
+ BLEND_ADD,
34
+ BLEND_NORMAL,
35
+ Blend,
36
+ BlendEquation
37
+ };
package/api/buffers.js CHANGED
@@ -1 +0,0 @@
1
- export {};
package/api/canvas.js CHANGED
@@ -1 +0,0 @@
1
- export {};
package/api/ext.js CHANGED
@@ -1,10 +1,13 @@
1
- export const GL_EXT_INFO = {
2
- WEBGL_draw_buffers: {
3
- gl: true,
4
- alias: "GL_EXT_draw_buffers",
5
- },
6
- OES_standard_derivatives: {
7
- gl: true,
8
- alias: "GL_OES_standard_derivatives",
9
- },
1
+ const GL_EXT_INFO = {
2
+ WEBGL_draw_buffers: {
3
+ gl: true,
4
+ alias: "GL_EXT_draw_buffers"
5
+ },
6
+ OES_standard_derivatives: {
7
+ gl: true,
8
+ alias: "GL_OES_standard_derivatives"
9
+ }
10
+ };
11
+ export {
12
+ GL_EXT_INFO
10
13
  };
package/api/glsl.js CHANGED
@@ -1 +0,0 @@
1
- export {};
package/api/material.js CHANGED
@@ -1 +0,0 @@
1
- export {};
package/api/model.js CHANGED
@@ -1,10 +1,13 @@
1
- export var DrawMode;
2
- (function (DrawMode) {
3
- DrawMode[DrawMode["POINTS"] = 0] = "POINTS";
4
- DrawMode[DrawMode["LINES"] = 1] = "LINES";
5
- DrawMode[DrawMode["LINE_LOOP"] = 2] = "LINE_LOOP";
6
- DrawMode[DrawMode["LINE_STRIP"] = 3] = "LINE_STRIP";
7
- DrawMode[DrawMode["TRIANGLES"] = 4] = "TRIANGLES";
8
- DrawMode[DrawMode["TRIANGLE_STRIP"] = 5] = "TRIANGLE_STRIP";
9
- DrawMode[DrawMode["TRIANGLE_FAN"] = 6] = "TRIANGLE_FAN";
10
- })(DrawMode || (DrawMode = {}));
1
+ var DrawMode = /* @__PURE__ */ ((DrawMode2) => {
2
+ DrawMode2[DrawMode2["POINTS"] = 0] = "POINTS";
3
+ DrawMode2[DrawMode2["LINES"] = 1] = "LINES";
4
+ DrawMode2[DrawMode2["LINE_LOOP"] = 2] = "LINE_LOOP";
5
+ DrawMode2[DrawMode2["LINE_STRIP"] = 3] = "LINE_STRIP";
6
+ DrawMode2[DrawMode2["TRIANGLES"] = 4] = "TRIANGLES";
7
+ DrawMode2[DrawMode2["TRIANGLE_STRIP"] = 5] = "TRIANGLE_STRIP";
8
+ DrawMode2[DrawMode2["TRIANGLE_FAN"] = 6] = "TRIANGLE_FAN";
9
+ return DrawMode2;
10
+ })(DrawMode || {});
11
+ export {
12
+ DrawMode
13
+ };
package/api/multipass.js CHANGED
@@ -1 +0,0 @@
1
- export {};
package/api/shader.js CHANGED
@@ -1 +1,4 @@
1
- export const DEFAULT_OUTPUT = { fragColor: ["vec4", 0] };
1
+ const DEFAULT_OUTPUT = { fragColor: ["vec4", 0] };
2
+ export {
3
+ DEFAULT_OUTPUT
4
+ };
package/api/stencil.js CHANGED
@@ -1,22 +1,26 @@
1
- export var StencilOp;
2
- (function (StencilOp) {
3
- StencilOp[StencilOp["KEEP"] = 7680] = "KEEP";
4
- StencilOp[StencilOp["ZERO"] = 0] = "ZERO";
5
- StencilOp[StencilOp["REPLACE"] = 7681] = "REPLACE";
6
- StencilOp[StencilOp["INCR"] = 7682] = "INCR";
7
- StencilOp[StencilOp["INCR_WRAP"] = 34055] = "INCR_WRAP";
8
- StencilOp[StencilOp["DECR"] = 7683] = "DECR";
9
- StencilOp[StencilOp["DECR_WRAP"] = 34056] = "DECR_WRAP";
10
- StencilOp[StencilOp["INVERT"] = 5386] = "INVERT";
11
- })(StencilOp || (StencilOp = {}));
12
- export var StencilFn;
13
- (function (StencilFn) {
14
- StencilFn[StencilFn["NEVER"] = 512] = "NEVER";
15
- StencilFn[StencilFn["LESS"] = 513] = "LESS";
16
- StencilFn[StencilFn["EQUAL"] = 514] = "EQUAL";
17
- StencilFn[StencilFn["LEQUAL"] = 515] = "LEQUAL";
18
- StencilFn[StencilFn["GREATER"] = 516] = "GREATER";
19
- StencilFn[StencilFn["NOTEQUAL"] = 517] = "NOTEQUAL";
20
- StencilFn[StencilFn["GEQUAL"] = 518] = "GEQUAL";
21
- StencilFn[StencilFn["ALWAYS"] = 519] = "ALWAYS";
22
- })(StencilFn || (StencilFn = {}));
1
+ var StencilOp = /* @__PURE__ */ ((StencilOp2) => {
2
+ StencilOp2[StencilOp2["KEEP"] = 7680] = "KEEP";
3
+ StencilOp2[StencilOp2["ZERO"] = 0] = "ZERO";
4
+ StencilOp2[StencilOp2["REPLACE"] = 7681] = "REPLACE";
5
+ StencilOp2[StencilOp2["INCR"] = 7682] = "INCR";
6
+ StencilOp2[StencilOp2["INCR_WRAP"] = 34055] = "INCR_WRAP";
7
+ StencilOp2[StencilOp2["DECR"] = 7683] = "DECR";
8
+ StencilOp2[StencilOp2["DECR_WRAP"] = 34056] = "DECR_WRAP";
9
+ StencilOp2[StencilOp2["INVERT"] = 5386] = "INVERT";
10
+ return StencilOp2;
11
+ })(StencilOp || {});
12
+ var StencilFn = /* @__PURE__ */ ((StencilFn2) => {
13
+ StencilFn2[StencilFn2["NEVER"] = 512] = "NEVER";
14
+ StencilFn2[StencilFn2["LESS"] = 513] = "LESS";
15
+ StencilFn2[StencilFn2["EQUAL"] = 514] = "EQUAL";
16
+ StencilFn2[StencilFn2["LEQUAL"] = 515] = "LEQUAL";
17
+ StencilFn2[StencilFn2["GREATER"] = 516] = "GREATER";
18
+ StencilFn2[StencilFn2["NOTEQUAL"] = 517] = "NOTEQUAL";
19
+ StencilFn2[StencilFn2["GEQUAL"] = 518] = "GEQUAL";
20
+ StencilFn2[StencilFn2["ALWAYS"] = 519] = "ALWAYS";
21
+ return StencilFn2;
22
+ })(StencilFn || {});
23
+ export {
24
+ StencilFn,
25
+ StencilOp
26
+ };