@predy-js/render-interface 0.1.61 → 0.1.62-beta.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/dist/statistic.js CHANGED
@@ -2,7 +2,7 @@
2
2
  * Name: @predy-js/render-interface
3
3
  * Description: undefined
4
4
  * Author: undefined
5
- * Version: v0.1.61
5
+ * Version: v0.1.62-beta.1
6
6
  */
7
7
 
8
8
  // https://github.com/greggman/webgl-memory/blob/main/src/texture-utils.js
@@ -0,0 +1,18 @@
1
+ export declare abstract class AndGLContext {
2
+ abstract isEnabled(param: GLenum): boolean;
3
+ /**
4
+ * 获取gl的参数, 返回值为4个int 数组
5
+ * @param param
6
+ */
7
+ abstract getParameter_i4(param: GLenum): [number, number, number, number];
8
+ /**
9
+ * 获取gl的参数, 返回值为4个bool 数组
10
+ * @param param
11
+ */
12
+ abstract getParameter_b4(param: GLenum): [boolean, boolean, boolean, boolean];
13
+ /**
14
+ * 获取gl的参数, 返回值为1个int
15
+ * @param param
16
+ */
17
+ abstract getParameter_i1(param: GLenum): number;
18
+ }
@@ -4,6 +4,7 @@ import type { RenderPassLoadAction, RenderPassStoreAction } from '../RenderPass'
4
4
  import type { TextureInternal } from './TextureInternal';
5
5
  import type { RenderPassStorageObject } from '../RenderPass';
6
6
  import type { RenderPassAttachmentStorageType } from '../RenderPass';
7
+ import type { AndGLContext } from './AndGLContext';
7
8
  export interface RenderPassColorAttachmentInternal {
8
9
  readonly storageType: RenderPassAttachmentStorageType.color;
9
10
  readonly texture: TextureInternal;
@@ -47,6 +48,7 @@ export declare abstract class RenderPassInternal implements ResourceInternal {
47
48
  readonly attachments: RenderPassColorAttachmentInternal[];
48
49
  readonly width: number;
49
50
  readonly height: number;
51
+ readonly gl?: AndGLContext;
50
52
  /**
51
53
  * 增删改查的操作,在warp层对Mesh进行后,得到的数据全部覆盖当前数据
52
54
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@predy-js/render-interface",
3
- "version": "0.1.61",
3
+ "version": "0.1.62-beta.1",
4
4
  "license": "MIT",
5
5
  "module": "./dist/index.mjs",
6
6
  "main": "./dist/index.js",
@@ -0,0 +1,22 @@
1
+
2
+ export abstract class AndGLContext {
3
+ abstract isEnabled (param: GLenum): boolean;
4
+
5
+ /**
6
+ * 获取gl的参数, 返回值为4个int 数组
7
+ * @param param
8
+ */
9
+ abstract getParameter_i4 (param: GLenum): [number, number, number, number];
10
+
11
+ /**
12
+ * 获取gl的参数, 返回值为4个bool 数组
13
+ * @param param
14
+ */
15
+ abstract getParameter_b4 (param: GLenum): [boolean, boolean, boolean, boolean];
16
+
17
+ /**
18
+ * 获取gl的参数, 返回值为1个int
19
+ * @param param
20
+ */
21
+ abstract getParameter_i1 (param: GLenum): number;
22
+ }
@@ -4,6 +4,7 @@ import type { RenderPassLoadAction, RenderPassStoreAction } from '../RenderPass'
4
4
  import type { TextureInternal } from './TextureInternal';
5
5
  import type { RenderPassStorageObject } from '../RenderPass';
6
6
  import type { RenderPassAttachmentStorageType } from '../RenderPass';
7
+ import type { AndGLContext } from './AndGLContext';
7
8
 
8
9
  //--- color ---
9
10
  export interface RenderPassColorAttachmentInternal {
@@ -54,6 +55,7 @@ export abstract class RenderPassInternal implements ResourceInternal {
54
55
  readonly attachments: RenderPassColorAttachmentInternal[];
55
56
  readonly width: number;
56
57
  readonly height: number;
58
+ readonly gl?: AndGLContext;
57
59
  /**
58
60
  * 增删改查的操作,在warp层对Mesh进行后,得到的数据全部覆盖当前数据
59
61
  */