You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
use a Threadsafe Queue for present, make the ISimpleManagedSurface::ISwapchainResources hold swapchain images, and prototype ISimpleManagedSurface::immediateBlit
// An interesting solution to the "Frames In Flight", our tiny wrapper class will have its own Timeline Semaphore incrementing with each acquire, and thats it.
if (!cmdbuf->pipelineBarrier(asset::EDF_NONE,depInfo))
104
+
returnfalse;
105
+
106
+
// do the blit
107
+
{
108
+
const IGPUCommandBuffer::SImageBlit region = {
109
+
// .srcSubresource = contents.subresourceRange,
110
+
// .srcOffsets[2] = ,
111
+
// .dstSubresource = ,
112
+
// .dstOffsets =,
113
+
};
114
+
if (!cmdbuf->blitImage(contents.image,blitSrcLayout,acquiredImage,blitDstLayout,1,®ion,IGPUSampler::ETF_LINEAR))
115
+
returnfalse;
116
+
}
117
+
118
+
// barrier after
119
+
constimage_barrier_t postBarriers[2] = {
120
+
{
121
+
.barrier = {
122
+
// When transitioning the image to VK_IMAGE_LAYOUT_SHARED_PRESENT_KHR or VK_IMAGE_LAYOUT_PRESENT_SRC_KHR, there is no need to delay subsequent processing,
123
+
// or perform any visibility operations (as vkQueuePresentKHR performs automatic visibility operations).
124
+
// To achieve this, the dstAccessMask member of the VkImageMemoryBarrier should be set to 0, and the dstStageMask parameter should be set to VK_PIPELINE_STAGE_2_NONE
0 commit comments