Skip to content

Commit

Permalink
Added --sRGB and --RGB options for selecting sRGB or RGB colour buffer.
Browse files Browse the repository at this point in the history
  • Loading branch information
robertosfield committed Jan 3, 2024
1 parent 4ff9bed commit 74b9126
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions examples/app/vsgviewer/vsgviewer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,11 @@ int main(int argc, char** argv)
if (arguments.read({"--window", "-w"}, windowTraits->width, windowTraits->height)) { windowTraits->fullscreen = false; }
if (arguments.read({"--no-frame", "--nf"})) windowTraits->decoration = false;
if (arguments.read("--or")) windowTraits->overrideRedirect = true;

if (arguments.read("--d32")) windowTraits->depthFormat = VK_FORMAT_D32_SFLOAT;
if (arguments.read("--sRGB")) windowTraits->swapchainPreferences.surfaceFormat = {VK_FORMAT_B8G8R8A8_SRGB, VK_COLOR_SPACE_SRGB_NONLINEAR_KHR};
if (arguments.read("--RGB")) windowTraits->swapchainPreferences.surfaceFormat = {VK_FORMAT_B8G8R8A8_UNORM, VK_COLOR_SPACE_SRGB_NONLINEAR_KHR};

arguments.read("--screen", windowTraits->screenNum);
arguments.read("--display", windowTraits->display);
arguments.read("--samples", windowTraits->samples);
Expand Down

0 comments on commit 74b9126

Please sign in to comment.