diff options
-rw-r--r-- | src/mesa/drivers/x11/fakeglx.c | 17 | ||||
-rw-r--r-- | src/mesa/drivers/x11/glxapi.c | 27 |
2 files changed, 37 insertions, 7 deletions
diff --git a/src/mesa/drivers/x11/fakeglx.c b/src/mesa/drivers/x11/fakeglx.c index 5a830dc0cc0..3027c3bb60f 100644 --- a/src/mesa/drivers/x11/fakeglx.c +++ b/src/mesa/drivers/x11/fakeglx.c @@ -1,4 +1,4 @@ -/* $Id: fakeglx.c,v 1.76 2002/11/14 16:14:56 brianp Exp $ */ +/* $Id: fakeglx.c,v 1.77 2002/11/18 15:11:49 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -2637,6 +2637,16 @@ Fake_glXFreeMemoryNV( GLvoid *pointer ) } +/*** GLX_MESA_agp_offset */ + +static GLuint +Fake_glXGetAGPOffsetMESA( const GLvoid *pointer ) +{ + (void) pointer; + return ~0; +} + + extern struct _glxapi_table *_mesa_GetGLXDispatchTable(void); struct _glxapi_table *_mesa_GetGLXDispatchTable(void) @@ -2775,9 +2785,12 @@ struct _glxapi_table *_mesa_GetGLXDispatchTable(void) /*** GLX_MESA_set_3dfx_mode ***/ glx.Set3DfxModeMESA = Fake_glXSet3DfxModeMESA; - /*** GLX AGP memory allocation ***/ + /*** GLX_NV_vertex_array_range ***/ glx.AllocateMemoryNV = Fake_glXAllocateMemoryNV; glx.FreeMemoryNV = Fake_glXFreeMemoryNV; + /*** GLX_MESA_agp_offset ***/ + glx.GetAGPOffsetMESA = Fake_glXGetAGPOffsetMESA; + return &glx; } diff --git a/src/mesa/drivers/x11/glxapi.c b/src/mesa/drivers/x11/glxapi.c index 7b36d419641..81170a7ef36 100644 --- a/src/mesa/drivers/x11/glxapi.c +++ b/src/mesa/drivers/x11/glxapi.c @@ -1,10 +1,10 @@ -/* $Id: glxapi.c,v 1.30 2002/08/22 21:10:01 brianp Exp $ */ +/* $Id: glxapi.c,v 1.31 2002/11/18 15:11:52 brianp Exp $ */ /* * Mesa 3-D graphics library - * Version: 4.0.2 + * Version: 5.1 * - * Copyright (C) 1999-2001 Brian Paul All Rights Reserved. + * Copyright (C) 1999-2002 Brian Paul All Rights Reserved. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -988,7 +988,8 @@ Bool glXSet3DfxModeMESA(int mode) -/*** AGP memory allocation ***/ + +/*** GLX_NV_vertex_array_range ***/ void * glXAllocateMemoryNV( GLsizei size, @@ -1017,6 +1018,19 @@ glXFreeMemoryNV( GLvoid *pointer ) } +/*** GLX_MESA_agp_offset */ + +GLuint +glXGetAGPOffsetMESA( const GLvoid *pointer ) +{ + struct _glxapi_table *t; + Display *dpy = glXGetCurrentDisplay(); + GET_DISPATCH(dpy, t); + if (!t) + return ~0; + return (t->GetAGPOffsetMESA)(pointer); +} + /**********************************************************************/ /* GLX API management functions */ @@ -1227,10 +1241,13 @@ static struct name_address_pair GLX_functions[] = { /*** GLX_ARB_get_proc_address ***/ { "glXGetProcAddressARB", (GLvoid *) glXGetProcAddressARB }, - /*** GLX AGP memory allocation ***/ + /*** GLX_NV_vertex_array_range ***/ { "glXAllocateMemoryNV", (GLvoid *) glXAllocateMemoryNV }, { "glXFreeMemoryNV", (GLvoid *) glXFreeMemoryNV }, + /*** GLX_MESA_agp_offset ***/ + { "glXGetAGPOffsetMESA", (GLvoid *) glXGetAGPOffsetMESA }, + { NULL, NULL } /* end of list */ }; |