Skip to content

Commit

Permalink
WebGPURenderer: Make work without three/nodes (#25904)
Browse files Browse the repository at this point in the history
  • Loading branch information
sunag committed Apr 22, 2023
1 parent 39936f7 commit 0588487
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion examples/jsm/renderers/webgpu/WebGPUBackground.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { GPULoadOp, GPUStoreOp } from './constants.js';
import { Color, Mesh, BoxGeometry, BackSide } from 'three';
import { context, positionWorldDirection, MeshBasicNodeMaterial } from 'three/nodes';
import { context, positionWorldDirection, MeshBasicNodeMaterial } from '../../nodes/Nodes.js';

let _clearAlpha;
const _clearColor = new Color();
Expand Down
2 changes: 1 addition & 1 deletion examples/jsm/renderers/webgpu/WebGPURenderStates.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import WebGPUWeakMap from './WebGPUWeakMap.js';
import { lights } from 'three/nodes';
import { lights } from '../../nodes/Nodes.js';

class WebGPURenderState {

Expand Down
2 changes: 1 addition & 1 deletion examples/jsm/renderers/webgpu/nodes/WebGPUNodeBuilder.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { getVectorLength, getStrideLength } from '../WebGPUBufferUtils.js';

import WebGPURenderTarget from '../WebGPURenderTarget.js';

import { NodeBuilder, WGSLNodeParser, CodeNode, NodeMaterial } from 'three/nodes';
import { NodeBuilder, WGSLNodeParser, CodeNode, NodeMaterial } from '../../../nodes/Nodes.js';

const gpuShaderStageLib = {
'vertex': GPUShaderStage.VERTEX,
Expand Down
2 changes: 1 addition & 1 deletion examples/jsm/renderers/webgpu/nodes/WebGPUNodes.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import WebGPUNodeBuilder from './WebGPUNodeBuilder.js';
import { NoToneMapping, EquirectangularReflectionMapping, EquirectangularRefractionMapping } from 'three';
import { NodeFrame, cubeTexture, texture, rangeFog, densityFog, reference, toneMapping, positionWorld, modelWorldMatrix, transformDirection, equirectUV, viewportBottomLeft } from 'three/nodes';
import { NodeFrame, cubeTexture, texture, rangeFog, densityFog, reference, toneMapping, positionWorld, modelWorldMatrix, transformDirection, equirectUV, viewportBottomLeft } from '../../../nodes/Nodes.js';

class WebGPUNodes {

Expand Down
3 changes: 1 addition & 2 deletions examples/webgpu_loader_gltf.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,7 @@
{
"imports": {
"three": "../build/three.module.js",
"three/addons/": "./jsm/",
"three/nodes": "./jsm/nodes/Nodes.js"
"three/addons/": "./jsm/"
}
}
</script>
Expand Down

0 comments on commit 0588487

Please sign in to comment.