glxapi.h File Reference

Include dependency graph for glxapi.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  __GLXcontextRec
struct  _glxapi_table

Defines

#define GLX_GLXEXT_PROTOTYPES

Typedefs

typedef struct __GLXcontextRec __GLXcontext

Functions

const char * _glxapi_get_version (void)
const char ** _glxapi_get_extensions (void)
GLuint _glxapi_get_dispatch_table_size (void)
void _glxapi_set_no_op_table (struct _glxapi_table *t)
__GLXextFuncPtr _glxapi_get_proc_address (const char *funcName)


Define Documentation

#define GLX_GLXEXT_PROTOTYPES

Definition at line 30 of file glxapi.h.


Typedef Documentation

typedef struct __GLXcontextRec __GLXcontext


Function Documentation

GLuint _glxapi_get_dispatch_table_size ( void   ) 

Definition at line 1167 of file glxapi.c.

01168 {
01169    return sizeof(struct _glxapi_table) / sizeof(void *);
01170 }

const char** _glxapi_get_extensions ( void   ) 

Definition at line 1127 of file glxapi.c.

01128 {
01129    static const char *extensions[] = {
01130 #ifdef GLX_EXT_import_context
01131       "GLX_EXT_import_context",
01132 #endif
01133 #ifdef GLX_SGI_video_sync
01134       "GLX_SGI_video_sync",
01135 #endif
01136 #ifdef GLX_MESA_copy_sub_buffer
01137       "GLX_MESA_copy_sub_buffer",
01138 #endif
01139 #ifdef GLX_MESA_release_buffers
01140       "GLX_MESA_release_buffers",
01141 #endif
01142 #ifdef GLX_MESA_pixmap_colormap
01143       "GLX_MESA_pixmap_colormap",
01144 #endif
01145 #ifdef GLX_MESA_set_3dfx_mode
01146       "GLX_MESA_set_3dfx_mode",
01147 #endif
01148 #ifdef GLX_SGIX_fbconfig
01149       "GLX_SGIX_fbconfig",
01150 #endif
01151 #ifdef GLX_SGIX_pbuffer
01152       "GLX_SGIX_pbuffer",
01153 #endif
01154 #ifdef GLX_EXT_texture_from_pixmap
01155       "GLX_EXT_texture_from_pixmap",
01156 #endif
01157       NULL
01158    };
01159    return extensions;
01160 }

__GLXextFuncPtr _glxapi_get_proc_address ( const char *  funcName  ) 

Definition at line 1355 of file glxapi.c.

References name_address_pair::Address, and name_address_pair::Name.

01356 {
01357    GLuint i;
01358    for (i = 0; GLX_functions[i].Name; i++) {
01359       if (strcmp(GLX_functions[i].Name, funcName) == 0)
01360          return GLX_functions[i].Address;
01361    }
01362    return NULL;
01363 }

const char* _glxapi_get_version ( void   ) 

Definition at line 1117 of file glxapi.c.

01118 {
01119    return "1.3";
01120 }

void _glxapi_set_no_op_table ( struct _glxapi_table t  ) 

Definition at line 1184 of file glxapi.c.

References _glxapi_get_dispatch_table_size(), and generic_no_op_func().

01185 {
01186    typedef int (*nop_func)(void);
01187    nop_func *dispatch = (nop_func *) t;
01188    GLuint n = _glxapi_get_dispatch_table_size();
01189    GLuint i;
01190    for (i = 0; i < n; i++) {
01191       dispatch[i] = generic_no_op_func;
01192    }
01193 }


Generated on Tue Sep 29 06:25:50 2009 for Gallium3D by  doxygen 1.5.4