"Create all thumbnails at once" not working for Branch View?

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
Megalith
Posts: 87
Joined: 24 Jan 2015 16:53

"Create all thumbnails at once" not working for Branch View?

Post by Megalith »

Is this deliberate behavior or a bug? in branch view, you have to scroll through all images in order to create the thumbnails.

highend
Posts: 14994
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: "Create all thumbnails at once" not working for Branch V

Post by highend »

In the second when I switch from details view (branch view is already activated) to thumbnail view, all thumbnails for all pictures from all branch view folders are generated automatically...

Tested with v16.20.0100 (official) + latest beta, both fresh portable versions...
One of my scripts helped you out? Please donate via Paypal

Megalith
Posts: 87
Joined: 24 Jan 2015 16:53

Re: "Create all thumbnails at once" not working for Branch V

Post by Megalith »

Can anyone else confirm that this is working? I don't see why it wouldn't be working on my installation; I am also running the latest official version.

highend
Posts: 14994
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: "Create all thumbnails at once" not working for Branch V

Post by highend »

You did try "::fresh;" and used that version to make sure it's not your installation?
One of my scripts helped you out? Please donate via Paypal

Papoulka
Posts: 455
Joined: 13 Jul 2013 23:41

Re: "Create all thumbnails at once" not working for Branch V

Post by Papoulka »

I work with folders of 100+ images on a USB3 external drive. I view the combined thumbnails from a dozen such folders in a search window. There, I have to scroll through every line of the thumbs manually, using the up & down arrow keys, to get the thumbs created. This must be done slowly or some will be skipped. Scrolling with the drag bar makes the process go nuts. "Create all at once" never works for this.

TheQwerty
Posts: 4373
Joined: 03 Aug 2007 22:30

Re: "Create all thumbnails at once" not working for Branch V

Post by TheQwerty »

Here it's working as documented:
Help wrote:Create all thumbnails at once

Check it to have all thumbnails in the current list created at once (not just the ones that are currently visible in the viewport). Enabling this option is only advisable if also "Cache thumbnails on disk" is enabled because then the work will have to be done only once. Otherwise browsing large image folders will become slow again and again.

Note that even with "Cache thumbnails on disk" enabled this new setting makes browsing a bit slower on fully cached folders. So, if all or most of your folders are already fully cached, you can (very) slightly increase speed by disabling "Create all thumbnails at once".

Note that this setting is ignored in Find mode (Search Results and Branch View) for performance reasons.

Tip 1: The context menu of the Toolbar buttons related to list views features a command Create All Thumbnails Now. Here you can have all thumbnails in the current list created for this list, without having the global Create all thumbnails at once enabled in Configuration | Thumbnails.

Tip 2: The same context menu also features the commands Refresh Selected Thumbnails (High Speed), Refresh Selected Thumbnails (Fast), Refresh Selected Thumbnails (Crisp), and Refresh Selected Thumbnails (Smooth).
::help 'idh_settings.htm#idh_settingsthumbs';

Unfortunately, the documentation also seems out of date as the Create All Thumbnails Now command mentioned in tip 1 seems to have been removed in v14.80.0012. (I cannot find any mention in history of this though.)


For me it only generates a screen full of thumbnails at a time in search results/branch view.
However, selecting all (Ctrl+A) and selecting any of the Refresh Selected Thumbnails... commands from tip 2 will generate all thumbnails including those not presently visible.

Papoulka
Posts: 455
Joined: 13 Jul 2013 23:41

Re: "Create all thumbnails at once" not working for Branch V

Post by Papoulka »

However, selecting all (Ctrl+A) and selecting any of the Refresh Selected Thumbnails... commands from tip 2 will generate all thumbnails including those not presently visible.
Is there any way to do this via scripting?

TheQwerty
Posts: 4373
Joined: 03 Aug 2007 22:30

Re: "Create all thumbnails at once" not working for Branch V

Post by TheQwerty »

Papoulka wrote:
However, selecting all (Ctrl+A) and selecting any of the Refresh Selected Thumbnails... commands from tip 2 will generate all thumbnails including those not presently visible.
Is there any way to do this via scripting?
This should...

Code: Select all

sel 'a';#506; /* View | Caches | Refresh Selected Thumbnails */

Papoulka
Posts: 455
Joined: 13 Jul 2013 23:41

Re: "Create all thumbnails at once" not working for Branch V

Post by Papoulka »

Thanks; not seeing a command number on the List views toolbar button context menu I assumed there wasn't one.

Megalith
Posts: 87
Joined: 24 Jan 2015 16:53

Re: "Create all thumbnails at once" not working for Branch V

Post by Megalith »

Thanks, all. That script works great.

But here's another potential oddity with Branch View. Is it just me, or are thumbnails not being cached in this view (or, at least, not consistently)? When I exit branch view and check the folders individually, it seems that some folders still go through the process of creating thumbnails. I do have "Include search results" checked under options.

