From 0ccd9d1e8fd880d56fccfde191edc5742d11a5c5 Mon Sep 17 00:00:00 2001 From: death2droid Date: Fri, 4 Sep 2009 13:46:04 +0000 Subject: [PATCH] DiscIO:Fix the includes up Dolphin should now compile. D3D and OGL: A minute clean up with texture dumping git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4199 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/DiscIO/Src/FileMonitor.cpp | 8 +++++--- Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp | 7 ++++--- Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp | 5 +++-- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/Source/Core/DiscIO/Src/FileMonitor.cpp b/Source/Core/DiscIO/Src/FileMonitor.cpp index 3e0a159764..f8d24db1c0 100644 --- a/Source/Core/DiscIO/Src/FileMonitor.cpp +++ b/Source/Core/DiscIO/Src/FileMonitor.cpp @@ -19,18 +19,20 @@ ///////////////////////////////////////////////////////////////////////////////////////////////// // Include // ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ +#include "stdafx.h" #include #include #include #include + #include "Common.h" // Common #include "IniFile.h" #include "LogManager.h" -#include "ConfigManager.h" -#include "../../DiscIO/Src/FileSystemGCWii.h" -#include "../../DiscIO/Src/VolumeCreator.h" +#include "..\..\core\src\ConfigManager.h" +#include "FileSystemGCWii.h" +#include "VolumeCreator.h" ///////////////////////////////////////////////////////////////////////////////////////////////// diff --git a/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp b/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp index c4f68add5a..7d613a009f 100644 --- a/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp +++ b/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp @@ -234,9 +234,10 @@ TextureCache::TCacheEntry *TextureCache::Load(int stage, u32 address, int width, char szTemp[MAX_PATH]; char szDir[MAX_PATH]; - + const char* uniqueId = ((struct SConfig *)globals->config)->m_LocalCoreStartupParameter.GetUniqueID().c_str(); bool bCheckedDumpDir = false; - sprintf(szDir,"%s/%s",FULL_DUMP_TEXTURES_DIR,((struct SConfig *)globals->config)->m_LocalCoreStartupParameter.GetUniqueID().c_str()); + + sprintf(szDir,"%s/%s",FULL_DUMP_TEXTURES_DIR,uniqueId); if(!bCheckedDumpDir) { @@ -246,7 +247,7 @@ TextureCache::TCacheEntry *TextureCache::Load(int stage, u32 address, int width, bCheckedDumpDir = true; } - sprintf(szTemp, "%s/%s_%08x_%i.png",szDir, ((struct SConfig *)globals->config)->m_LocalCoreStartupParameter.GetUniqueID().c_str(), tex_hash, format); + sprintf(szTemp, "%s/%s_%08x_%i.png",szDir, uniqueId, tex_hash, format); //sprintf(szTemp, "%s\\txt_%04i_%i.png", g_Config.texDumpPath.c_str(), counter++, format); <-- Old method if (!File::Exists(szTemp)) D3DXSaveTextureToFileA(szTemp,D3DXIFF_BMP,entry.texture,0); diff --git a/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp b/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp index e166d991c4..a0378bc2a8 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp @@ -467,9 +467,10 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width char szTemp[MAX_PATH]; char szDir[MAX_PATH]; + const char* uniqueId = ((struct SConfig *)globals->config)->m_LocalCoreStartupParameter.GetUniqueID().c_str(); bool bCheckedDumpDir = false; - sprintf(szDir,"%s/%s",FULL_DUMP_TEXTURES_DIR,((struct SConfig *)globals->config)->m_LocalCoreStartupParameter.GetUniqueID().c_str()); + sprintf(szDir,"%s/%s",FULL_DUMP_TEXTURES_DIR,uniqueId); if(!bCheckedDumpDir) { @@ -479,7 +480,7 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width bCheckedDumpDir = true; } - sprintf(szTemp, "%s/%s_%08x_%i.tga",szDir, ((struct SConfig *)globals->config)->m_LocalCoreStartupParameter.GetUniqueID().c_str(), texHash, tex_format); + sprintf(szTemp, "%s/%s_%08x_%i.tga",szDir, uniqueId, texHash, tex_format); if (!File::Exists(szTemp)) { SaveTexture(szTemp, target, entry.texture, expandedWidth, expandedHeight);