Skip to content

Support multiple adhoc-swapchains, use for multi-layered images#2835

Merged
fabian-lunarg merged 5 commits intoLunarG:devfrom
fabian-lunarg:fabian_present_override_follow_up
Apr 15, 2026
Merged

Support multiple adhoc-swapchains, use for multi-layered images#2835
fabian-lunarg merged 5 commits intoLunarG:devfrom
fabian-lunarg:fabian_present_override_follow_up

Conversation

@fabian-lunarg
Copy link
Copy Markdown
Contributor

@fabian-lunarg fabian-lunarg commented Mar 31, 2026

  • refactor adhoc-windowing code to support multiple windows
  • present multi-layer images in Swapchain::PresentImageAdHoc using multiple windows
  • fix missing sRGB check for fallback color-format
  • add option to blit into specific layer(s)
  • some work on usability, window-title/position

@fabian-lunarg fabian-lunarg self-assigned this Mar 31, 2026
@fabian-lunarg fabian-lunarg requested a review from a team as a code owner March 31, 2026 09:38
@fabian-lunarg fabian-lunarg added the approved-to-run-ci Can run CI check on internal LunarG machines label Mar 31, 2026
@fabian-lunarg fabian-lunarg force-pushed the fabian_present_override_follow_up branch from a93277d to 2f17fb0 Compare April 14, 2026 16:10
AdhocSwapChain(AdhocSwapChain&& other) noexcept : AdhocSwapChain() { swap(*this, other); }
AdhocSwapChain& operator=(AdhocSwapChain other) noexcept
{
swap(*this, other);
Copy link
Copy Markdown
Contributor

@MarkY-LunarG MarkY-LunarG Apr 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you need "using std::swap" above this too (and above on line 219) or at least globally?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

only used in the body of AdHocSwapChain::swap(), so should not have spilled into the namespace.

title_ss << " - " << window_width << " x " << window_height;
if (layer_count > 1)
{
title_ss << " - layer: " << (layer + 1) << " / " << layer_count;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it typical for layers to be 1 based?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, but I thought it would make more intuitive sense, when displaying as a count. e.g. for two images I wanted to avoid: 0 / 2 | 1 / 2 and preferred 1 / 2 | 2 / 2. also the resulting title-bar is not guaranteed to be even visible (e.g. on wayland we do not render window-decorations at all). so this whole string-formatting was mostly a nice to have

@fabian-lunarg
Copy link
Copy Markdown
Contributor Author

thank you @MarkY-LunarG !

@fabian-lunarg fabian-lunarg force-pushed the fabian_present_override_follow_up branch from 2f17fb0 to 3f79f37 Compare April 15, 2026 06:34
@fabian-lunarg fabian-lunarg enabled auto-merge April 15, 2026 06:34
@fabian-lunarg fabian-lunarg disabled auto-merge April 15, 2026 06:34
@fabian-lunarg fabian-lunarg added this pull request to the merge queue Apr 15, 2026
Merged via the queue into LunarG:dev with commit 9453f14 Apr 15, 2026
10 checks passed
davidlunarg pushed a commit to davidlunarg/gfxreconstruct that referenced this pull request Apr 15, 2026
…rG#2835)

* Fix for fallback-VkFormat, check if SRGB is required

* refactor AdhocSwapChain lifecycle, allow multiple windows (WIP)

* Support mutliple adhoc-swapchains, use for multi-layered images

* window-title and positioning. report layer-idx, if any. tile to avoid overlap

* missing header-include for android
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved-to-run-ci Can run CI check on internal LunarG machines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants