@predy-js/render-interface 0.3.0-beta.26 → 0.3.0-beta.28

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@
2
2
  * Name: @predy-js/render-interface
3
3
  * Description: undefined
4
4
  * Author: undefined
5
- * Version: v0.3.0-beta.26
5
+ * Version: v0.3.0-beta.28
6
6
  */
7
7
 
8
8
  'use strict';
@@ -5860,7 +5860,7 @@ var MarsSharedGeometry = /** @class */ (function (_super) {
5860
5860
  return MarsSharedGeometry;
5861
5861
  }(MarsGeometry));
5862
5862
 
5863
- consoleLog('version: ' + "0.3.0-beta.26");
5863
+ consoleLog('version: ' + "0.3.0-beta.28");
5864
5864
  var ModuleMsg = 'RI Package: @predy-js/render-interface';
5865
5865
 
5866
5866
  var RI = /*#__PURE__*/Object.freeze({
package/dist/index.mjs CHANGED
@@ -2,7 +2,7 @@
2
2
  * Name: @predy-js/render-interface
3
3
  * Description: undefined
4
4
  * Author: undefined
5
- * Version: v0.3.0-beta.26
5
+ * Version: v0.3.0-beta.28
6
6
  */
7
7
 
8
8
  /******************************************************************************
@@ -5856,7 +5856,7 @@ var MarsSharedGeometry = /** @class */ (function (_super) {
5856
5856
  return MarsSharedGeometry;
5857
5857
  }(MarsGeometry));
5858
5858
 
5859
- consoleLog('version: ' + "0.3.0-beta.26");
5859
+ consoleLog('version: ' + "0.3.0-beta.28");
5860
5860
  var ModuleMsg = 'RI Package: @predy-js/render-interface';
5861
5861
 
5862
5862
  var RI = /*#__PURE__*/Object.freeze({
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.3.0-beta.26
5
+ * Version: v0.3.0-beta.28
6
6
  */
7
7
 
8
8
  // https://github.com/greggman/webgl-memory/blob/main/src/texture-utils.js
@@ -4,7 +4,9 @@ import type { TextureInternal } from './TextureInternal';
4
4
  export interface DataBlockInternalOptions {
5
5
  name: string;
6
6
  }
7
- export type NativeUniformStruct = [key: string, value: TypedArray][];
7
+ export interface NativeUniformStruct {
8
+ [key: string]: TypedArray;
9
+ }
8
10
  export declare abstract class DataBlockInternal implements ResourceInternal {
9
11
  readonly isDestroyed: boolean;
10
12
  /**
@@ -31,11 +33,11 @@ export declare abstract class DataBlockInternal implements ResourceInternal {
31
33
  /**
32
34
  * 设置uniform的结构体数据
33
35
  */
34
- abstract setUniformStructValue(name: string, value: NativeUniformStruct): void;
36
+ abstract setUniformStructValue(name: string, value: NativeUniformStruct[]): boolean;
35
37
  /**
36
- * 设置uniform的结构体Array数据
38
+ * 获取uniform的结构体数据
37
39
  */
38
- abstract setUniformStructArrayValue(name: string, value: NativeUniformStruct[]): void;
40
+ abstract getUniformStructValue(name: string, idx: number, value: NativeUniformStruct): boolean;
39
41
  abstract setUniformTextures(uniformName: string, texture: TextureInternal[] | undefined): void;
40
42
  abstract getUniformTextures(uniformName: string): TextureInternal[] | undefined;
41
43
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@predy-js/render-interface",
3
- "version": "0.3.0-beta.26",
3
+ "version": "0.3.0-beta.28",
4
4
  "license": "MIT",
5
5
  "module": "./dist/index.mjs",
6
6
  "main": "./dist/index.js",
@@ -5,7 +5,7 @@ import type { TextureInternal } from './TextureInternal';
5
5
  export interface DataBlockInternalOptions {
6
6
  name: string,
7
7
  }
8
- export type NativeUniformStruct = [key: string, value: TypedArray][];
8
+ export interface NativeUniformStruct { [key: string]: TypedArray }
9
9
 
10
10
  export abstract class DataBlockInternal implements ResourceInternal {
11
11
  readonly isDestroyed: boolean;
@@ -38,12 +38,12 @@ export abstract class DataBlockInternal implements ResourceInternal {
38
38
  /**
39
39
  * 设置uniform的结构体数据
40
40
  */
41
- abstract setUniformStructValue (name: string, value: NativeUniformStruct): void;
41
+ abstract setUniformStructValue (name: string, value: NativeUniformStruct[]): boolean;
42
42
 
43
43
  /**
44
- * 设置uniform的结构体Array数据
44
+ * 获取uniform的结构体数据
45
45
  */
46
- abstract setUniformStructArrayValue (name: string, value: NativeUniformStruct[]): void;
46
+ abstract getUniformStructValue (name: string, idx: number, value: NativeUniformStruct): boolean;
47
47
 
48
48
  abstract setUniformTextures (uniformName: string, texture: TextureInternal[] | undefined): void;
49
49