Changeset 37873 in vbox for trunk/src/VBox/Additions
- Timestamp:
- Jul 11, 2011 2:33:28 PM (14 years ago)
- svn:sync-xref-src-repo-rev:
- 72771
- Location:
- trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d/basetexture.c ¶
r35650 r37873 112 112 IWineD3DTextureImpl *This = (IWineD3DTextureImpl *)iface; 113 113 IWineD3DDeviceImpl *device = This->resource.device; 114 struct wined3d_context *context = NULL; 115 116 if (This->baseTexture.texture_rgb.name || This->baseTexture.texture_srgb.name) 117 { 118 context = context_acquire(device, NULL, CTXUSAGE_RESOURCELOAD); 119 } 120 121 if(This->baseTexture.texture_rgb.name) { 122 gltexture_delete(&This->baseTexture.texture_rgb); 123 } 124 if(This->baseTexture.texture_srgb.name) { 125 gltexture_delete(&This->baseTexture.texture_srgb); 126 } 127 128 if (context) context_release(context); 114 115 #ifdef VBOX_WITH_WDDM 116 if (VBOXSHRC_IS_SHARED_OPENED(This)) 117 { 118 This->baseTexture.texture_rgb.name = 0; 119 This->baseTexture.texture_srgb.name = 0; 120 } 121 else 122 #endif 123 { 124 struct wined3d_context *context = NULL; 125 if (This->baseTexture.texture_rgb.name || This->baseTexture.texture_srgb.name) 126 { 127 context = context_acquire(device, NULL, CTXUSAGE_RESOURCELOAD); 128 } 129 130 if(This->baseTexture.texture_rgb.name) { 131 gltexture_delete(&This->baseTexture.texture_rgb); 132 } 133 if(This->baseTexture.texture_srgb.name) { 134 gltexture_delete(&This->baseTexture.texture_srgb); 135 } 136 137 if (context) context_release(context); 138 } 129 139 130 140 This->baseTexture.texture_rgb.dirty = TRUE; -
TabularUnified trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d/device.c ¶
r35650 r37873 6268 6268 if (surface->texture_name) 6269 6269 { 6270 struct wined3d_context *context = context_acquire(device, NULL, CTXUSAGE_RESOURCELOAD); 6271 ENTER_GL(); 6272 glDeleteTextures(1, &surface->texture_name); 6273 LEAVE_GL(); 6274 context_release(context); 6270 #ifdef VBOX_WITH_WDDM 6271 # ifdef DEBUG_misha 6272 /* shared case needs testing! */ 6273 Assert(!VBOXSHRC_IS_SHARED(surface)); 6274 # endif 6275 if (!VBOXSHRC_IS_SHARED_OPENED(surface)) 6276 #endif 6277 { 6278 struct wined3d_context *context = context_acquire(device, NULL, CTXUSAGE_RESOURCELOAD); 6279 ENTER_GL(); 6280 glDeleteTextures(1, &surface->texture_name); 6281 LEAVE_GL(); 6282 context_release(context); 6283 } 6275 6284 surface->texture_name = 0; 6276 6285 surface->Flags &= ~SFLAG_CLIENT; -
TabularUnified trunk/src/VBox/Additions/WINNT/Graphics/Wine/wined3d/surface.c ¶
r37870 r37873 98 98 ENTER_GL(); 99 99 100 if (This->texture_name) 100 if (This->texture_name 101 #ifdef VBOX_WITH_WDDM 102 && !VBOXSHRC_IS_SHARED_OPENED(This) 103 #endif 104 ) 101 105 { 102 106 /* Release the OpenGL texture. */ … … 1407 1411 if(!texture) { 1408 1412 ENTER_GL(); 1409 glDeleteTextures(1, &This->texture_name); 1413 #ifdef VBOX_WITH_WDDM 1414 if (!VBOXSHRC_IS_SHARED_OPENED(This)) 1415 #endif 1416 glDeleteTextures(1, &This->texture_name); 1410 1417 This->texture_name = 0; 1411 glDeleteTextures(1, &This->texture_name_srgb); 1418 #ifdef VBOX_WITH_WDDM 1419 if (!VBOXSHRC_IS_SHARED_OPENED(This)) 1420 #endif 1421 glDeleteTextures(1, &This->texture_name_srgb); 1412 1422 This->texture_name_srgb = 0; 1413 1423 LEAVE_GL();
Note:
See TracChangeset
for help on using the changeset viewer.