summaryrefslogtreecommitdiff
path: root/src/gallium/state_trackers/xorg/xorg_tracker.h
diff options
context:
space:
mode:
authorKeith Whitwell <keithw@vmware.com>2009-11-26 11:55:47 +0000
committerKeith Whitwell <keithw@vmware.com>2009-11-26 11:55:47 +0000
commit7b0e4adaf21d4c788657eff41cb51d5c89647309 (patch)
treecbdb55e113654e1485c63c7748c55c6dd758adea /src/gallium/state_trackers/xorg/xorg_tracker.h
parent8544c309d0a296449d11cf2cf52ca306662dc41d (diff)
st/xorg: render throttling in block handler
Similar to the classic swapbuffer throttling in GL drivers, put an upper bound on the number of outstanding chunks of rendering the state tracker can generate -- where calling the block handler denotes a chunk. Currently that number is set at around 4 "chunks", but could be tweaked up or down. If a better measure for the amount of outstanding rendering is found, that would be fine too. As it stands, this improves interactivity by preventing the X server from queueing up arbitary amounts of rendering.
Diffstat (limited to 'src/gallium/state_trackers/xorg/xorg_tracker.h')
-rw-r--r--src/gallium/state_trackers/xorg/xorg_tracker.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/xorg/xorg_tracker.h b/src/gallium/state_trackers/xorg/xorg_tracker.h
index 31e11b4809..c6c7b2fe15 100644
--- a/src/gallium/state_trackers/xorg/xorg_tracker.h
+++ b/src/gallium/state_trackers/xorg/xorg_tracker.h
@@ -63,6 +63,8 @@ typedef struct
ScrnInfoPtr pScrn_2;
} EntRec, *EntPtr;
+#define XORG_NR_FENCES 3
+
typedef struct _modesettingRec
{
/* drm */
@@ -86,6 +88,8 @@ typedef struct _modesettingRec
unsigned int SaveGeneration;
void (*blockHandler)(int, pointer, pointer, pointer);
+ struct pipe_fence_handle *fence[XORG_NR_FENCES];
+
CreateScreenResourcesProcPtr createScreenResources;
/* for frontbuffer backing store */