wined3d: Implement EvictManagedResources.
This commit is contained in:
parent
b2f09fd204
commit
0188f96dd2
|
@ -6856,14 +6856,21 @@ static HRESULT WINAPI IWineD3DDeviceImpl_TestCooperativeLevel(IWineD3DDevice*
|
||||||
return WINED3DERR_DRIVERINTERNALERROR;
|
return WINED3DERR_DRIVERINTERNALERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static HRESULT WINAPI evict_managed_resource(IWineD3DResource *resource, void *data) {
|
||||||
|
TRACE("checking resource %p for eviction\n", resource);
|
||||||
|
if(((IWineD3DResourceImpl *) resource)->resource.pool == WINED3DPOOL_MANAGED) {
|
||||||
|
TRACE("Evicting %p\n", resource);
|
||||||
|
IWineD3DResource_UnLoad(resource);
|
||||||
|
}
|
||||||
|
IWineD3DResource_Release(resource);
|
||||||
|
return S_OK;
|
||||||
|
}
|
||||||
|
|
||||||
static HRESULT WINAPI IWineD3DDeviceImpl_EvictManagedResources(IWineD3DDevice* iface) {
|
static HRESULT WINAPI IWineD3DDeviceImpl_EvictManagedResources(IWineD3DDevice* iface) {
|
||||||
IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *) iface;
|
IWineD3DDeviceImpl *This = (IWineD3DDeviceImpl *) iface;
|
||||||
/** FIXME: Resource tracking needs to be done,
|
TRACE("(%p)\n", This);
|
||||||
* The closes we can do to this is set the priorities of all managed textures low
|
|
||||||
* and then reset them.
|
IWineD3DDevice_EnumResources(iface, evict_managed_resource, NULL);
|
||||||
***********************************************************/
|
|
||||||
FIXME("(%p) : stub\n", This);
|
|
||||||
return WINED3D_OK;
|
return WINED3D_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue