Commit 728932f2 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Don't needlessly bind the texture in PreLoad().

parent 17330c03
......@@ -123,7 +123,6 @@ static void WINAPI IWineD3DCubeTextureImpl_PreLoad(IWineD3DCubeTexture *iface) {
srgb_was_toggled = (This->baseTexture.is_srgb != srgb_mode);
This->baseTexture.is_srgb = srgb_mode;
}
IWineD3DCubeTexture_BindTexture(iface);
if (This->resource.format == WINED3DFMT_P8 || This->resource.format == WINED3DFMT_A8P8) {
for (i = 0; i < This->baseTexture.levels; i++) {
......
......@@ -114,8 +114,6 @@ static void WINAPI IWineD3DTextureImpl_PreLoad(IWineD3DTexture *iface) {
This->baseTexture.is_srgb = srgb_mode;
}
IWineD3DTexture_BindTexture(iface);
if (This->resource.format == WINED3DFMT_P8 || This->resource.format == WINED3DFMT_A8P8) {
for (i = 0; i < This->baseTexture.levels; i++) {
if(palette9_changed((IWineD3DSurfaceImpl *)This->surfaces[i])) {
......
......@@ -100,8 +100,6 @@ static void WINAPI IWineD3DVolumeTextureImpl_PreLoad(IWineD3DVolumeTexture *ifac
TRACE("(%p) : About to load texture\n", This);
IWineD3DVolumeTexture_BindTexture(iface);
if(!device->isInDraw) {
ActivateContext(device, device->lastActiveRenderTarget, CTXUSAGE_RESOURCELOAD);
} else if (GL_SUPPORT(EXT_TEXTURE_SRGB) && This->baseTexture.bindCount > 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment