diff options
author | jmarshallnz <jmarshallnz@svn> | 2009-12-20 21:40:16 +0000 |
---|---|---|
committer | jmarshallnz <jmarshallnz@svn> | 2009-12-20 21:40:16 +0000 |
commit | 1fa3494a2ed03b5897fc27c961a003f14befaa0e (patch) | |
tree | 730a5851519cdc68b88dcacfd9316dd8eefbbb1d | |
parent | d777983986ee96d55386f3fd7fa1204cf8e0898f (diff) |
merged: r25753,r25754 from Camelot branch - useful logging changes.
git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/trunk@25896 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
-rw-r--r-- | xbmc/GUILargeTextureManager.cpp | 4 | ||||
-rw-r--r-- | xbmc/RenderSystemDX.cpp | 4 |
2 files changed, 7 insertions, 1 deletions
diff --git a/xbmc/GUILargeTextureManager.cpp b/xbmc/GUILargeTextureManager.cpp index f7b3559864..3b1d1b9e94 100644 --- a/xbmc/GUILargeTextureManager.cpp +++ b/xbmc/GUILargeTextureManager.cpp @@ -31,6 +31,7 @@ #include "Settings.h" #include "AdvancedSettings.h" #include "Util.h" +#include "utils/log.h" using namespace std; @@ -70,11 +71,14 @@ bool CImageLoader::DoWork() } } m_texture = new CTexture(); + DWORD start = CTimeUtils::GetTimeMS(); if (!m_texture->LoadFromFile(loadPath, min(g_graphicsContext.GetWidth(), 2048), min(g_graphicsContext.GetHeight(), 1080), g_guiSettings.GetBool("pictures.useexifrotation"))) { delete m_texture; m_texture = NULL; } + else + CLog::Log(LOGDEBUG, "%s - took %d ms to load %s", __FUNCTION__, CTimeUtils::GetTimeMS() - start, m_path.c_str()); } return true; diff --git a/xbmc/RenderSystemDX.cpp b/xbmc/RenderSystemDX.cpp index c31737e848..442724639e 100644 --- a/xbmc/RenderSystemDX.cpp +++ b/xbmc/RenderSystemDX.cpp @@ -387,6 +387,7 @@ bool CRenderSystemDX::BeginRender() if (!m_bRenderCreated) return false; + DWORD oldStatus = m_nDeviceStatus; if( FAILED( m_nDeviceStatus = m_pD3DDevice->TestCooperativeLevel() ) ) { // The device has been lost but cannot be reset at this time. @@ -394,7 +395,8 @@ bool CRenderSystemDX::BeginRender() // and try again at a later time. if( m_nDeviceStatus == D3DERR_DEVICELOST ) { - CLog::Log(LOGDEBUG, "D3DERR_DEVICELOST"); + if (m_nDeviceStatus != oldStatus) + CLog::Log(LOGDEBUG, "D3DERR_DEVICELOST"); OnDeviceLost(); return false; } |