Skip to content

Commit

Permalink
chore: rename engine-shader-lab to engine-shaderlab
Browse files Browse the repository at this point in the history
  • Loading branch information
Sway007 committed Jan 2, 2025
1 parent b80c07d commit 0d367c3
Show file tree
Hide file tree
Showing 11 changed files with 34 additions and 15 deletions.
2 changes: 1 addition & 1 deletion e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"files": [],
"dependencies": {
"@galacean/engine-toolkit": "^1.3.9",
"@galacean/engine-shader-lab": "workspace:*",
"@galacean/engine-shaderlab": "workspace:*",
"@galacean/engine": "workspace:*",
"@galacean/engine-core": "workspace:*",
"@galacean/engine-loader": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/shader/Shader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export class Shader implements IReferable {
* ShaderLab must be enabled first as follows:
* ```ts
* // Import shaderLab
* import { ShaderLab } from "@galacean/engine-shader-lab";
* import { ShaderLab } from "@galacean/engine-shaderlab";
* // Create engine with shaderLab
* const engine = await WebGLEngine.create({ canvas: "canvas", shader: new ShaderLab() });
* ...
Expand Down
6 changes: 3 additions & 3 deletions packages/shader-lab/README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
## Installation

```sh
npm install @galacean/engine-shader-lab
npm install @galacean/engine-shaderlab
```

## Usage

```typescript
import { ShaderLab } from "@galacean/engine-shader-lab";
import { ShaderLab } from "@galacean/engine-shaderlab";

// Create ShaderLab
const shaderLab = new ShaderLab();
Expand All @@ -31,7 +31,7 @@ There are two versions of ShaderLab: `Release` and `Verbose`. The `Verbose` vers
you can use `Verbose` version by import:

```ts
import { ShaderLab } from "@galacean/engine-shader-lab/verbose";
import { ShaderLab } from "@galacean/engine-shaderlab/verbose";
```

## CFG Grammar conflict detection
Expand Down
2 changes: 1 addition & 1 deletion packages/shader-lab/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@galacean/engine-shader-lab",
"name": "@galacean/engine-shaderlab",
"version": "1.4.0-alpha.2",
"publishConfig": {
"access": "public",
Expand Down
23 changes: 21 additions & 2 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const pkgs = fs
};
});

const shaderLabPkg = pkgs.find((item) => item.pkgJson.name === "@galacean/engine-shader-lab");
const shaderLabPkg = pkgs.find((item) => item.pkgJson.name === "@galacean/engine-shaderlab");
pkgs.push({ ...shaderLabPkg, verboseMode: true });

// toGlobalName
Expand Down
2 changes: 1 addition & 1 deletion tests/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"@galacean/engine-math": "workspace:*",
"@galacean/engine-rhi-webgl": "workspace:*",
"@galacean/engine-physics-lite": "workspace:*",
"@galacean/engine-shader-lab": "workspace:*",
"@galacean/engine-shaderlab": "workspace:*",
"@galacean/engine-physics-physx": "workspace:*"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/core/Shader.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {
SubShader
} from "@galacean/engine-core";
import { WebGLEngine } from "@galacean/engine-rhi-webgl";
import { ShaderLab } from "@galacean/engine-shader-lab";
import { ShaderLab } from "@galacean/engine-shaderlab";
import { vi, describe, expect, it } from "vitest";

const shaderLab = new ShaderLab();
Expand Down
2 changes: 1 addition & 1 deletion tests/src/shader-lab/Preprocessor.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { testCaseList } from "./test-case";
// @ts-ignore
import { ShaderLib } from "@galacean/engine-core";
import { Preprocessor } from "@galacean/engine-shader-lab/verbose";
import { Preprocessor } from "@galacean/engine-shaderlab/verbose";
import { describe, expect, it } from "vitest";
import { server } from "@vitest/browser/context";
const { readFile } = server.commands;
Expand Down
4 changes: 2 additions & 2 deletions tests/src/shader-lab/ShaderLab.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import {
ShaderPlatformTarget
} from "@galacean/engine-core";
import { Color } from "@galacean/engine-math";
import { ShaderLab as ShaderLabVerbose, GSError } from "@galacean/engine-shader-lab/verbose";
import { ShaderLab as ShaderLabRelease } from "@galacean/engine-shader-lab";
import { ShaderLab as ShaderLabVerbose, GSError } from "@galacean/engine-shaderlab/verbose";
import { ShaderLab as ShaderLabRelease } from "@galacean/engine-shaderlab";
import { glslValidate, shaderParse } from "./ShaderValidate";

import { IShaderContent } from "@galacean/engine-design";
Expand Down
2 changes: 1 addition & 1 deletion tests/src/shader-lab/ShaderValidate.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ShaderLab } from "@galacean/engine-shader-lab";
import { ShaderLab } from "@galacean/engine-shaderlab";
import { Shader, ShaderFactory, ShaderPass, ShaderPlatformTarget, ShaderMacro } from "@galacean/engine-core";
import { IShaderContent } from "@galacean/engine-design/src/shader-lab";
import { expect } from "vitest";
Expand Down

0 comments on commit 0d367c3

Please sign in to comment.