egl: Handle dri configs with floating point pixel data
[mesa.git] / src / gbm / backends / dri / gbm_driint.h
index db9038a623aaa22ec133234c522fcdd8a8f801e1..a8bfa39e5222f37702d7da56790237a505d892bc 100644 (file)
 struct gbm_dri_surface;
 struct gbm_dri_bo;
 
+struct gbm_dri_visual {
+   uint32_t gbm_format;
+   int dri_image_format;
+   struct {
+      int red;
+      int green;
+      int blue;
+      int alpha;
+   } rgba_shifts;
+   struct {
+      unsigned int red;
+      unsigned int green;
+      unsigned int blue;
+      unsigned int alpha;
+   } rgba_sizes;
+   bool is_float;
+};
+
 struct gbm_dri_device {
    struct gbm_device base;
 
@@ -97,6 +115,9 @@ struct gbm_dri_device {
                             void          *loaderPrivate);
 
    struct wl_drm *wl_drm;
+
+   const struct gbm_dri_visual *visual_table;
+   int num_visuals;
 };
 
 struct gbm_dri_bo {