From d35b888b6cb263cb31c90946ac4b3340c94ff3e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20D=C3=B6singer?= Date: Sat, 28 Nov 2009 18:11:17 +0100 Subject: [PATCH 04/18] WineD3D: Add GL_APPLE_flush_buffer_range --- dlls/wined3d/directx.c | 1 + dlls/wined3d/wined3d_gl.h | 16 +++++++++++++++- 2 files changed, 16 insertions(+), 1 deletions(-) diff --git a/dlls/wined3d/directx.c b/dlls/wined3d/directx.c index f9bc752..d088fa9 100644 --- a/dlls/wined3d/directx.c +++ b/dlls/wined3d/directx.c @@ -46,6 +46,7 @@ static const struct { {"GL_APPLE_flush_render", APPLE_FLUSH_RENDER, 0 }, {"GL_APPLE_ycbcr_422", APPLE_YCBCR_422, 0 }, {"GL_APPLE_float_pixels", APPLE_FLOAT_PIXELS, 0 }, + {"GL_APPLE_flush_buffer_range", APPLE_FLUSH_BUFFER_RANGE, 0 }, /* ATI */ {"GL_ATI_separate_stencil", ATI_SEPARATE_STENCIL, 0 }, diff --git a/dlls/wined3d/wined3d_gl.h b/dlls/wined3d/wined3d_gl.h index 4eb57d2..8bd8857 100644 --- a/dlls/wined3d/wined3d_gl.h +++ b/dlls/wined3d/wined3d_gl.h @@ -3261,6 +3261,15 @@ typedef void (WINE_GLAPI *PGLFNSETFRAGMENTSHADERCONSTANTATI) (GLuint dst, const #define GL_MAX_PROGRAM_CALL_DEPTH_NV 0x88F5 #endif +/* GL_APPLE_flush_buffer_range */ +#ifndef GL_APPLE_flush_buffer_range +#define GL_APPLE_flush_buffer_range +#define GL_BUFFER_SERIALIZED_MODIFY_APPLE 0x8A12 +#define GL_BUFFER_FLUSHING_UNMAP_APPLE 0x8A13 +typedef void (WINE_GLAPI *PGLBUFFERPARAMETERIAPPLE) (GLenum target, GLenum pname, GLint param); +typedef void (WINE_GLAPI *PGLFLUSHMAPPEDBUFFERRANGEAPPLE) (GLenum target, ptrdiff_t offset, ptrdiff_t size); +#endif + /* GL_VERSION_2_0 */ #ifndef GL_VERSION_2_0 #define GL_VERSION_2_0 1 @@ -3570,6 +3579,7 @@ typedef enum _GL_SupportedExt { APPLE_FLUSH_RENDER, APPLE_YCBCR_422, APPLE_FLOAT_PIXELS, + APPLE_FLUSH_BUFFER_RANGE, /* SGI */ SGI_VIDEO_SYNC, SGIS_GENERATE_MIPMAP, @@ -3918,7 +3928,11 @@ typedef enum _GL_SupportedExt { USE_GL_FUNC(PGLFNALPHAFRAGMENTOP1ATI, glAlphaFragmentOp1ATI, ATI_FRAGMENT_SHADER, NULL )\ USE_GL_FUNC(PGLFNALPHAFRAGMENTOP2ATI, glAlphaFragmentOp2ATI, ATI_FRAGMENT_SHADER, NULL )\ USE_GL_FUNC(PGLFNALPHAFRAGMENTOP3ATI, glAlphaFragmentOp3ATI, ATI_FRAGMENT_SHADER, NULL )\ - USE_GL_FUNC(PGLFNSETFRAGMENTSHADERCONSTANTATI, glSetFragmentShaderConstantATI, ATI_FRAGMENT_SHADER, NULL ) + USE_GL_FUNC(PGLFNSETFRAGMENTSHADERCONSTANTATI, glSetFragmentShaderConstantATI, ATI_FRAGMENT_SHADER, NULL )\ + /* GL_APPLE_flush_buffer_range */ \ + USE_GL_FUNC(PGLBUFFERPARAMETERIAPPLE, glBufferParameteriAPPLE, APPLE_FLUSH_BUFFER_RANGE,NULL)\ + USE_GL_FUNC(PGLFLUSHMAPPEDBUFFERRANGEAPPLE, glFlushMappedBufferRangeAPPLE, APPLE_FLUSH_BUFFER_RANGE,NULL) + /**************************************************** * OpenGL WGL defines and functions pointer -- 1.6.4.4