summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeorge Sapountzis <[email protected]>2011-11-03 13:14:31 +0200
committerGeorge Sapountzis <[email protected]>2011-11-04 23:33:04 +0200
commit96bd41b315ce2943df2e59656fb200fedb866412 (patch)
treee8498be16c32c20694793c5cf69c43bcec7ada72
parente438a36d8379d2ccb06aab2fa53fb52ae100198c (diff)
dri: reorder as driver,screen,context,drawable
-rw-r--r--src/mesa/drivers/dri/common/dri_util.h130
1 files changed, 65 insertions, 65 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.h b/src/mesa/drivers/dri/common/dri_util.h
index 3a33d275541..f71b7be47e3 100644
--- a/src/mesa/drivers/dri/common/dri_util.h
+++ b/src/mesa/drivers/dri/common/dri_util.h
@@ -109,59 +109,54 @@ extern const struct __DriverAPIRec driDriverAPI;
/**
- * Per-drawable private DRI driver information.
+ * Per-screen private driver information.
*/
-struct __DRIdrawableRec {
+struct __DRIscreenRec {
/**
- * Driver's private drawable information.
- *
- * This structure is opaque.
+ * Current screen's number
*/
- void *driverPrivate;
+ int myNum;
/**
- * Private data from the loader. We just hold on to it and pass
- * it back when calling into loader provided functions.
+ * File descriptor returned when the kernel device driver is opened.
+ *
+ * Used to:
+ * - authenticate client to kernel
+ * - map the frame buffer, SAREA, etc.
+ * - close the kernel device driver
*/
- void *loaderPrivate;
+ int fd;
/**
- * Pointer to context to which this drawable is currently bound.
+ * DRM (kernel module) version information.
*/
- __DRIcontext *driContextPriv;
+ __DRIversion drm_version;
/**
- * Pointer to screen on which this drawable was created.
+ * Device-dependent private information (not stored in the SAREA).
+ *
+ * This pointer is never touched by the DRI layer.
*/
- __DRIscreen *driScreenPriv;
+ void *driverPrivate;
- /**
- * Reference count for number of context's currently bound to this
- * drawable.
- *
- * Once it reaches zero, the drawable can be destroyed.
- *
- * \note This behavior will change with GLX 1.3.
- */
- int refcount;
+ void *loaderPrivate;
- /**
- * Last value of the stamp.
- *
- * If this differs from the value stored at __DRIdrawable::dri2.stamp,
- * then the drawable information has been modified by the X server, and the
- * drawable information (below) should be retrieved from the X server.
- */
- unsigned int lastStamp;
+ const __DRIextension **extensions;
- int w, h;
+ const __DRIswrastLoaderExtension *swrast_loader;
- /**
- * Drawable timestamp. Increased when the loader calls invalidate.
- */
struct {
- unsigned int stamp;
+ /* Flag to indicate that this is a DRI2 screen. Many of the above
+ * fields will not be valid or initializaed in that case. */
+ __DRIdri2LoaderExtension *loader;
+ __DRIimageLookupExtension *image;
+ __DRIuseInvalidateExtension *useInvalidate;
} dri2;
+
+ driOptionCache optionInfo;
+ driOptionCache optionCache;
+
+ unsigned int api_mask;
};
/**
@@ -200,54 +195,59 @@ struct __DRIcontextRec {
};
/**
- * Per-screen private driver information.
+ * Per-drawable private DRI driver information.
*/
-struct __DRIscreenRec {
+struct __DRIdrawableRec {
/**
- * Current screen's number
+ * Driver's private drawable information.
+ *
+ * This structure is opaque.
*/
- int myNum;
+ void *driverPrivate;
/**
- * File descriptor returned when the kernel device driver is opened.
- *
- * Used to:
- * - authenticate client to kernel
- * - map the frame buffer, SAREA, etc.
- * - close the kernel device driver
+ * Private data from the loader. We just hold on to it and pass
+ * it back when calling into loader provided functions.
*/
- int fd;
+ void *loaderPrivate;
/**
- * DRM (kernel module) version information.
+ * Pointer to context to which this drawable is currently bound.
*/
- __DRIversion drm_version;
+ __DRIcontext *driContextPriv;
/**
- * Device-dependent private information (not stored in the SAREA).
- *
- * This pointer is never touched by the DRI layer.
+ * Pointer to screen on which this drawable was created.
*/
- void *driverPrivate;
+ __DRIscreen *driScreenPriv;
- void *loaderPrivate;
+ /**
+ * Reference count for number of context's currently bound to this
+ * drawable.
+ *
+ * Once it reaches zero, the drawable can be destroyed.
+ *
+ * \note This behavior will change with GLX 1.3.
+ */
+ int refcount;
- const __DRIextension **extensions;
+ /**
+ * Last value of the stamp.
+ *
+ * If this differs from the value stored at __DRIdrawable::dri2.stamp,
+ * then the drawable information has been modified by the X server, and the
+ * drawable information (below) should be retrieved from the X server.
+ */
+ unsigned int lastStamp;
- const __DRIswrastLoaderExtension *swrast_loader;
+ int w, h;
+ /**
+ * Drawable timestamp. Increased when the loader calls invalidate.
+ */
struct {
- /* Flag to indicate that this is a DRI2 screen. Many of the above
- * fields will not be valid or initializaed in that case. */
- __DRIdri2LoaderExtension *loader;
- __DRIimageLookupExtension *image;
- __DRIuseInvalidateExtension *useInvalidate;
+ unsigned int stamp;
} dri2;
-
- driOptionCache optionInfo;
- driOptionCache optionCache;
-
- unsigned int api_mask;
};
extern void