Loud chirps when stopping playback with positive track gain

Bug #648908 reported by Sean M. Pappalardo
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Mixxx
Fix Released
Medium
RJ Skerry-Ryan
1.8
Fix Released
Medium
RJ Skerry-Ryan

Bug Description

When stopping playback by any means (play/pause button on screen or MIDI, using hot cue stutters, regular cue stutters) with the track gain above unity (positive, more noticeable 3/4 or more of the way up,) there are loud chirps, with increasing frequency as latency decreases (most noticeable at 1ms.) This happens in VE and PITS modes.

Tested on Windows x64, ASIO subsystem with integrated NVidia sound as of 1.8 branch r2632.

Changed in mixxx:
milestone: 1.8.1 → none
status: Confirmed → New
description: updated
description: updated
Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

I've ruled out any problems in the filters, pregain, clipping, volume, EngineVinylSoundEmu (not to be confused with VE) and vumeter, etc code. This is almost definitely coming out of EngineBuffer. Even if I disable the gain processing I can still hear the buzz, faintly though.

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

Weird. If you change your latency while you hear the buzzing, as latency gets lower the sound gets higher and vice-versa.

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

I fail at reading the bug description. Sorry Sean!

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

Does this happen in 1.7.x? From the looks of it, it should.

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

This is a longstanding bug in Mixxx. The rampOut code in EngineBuffer is to blame. If we rampOut, then we never clear the buffer to 0 on the next paused buffer. Therefore, the ramp period (50 samples) is a ramp from the last sample value down to 0 in 50 samples. If the buffer size is 1ms, roughly 48 samples, then this generates a sawtooth wave that is persistently played while the buffer is paused. The higher the latency, the more samples are placed in between the saw tooth blades, though each tooth itself is still 50 samples long.

Basically, this is audible when hitting 'stop' on a buffer that ended in a large sample value, because this is the starting value that is ramped-out over 50 samples.

My fix is to check that m_bLastBufferIsPaused && bCurBufferPaused at the end of EngineBuffer::process. If that condition is true, then memset the output buffer to 0. This is more work than was done before, but I don't see a good way to make sure we aren't playing some noise on paused buffer cycles.

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

By the way, to get the persistent buzzing you have to turn off EngineVinylSoundEmu, because this damps the buffer toward 0. I basically turned off everything but EngineBuffer to diagnose this.

Revision history for this message
Sean M. Pappalardo (pegasus-renegadetech) wrote :

Iiiinteresting...I didn't notice it with 1.7 or earlier revisions of 1.8. Might your fix also help bug# 513130?

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :
RJ Skerry-Ryan (rryan)
Changed in mixxx:
assignee: nobody → RJ Ryan (rryan)
Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

slipped into 1.8.0 for Windows and Ubuntu. OSX will get the fix in 1.8.1

Changed in mixxx:
status: New → 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/5540

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.