Fanart not caching in beta 1
#61
jmarshall Wrote:All: Add this:

<sleepbeforeflip>0.9</sleepbeforeflip>

to advancedsettings.xml. That is the ONLY change that could have affected things from Alpha2 to Beta1.

Cheers,
Jonathan

Problem is still there in RC1 !!

I also tried the settings from jmarshall and it solved the problem partly. It's much better now but XBMC 9.04 is still faster in thumbnails scrolling (libary mode).
Reply
#62
It's not faster at all in 9.04. Indeed, the scrolling will be much slower as it's FORCED to load the thumbs in the same thread.

Now the scrolling is nice and smooth at the small sacrifice of waiting a little bit for the thumbs to load once you've stopped.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#63
I have a similar issue on a new laptop which I was using to do some skin development work on. The thumbs and fanart backgrounds take an AGE to display. CPU usage sits around 100% almost all the time.

I switched to the Confluence skin and updated the settings (as proposed by JM above) and they made a slight difference but it can still take a minute or more to display a background image when using the Fanart view for Movies.

If you need any more debug logs or any other info please let me know. (I'm currently using Beta 2 on Windows Vista but am going to be upgrading to RC1 very soon)
Follow development of MediaStream, MiniMeedia and other skins on Twitter (@skunkm0nkee)
Reply
#64
With RC1 my posters and fanart come up much quicker than they did with Beta 2.

Thanks for the fix.......
Reply
#65
while the "<sleepbeforeflip>0.9</sleepbeforeflip>" toggle does lower the cpu usage in the gui, playing video is jerky.

Is there another fix, I've tried everything in this thread but still have the high cpu issue.

P.S.
XBMC Live 9.04 didn't have this issue. (tested on multiple machines)
Athlon 3500+ (Nvidia 8400GS) 2GB Ram, Pentium 4 2.8 Ghz (Nvidia G210) 2GB Ram, Pentuim 4 3.0 Ghz (Nvidia 9600GT) 2GB Ram

Also, running live version 9.11 repack with no cpu/cover caching issues on any of the listed machines.
Reply
#66
Is it possible to have the <sleepbeforeflip></sleepbeforeflip> option only set while navigating the gui and off while watching videos?
Reply
#67
Marbieskarb Wrote:Is it possible to have the <sleepbeforeflip></sleepbeforeflip> option only set while navigating the gui and off while watching videos?


Maybe try to change the sleep before flip to .85 instead of .9.

.9 may be too high.
Reply
#68
Thanks for the suggestions!
Unfortunately, the problem still persists for me. Also, sleepbeforeflip doesn't affect the OpenGL build which is the only one that runs smoothly on my configuration.
Reply
#69
Mirt, mind posting the full debug log of that session showing the fanart problems?
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#70
dtviewer Wrote:Maybe try to change the sleep before flip to .85 instead of .9.

.9 may be too high.

Tried all variations and still the same issue. I was just wondering if it could be used only while browsing the GUI and not playing video
Reply
#71
Marbieskarb Wrote:Tried all variations and still the same issue. I was just wondering if it could be used only while browsing the GUI and not playing video

One more thing to check is what is your cpu usage with the setting for fake fullscreen enabled and then disabled.

Try both and see if it makes a difference either way.
Reply
#72
vdrfan Wrote:Mirt, mind posting the full debug log of that session showing the fanart problems?

Same to you Marbieskarb
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#73
vdrfan Wrote:Mirt, mind posting the full debug log of that session showing the fanart problems?

Here you go. I highlighted the lines where loading images took a long time. As you can see it is not the most recent rev but currently the OGL build is broken.

What I did:
  1. Startup XBMC with standard Confluence skin with no additional background scripts.
  2. Hover over "Music" until the background image loads
  3. Hover over "Movies" until the background image loads
  4. Go into TV Series, select a series and then hovered over a Season for a while, waiting for the picture to load, but it didn't
  5. Go back to main menu
  6. Go into "Movies" -> "Movies"
  7. Hover over first movie, waiting for fanart to load
  8. Hover over second movie, waiting for fanart to load
  9. Quit XBMC

Thanks in advance.

Edit: Also, if I browse through my movies and then immediatly try to quit XBMC, some minutes pass before it eventually quits. I guess the application waits for the imageload-threads to finish (it can be inferred from the log, I think).

Edit2: Here is the same log again. But here I highlighted all the log entries coming from the image loading threads. I guess that the thread priotities have to be changed a little bit for efficient single-core usage.
Reply
#74
Ok, I did some digging. The root of the problem obviously is the 100% CPU usage all the time.

CImageLoader loads all the big images (menu backgrounds, fanart, ...). It is derived from CJob and run by a CJobWorker. Now, the thread priority of a CJobWorker is always set to the lowest possible value, i.e. with high CPU usage CImageLoader hardly gets any CPU time. So increasing thread priority for CImageLoader:: DoWork would solve the problem? To prove that I did a small hackfix for Windows (diff file):

Code:
Index: GUILargeTextureManager.cpp
===================================================================
--- GUILargeTextureManager.cpp    (Revision 26904)
+++ GUILargeTextureManager.cpp    (Arbeitskopie)
@@ -52,6 +52,12 @@
bool CImageLoader::DoWork()
{
   CFileItem file(m_path, false);
+
+  HANDLE hThread = GetCurrentThread();
+  int iPriority = GetThreadPriority( hThread );
+
+  SetThreadPriority( hThread, THREAD_PRIORITY_HIGHEST );
+
   if (file.IsPicture() && !(file.IsZIP() || file.IsRAR() || file.IsCBR() || file.IsCBZ())) // ignore non-pictures
   { // check for filename only (i.e. lookup in skin/media/)
     CStdString loadPath(m_path);
@@ -81,6 +87,8 @@
       CLog::Log(LOGDEBUG, "%s - took %d ms to load %s", __FUNCTION__, CTimeUtils::GetTimeMS() - start, m_path.c_str());
   }

+  SetThreadPriority( hThread, iPriority );
+
   return true;
}

With these 4 Lines of code added the images load quickly without delay again! I'm quite happy with it now. Note: THREAD_PRIORITY_ABOVE_NORMAL wasn't enough. I had to use THREAD_PRIORITY_HIGHEST.

A proper fix could be to add a thread priority attribute to CJob or solving the 100% CPU usage issue. I suspect that the latter could be a problem with graphics drivers in combination with OpenGL (VSync doesn't work).
Reply
#75
If you add <sleepbeforeflip>0.85</sleepbeforeflip> to your windows XP single-core computer advancedsettings.xml file, then you don't need to mess with thread priorities.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply

Logout Mark Read Team Forum Stats Members Help
Fanart not caching in beta 10