Skip to content

Commit

Permalink
WebGPURenderer: support mat2() and extend RotateNode to support vec2 …
Browse files Browse the repository at this point in the history
…rotation. (#785)
  • Loading branch information
Methuselah96 committed Jan 25, 2024
1 parent 3a829ac commit 23fe4c3
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
2 changes: 2 additions & 0 deletions types/three/examples/jsm/nodes/core/constants.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ export enum NodeType {
VECTOR2 = 'vec2',
VECTOR3 = 'vec3',
VECTOR4 = 'vec4',
MATRIX2 = 'mat2',
MATRIX3 = 'mat3',
MATRIX4 = 'mat4',
}
Expand All @@ -28,6 +29,7 @@ export type NodeTypeOption =
| 'vec2'
| 'vec3'
| 'vec4'
| 'mat2'
| 'mat3'
| 'mat4'
| 'code' /* CodeNode */
Expand Down
9 changes: 9 additions & 0 deletions types/three/examples/jsm/nodes/shadernode/ShaderNode.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ export interface NodeElements {
ivec4: typeof ivec4;
uvec4: typeof uvec4;
bvec4: typeof bvec4;
mat2: typeof mat2;
imat2: typeof imat2;
umat2: typeof umat2;
bmat2: typeof bmat2;
mat3: typeof mat3;
imat3: typeof imat3;
umat3: typeof umat3;
Expand Down Expand Up @@ -223,6 +227,11 @@ export const ivec4: ConvertType;
export const uvec4: ConvertType;
export const bvec4: ConvertType;

export const mat2: ConvertType;
export const imat2: ConvertType;
export const umat2: ConvertType;
export const bmat2: ConvertType;

export const mat3: ConvertType;
export const imat3: ConvertType;
export const umat3: ConvertType;
Expand Down

0 comments on commit 23fe4c3

Please sign in to comment.