Monday, May 20, 2024
HomeGame Developmentc++ - Issues after resizing with multiple render passes

c++ – Issues after resizing with multiple render passes


I have the following deferred rendering setup:

The first renderpass renders the scene to a fixed size image (2048×2048) from the “suns” pov to one color attachment as a shadow map.

The second renderpass renders from the cameras pov and has for image attachments (1 depth, 3 color) for depth, position, normal and albedo.

The last one takes all 4 color attachments and resolves the deferred rendering. This one outputs to the swapchain image.

In my scene I have a rotating cube.

When the windows is resized, the swapchain and the framebuffers are recreated.

After that happened, somehow the OLD color attachment images are beeing used.
(The cube doesnt rotate and more and resizing shows a rescaled version of the last albedo image.

This is very strange since these image should no longer exist.

I have checked and the images and descriptors I am using are being updated properly.

Has anyone else experienced this pitfall and can point me in the right direction to fix this?

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments