mirror of https://github.com/axmolengine/axmol.git
Enable vsync by default (#2118)
* Enable vsync by default * Update comment * Update comment [skip ci]
This commit is contained in:
parent
80f55eb87a
commit
62393b9271
|
@ -88,7 +88,7 @@ struct GLContextAttrs
|
|||
int multisamplingCount;
|
||||
bool visible = true;
|
||||
bool decorated = true;
|
||||
bool vsync = false;
|
||||
bool vsync = true;
|
||||
#if defined(_WIN32)
|
||||
void* viewParent = nullptr;
|
||||
#endif
|
||||
|
|
|
@ -46,6 +46,8 @@ void AppDelegate::initGLContextAttrs()
|
|||
{
|
||||
// set OpenGL context attributes: red,green,blue,alpha,depth,stencil,multisamplesCount
|
||||
GLContextAttrs glContextAttrs = {8, 8, 8, 8, 24, 8, 0};
|
||||
// since axmol-2.2 vsync was enabled in engine by default
|
||||
// glContextAttrs.vsync = false;
|
||||
|
||||
GLView::setGLContextAttrs(glContextAttrs);
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ void AppDelegate::initGLContextAttrs()
|
|||
{
|
||||
// set OpenGL context attributes: red,green,blue,alpha,depth,stencil,multisamplesCount
|
||||
GLContextAttrs glContextAttrs = {8, 8, 8, 8, 24, 8, 0};
|
||||
|
||||
// glContextAttrs.vsync = false
|
||||
GLView::setGLContextAttrs(glContextAttrs);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue