Commit 6ac84072 authored by Lionel Ulmer's avatar Lionel Ulmer Committed by Alexandre Julliard

- fix bad TRACE

- fixed computation of memory used by a texture
parent 16fcd747
...@@ -652,8 +652,7 @@ GL_IDirect3DTextureImpl_2_1T_Load(LPDIRECT3DTEXTURE2 iface, ...@@ -652,8 +652,7 @@ GL_IDirect3DTextureImpl_2_1T_Load(LPDIRECT3DTEXTURE2 iface,
if (glThis->loaded == FALSE) { if (glThis->loaded == FALSE) {
/* Only check memory for not already loaded texture... */ /* Only check memory for not already loaded texture... */
mem_used = This->surface_desc.dwHeight * mem_used = This->surface_desc.dwHeight *
This->surface_desc.dwHeight * This->surface_desc.u1.lPitch;
This->surface_desc.u4.ddpfPixelFormat.u1.dwRGBBitCount;
if (This->ddraw_owner->allocate_memory(This->ddraw_owner, mem_used) < 0) { if (This->ddraw_owner->allocate_memory(This->ddraw_owner, mem_used) < 0) {
TRACE(" out of virtual memory... Warning application.\n"); TRACE(" out of virtual memory... Warning application.\n");
return D3DERR_TEXTURE_LOAD_FAILED; return D3DERR_TEXTURE_LOAD_FAILED;
......
...@@ -1115,7 +1115,7 @@ Main_DirectDraw_GetAvailableVidMem(LPDIRECTDRAW7 iface, LPDDSCAPS2 ddscaps, ...@@ -1115,7 +1115,7 @@ Main_DirectDraw_GetAvailableVidMem(LPDIRECTDRAW7 iface, LPDDSCAPS2 ddscaps,
if (TRACE_ON(ddraw)) { if (TRACE_ON(ddraw)) {
TRACE(" Asking for memory of type : \n"); TRACE(" Asking for memory of type : \n");
DDRAW_dump_DDSCAPS2(ddscaps); DDRAW_dump_DDSCAPS2(ddscaps); DPRINTF("\n");
} }
/* We have 16 MB videomemory */ /* We have 16 MB videomemory */
......
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