Skip to content

Commit 4e1c1a0

Browse files
authored
Merge pull request #15902 from takahirox/CleanUp3DTexture
Minor DataTexture3D Clean up
2 parents a9e6a12 + f89e8db commit 4e1c1a0

File tree

3 files changed

+6
-11
lines changed

3 files changed

+6
-11
lines changed

src/renderers/WebGLRenderer.js

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2462,16 +2462,11 @@ function WebGLRenderer( parameters ) {
24622462

24632463
}() );
24642464

2465-
this.setTexture3D = ( function () {
2465+
this.setTexture3D = function ( texture, slot ) {
24662466

2467-
// backwards compatibility: peel texture.texture
2468-
return function setTexture3D( texture, slot ) {
2469-
2470-
textures.setTexture3D( texture, slot );
2471-
2472-
};
2467+
textures.setTexture3D( texture, slot );
24732468

2474-
}() );
2469+
};
24752470

24762471
this.setTexture = ( function () {
24772472

src/renderers/webgl/WebGLUniforms.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,7 @@ function getSingularSetter( type ) {
476476
case 0x8b5c: return setValue4fm; // _MAT4
477477

478478
case 0x8b5e: case 0x8d66: return setValueT1; // SAMPLER_2D, SAMPLER_EXTERNAL_OES
479-
case 0x8B5F: return setValueT3D1; // SAMPLER_3D
479+
case 0x8b5f: return setValueT3D1; // SAMPLER_3D
480480
case 0x8b60: return setValueT6; // SAMPLER_CUBE
481481

482482
case 0x1404: case 0x8b56: return setValue1i; // INT, BOOL

src/textures/DataTexture3D.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export class DataTexture3D extends Texture {
66
constructor(
77
data: ArrayBuffer | TypedArray,
88
width: number,
9-
heighht: number,
10-
depth?: number
9+
height: number,
10+
depth: number
1111
);
1212
}

0 commit comments

Comments
 (0)