diff --git a/src/renderers/WebGLRenderer.js b/src/renderers/WebGLRenderer.js index e0d4baada4a052..35b215c3e2198d 100644 --- a/src/renderers/WebGLRenderer.js +++ b/src/renderers/WebGLRenderer.js @@ -2395,13 +2395,6 @@ class WebGLRenderer { }; - this.resetColorManagement = function () { - - _gl.drawingBufferColorSpace = this._outputColorSpace === DisplayP3ColorSpace ? 'display-p3' : 'srgb'; - _gl.unpackColorSpace = ColorManagement.workingColorSpace === LinearDisplayP3ColorSpace ? 'display-p3' : 'srgb'; - - }; - this.resetState = function () { _currentActiveCubeFace = 0; @@ -2437,7 +2430,9 @@ class WebGLRenderer { this._outputColorSpace = colorSpace; - this.resetColorManagement(); + const gl = this.getContext(); + gl.drawingBufferColorSpace = colorSpace === DisplayP3ColorSpace ? 'display-p3' : 'srgb'; + gl.unpackColorSpace = ColorManagement.workingColorSpace === LinearDisplayP3ColorSpace ? 'display-p3' : 'srgb'; }