0.93.1: Random slideshow shows at most ~32,000 images

Moderators: cday, XnTriq, helmut, xnview, Dreamer

Post Reply
xcq1
Posts: 2
Joined: Fri Jul 19, 2013 6:04 am

0.93.1: Random slideshow shows at most ~32,000 images

Post by xcq1 » Sat Mar 16, 2019 9:37 am

XnView: MP 0.93.1 - 64 bit
OS: Windows 10 - 64bit

When you activate the random quick slideshow feature in a folder with more than 32,000 files and watch the overlay "xyz/40000" over a long period of time, it is noticeable that all random picks occur below ~33,000. From coding experience, I would believe the actual value is 32767 from the minimal default RAND_MAX implementation.

Effect: You cannot create a random slideshow with more than ~32,000 pictures because the population space is limited and thus the images are not selected at random.

To reproduce:
1. Copy or generate more than 40,000 images in a folder
2. Settings > View > Quick slideshow: Delay: 50ms and Direction Random
3. Start slideshow
4. Closely watch the counter in the top left

Actual behaviour (bug): Counter never goes above 33,000

Expected behaviour: Counter picks each image equally likely, even if the user is insane enough to have such an amount of images.

User avatar
xnview
Author of XnView
Posts: 31737
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 0.93.1: Random slideshow shows at most ~32,000 images

Post by xnview » Mon Apr 15, 2019 1:39 pm

right...
Pierre.

User avatar
xnview
Author of XnView
Posts: 31737
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 0.93.1: Random slideshow shows at most ~32,000 images

Post by xnview » Tue Aug 27, 2019 8:50 am

See issue for current status and some details.
Pierre.

User avatar
xnview
Author of XnView
Posts: 31737
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 0.93.1: Random slideshow shows at most ~32,000 images

Post by xnview » Tue Sep 17, 2019 10:16 am

This problem is supposed to be fixed in XnView MP 0.94. Please check and confirm the bug fix here.
Pierre.

Post Reply