deadbeef
deadbeef copied to clipboard
Swapping tracks in shuffle mode doesn't change position in internal playlist
Steps to reproduce the problem
- load an arbitrary number of tracks
- turn on shuffle
- manually select a track, then skip forward
What's going on? Describe the problem in as much detail as possible.
Expected behavior: In a list of songs 1-4 shuffled to 1432, while song 1 is playing, selecting 3, then hitting next track should play 2 Actual behavior: In the aforementioned example, skipping from 1 to 3, then hitting next track plays 4
Information about the software:
Deadbeef version: 1.8.2 OS: Fedora 31
To play the songs one after the other you have to activate Shuffle → Off, then the song below the current played is always selected if available or from top of the playlist.
I'm trying to skip around in the shuffled list, not the unshuffled list. I know the desired effect can be achieved by swapping to the new song, then turning shuffle off and back on again, but that's a workaround to an issue that I feel shouldn't exist in the first place.
No, this is not a workaround, this is deliberate. With Shuffle you set the order in which the songs should be played. The behaviour is identical to foobar2000 and applies to all playlists:
- Off → Songs will be played in order of appearence
- Tracks → Creates an internal randomized list of tracks in your playlist and play tracks according to their order in that list, so you don't get repetitions until all tracks in your playlist have been played.
- Random → Random mode picks tracks randomly, without special measures to prevent track repetitions other than a simple check to prevent the same track from playing twice in a row.
- Albums → Plays whole albums randomly
Track selection in UI doesn't do anything to shuffle. It sounds like everything is working by design.
The behaviour is identical to foobar2000 and applies to all playlists:
The issue is that it doesn't behave the same. Deadbeef behavior versus foobar behavior
@LisandraBrave ok so what you're saying is that what deadbeef considers correct doesn't match foobar behavior. I wasn't aware that foobar skips tracks in shuffle queue via UI selection. Will need to try this out.
I read the problem description a few times more, and now I understand what the problem is. The behavior in deadbeef is by design indeed. It's not exactly as described though.
If a track is manually activated, the shuffle queue is rebuilt -- which means the previous shuffle order is lost. Then, if it's "shuffle tracks" -- it simply puts the selected track to the front of the queue. In "shuffle albums" mode, the behavior is different, but probably still not the same as fb2k - it was never intended to replicate fb2k behavior in this feature.
I need to think a bit more about this. I will consider changing this behavior, especially since the code is now in a fairly clean state. But I won't do this for the upcoming release, since this is still a bit too risky to do at this stage.
Changed to Enhancement, since implementing such behavior would not need to change the existing logic -- but rather to add a special case on what happens when the user manually triggers next track. This needs careful thinking, and some design. If anyone decides to implement this -- please get in touch with me first to coordinate.