Processing Ajax...

Title

Message

Confirm

Confirm

Confirm

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure you want to delete this item?

Confirm

Are you sure?

User Image
RobF
3 discussion posts
I'm using the Wallpaper slide show feature where I point displayfusion to my photographs on my local hard drive. I have thousands of photos I've taken over the years and periodically I point DF to a new directory. It seems to me that its showing the same subset of pictures from the directory without ever showing some others.

I'm curious how the images are selected. Presumably you recursively traverse the directory hierarchy looking for all of the supported image types and you make a list that you then randomly select the image to display. Can you explain how the process works?

Is there a maximum number of images that can be candidates for display?

Many thanks,
Rob.
Jul 24, 2019  • #1
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Here's how it works:

  • Builds a list of all files in the selected directory and keeps it in memory.
  • When the wallpaper changes, it chooses a new image from the list, and adds it to a local image history database so that the image won't be shown again until all other images in the directory have been shown.
  • It will remove images from the history after 7 days by default, because some folks were running into issues where they were adding images faster than they could be shown, so they only ever saw new images, never old ones. You can increase this using the "Days to Expire History Images" option in the DisplayFusion Settings > Advanced Settings window.

Hope that helps!
Jul 24, 2019  • #2
User Image
sandmann
65 discussion posts
The DF selection process works fine if you have up to a couple thousand images or so. From my informal observations I think it starts breaking down in the 4000 to 5000 image range. The reason for this is when DF selects a new image to show (assuming a random image selection, not the "in order" option), it has to look up that filename in the wallpaper history database. This is an SQL file that has to be searched every time.

If the filename is not found, it is added to the history and then displayed as your wallpaper. If it *is* in the history, then DF "randomly" selects another image, searches the history DB, and the cycle repeats until it finds a file not in the history DB.

The random file selection, and the SQL database look-ups, all take time. DF limits this process to just a few seconds, which is okay for a few thousand images, but not when you get 50,000 or 500,000. For these larger image libraries, no one at DF has been able to explain to me what DF and SQL are really doing, and the number of users with these big image libraries is too small for DF to invest the time to investigate and fix it.

Also, a point Keith glides past (unless something has changed) is that DF enumerates the directory/directories every wallpaper change. This has the advantage of making sure new images are eligible to display immediately, but sucks up lots of CPU cycles with all that is involved.

All this said, in the Advanced Settings, make sure "Ignore Sub-Folders" is NOT set (a recent DF update somehow caused this to be enabled on one of my computers). Also, set "Days to Expire History Images" to 9999. When DF does eventually cycle through all the images in your library, it will just delete the entire history and start over. Note that DF maintains separate histories for each monitor and/or monitor split.
Jul 25, 2019  • #3
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Quote:
For these larger image libraries, no one at DF has been able to explain to me what DF and SQL are really doing...


@sandmann: Thanks for providing some more context here. I'm not sure what you mean by the above quote though. We don't have any limits set on the number of files, it should work the same way regardless of how many there are.
Jul 25, 2019  • #4
User Image
sandmann
65 discussion posts
@Keith,

I was referring to a previous discussion with Jon on large image libraries.

https://www.displayfusion.com/Discussions/View/wallpaperhistoryv4db-corruptionbad-data/?ID=47ad4ed7-3fb6-49f8-9d25-0be3aa8f778a

Quote:
Thanks for the follow-up, 300k images is a huge collection for sure. It could be a timing issue where it just takes too long to look through them all, we'll have to look into that.
Jul 11, 2018 • Quote • #14


and later in the same discussion:

Quote:
Sorry, no progress on this issue yet. It's going to take some significant time to troubleshoot and rewrite the file selection code.
Aug 28, 2018 • Quote • #18


More specifically, the underlying technical question is what does SQL do when it runs out of time, does it just grab the last filename it was looking up, or something else. (One thing I have noticed is that images just added to the library seem to bubble to the top of the selection list. Just a consistent observation.)

Frankly, I don't expect DF to fix this problem because the current method works with probably 90 percent plus of your user base. And it would probably be quicker to just write a new file selection module optimized for large libraries that could be optionally used (e.g., without the directory enumeration every wallpaper change, pre-building image-to-show lists, etc.) than it would be to troubleshoot and rewrite the existing code.
Jul 25, 2019  • #5
Keith Lammers (BFS)'s profile on WallpaperFusion.com
Ah ok, thanks! I hadn't seen the end of that other thread previously. I'll follow-up with Jon and we'll definitely let you know if/when we do make some progress on that. We do appreciate the understanding on the difficulty of the issue and priorities :)
Jul 25, 2019  • #6
User Image
RobF
3 discussion posts
Thanks for the clarification on how this works guys. Its one of my favorite features in DF.
Jul 25, 2019  • #7
User Image
Rob Freyder
1 discussion post
Oops. I initially posted this on the wrong account. This is my account with the license.
Jul 25, 2019  • #8
Subscribe to this discussion topic using RSS
Was this helpful?  Login to Vote(1)  Login to Vote(-)