From ecd8117ef70ee2bf241ad1e2c6f984dfff298ca2 Mon Sep 17 00:00:00 2001 From: Garrett Johnson Date: Fri, 4 Dec 2020 13:26:07 -0800 Subject: [PATCH] this.oldClearColor -> this._oldClearColor --- examples/js/postprocessing/BokehPass.js | 6 +++--- examples/js/postprocessing/ClearPass.js | 6 +++--- examples/js/postprocessing/OutlinePass.js | 6 +++--- examples/js/postprocessing/RenderPass.js | 6 +++--- examples/js/postprocessing/SAOPass.js | 6 +++--- examples/js/postprocessing/SSAARenderPass.js | 6 +++--- examples/js/postprocessing/UnrealBloomPass.js | 6 +++--- 7 files changed, 21 insertions(+), 21 deletions(-) diff --git a/examples/js/postprocessing/BokehPass.js b/examples/js/postprocessing/BokehPass.js index 676193acc6..191f2ca73f 100644 --- a/examples/js/postprocessing/BokehPass.js +++ b/examples/js/postprocessing/BokehPass.js @@ -64,7 +64,7 @@ THREE.BokehPass = function ( scene, camera, params ) { this.fsQuad = new THREE.Pass.FullScreenQuad( this.materialBokeh ); - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); }; @@ -78,7 +78,7 @@ THREE.BokehPass.prototype = Object.assign( Object.create( THREE.Pass.prototype ) this.scene.overrideMaterial = this.materialDepth; - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); var oldClearAlpha = renderer.getClearAlpha(); var oldAutoClear = renderer.autoClear; renderer.autoClear = false; @@ -109,7 +109,7 @@ THREE.BokehPass.prototype = Object.assign( Object.create( THREE.Pass.prototype ) } this.scene.overrideMaterial = null; - renderer.setClearColor( this.oldClearColor ); + renderer.setClearColor( this._oldClearColor ); renderer.setClearAlpha( oldClearAlpha ); renderer.autoClear = oldAutoClear; diff --git a/examples/js/postprocessing/ClearPass.js b/examples/js/postprocessing/ClearPass.js index f05bd2018a..05e985b630 100644 --- a/examples/js/postprocessing/ClearPass.js +++ b/examples/js/postprocessing/ClearPass.js @@ -6,7 +6,7 @@ THREE.ClearPass = function ( clearColor, clearAlpha ) { this.clearColor = ( clearColor !== undefined ) ? clearColor : 0x000000; this.clearAlpha = ( clearAlpha !== undefined ) ? clearAlpha : 0; - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); }; @@ -20,7 +20,7 @@ THREE.ClearPass.prototype = Object.assign( Object.create( THREE.Pass.prototype ) if ( this.clearColor ) { - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); oldClearAlpha = renderer.getClearAlpha(); renderer.setClearColor( this.clearColor, this.clearAlpha ); @@ -32,7 +32,7 @@ THREE.ClearPass.prototype = Object.assign( Object.create( THREE.Pass.prototype ) if ( this.clearColor ) { - renderer.setClearColor( this.oldClearColor, oldClearAlpha ); + renderer.setClearColor( this._oldClearColor, oldClearAlpha ); } diff --git a/examples/js/postprocessing/OutlinePass.js b/examples/js/postprocessing/OutlinePass.js index e94f911630..0d26e5312f 100644 --- a/examples/js/postprocessing/OutlinePass.js +++ b/examples/js/postprocessing/OutlinePass.js @@ -96,7 +96,7 @@ THREE.OutlinePass = function ( resolution, scene, camera, selectedObjects ) { this.enabled = true; this.needsSwap = false; - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); this.oldClearAlpha = 1; this.fsQuad = new THREE.Pass.FullScreenQuad( null ); @@ -276,7 +276,7 @@ THREE.OutlinePass.prototype = Object.assign( Object.create( THREE.Pass.prototype if ( this.selectedObjects.length > 0 ) { - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); this.oldClearAlpha = renderer.getClearAlpha(); var oldAutoClear = renderer.autoClear; @@ -391,7 +391,7 @@ THREE.OutlinePass.prototype = Object.assign( Object.create( THREE.Pass.prototype renderer.setRenderTarget( readBuffer ); this.fsQuad.render( renderer ); - renderer.setClearColor( this.oldClearColor, this.oldClearAlpha ); + renderer.setClearColor( this._oldClearColor, this.oldClearAlpha ); renderer.autoClear = oldAutoClear; } diff --git a/examples/js/postprocessing/RenderPass.js b/examples/js/postprocessing/RenderPass.js index 94744438f2..2f824209ff 100644 --- a/examples/js/postprocessing/RenderPass.js +++ b/examples/js/postprocessing/RenderPass.js @@ -13,7 +13,7 @@ THREE.RenderPass = function ( scene, camera, overrideMaterial, clearColor, clear this.clear = true; this.clearDepth = false; this.needsSwap = false; - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); }; @@ -38,7 +38,7 @@ THREE.RenderPass.prototype = Object.assign( Object.create( THREE.Pass.prototype if ( this.clearColor ) { - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); oldClearAlpha = renderer.getClearAlpha(); renderer.setClearColor( this.clearColor, this.clearAlpha ); @@ -59,7 +59,7 @@ THREE.RenderPass.prototype = Object.assign( Object.create( THREE.Pass.prototype if ( this.clearColor ) { - renderer.setClearColor( this.oldClearColor, oldClearAlpha ); + renderer.setClearColor( this._oldClearColor, oldClearAlpha ); } diff --git a/examples/js/postprocessing/SAOPass.js b/examples/js/postprocessing/SAOPass.js index 5bf7b40f77..354b03cd3a 100644 --- a/examples/js/postprocessing/SAOPass.js +++ b/examples/js/postprocessing/SAOPass.js @@ -16,7 +16,7 @@ THREE.SAOPass = function ( scene, camera, depthTexture, useNormals, resolution ) this.supportsNormalTexture = ( useNormals !== undefined ) ? useNormals : false; this.originalClearColor = new THREE.Color(); - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); this.oldClearAlpha = 1; this.params = { @@ -192,7 +192,7 @@ THREE.SAOPass.prototype = Object.assign( Object.create( THREE.Pass.prototype ), } - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); this.oldClearAlpha = renderer.getClearAlpha(); var oldAutoClear = renderer.autoClear; renderer.autoClear = false; @@ -303,7 +303,7 @@ THREE.SAOPass.prototype = Object.assign( Object.create( THREE.Pass.prototype ), // Rendering SAOPass result on top of previous pass this.renderPass( renderer, outputMaterial, this.renderToScreen ? null : readBuffer ); - renderer.setClearColor( this.oldClearColor, this.oldClearAlpha ); + renderer.setClearColor( this._oldClearColor, this.oldClearAlpha ); renderer.autoClear = oldAutoClear; }, diff --git a/examples/js/postprocessing/SSAARenderPass.js b/examples/js/postprocessing/SSAARenderPass.js index d9942439d7..23f76f2877 100644 --- a/examples/js/postprocessing/SSAARenderPass.js +++ b/examples/js/postprocessing/SSAARenderPass.js @@ -21,7 +21,7 @@ THREE.SSAARenderPass = function ( scene, camera, clearColor, clearAlpha ) { // as we need to clear the buffer in this pass, clearColor must be set to something, defaults to black. this.clearColor = ( clearColor !== undefined ) ? clearColor : 0x000000; this.clearAlpha = ( clearAlpha !== undefined ) ? clearAlpha : 0; - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); if ( THREE.CopyShader === undefined ) console.error( "THREE.SSAARenderPass relies on THREE.CopyShader" ); @@ -78,7 +78,7 @@ THREE.SSAARenderPass.prototype = Object.assign( Object.create( THREE.Pass.protot var autoClear = renderer.autoClear; renderer.autoClear = false; - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); var oldClearAlpha = renderer.getClearAlpha(); var baseSampleWeight = 1.0 / jitterOffsets.length; @@ -135,7 +135,7 @@ THREE.SSAARenderPass.prototype = Object.assign( Object.create( THREE.Pass.protot if ( this.camera.clearViewOffset ) this.camera.clearViewOffset(); renderer.autoClear = autoClear; - renderer.setClearColor( this.oldClearColor, oldClearAlpha ); + renderer.setClearColor( this._oldClearColor, oldClearAlpha ); } diff --git a/examples/js/postprocessing/UnrealBloomPass.js b/examples/js/postprocessing/UnrealBloomPass.js index e6f43cf995..df9372bdc6 100644 --- a/examples/js/postprocessing/UnrealBloomPass.js +++ b/examples/js/postprocessing/UnrealBloomPass.js @@ -131,7 +131,7 @@ THREE.UnrealBloomPass = function ( resolution, strength, radius, threshold ) { this.enabled = true; this.needsSwap = false; - this.oldClearColor = new THREE.Color(); + this._oldClearColor = new THREE.Color(); this.oldClearAlpha = 1; this.basic = new THREE.MeshBasicMaterial(); @@ -185,7 +185,7 @@ THREE.UnrealBloomPass.prototype = Object.assign( Object.create( THREE.Pass.proto render: function ( renderer, writeBuffer, readBuffer, deltaTime, maskActive ) { - renderer.getClearColor( this.oldClearColor ); + renderer.getClearColor( this._oldClearColor ); this.oldClearAlpha = renderer.getClearAlpha(); var oldAutoClear = renderer.autoClear; renderer.autoClear = false; @@ -273,7 +273,7 @@ THREE.UnrealBloomPass.prototype = Object.assign( Object.create( THREE.Pass.proto // Restore renderer settings - renderer.setClearColor( this.oldClearColor, this.oldClearAlpha ); + renderer.setClearColor( this._oldClearColor, this.oldClearAlpha ); renderer.autoClear = oldAutoClear; }, -- GitLab