Skip to content

Commit f98fd6e

Browse files
authored
Merge pull request #15108 from WestLangley/dev-background_order
WebGLBackground: clarify background's render order
2 parents d2a9278 + 3d2b80f commit f98fd6e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/renderers/webgl/WebGLBackground.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ function WebGLBackground( renderer, state, objects, premultipliedAlpha ) {
7373
boxMesh.material.uniforms.tCube.value = ( background.isWebGLRenderTargetCube ) ? background.texture : background;
7474
boxMesh.material.uniforms.tFlip.value = ( background.isWebGLRenderTargetCube ) ? 1 : - 1;
7575

76+
// push to the pre-sorted opaque render list
7677
renderList.push( boxMesh, boxMesh.geometry, boxMesh.material, 0, null );
7778

7879
} else if ( background && background.isTexture ) {
@@ -100,6 +101,7 @@ function WebGLBackground( renderer, state, objects, premultipliedAlpha ) {
100101

101102
planeMesh.material.uniforms.t2D.value = background;
102103

104+
// push to the pre-sorted opaque render list
103105
renderList.push( planeMesh, planeMesh.geometry, planeMesh.material, 0, null );
104106

105107
}

0 commit comments

Comments
 (0)