Henri Verbeet : wined3d: Return the activated context from ActivateContext( ).
Alexandre Julliard
julliard at winehq.org
Thu Jul 23 09:59:48 CDT 2009
Module: wine
Branch: master
Commit: ea2caa9ba190bd3aae91d85ee4f949e3382e5d9d
URL: http://source.winehq.org/git/wine.git/?a=commit;h=ea2caa9ba190bd3aae91d85ee4f949e3382e5d9d
Author: Henri Verbeet <hverbeet at codeweavers.com>
Date: Thu Jul 23 10:54:36 2009 +0200
wined3d: Return the activated context from ActivateContext().
---
dlls/wined3d/context.c | 5 ++++-
dlls/wined3d/wined3d_private.h | 2 +-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c
index 1d25afc..5afbda7 100644
--- a/dlls/wined3d/context.c
+++ b/dlls/wined3d/context.c
@@ -1794,7 +1794,8 @@ static void context_apply_draw_buffer(struct WineD3DContext *context, BOOL blit)
* usage: Prepares the context for blitting, drawing or other actions
*
*****************************************************************************/
-void ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, ContextUsage usage) {
+struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, enum ContextUsage usage)
+{
struct WineD3DContext *current_context = context_get_current();
DWORD tid = GetCurrentThreadId();
DWORD i, dirtyState, idx;
@@ -1929,4 +1930,6 @@ void ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, ContextU
default:
FIXME("Unexpected context usage requested\n");
}
+
+ return context;
}
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
index a28878e..bb64875 100644
--- a/dlls/wined3d/wined3d_private.h
+++ b/dlls/wined3d/wined3d_private.h
@@ -1262,7 +1262,7 @@ typedef enum ContextUsage {
CTXUSAGE_CLEAR = 4, /* Drawable and states are set up for clearing */
} ContextUsage;
-void ActivateContext(IWineD3DDeviceImpl *device, IWineD3DSurface *target, ContextUsage usage);
+struct WineD3DContext *ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, enum ContextUsage usage);
WineD3DContext *CreateContext(IWineD3DDeviceImpl *This, IWineD3DSurfaceImpl *target, HWND win, BOOL create_pbuffer, const WINED3DPRESENT_PARAMETERS *pPresentParms);
void DestroyContext(IWineD3DDeviceImpl *This, WineD3DContext *context);
void context_resource_released(IWineD3DDevice *iface, IWineD3DResource *resource, WINED3DRESOURCETYPE type);
More information about the wine-cvs
mailing list