dril: also create double-buffered configs in swrast fallback
Fixes: 06d417af80 ("dril: use the super fallback path for software fallback")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31013>
This commit is contained in:
committed by
Marge Bot
parent
68a631947f
commit
56ac378454
@@ -437,9 +437,16 @@ drilCreateNewScreen(int scrn, int fd,
|
||||
const __DRIconfig **configs = init_dri2_configs(fd);
|
||||
if (!configs && fd == -1) {
|
||||
// otherwise set configs to point to our config list
|
||||
configs = calloc(ARRAY_SIZE(drilConfigs) + 1, sizeof(void *));
|
||||
configs = calloc(ARRAY_SIZE(drilConfigs) * 2 + 1, sizeof(void *));
|
||||
int c = 0;
|
||||
for (int i = 0; i < ARRAY_SIZE(drilConfigs); i++) {
|
||||
configs[i] = mem_dup(&drilConfigs[i], sizeof(drilConfigs[i]));
|
||||
/* create normal config */
|
||||
configs[c++] = mem_dup(&drilConfigs[i], sizeof(drilConfigs[i]));
|
||||
|
||||
/* create double-buffered config */
|
||||
configs[c] = mem_dup(&drilConfigs[i], sizeof(drilConfigs[i]));
|
||||
struct gl_config *cfg = (void*)configs[c++];
|
||||
cfg->doubleBufferMode = 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user