Commit 5bc44955 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Add missing GL locking to d3dfmt_p8_upload_palette().

parent 2a48ef1d
......@@ -2263,7 +2263,9 @@ static void d3dfmt_p8_upload_palette(IWineD3DSurface *iface, CONVERT_TYPES conve
if(GL_SUPPORT(EXT_PALETTED_TEXTURE))
{
TRACE("Using GL_EXT_PALETTED_TEXTURE for 8-bit paletted texture support\n");
ENTER_GL();
GL_EXTCALL(glColorTableEXT(This->glDescription.target,GL_RGBA,256,GL_RGBA,GL_UNSIGNED_BYTE, table));
LEAVE_GL();
}
else
{
......@@ -2271,6 +2273,8 @@ static void d3dfmt_p8_upload_palette(IWineD3DSurface *iface, CONVERT_TYPES conve
* The 8bit pixel data will be used as an index in this palette texture to retrieve the final color. */
TRACE("Using fragment shaders for emulating 8-bit paletted texture support\n");
ENTER_GL();
/* Create the fragment program if we don't have it */
if(!device->paletteConversionShader)
{
......@@ -2310,6 +2314,8 @@ static void d3dfmt_p8_upload_palette(IWineD3DSurface *iface, CONVERT_TYPES conve
/* Rebind the texture because it isn't bound anymore */
glBindTexture(This->glDescription.target, This->glDescription.textureName);
LEAVE_GL();
}
}
......
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