mirror of
https://github.com/edubart/otclient.git
synced 2025-10-19 05:53:26 +02:00
ui and graphics changes
* implement draw clipping using opengl stencil buffers * allow to create Widgets by style name with g_ui.createWidgetByStyle * styles can now have children widgets * make proper use of the isNotPathable in pathfinding * add scrollbar skin
This commit is contained in:
@@ -306,16 +306,16 @@ void WIN32Window::internalChooseGLVisual()
|
||||
0, // No Accumulation Buffer
|
||||
0, 0, 0, 0, // Accumulation Bits Ignored
|
||||
16, // 16Bit Z-Buffer (Depth Buffer)
|
||||
0, // No Stencil Buffer
|
||||
1, // 1Bit Stencil Buffer
|
||||
0, // No Auxiliary Buffer
|
||||
PFD_MAIN_PLANE, // Main Drawing Layer
|
||||
0, // Reserved
|
||||
0, 0, 0 }; // Layer Masks Ignored
|
||||
|
||||
pixelFormat = ChoosePixelFormat(m_deviceContext, &pfd);
|
||||
if(!pixelFormat)
|
||||
logFatal("Could not find a suitable pixel format");
|
||||
|
||||
pfd.cStencilBits = 8;
|
||||
if(!SetPixelFormat(m_deviceContext, pixelFormat, &pfd))
|
||||
logFatal("Could not set the pixel format");
|
||||
}
|
||||
|
@@ -367,6 +367,7 @@ void X11Window::internalChooseGLVisual()
|
||||
GLX_USE_GL,
|
||||
GLX_RGBA,
|
||||
GLX_DOUBLEBUFFER,
|
||||
GLX_STENCIL_SIZE, 1,
|
||||
None
|
||||
};
|
||||
|
||||
@@ -379,6 +380,7 @@ void X11Window::internalChooseGLVisual()
|
||||
static int attrList[] = {
|
||||
//EGL_BUFFER_SIZE, 24,
|
||||
EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT,
|
||||
EGL_STENCIL_SIZE, 1,
|
||||
EGL_NONE
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user