//The resize method is called at least once before any rendering, so it's //a safe place to initialize output size related vulkan objects like the //frame buffers. protected override void OnResize() { base.OnResize(); frameBuffers?.Dispose(); frameBuffers = renderPass.CreateFrameBuffers(swapChain); buildCommandBuffers(); }
protected override void OnResize() { base.OnResize(); updateViewRequested = true; frameBuffers?.Dispose(); frameBuffers = pipeline.RenderPass.CreateFrameBuffers(swapChain); buildCommandBuffers(); }
protected override void OnResize() { base.OnResize(); dev.WaitIdle(); updateMatrices(); frameBuffers?.Dispose(); frameBuffers = pipeline.RenderPass.CreateFrameBuffers(swapChain); buildCommandBuffers(); }
public void Resize() { frameBuffers?.Dispose(); frameBuffers = new FrameBuffers(); createGBuff(); for (int i = 0; i < swapChain.ImageCount; ++i) { frameBuffers.Add(new FrameBuffer(renderPass, swapChain.Width, swapChain.Height, new Image [] { swapChain.images[i], null, gbColorRough, gbEmitMetal, gbN_AO, gbPos, hdrImg })); } //frameBuffers = renderPass.CreateFrameBuffers (swapChain); }
protected override void OnResize() { base.OnResize(); dev.WaitIdle(); renderer.Resize(Width, Height); UpdateView(); frameBuffers?.Dispose(); frameBuffers = plToneMap.RenderPass.CreateFrameBuffers(swapChain); DescriptorSetWrites dsUpdate = new DescriptorSetWrites(plToneMap.Layout.DescriptorSetLayouts[0].Bindings[0]); dsUpdate.Write(dev, descriptorSet, renderer.hdrImgResolved.Descriptor); buildCommandBuffers(); dev.WaitIdle(); }
protected override void Dispose(bool disposing) { dev.WaitIdle(); if (disposing) { if (!isDisposed) { pipeline.Dispose(); dsLayout.Dispose(); frameBuffers.Dispose(); descriptorPool.Dispose(); texture?.Dispose(); nextTexture?.Dispose(); vbo.Dispose(); ibo.Dispose(); uboMats.Dispose(); } } base.Dispose(disposing); }