Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions olcPixelGameEngine.h
Original file line number Diff line number Diff line change
Expand Up @@ -4257,11 +4257,12 @@ namespace olc
PFD_MAIN_PLANE, 0, 0, 0, 0
};

int pf = 0;
if (!(pf = ChoosePixelFormat(glDeviceContext, &pfd))) return olc::FAIL;
int pf = ChoosePixelFormat(glDeviceContext, &pfd);
if (!pf) return olc::FAIL;
SetPixelFormat(glDeviceContext, pf, &pfd);

if (!(glRenderContext = wglCreateContext(glDeviceContext))) return olc::FAIL;

glRenderContext = wglCreateContext(glDeviceContext);
if (!glRenderContext) return olc::FAIL;
wglMakeCurrent(glDeviceContext, glRenderContext);

// Remove Frame cap
Expand Down Expand Up @@ -6693,4 +6694,3 @@ namespace olc
// O------------------------------------------------------------------------------O
// | END OF OLC_PGE_APPLICATION |
// O------------------------------------------------------------------------------O