glx: clarify a comment

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
Yuxuan Shui 2019-08-11 03:23:57 +01:00
parent 0771234ee2
commit 04520368f6
No known key found for this signature in database
GPG Key ID: 37C999F617EA1A47
1 changed files with 5 additions and 3 deletions

View File

@ -119,10 +119,12 @@ struct glx_fbconfig_info *glx_find_fbconfig(Display *dpy, int screen, struct xvi
if (m.visual_depth != -1 &&
x_get_visual_depth(XGetXCBConnection(dpy), (xcb_visualid_t)visual) !=
m.visual_depth) {
// Some driver might attach fbconfig to a GLX visual with a
// different depth.
// FBConfig and the correspondent X Visual might not have the same
// depth. (e.g. 32 bit FBConfig with a 24 bit Visual). This is
// quite common, seen in both open source and proprietary drivers.
//
// (That makes total sense. - NVIDIA developers)
// If the FBConfig has a matching depth but its visual doesn't, we
// still cannot use it.
continue;
}