diff options
author | Kristian Høgsberg <krh@hinata.boston.redhat.com> | 2007-05-16 14:10:29 -0400 |
---|---|---|
committer | Kristian Høgsberg <krh@redhat.com> | 2007-10-11 11:09:57 -0400 |
commit | 78a6aa57a0155d72280dd91c05513c847bf76f3b (patch) | |
tree | f007653457bdcff728af99fda719b574c20a2575 /include | |
parent | efaf90b03e8b69e04909bce071f8ef6b65cc0e9d (diff) |
Move GLX_MESA_allocate_memory related functions to new extension mechanism.
Diffstat (limited to 'include')
-rw-r--r-- | include/GL/internal/dri_interface.h | 34 |
1 files changed, 18 insertions, 16 deletions
diff --git a/include/GL/internal/dri_interface.h b/include/GL/internal/dri_interface.h index 7eb168a1b9..fcf82523d9 100644 --- a/include/GL/internal/dri_interface.h +++ b/include/GL/internal/dri_interface.h @@ -57,9 +57,10 @@ typedef struct __DRIframebufferRec __DRIframebuffer; typedef struct __DRIversionRec __DRIversion; typedef struct __DRIinterfaceMethodsRec __DRIinterfaceMethods; -typedef struct __DRIextensionRec __DRIextension; +typedef struct __DRIextensionRec __DRIextension; typedef struct __DRIcopySubBufferExtensionRec __DRIcopySubBufferExtension; typedef struct __DRIswapControlExtensionRec __DRIswapControlExtension; +typedef struct __DRIallocateExtensionRec __DRIallocateExtension; /*@}*/ @@ -96,6 +97,22 @@ struct __DRIswapControlExtensionRec { }; /** + * Used by drivers that implement the GLX_MESA_allocate_memory. + */ +#define __DRI_ALLOCATE "DRI_Allocate" +struct __DRIallocateExtensionRec { + __DRIextension base; + + void *(*allocateMemory)(__DRIscreen *screen, GLsizei size, + GLfloat readfreq, GLfloat writefreq, + GLfloat priority); + + void (*freeMemory)(__DRIscreen *screen, GLvoid *pointer); + + GLuint (*memoryOffset)(__DRIscreen *screen, const GLvoid *pointer); +}; + +/** * \name Functions provided by the driver loader. */ /*@{*/ @@ -341,21 +358,6 @@ struct __DRIscreenRec { int (*getMSC)(__DRIscreen *screen, int64_t *msc); /** - * Functions associated with MESA_allocate_memory. - * - * \since Internal API version 20030815. - */ - /*@{*/ - void *(*allocateMemory)(__DRIscreen *screen, GLsizei size, - GLfloat readfreq, GLfloat writefreq, - GLfloat priority); - - void (*freeMemory)(__DRIscreen *screen, GLvoid *pointer); - - GLuint (*memoryOffset)(__DRIscreen *screen, const GLvoid *pointer); - /*@}*/ - - /** * Method to create the private DRI context data and initialize the * context dependent methods. * |