Kaynağa Gözat

Merge pull request #7371 from Popov72/Fix-bug-resize-MRT

Fix a bug when resizing a MRT
David Catuhe 5 yıl önce
ebeveyn
işleme
b953e2d7d3

+ 1 - 0
dist/preview release/what's new.md

@@ -273,6 +273,7 @@
 - Fixed bug so Playground will now download .env texture files to ./textures in .zip  ([Kyle Belfort](https://github.com/belfortk))
 - Fixed bug so Playground will now download .env texture files to ./textures in .zip  ([Kyle Belfort](https://github.com/belfortk))
 - It was not possible to change the gaze and laser color in VR ([#7323](https://github.com/BabylonJS/Babylon.js/issues/7323)) ([RaananW](https://github.com/RaananW/))
 - It was not possible to change the gaze and laser color in VR ([#7323](https://github.com/BabylonJS/Babylon.js/issues/7323)) ([RaananW](https://github.com/RaananW/))
 - Fixed issue where textures exported using Safari web browser are Y mirrored. ([#7352](https://github.com/BabylonJS/Babylon.js/issues/7352)) ([Drigax](https://github.com/drigax))
 - Fixed issue where textures exported using Safari web browser are Y mirrored. ([#7352](https://github.com/BabylonJS/Babylon.js/issues/7352)) ([Drigax](https://github.com/drigax))
+- Fix a bug when resizing a MRT ([Popov72](https://github.com/Popov72))
 
 
 ## Breaking changes
 ## Breaking changes
 
 

+ 1 - 1
src/Materials/Textures/multiRenderTarget.ts

@@ -219,7 +219,7 @@ export class MultiRenderTarget extends RenderTargetTexture {
      */
      */
     public resize(size: any) {
     public resize(size: any) {
         this.releaseInternalTextures();
         this.releaseInternalTextures();
-        this._internalTextures = this._engine.createMultipleRenderTarget(size, this._multiRenderTargetOptions);
+        this._size = size;
         this._createInternalTextures();
         this._createInternalTextures();
     }
     }