--- dlls/wined3d/device.c | 12 +++--------- dlls/wined3d/indexbuffer.c | 4 +--- dlls/wined3d/surface.c | 5 ++--- 3 files changed, 6 insertions(+), 15 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 9ebce5e..30f7b61 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -4246,12 +4246,8 @@ static HRESULT WINAPI IWineD3DDeviceImpl_ProcessVertices(IWineD3DDevice *iface, ERR("Output vertex declaration not implemented yet\n"); } - /* Need any context to write to the vbo. In a non-multithreaded environment a context is there anyway, - * and this call is quite performance critical, so don't call needlessly - */ - if(This->createParms.BehaviorFlags & WINED3DCREATE_MULTITHREADED) { - ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); - } + /* Need any context to write to the vbo. */ + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); /* ProcessVertices reads from vertex buffers, which have to be assigned. DrawPrimitive and DrawPrimitiveUP * control the streamIsUP flag, thus restore it afterwards. @@ -4741,9 +4737,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_EndScene(IWineD3DDevice *iface) { return WINED3DERR_INVALIDCALL; } - if(This->createParms.BehaviorFlags & WINED3DCREATE_MULTITHREADED) { - ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); - } + ActivateContext(This, This->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); /* We only have to do this if we need to read the, swapbuffers performs a flush for us */ ENTER_GL(); glFlush(); diff --git a/dlls/wined3d/indexbuffer.c b/dlls/wined3d/indexbuffer.c index 62d90d1..bcfb0e6 100644 --- a/dlls/wined3d/indexbuffer.c +++ b/dlls/wined3d/indexbuffer.c @@ -158,9 +158,7 @@ static HRESULT WINAPI IWineD3DIndexBufferImpl_Unlock(IWineD3DIndexBuffer *iface) if(locks == 0 && This->vbo && (This->dirtyend - This->dirtystart) > 0) { IWineD3DDeviceImpl *device = This->resource.wineD3DDevice; - if(device->createParms.BehaviorFlags & WINED3DCREATE_MULTITHREADED) { - ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); - } + ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); ENTER_GL(); GL_EXTCALL(glBindBufferARB(GL_ELEMENT_ARRAY_BUFFER_ARB, This->vbo)); diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c index 489f72e..29bc21c 100644 --- a/dlls/wined3d/surface.c +++ b/dlls/wined3d/surface.c @@ -44,9 +44,8 @@ static void surface_download_data(IWineD3DSurfaceImpl *This) { return; } - if(myDevice->createParms.BehaviorFlags & WINED3DCREATE_MULTITHREADED) { - ActivateContext(myDevice, myDevice->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); - } + ActivateContext(myDevice, myDevice->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD); + if(This->Flags & SFLAG_CONVERTED) { FIXME("Read back converted textures unsupported, format=%s\n", debug_d3dformat(This->resource.format)); return;