@galacean/engine-design 2.0.0-alpha.29 → 2.0.0-alpha.31

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@galacean/engine-design",
3
- "version": "2.0.0-alpha.29",
3
+ "version": "2.0.0-alpha.31",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org"
@@ -17,7 +17,7 @@
17
17
  ],
18
18
  "types": "types/index.d.ts",
19
19
  "dependencies": {
20
- "@galacean/engine-math": "2.0.0-alpha.29"
20
+ "@galacean/engine-math": "2.0.0-alpha.31"
21
21
  },
22
22
  "scripts": {
23
23
  "b:types": "tsc"
package/types/index.d.ts CHANGED
@@ -2,5 +2,5 @@ export type { IClone } from "./IClone";
2
2
  export * from "./input/index";
3
3
  export * from "./physics/index";
4
4
  export * from "./renderingHardwareInterface/index";
5
- export * from "./shader-lab/index";
5
+ export * from "./shader-compiler/index";
6
6
  export * from "./xr/index";
@@ -2,9 +2,9 @@ import { IPrecompiledShader } from "./IPrecompiledShader";
2
2
  import { IShaderProgramSource } from "./IShaderProgramSource";
3
3
  import { IShaderSource } from "./shaderSource/IShaderSource";
4
4
  /**
5
- * Shader lab interface.
5
+ * Shader compiler interface.
6
6
  */
7
- export interface IShaderLab {
7
+ export interface IShaderCompiler {
8
8
  /**
9
9
  * @internal
10
10
  * Parse shader source code to get the source structure of shader.
@@ -13,11 +13,13 @@ export interface IShaderLab {
13
13
  /**
14
14
  * @internal
15
15
  * Parse shader pass source code.
16
- * @param basePathForIncludeKey the base path to resolve the relative path of `#include` directive. Must follow the specifications of [URL.origin](https://developer.mozilla.org/en-US/docs/Web/API/URL/origin), like: `shaders://root/`
16
+ * @param basePathForIncludeKey - The base path to resolve the relative path of `#include` directives.
17
+ * Must follow the specifications of [URL.origin](https://developer.mozilla.org/en-US/docs/Web/API/URL/origin),
18
+ * like: `shaders://root/`.
17
19
  */
18
- _parseShaderPass(shaderPassSource: string, vertexEntry: string, fragmentEntry: string, backend: any, basePathForIncludeKey: string): IShaderProgramSource;
20
+ _parseShaderPass(shaderPassSource: string, vertexEntry: string, fragmentEntry: string, backend: any, basePathForIncludeKey: string): IShaderProgramSource | undefined;
19
21
  /**
20
22
  * @internal
21
23
  */
22
- _precompile(sourceCode: string, platformTarget: any, basePath: string): IPrecompiledShader;
24
+ _precompile(sourceCode: string, platformTarget: any, basePathForIncludeKey: string): IPrecompiledShader;
23
25
  }
@@ -1,4 +1,4 @@
1
- export type { IShaderLab } from "./IShaderLab";
1
+ export type { IShaderCompiler } from "./IShaderCompiler";
2
2
  export type { Condition, DefinedCondition, NotDefinedCondition, CompareCondition, BoolCondition, ShaderInstruction } from "./ICondition";
3
3
  export type { IPrecompiledShader, IPrecompiledSubShader, IPrecompiledPass } from "./IPrecompiledShader";
4
4
  export type { IShaderProgramSource as IShaderInfo } from "./IShaderProgramSource";
@@ -6,7 +6,7 @@ export interface IShaderPassSource {
6
6
  isUsePass: boolean;
7
7
  tags?: Record<string, number | string | boolean>;
8
8
  renderStates: IRenderStates;
9
- /** ShaderLab code source. */
9
+ /** Shader source code. */
10
10
  contents: string;
11
11
  vertexEntry: string;
12
12
  fragmentEntry: string;