diff --git a/types/three/examples/jsm/nodes/core/UniformGroup.d.ts b/types/three/examples/jsm/nodes/core/UniformGroup.d.ts new file mode 100644 index 000000000..60339877b --- /dev/null +++ b/types/three/examples/jsm/nodes/core/UniformGroup.d.ts @@ -0,0 +1,7 @@ +export default class UniformGroup { + name: string; + + readonly isUniformGroup: true; + + constructor(name: string); +} diff --git a/types/three/examples/jsm/nodes/core/UniformGroupNode.d.ts b/types/three/examples/jsm/nodes/core/UniformGroupNode.d.ts new file mode 100644 index 000000000..de80f2a4c --- /dev/null +++ b/types/three/examples/jsm/nodes/core/UniformGroupNode.d.ts @@ -0,0 +1,21 @@ +import Node from "./Node.js"; + +export default class UniformGroupNode extends Node { + name: string; + version: number; + + shared: boolean; + + readonly isUniformGroup: true; + + constructor(name: string, shared?: boolean); + + set needsUpdate(value: boolean); +} + +export const uniformGroup: (name: string) => UniformGroupNode; +export const sharedUniformGroup: (name: string) => UniformGroupNode; + +export const frameGroup: UniformGroupNode; +export const renderGroup: UniformGroupNode; +export const objectGroup: UniformGroupNode; diff --git a/types/three/examples/jsm/nodes/core/UniformNode.d.ts b/types/three/examples/jsm/nodes/core/UniformNode.d.ts index fb09e158d..70ac0b441 100644 --- a/types/three/examples/jsm/nodes/core/UniformNode.d.ts +++ b/types/three/examples/jsm/nodes/core/UniformNode.d.ts @@ -3,12 +3,19 @@ import { NodeTypeOption } from "./constants.js"; import InputNode from "./InputNode.js"; import Node from "./Node.js"; import NodeBuilder from "./NodeBuilder.js"; +import UniformGroupNode from "./UniformGroupNode.js"; export default class UniformNode extends InputNode { readonly isUniformNode: true; + groupNode: UniformGroupNode; + constructor(value: Value, nodeType?: NodeTypeOption | null); + setGroup(group: UniformGroupNode): this; + + getGroup(): UniformGroupNode; + getUniformHash(builder: NodeBuilder): string; }