mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-06 19:40:10 +01:00
loader_dri3: Increase the likelyhood of reusing the current swap buffer
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
This commit is contained in:
parent
2db9548296
commit
f71e174bb8
1 changed files with 6 additions and 0 deletions
|
|
@ -56,6 +56,9 @@ static struct loader_dri3_blit_context blit_context = {
|
|||
_MTX_INITIALIZER_NP, NULL
|
||||
};
|
||||
|
||||
static void
|
||||
dri3_flush_present_events(struct loader_dri3_drawable *draw);
|
||||
|
||||
/**
|
||||
* Do we have blit functionality in the image blit extension?
|
||||
*
|
||||
|
|
@ -482,6 +485,9 @@ dri3_find_back(struct loader_dri3_drawable *draw)
|
|||
xcb_generic_event_t *ev;
|
||||
xcb_present_generic_event_t *ge;
|
||||
|
||||
/* Increase the likelyhood of reusing current buffer */
|
||||
dri3_flush_present_events(draw);
|
||||
|
||||
for (;;) {
|
||||
for (b = 0; b < draw->num_back; b++) {
|
||||
int id = LOADER_DRI3_BACK_ID((b + draw->cur_back) % draw->num_back);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue