Index: xbmc/cores/dvdplayer/DVDFileInfo.cpp =================================================================== --- xbmc/cores/dvdplayer/DVDFileInfo.cpp (revision 32980) +++ xbmc/cores/dvdplayer/DVDFileInfo.cpp (working copy) @@ -66,7 +66,7 @@ return false; } -bool CDVDFileInfo::ExtractThumb(const CStdString &strPath, const CStdString &strTarget, CStreamDetails *pStreamDetails) +bool CDVDFileInfo::ExtractThumb(const CStdString &strPath, const CStdString &strTarget/*, CStreamDetails *pStreamDetails*/) { int nTime = timeGetTime(); CDVDInputStream *pInputStream = CDVDFactoryInputStream::CreateInputStream(NULL, strPath, ""); @@ -112,8 +112,8 @@ return false; } - if (pStreamDetails) - DemuxerToStreamDetails(pDemuxer, *pStreamDetails, strPath); + // if (pStreamDetails) + // DemuxerToStreamDetails(pDemuxer, *pStreamDetails, strPath); CDemuxStream* pStream = NULL; int nVideoStream = -1; Index: xbmc/cores/dvdplayer/DVDFileInfo.h =================================================================== --- xbmc/cores/dvdplayer/DVDFileInfo.h (revision 32980) +++ xbmc/cores/dvdplayer/DVDFileInfo.h (working copy) @@ -29,7 +29,7 @@ { public: // Extract a thumbnail immage from the media at strPath an image file in strTarget, optionally populating a streamdetails class with the data - static bool ExtractThumb(const CStdString &strPath, const CStdString &strTarget, CStreamDetails *pStreamDetails); + static bool ExtractThumb(const CStdString &strPath, const CStdString &strTarget /*, CStreamDetails *pStreamDetails*/); // GetFileMetaData will fill pItem's properties according to what can be extracted from the file. static void GetFileMetaData(const CStdString &strPath, CFileItem *pItem); Index: xbmc/settings/GUISettings.cpp =================================================================== --- xbmc/settings/GUISettings.cpp (revision 32980) +++ xbmc/settings/GUISettings.cpp (working copy) @@ -437,7 +437,7 @@ AddBool(0, "myvideos.treatstackasfile", 20051, true); AddBool(0, "myvideos.extractflags",20433, false); AddBool(3, "myvideos.cleanstrings", 20418, false); - AddBool(0, "myvideos.extractthumb",20433, false); + AddBool(4, "myvideos.extractthumb",20433, false); AddCategory(5, "subtitles", 287); AddString(1, "subtitles.font", 288, "Arial.ttf", SPIN_CONTROL_TEXT); Index: xbmc/ThumbLoader.cpp =================================================================== --- xbmc/ThumbLoader.cpp (revision 32980) +++ xbmc/ThumbLoader.cpp (working copy) @@ -17,7 +17,6 @@ * . * */ - #include "ThumbLoader.h" #include "Util.h" #include "URL.h" @@ -76,6 +75,7 @@ void CVideoThumbLoader::OnLoaderStart() { + } void CVideoThumbLoader::OnLoaderFinish() @@ -129,6 +129,14 @@ { CStdString strPath, strFileName; URIUtils::Split(cachedThumb, strPath, strFileName); + + if(g_guiSettings.GetBool("myvideos.extractthumb")) + { + cachedThumb = strPath + "auto-" + strFileName; + if (pItem->IsVideo() && !pItem->IsInternetStream() && !pItem->IsPlayList() && !CFile::Exists(cachedThumb)) + + CDVDFileInfo::ExtractThumb(pItem->GetPath(), cachedThumb); + } // create unique thumb for auto generated thumbs cachedThumb = strPath + "auto-" + strFileName;