Skip to content

Commit

Permalink
Revert commit 9f66ce0
Browse files Browse the repository at this point in the history
  • Loading branch information
tx00100xt committed Nov 7, 2023
1 parent 3e91ce3 commit 791bd50
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 28 deletions.
22 changes: 8 additions & 14 deletions SamTFE/Sources/Engine/Graphics/GfxLibrary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1533,21 +1533,15 @@ BOOL CGfxLibrary::StartDisplayMode( enum GfxAPIType eAPI, INDEX iAdapter, PIX pi
else if (eAPI == GAT_VK)
{
#ifdef PLATFORM_WIN32
PIX pixCurrentSizeI = ::GetSystemMetrics(SM_CXSCREEN);
PIX pixCurrentSizeJ = ::GetSystemMetrics(SM_CYSCREEN);
if ( (pixCurrentSizeI == pixSizeI) && (pixCurrentSizeJ == pixSizeJ) ) {
// Nothing, because the resolution does not need to be changed
// disable multimonitor support if it can interfere with Vulkan
MonitorsOff();
if( bFullScreen) {
// set windows mode to fit same size
bSuccess = CDS_SetMode( pixSizeI, pixSizeJ, eColorDepth);
if( !bSuccess) return FALSE;
} else {
// disable multimonitor support if it can interfere with Vulkan
MonitorsOff();
if( bFullScreen) {
// set windows mode to fit same size
bSuccess = CDS_SetMode( pixSizeI, pixSizeJ, eColorDepth);
if( !bSuccess) return FALSE;
} else {
// reset windows mode
CDS_ResetMode();
}
// reset windows mode
CDS_ResetMode();
}
#endif
// startup Vulkan
Expand Down
22 changes: 8 additions & 14 deletions SamTSE/Sources/Engine/Graphics/GfxLibrary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1533,21 +1533,15 @@ BOOL CGfxLibrary::StartDisplayMode( enum GfxAPIType eAPI, INDEX iAdapter, PIX pi
else if (eAPI == GAT_VK)
{
#ifdef PLATFORM_WIN32
PIX pixCurrentSizeI = ::GetSystemMetrics(SM_CXSCREEN);
PIX pixCurrentSizeJ = ::GetSystemMetrics(SM_CYSCREEN);
if ( (pixCurrentSizeI == pixSizeI) && (pixCurrentSizeJ == pixSizeJ) ) {
// Nothing, because the resolution does not need to be changed
// disable multimonitor support if it can interfere with Vulkan
MonitorsOff();
if( bFullScreen) {
// set windows mode to fit same size
bSuccess = CDS_SetMode( pixSizeI, pixSizeJ, eColorDepth);
if( !bSuccess) return FALSE;
} else {
// disable multimonitor support if it can interfere with Vulkan
MonitorsOff();
if( bFullScreen) {
// set windows mode to fit same size
bSuccess = CDS_SetMode( pixSizeI, pixSizeJ, eColorDepth);
if( !bSuccess) return FALSE;
} else {
// reset windows mode
CDS_ResetMode();
}
// reset windows mode
CDS_ResetMode();
}
#endif
// startup Vulkan
Expand Down

0 comments on commit 791bd50

Please sign in to comment.