Skip to content

Commit

Permalink
docs: Update README examples
Browse files Browse the repository at this point in the history
`GLTFLoader` and `MToonMaterialLoaderPlugin` should be imported in these codes
  • Loading branch information
0b5vr committed Aug 5, 2024
1 parent 281ed30 commit f050812
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ To use three-vrm with WebGPURenderer, specify the WebGPU-compatible `MToonNodeMa
The NodeMaterial system of Three.js is still under development, so we may break compatibility with older versions of Three.js more frequently than other parts of three-vrm.

```js
import { VRMLoaderPlugin } from '@pixiv/three-vrm';
import { GLTFLoader } from 'three/addons/loaders/GLTFLoader.js';
import { MToonMaterialLoaderPlugin, VRMLoaderPlugin } from '@pixiv/three-vrm';
import { MToonNodeMaterial } from '@pixiv/three-vrm/nodes';

// ... Setup renderer, camera, scene ...
Expand Down
1 change: 1 addition & 0 deletions packages/three-vrm-materials-mtoon/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ To use MToon with WebGPURenderer, specify the WebGPU-compatible `MToonNodeMateri
The NodeMaterial system of Three.js is still under development, so we may break compatibility with older versions of Three.js more frequently than other parts of three-vrm.

```js
import { GLTFLoader } from 'three/addons/loaders/GLTFLoader.js';
import { MToonMaterialLoaderPlugin } from '@pixiv/three-vrm-materials-mtoon';
import { MToonNodeMaterial } from '@pixiv/three-vrm-materials-mtoon/nodes';

Expand Down
3 changes: 2 additions & 1 deletion packages/three-vrm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ To use three-vrm with WebGPURenderer, specify the WebGPU-compatible `MToonNodeMa
The NodeMaterial system of Three.js is still under development, so we may break compatibility with older versions of Three.js more frequently than other parts of three-vrm.

```js
import { VRMLoaderPlugin } from '@pixiv/three-vrm';
import { GLTFLoader } from 'three/addons/loaders/GLTFLoader.js';
import { MToonMaterialLoaderPlugin, VRMLoaderPlugin } from '@pixiv/three-vrm';
import { MToonNodeMaterial } from '@pixiv/three-vrm/nodes';

// ... Setup renderer, camera, scene ...
Expand Down

0 comments on commit f050812

Please sign in to comment.