40 #ifndef DRI_INTERFACE_H
41 #define DRI_INTERFACE_H
44 #if defined(__APPLE__) || defined(__CYGWIN__) || defined(__GNU__)
45 #ifndef __NOT_HAVE_DRM_H
46 #define __NOT_HAVE_DRM_H
50 #ifndef __NOT_HAVE_DRM_H
53 typedef unsigned int drm_context_t;
54 typedef unsigned int drm_drawable_t;
55 typedef struct drm_clip_rect drm_clip_rect_t;
126 #define __DRI_READ_DRAWABLE "DRI_ReadDrawable"
127 #define __DRI_READ_DRAWABLE_VERSION 1
132 #define __DRI_COPY_SUB_BUFFER "DRI_CopySubBuffer"
133 #define __DRI_COPY_SUB_BUFFER_VERSION 1
143 #define __DRI_SWAP_CONTROL "DRI_SwapControl"
144 #define __DRI_SWAP_CONTROL_VERSION 1
154 #define __DRI_FRAME_TRACKING "DRI_FrameTracking"
155 #define __DRI_FRAME_TRACKING_VERSION 1
173 float * lastMissedUsage,
float *
usage);
180 #define __DRI_MEDIA_STREAM_COUNTER "DRI_MediaStreamCounter"
181 #define __DRI_MEDIA_STREAM_COUNTER_VERSION 1
204 #define __DRI_TEX_OFFSET "DRI_TexOffset"
205 #define __DRI_TEX_OFFSET_VERSION 1
224 #define __DRI_TEXTURE_FORMAT_NONE 0x20D8
225 #define __DRI_TEXTURE_FORMAT_RGB 0x20D9
226 #define __DRI_TEXTURE_FORMAT_RGBA 0x20DA
228 #define __DRI_TEX_BUFFER "DRI_TexBuffer"
229 #define __DRI_TEX_BUFFER_VERSION 2
268 #define __DRI2_FLUSH "DRI2_Flush"
269 #define __DRI2_FLUSH_VERSION 3
314 #define __DRI_GET_DRAWABLE_INFO "DRI_GetDrawableInfo"
315 #define __DRI_GET_DRAWABLE_INFO_VERSION 1
324 unsigned int *
index,
unsigned int * stamp,
326 int * numClipRects, drm_clip_rect_t ** pClipRects,
327 int * backX,
int * backY,
328 int * numBackClipRects, drm_clip_rect_t ** pBackClipRects,
329 void *loaderPrivate);
335 #define __DRI_SYSTEM_TIME "DRI_SystemTime"
336 #define __DRI_SYSTEM_TIME_VERSION 1
354 void *loaderPrivate);
360 #define __DRI_DAMAGE "DRI_Damage"
361 #define __DRI_DAMAGE_VERSION 1
382 drm_clip_rect_t *rects,
int num_rects,
384 void *loaderPrivate);
387 #define __DRI_SWRAST_IMAGE_OP_DRAW 1
388 #define __DRI_SWRAST_IMAGE_OP_CLEAR 2
389 #define __DRI_SWRAST_IMAGE_OP_SWAP 3
394 #define __DRI_SWRAST_LOADER "DRI_SWRastLoader"
395 #define __DRI_SWRAST_LOADER_VERSION 1
404 void *loaderPrivate);
411 char *
data,
void *loaderPrivate);
418 char *
data,
void *loaderPrivate);
433 #define __DRI_USE_INVALIDATE "DRI_UseInvalidate"
434 #define __DRI_USE_INVALIDATE_VERSION 1
447 #define __DRI_DRIVER_EXTENSIONS "__driDriverExtensions"
455 #define __DRI_ATTRIB_BUFFER_SIZE 1
456 #define __DRI_ATTRIB_LEVEL 2
457 #define __DRI_ATTRIB_RED_SIZE 3
458 #define __DRI_ATTRIB_GREEN_SIZE 4
459 #define __DRI_ATTRIB_BLUE_SIZE 5
460 #define __DRI_ATTRIB_LUMINANCE_SIZE 6
461 #define __DRI_ATTRIB_ALPHA_SIZE 7
462 #define __DRI_ATTRIB_ALPHA_MASK_SIZE 8
463 #define __DRI_ATTRIB_DEPTH_SIZE 9
464 #define __DRI_ATTRIB_STENCIL_SIZE 10
465 #define __DRI_ATTRIB_ACCUM_RED_SIZE 11
466 #define __DRI_ATTRIB_ACCUM_GREEN_SIZE 12
467 #define __DRI_ATTRIB_ACCUM_BLUE_SIZE 13
468 #define __DRI_ATTRIB_ACCUM_ALPHA_SIZE 14
469 #define __DRI_ATTRIB_SAMPLE_BUFFERS 15
470 #define __DRI_ATTRIB_SAMPLES 16
471 #define __DRI_ATTRIB_RENDER_TYPE 17
472 #define __DRI_ATTRIB_CONFIG_CAVEAT 18
473 #define __DRI_ATTRIB_CONFORMANT 19
474 #define __DRI_ATTRIB_DOUBLE_BUFFER 20
475 #define __DRI_ATTRIB_STEREO 21
476 #define __DRI_ATTRIB_AUX_BUFFERS 22
477 #define __DRI_ATTRIB_TRANSPARENT_TYPE 23
478 #define __DRI_ATTRIB_TRANSPARENT_INDEX_VALUE 24
479 #define __DRI_ATTRIB_TRANSPARENT_RED_VALUE 25
480 #define __DRI_ATTRIB_TRANSPARENT_GREEN_VALUE 26
481 #define __DRI_ATTRIB_TRANSPARENT_BLUE_VALUE 27
482 #define __DRI_ATTRIB_TRANSPARENT_ALPHA_VALUE 28
483 #define __DRI_ATTRIB_FLOAT_MODE 29
484 #define __DRI_ATTRIB_RED_MASK 30
485 #define __DRI_ATTRIB_GREEN_MASK 31
486 #define __DRI_ATTRIB_BLUE_MASK 32
487 #define __DRI_ATTRIB_ALPHA_MASK 33
488 #define __DRI_ATTRIB_MAX_PBUFFER_WIDTH 34
489 #define __DRI_ATTRIB_MAX_PBUFFER_HEIGHT 35
490 #define __DRI_ATTRIB_MAX_PBUFFER_PIXELS 36
491 #define __DRI_ATTRIB_OPTIMAL_PBUFFER_WIDTH 37
492 #define __DRI_ATTRIB_OPTIMAL_PBUFFER_HEIGHT 38
493 #define __DRI_ATTRIB_VISUAL_SELECT_GROUP 39
494 #define __DRI_ATTRIB_SWAP_METHOD 40
495 #define __DRI_ATTRIB_MAX_SWAP_INTERVAL 41
496 #define __DRI_ATTRIB_MIN_SWAP_INTERVAL 42
497 #define __DRI_ATTRIB_BIND_TO_TEXTURE_RGB 43
498 #define __DRI_ATTRIB_BIND_TO_TEXTURE_RGBA 44
499 #define __DRI_ATTRIB_BIND_TO_MIPMAP_TEXTURE 45
500 #define __DRI_ATTRIB_BIND_TO_TEXTURE_TARGETS 46
501 #define __DRI_ATTRIB_YINVERTED 47
502 #define __DRI_ATTRIB_FRAMEBUFFER_SRGB_CAPABLE 48
505 #define __DRI_ATTRIB_RGBA_BIT 0x01
506 #define __DRI_ATTRIB_COLOR_INDEX_BIT 0x02
507 #define __DRI_ATTRIB_LUMINANCE_BIT 0x04
510 #define __DRI_ATTRIB_SLOW_BIT 0x01
511 #define __DRI_ATTRIB_NON_CONFORMANT_CONFIG 0x02
514 #define __DRI_ATTRIB_TRANSPARENT_RGB 0x00
515 #define __DRI_ATTRIB_TRANSPARENT_INDEX 0x01
518 #define __DRI_ATTRIB_TEXTURE_1D_BIT 0x01
519 #define __DRI_ATTRIB_TEXTURE_2D_BIT 0x02
520 #define __DRI_ATTRIB_TEXTURE_RECTANGLE_BIT 0x04
525 #define __DRI_CORE "DRI_Core"
526 #define __DRI_CORE_VERSION 1
532 unsigned int sarea_handle,
535 void *loaderPrivate);
543 unsigned int *
value);
546 unsigned int *attrib,
unsigned int *
value);
550 unsigned int drawable_id,
552 void *loaderPrivate);
561 void *loaderPrivate);
624 #define __DRI_LEGACY "DRI_Legacy"
625 #define __DRI_LEGACY_VERSION 1
635 void *pSAREA,
int fd,
638 void *loaderPrivate);
642 drm_drawable_t hwDrawable,
643 int renderType,
const int *attrs,
644 void *loaderPrivate);
650 drm_context_t hwContext,
651 void *loaderPrivate);
659 #define __DRI_SWRAST "DRI_SWRast"
660 #define __DRI_SWRAST_VERSION 2
668 void *loaderPrivate);
672 void *loaderPrivate);
685 #define __DRI_BUFFER_FRONT_LEFT 0
686 #define __DRI_BUFFER_BACK_LEFT 1
687 #define __DRI_BUFFER_FRONT_RIGHT 2
688 #define __DRI_BUFFER_BACK_RIGHT 3
689 #define __DRI_BUFFER_DEPTH 4
690 #define __DRI_BUFFER_STENCIL 5
691 #define __DRI_BUFFER_ACCUM 6
692 #define __DRI_BUFFER_FAKE_FRONT_LEFT 7
693 #define __DRI_BUFFER_FAKE_FRONT_RIGHT 8
694 #define __DRI_BUFFER_DEPTH_STENCIL 9
695 #define __DRI_BUFFER_HIZ 10
705 #define __DRI_DRI2_LOADER "DRI_DRI2Loader"
706 #define __DRI_DRI2_LOADER_VERSION 3
713 int *out_count,
void *loaderPrivate);
751 int *out_count,
void *loaderPrivate);
758 #define __DRI_DRI2 "DRI_DRI2"
759 #define __DRI_DRI2_VERSION 2
761 #define __DRI_API_OPENGL 0
762 #define __DRI_API_GLES 1
763 #define __DRI_API_GLES2 2
771 void *loaderPrivate);
775 void *loaderPrivate);
780 void *loaderPrivate);
805 #define __DRI_IMAGE "DRI_IMAGE"
806 #define __DRI_IMAGE_VERSION 1
814 #define __DRI_IMAGE_FORMAT_RGB565 0x1001
815 #define __DRI_IMAGE_FORMAT_XRGB8888 0x1002
816 #define __DRI_IMAGE_FORMAT_ARGB8888 0x1003
818 #define __DRI_IMAGE_USE_SHARE 0x0001
819 #define __DRI_IMAGE_USE_SCANOUT 0x0002
820 #define __DRI_IMAGE_USE_CURSOR 0x0004
826 #define __DRI_IMAGE_ATTRIB_STRIDE 0x2000
827 #define __DRI_IMAGE_ATTRIB_HANDLE 0x2001
828 #define __DRI_IMAGE_ATTRIB_NAME 0x2002
838 void *loaderPrivate);
842 void *loaderPrivate);
849 void *loaderPrivate);
869 #define __DRI_IMAGE_LOOKUP "DRI_IMAGE_LOOKUP"
870 #define __DRI_IMAGE_LOOKUP_VERSION 1
877 void *loaderPrivate);
883 #define __DRI2_CONFIG_QUERY "DRI_CONFIG_QUERY"
884 #define __DRI2_CONFIG_QUERY_VERSION 1
INT32 INT32 * denominator
GLboolean(* getMSCRate)(__DRIdrawable *draw, int32_t *numerator, int32_t *denominator, void *loaderPrivate)
struct __DRIimageRec __DRIimage
struct __DRIconfigRec __DRIconfig
GLuint const GLfloat * val
GLfloat GLfloat GLfloat GLfloat h
GLvoid **typedef void(GLAPIENTRY *PFNGLGETVERTEXATTRIBDVPROC)(GLuint
void(* releaseBuffer)(__DRIscreen *screen, __DRIbuffer *buffer)
struct __DRIscreenRec __DRIscreen
int(* unbindContext)(__DRIcontext *ctx)
void(* destroyScreen)(__DRIscreen *screen)
int(* getConfigAttrib)(const __DRIconfig *config, unsigned int attrib, unsigned int *value)
const char __driConfigOptions[]
void(* flush)(__DRIdrawable *drawable)
EGLSurface EGLint EGLint EGLint EGLint height
EGLImageKHR EGLint * name
struct __DRIcontextRec __DRIcontext
void(* swapBuffers)(__DRIdrawable *drawable)
int(* configQueryf)(__DRIscreen *screen, const char *var, GLfloat *val)
void(* destroyContext)(__DRIcontext *context)
void(* getImage)(__DRIdrawable *readable, int x, int y, int width, int height, char *data, void *loaderPrivate)
void(* setSwapInterval)(__DRIdrawable *drawable, unsigned int inteval)
EGLContext EGLenum target
EGLContext EGLenum EGLClientBuffer buffer
int(* frameTracking)(__DRIdrawable *drawable, GLboolean enable)
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
EGLSurface EGLint EGLint EGLint width
unsigned int(* getSwapInterval)(__DRIdrawable *drawable)
void(* destroyDrawable)(__DRIdrawable *drawable)
void(* releaseTexBuffer)(__DRIcontext *pDRICtx, GLint target, __DRIdrawable *pDraw)
GLboolean(* queryImage)(__DRIimage *image, int attrib, int *value)
int(* getUST)(int64_t *ust)
struct __DRIloaderExtensionRec __DRIloaderExtension
int(* indexConfigAttrib)(const __DRIconfig *config, int index, unsigned int *attrib, unsigned int *value)
GLboolean(* getDrawableInfo)(__DRIdrawable *drawable, unsigned int *index, unsigned int *stamp, int *x, int *y, int *width, int *height, int *numClipRects, drm_clip_rect_t **pClipRects, int *backX, int *backY, int *numBackClipRects, drm_clip_rect_t **pBackClipRects, void *loaderPrivate)
GLint GLenum GLsizei GLsizei GLsizei GLint GLenum format
GLint GLenum GLsizei GLsizei GLsizei depth
int(* bindContext)(__DRIcontext *ctx, __DRIdrawable *pdraw, __DRIdrawable *pread)
int(* queryFrameTracking)(__DRIdrawable *drawable, int64_t *sbc, int64_t *missedFrames, float *lastMissedUsage, float *usage)
struct __DRIdisplayRec __DRIdisplay
void(* invalidate)(__DRIdrawable *drawable)
void(* setTexBuffer)(__DRIcontext *pDRICtx, GLint target, __DRIdrawable *pDraw)
int(* configQueryi)(__DRIscreen *screen, const char *var, GLint *val)
void(* copySubBuffer)(__DRIdrawable *drawable, int x, int y, int w, int h)
EGLSurface EGLint EGLint y
int(* configQueryb)(__DRIscreen *screen, const char *var, GLboolean *val)
void(* destroyImage)(__DRIimage *image)
EGLSurface EGLint void ** value
void(* getDrawableInfo)(__DRIdrawable *drawable, int *x, int *y, int *width, int *height, void *loaderPrivate)
GLint GLint GLint GLint GLint GLint GLint GLbitfield mask
GLint GLint GLint GLint GLint w
void(* reportDamage)(__DRIdrawable *draw, int x, int y, drm_clip_rect_t *rects, int num_rects, GLboolean front_buffer, void *loaderPrivate)
unsigned int(* getAPIMask)(__DRIscreen *screen)
int(* copyContext)(__DRIcontext *dest, __DRIcontext *src, unsigned long mask)
void(* setTexOffset)(__DRIcontext *pDRICtx, GLint texname, unsigned long long offset, GLint depth, GLuint pitch)
GLsizeiptr const GLvoid GLenum usage
struct __DRIdrawableRec __DRIdrawable
void(* setTexBuffer2)(__DRIcontext *pDRICtx, GLint target, GLint format, __DRIdrawable *pDraw)
void(* putImage)(__DRIdrawable *drawable, int op, int x, int y, int width, int height, char *data, void *loaderPrivate)
void(* flushFrontBuffer)(__DRIdrawable *driDrawable, void *loaderPrivate)
INT64 INT64 INT64 remainder
GLsizei const GLenum * attachments