+
+ /**
+ * Blit a part of a __DRIimage to another and flushes
+ *
+ * flush_flag:
+ * 0: no flush
+ * __BLIT_FLAG_FLUSH: flush after the blit operation
+ * __BLIT_FLAG_FINISH: flush and wait the blit finished
+ *
+ * \since 9
+ */
+ void (*blitImage)(__DRIcontext *context, __DRIimage *dst, __DRIimage *src,
+ int dstx0, int dsty0, int dstwidth, int dstheight,
+ int srcx0, int srcy0, int srcwidth, int srcheight,
+ int flush_flag);
+
+ /**
+ * Query for general capabilities of the driver that concern
+ * buffer sharing and image importing.
+ *
+ * \since 10
+ */
+ int (*getCapabilities)(__DRIscreen *screen);
+
+ /**
+ * Returns a map of the specified region of a __DRIimage for the specified usage.
+ *
+ * flags may include __DRI_IMAGE_TRANSFER_READ, which will populate the
+ * mapping with the current buffer content. If __DRI_IMAGE_TRANSFER_READ
+ * is not included in the flags, the buffer content at map time is
+ * undefined. Users wanting to modify the mapping must include
+ * __DRI_IMAGE_TRANSFER_WRITE; if __DRI_IMAGE_TRANSFER_WRITE is not
+ * included, behaviour when writing the mapping is undefined.
+ *
+ * Returns the byte stride in *stride, and an opaque pointer to data
+ * tracking the mapping in **data, which must be passed to unmapImage().
+ *
+ * \since 12
+ */
+ void *(*mapImage)(__DRIcontext *context, __DRIimage *image,
+ int x0, int y0, int width, int height,
+ unsigned int flags, int *stride, void **data);
+
+ /**
+ * Unmap a previously mapped __DRIimage
+ *
+ * \since 12
+ */
+ void (*unmapImage)(__DRIcontext *context, __DRIimage *image, void *data);
+
+
+ /**
+ * Creates an image with implementation's favorite modifiers.
+ *
+ * This acts like createImage except there is a list of modifiers passed in
+ * which the implementation may selectively use to create the DRIimage. The
+ * result should be the implementation selects one modifier (perhaps it would
+ * hold on to a few and later pick).
+ *
+ * The created image should be destroyed with destroyImage().
+ *
+ * Returns the new DRIimage. The chosen modifier can be obtained later on
+ * and passed back to things like the kernel's AddFB2 interface.
+ *
+ * \sa __DRIimageRec::createImage
+ *
+ * \since 14
+ */
+ __DRIimage *(*createImageWithModifiers)(__DRIscreen *screen,
+ int width, int height, int format,
+ const uint64_t *modifiers,
+ const unsigned int modifier_count,
+ void *loaderPrivate);
+
+ /*
+ * Like createImageFromDmaBufs, but takes also format modifiers.
+ *
+ * For EGL_EXT_image_dma_buf_import_modifiers.
+ *
+ * \since 15
+ */
+ __DRIimage *(*createImageFromDmaBufs2)(__DRIscreen *screen,
+ int width, int height, int fourcc,
+ uint64_t modifier,
+ int *fds, int num_fds,
+ int *strides, int *offsets,
+ enum __DRIYUVColorSpace color_space,
+ enum __DRISampleRange sample_range,
+ enum __DRIChromaSiting horiz_siting,
+ enum __DRIChromaSiting vert_siting,
+ unsigned *error,
+ void *loaderPrivate);
+
+ /*
+ * dmabuf format query to support EGL_EXT_image_dma_buf_import_modifiers.
+ *
+ * \param max Maximum number of formats that can be accomodated into
+ * \param formats. If zero, no formats are returned -
+ * instead, the driver returns the total number of
+ * supported dmabuf formats in \param count.
+ * \param formats Buffer to fill formats into.
+ * \param count Count of formats returned, or, total number of
+ * supported formats in case \param max is zero.
+ *
+ * Returns true on success.
+ *
+ * \since 15
+ */
+ GLboolean (*queryDmaBufFormats)(__DRIscreen *screen, int max,
+ int *formats, int *count);
+
+ /*
+ * dmabuf format modifier query for a given format to support
+ * EGL_EXT_image_dma_buf_import_modifiers.
+ *
+ * \param fourcc The format to query modifiers for. If this format
+ * is not supported by the driver, return false.
+ * \param max Maximum number of modifiers that can be accomodated in
+ * \param modifiers. If zero, no modifiers are returned -
+ * instead, the driver returns the total number of
+ * modifiers for \param format in \param count.
+ * \param modifiers Buffer to fill modifiers into.
+ * \param count Count of the modifiers returned, or, total number of
+ * supported modifiers for \param fourcc in case
+ * \param max is zero.
+ *
+ * Returns true upon success.
+ *
+ * \since 15
+ */
+ GLboolean (*queryDmaBufModifiers)(__DRIscreen *screen, int fourcc,
+ int max, uint64_t *modifiers,
+ unsigned int *external_only,
+ int *count);
+
+ /**
+ * dmabuf format modifier attribute query for a given format and modifier.
+ *
+ * \param fourcc The format to query. If this format is not supported by
+ * the driver, return false.
+ * \param modifier The modifier to query. If this format+modifier is not
+ * supported by the driver, return false.
+ * \param attrib The __DRI_IMAGE_FORMAT_MODIFIER_ATTRIB to query.
+ * \param value A pointer to where to store the result of the query.
+ *
+ * Returns true upon success.
+ *
+ * \since 16
+ */
+ GLboolean (*queryDmaBufFormatModifierAttribs)(__DRIscreen *screen,
+ uint32_t fourcc, uint64_t modifier,
+ int attrib, uint64_t *value);
+
+ /**
+ * Create a DRI image from the given renderbuffer.
+ *
+ * \param context the current DRI context
+ * \param renderbuffer the GL name of the renderbuffer
+ * \param loaderPrivate for callbacks into the loader related to the image
+ * \param error will be set to one of __DRI_IMAGE_ERROR_xxx
+ * \return the newly created image on success, or NULL otherwise
+ *
+ * \since 17
+ */
+ __DRIimage *(*createImageFromRenderbuffer2)(__DRIcontext *context,
+ int renderbuffer,
+ void *loaderPrivate,
+ unsigned *error);