i965: Move front buffer rendering fields from intel_context to brw.
[mesa.git] / src / mesa / drivers / dri / i965 / brw_context.h
index 21894cdd89a59dda8c7099ee3fd3ab8f99953e72..6d2393e7b2ea64be5438985e0bd9c6fe19461bfa 100644 (file)
@@ -802,6 +802,31 @@ struct brw_context
 
    } vtbl;
 
+   /**
+    * Set if rendering has occured to the drawable's front buffer.
+    *
+    * This is used in the DRI2 case to detect that glFlush should also copy
+    * the contents of the fake front buffer to the real front buffer.
+    */
+   bool front_buffer_dirty;
+
+   /**
+    * Track whether front-buffer rendering is currently enabled
+    *
+    * A separate flag is used to track this in order to support MRT more
+    * easily.
+    */
+   bool is_front_buffer_rendering;
+
+   /**
+    * Track whether front-buffer is the current read target.
+    *
+    * This is closely associated with is_front_buffer_rendering, but may
+    * be set separately.  The DRI2 fake front buffer must be referenced
+    * either way.
+    */
+   bool is_front_buffer_reading;
+
    /** drirc option cache */
    driOptionCache optionCache;