Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions src/renderers/webgpu/nodes/WGSLNodeBuilder.js
Original file line number Diff line number Diff line change
Expand Up @@ -1146,14 +1146,12 @@ class WGSLNodeBuilder extends NodeBuilder {
if ( uniformsGroup === undefined ) {

uniformsGroup = new NodeUniformsGroup( groupName, group );
uniformsGroup.setVisibility( GPUShaderStage.VERTEX | GPUShaderStage.FRAGMENT | GPUShaderStage.COMPUTE );

this.uniformGroups[ groupName ] = uniformsGroup;

}

// TODO: Verifier caches
uniformsGroup.setVisibility( GPUShaderStage.VERTEX | GPUShaderStage.FRAGMENT | GPUShaderStage.COMPUTE );

// Add to bindings for this stage if not already present
if ( bindings.indexOf( uniformsGroup ) === - 1 ) {

Expand Down
3 changes: 2 additions & 1 deletion src/renderers/webgpu/utils/WebGPUBindingUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {
import { FloatType, IntType, UnsignedIntType, Compatibility } from '../../../constants.js';
import { NodeAccess } from '../../../nodes/core/constants.js';
import { isTypedArray, error } from '../../../utils.js';
import { hashString } from '../../../nodes/core/NodeUtils.js';

/**
* Class representing a WebGPU bind group layout.
Expand Down Expand Up @@ -99,7 +100,7 @@ class WebGPUBindingUtils {
// if not, assing one

const entries = this._createLayoutEntries( bindGroup );
const bindGroupLayoutKey = JSON.stringify( entries );
const bindGroupLayoutKey = hashString( JSON.stringify( entries ) );

// try to find an existing layout in the cache

Expand Down
Loading