diff options
| author | NeoBrainX <NeoBrainX@gmail.com> | 2012-05-22 08:14:33 +0200 |
|---|---|---|
| committer | NeoBrainX <NeoBrainX@gmail.com> | 2012-05-22 08:14:49 +0200 |
| commit | 4131ca8d386eb37533eb2863214bbc76de67e389 (patch) | |
| tree | 35e15f462a9cb581fb6ccb91f948432470dbf997 /Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp | |
| parent | 1bc5f41e40e604ef6c1d1e84617c13fdf40e04d1 (diff) | |
| parent | 54aeec7a8ff6b6e5d050637b6cce8df6d9a8b633 (diff) | |
Merge branch 'hires-tex-improvements'
Diffstat (limited to 'Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp')
| -rw-r--r-- | Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp b/Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp index e59fbd496e..0e43eb013d 100644 --- a/Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp +++ b/Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp @@ -45,8 +45,16 @@ void TextureCache::TCacheEntry::Bind(unsigned int stage) D3D::context->PSSetShaderResources(stage, 1, &texture->GetSRV()); } -bool TextureCache::TCacheEntry::Save(const char filename[]) +bool TextureCache::TCacheEntry::Save(const char filename[], unsigned int level) { + // TODO: Somehow implement this (D3DX11 doesn't support dumping individual LODs) + static bool warn_once = true; + if (level && warn_once) + { + WARN_LOG(VIDEO, "Dumping individual LOD not supported by D3D11 backend!"); + warn_once = false; + return false; + } return SUCCEEDED(PD3DX11SaveTextureToFileA(D3D::context, texture->GetTex(), D3DX11_IFF_PNG, filename)); } |