TheQwerty
Posts: 4373
Joined: 03 Aug 2007 22:30

Re: "Create all thumbnails at once" not working for Branch V

Post by TheQwerty »

Megalith wrote:Is it just me, or are thumbnails not being cached in this view (or, at least, not consistently)? When I exit branch view and check the folders individually, it seems that some folders still go through the process of creating thumbnails. I do have "Include search results" checked under options.
It's not just you, I believe this was a conscious choice for performance, but Don would have to chime in to make that anything but a wild-guess by me.

I believe what happens is...
When XY creates thumbs it caches them in some files, one of those files is XYThumbs.txt, which contains a table correlating the path & thumb size to a hash which is the name of the corresponding cache files.

Say you are browsing the path 'C:\My\Images' when XY caches the thumbs it adds a table entry like so:
C:\My\Images\|300x128|ea4cbf0d194d82de33985d11c946c710fc34d019
And creates two cache files:
ea4cbf0d194d82de33985d11c946c710fc34d019.dat2
ea4cbf0d194d82de33985d11c946c710fc34d019.dbits

When you revisit 'C:\My\Images' XY knows that any images it has cached are in those files.

However, when it comes to caching search results or branch view XY appends an '*' to the end of the path and calculates a different hash, making it:
C:\My\Images\*|300x128|0bbfbb0461351940b275dd03bda24015

Presumably, this is because the cache data might be for items in 'C:\My\Images' or for items in 'C:\My\Images\Of\My\Favorite\Taco\Trucks' and for performance reasons when revisiting this search or branch view it is better to load one set of cache files rather than the files corresponding to all of these locations and any other descendants of 'C:\My\Images'.
'C:\My\Images'
'C:\My\Images\Of'
'C:\My\Images\Of\My'
'C:\My\Images\Of\My\Favorite'
'C:\My\Images\Of\My\Favorite\Taco'
'C:\My\Images\Of\My\Favorite\Taco\Trucks'

It's unfortunate, but I also think it is something Don has given much thought to and would improve if he felt it worthwhile. It could be that given the quickness with which XY can generate most thumbnails that there isn't much more that can be squeezed out of the caching process or that the possible improvements are not yet worth the effort/time.

klownboy
Posts: 4468
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.8737 at 100% 2560x1440

Re: "Create all thumbnails at once" not working for Branch V

Post by klownboy »

TheQwerty wrote:However, when it comes to caching search results or branch view XY appends an '*' to the end of the path and calculates a different hash
Do you actually see any asterisks in the thumbs.txt file? I ask because all thumbnailed folders whether they are normal or branch view get the hash value of the folder and thumbnail size in the format with the asterisk between folder and thumbnail size: "H:\Pictures\The Channels\*240x240". You can see that in the raw view of the dat2 file. The associated line in the thumbs.txt file looks like this: H:\Pictures\The Channels\|240x240|22fb588954f6a1c095e1d34bef23c031 pipe separated with no asterisk. The md5 hash of "H:\Pictures\The Channels\*240x240" is: 22fb588954f6a1c095e1d34bef23c031 which is the cache files' (dat2 and dbits) base name. I don't use branch view so I'm guessing, but it's probably the fact that as the user traverses the branch he's encountering the different folders whose associated thumbnail caches are contained in different cache files which slows down the process. A slow process when generating thumbs.

TheQwerty
Posts: 4373
Joined: 03 Aug 2007 22:30

Re: "Create all thumbnails at once" not working for Branch V

Post by TheQwerty »

The asterisk is added...
XYThumbs.txt wrote:XYplorer Thumbs Index v1
2016-01-28 15:25:03


C:\Zen\Dropbox\Screenshots\*|675x675|eed7d639e595def204abcb79f1377c61
C:\Zen\Dropbox\Screenshots\|675x675|0bbfbb0461351940b275dd03bda24015

klownboy
Posts: 4468
Joined: 28 Feb 2012 19:27
Location: Windows 11, 25H2 Build 26200.8737 at 100% 2560x1440

Re: "Create all thumbnails at once" not working for Branch V

Post by klownboy »

Well I'm still learning this program. What you say is true with one explanation. It's only true if in Configuration | Cache Thumbnails on disk, you have "Include search results" checked off. If you don't, as I didn't, you'll only see the separate caches for each folder no matter how many times you go into and out of branch view. I was wondering what was going on, since I had tried it over and over before I had posted. I didn't get the extra asterisk in the dat2 file or the single asterisk in the thumbs.txt file. Obviously the search results are tied in with branch view regarding that setting (and most settings).

This explanation though may account for why some are getting different results in viewing thumbnails in branch view. Don, it might be worthwhile to actually expand on that particular setting to say "Include Branch view and search results". I hadn't used branch view much if at all, so I can see if a user is looking for settings which may affect branch view that surely is one and they might miss it with the current wording.

Thanks TheQwerty.

Post Reply