mvysny / photocloud-frame-slideshow

Android Digital Photo Frame
https://www.android-photo-frame.eu
14 stars 1 forks source link

Randomization is bad #168

Closed Spulifan closed 1 year ago

Spulifan commented 2 years ago

I have Google Drive with many subfolders and I want the slideshow to shuffle through all of the images within those folders. Right now the app just picks random folder from root directory and then selects a few random folders from that folder. It should pick the next image from a new random folder every time so the image sequence is truly random.

mvysny commented 2 years ago

PhotoCloud's main goal is to display first image as soon as possible. Since the images are expected to be nested deep within the directory structure, PhotoCloud performs a depth-first search - it will try to enter folders as soon as possible, to discover the first image. After the first image is displayed, PhotoCloud will continue to crawl through folders in random order, finding more images and showing them one-by-one. Newly found images are stored to a small database and randomized, so after a while the stream of images should be quite randomized.

That means that the randomization is performed on multiple levels.

This also guarantees that all images are shown eventually. If that's not the case, please let me know.