Changing the tempo of two master synced tracks causes drifting

Bug #1884324 reported by Swiftb0y
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mixxx
Fix Released
Medium
Owen Williams

Bug Description

When two tracks are playing side-by-side with both decks having master sync active, changes in tempo fader positions lag behind on the follower deck. This causes both decks to drift apart. This only happens when the quantize setting on the decks differ from each other. When the tempo fader of a quantized deck is moved, all other quantized decks don't exhibit this behavior and vice versa.
Has been tested on Linux 2.3.0-beta (build HEAD r7454) (git 2.3 branch).

Revision history for this message
Owen Williams (ywwg) wrote :

We do already have a test for ZeroLatencyRateChange but it looks like it's not good enough. checking this out.

Changed in mixxx:
assignee: nobody → Owen Williams (ywwg)
Revision history for this message
Owen Williams (ywwg) wrote :

I am unable to reproduce this bug. I created more tests with more iterations and with quantize on, off, and mixed, and the rate changes are all perfect.

Were these beatmap tracks?

https://github.com/mixxxdj/mixxx/compare/master...ywwg:more-rate-change-tests?expand=1

Revision history for this message
Swiftb0y (swiftb0y) wrote :

Not sure what you define as beatmap tracks but they were analyzed with "assume constant tempo" enabled.

Revision history for this message
Owen Williams (ywwg) wrote :

"assume constant tempo": beatgrid
that feature off: beatmap

So yeah, I am unable to reproduce this issue as you describe. Can you upload a video of it happening?

Revision history for this message
Swiftb0y (swiftb0y) wrote :

I'm attaching a quick video demonstrating the issue. I used my controller to move the rateslider but exactly the same occurs when I use the GUI sliders. Keep in mind when reproducing, this only happens when one deck has quantize active, while the other does not.
You can see in the video that the beatgrids (and the track with it) drift apart, even though they should stay in sync.

Revision history for this message
Owen Williams (ywwg) wrote :

The tracks weirdly don't look like they are in sync in the first place, which is strange. Do they stay aligned when you don't adjust the sliders?

(I did add tests and do experiments for the exact situation you describe and wasn't able to reproduce the issue)

Revision history for this message
Swiftb0y (swiftb0y) wrote :

Yes they do. They just don't look aligned in the first couple of frames because they don't start quantized which is why reenabled sync at 06s. Unfortunately, recording with OBS also introduced more jitter into the waveforms which is why they look less aligned, but you can see them drifting apart the moment I move the rate slider harshly.

I can try to run the tests on my machine and see whether they fail.

Revision history for this message
Owen Williams (ywwg) wrote :

Are you moving the slider on the deck that has quantize on, or not? What are the natural bpms of the tracks?

Revision history for this message
Swiftb0y (swiftb0y) wrote :

The deck doesn't seem to make a difference. The BPM also doesn't make a difference, its even reproducable with two tracks that have exactly the same BPM. however, what does seem to make a difference is whether keylock activated, its still noticeable without keylock, but the effect is magnitudes greater when it is active.

Revision history for this message
Owen Williams (ywwg) wrote :

go to internalclock.cpp and comment out the lines:

    if (m_bClockUpdated.fetchAndStoreRelaxed(false)) {
        return;
    }

does that fix it?

Revision history for this message
Owen Williams (ywwg) wrote :
Changed in mixxx:
importance: Undecided → Medium
milestone: none → 2.3.0
Revision history for this message
Owen Williams (ywwg) wrote :

(yes, that fixed it)

Swiftb0y (swiftb0y)
Changed in mixxx:
status: New → Fix Committed
Changed in mixxx:
status: Fix Committed → Fix Released
Revision history for this message
Swiftb0y (swiftb0y) wrote :

Mixxx now uses GitHub for bug tracking. This bug has been migrated to:
https://github.com/mixxxdj/mixxx/issues/10024

lock status: Metadata changes locked and limited to project staff
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.