wined3d: Support custom pitches in wined3d_surface_update_desc.

This commit is contained in:
Stefan Dösinger 2014-01-07 22:12:12 +01:00 committed by Alexandre Julliard
parent 8d9ecf70e2
commit 70eab9d025
1 changed files with 4 additions and 1 deletions

View File

@ -2861,7 +2861,10 @@ HRESULT CDECL wined3d_surface_update_desc(struct wined3d_surface *surface,
surface->resource.format = format;
surface->resource.multisample_type = multisample_type;
surface->resource.multisample_quality = multisample_quality;
surface->resource.size = resource_size;
if (surface->pitch)
surface->resource.size = height * surface->pitch;
else
surface->resource.size = resource_size;
if (create_dib)
{