View Issue Details

IDProjectCategoryView StatusLast Update
0000747OpenMPTFeature Requestpublic2016-02-05 01:03
ReporterRyan Albano Assigned To 
PrioritynormalSeverityfeatureReproducibilityhave not tried
Status closedResolutionwon't fix 
Summary0000747: Add an alternative Algorithm that controls clicks and pops without Volume Ramping
Description

As it is, the only way I know to fix 'clicks and pops' on cut/replaced notes in MPT is with the Ramp-Up/Down option. The 'ramping' is arbitrarily time-based and doesn't work well when samples get played back at very high or low pitches.
(At low playback speeds the pops don't always get stopped and on high playback speeds the samples get their attack/decay extra-blunted for no reason).

I propose a new 'smart' algorithm that cuts off a note's sound when the waveform hits a 'point of silence' (maybe the user could specify this, such as '-60dB'), instead of using an arbitrary Ramp-Down length.
It would eliminate the need for 'ramping' and would do the job well for all playback speeds.

TagsNo tags attached.
Has the bug occurred in previous versions?
Tested code revision (in case you know it)

Activities

Saga Musix

Saga Musix

2016-02-04 16:45

administrator   ~0002243

How is that supposed to work? How should the sample reach a silence level when it's never ramped down?
There are already better ways to solve this which are partly used e.g. when a sample ends on itself.

Ryan Albano

Ryan Albano

2016-02-04 23:25

reporter   ~0002245

Like I said before--use the 'points of silence'. Essentially all audio clips have them.
The algorithm just looks up incoming 'dead zones' in the clip's output--there are literally thousands of these potential points in a sample.

So you wouldn't even use the Ramp-Down--you'd just cut off the sample while its amplitude is at the dead point. This eliminates the NEED for ramping and will stop any 'pops' as well. This is a fact of audio. If there's a 'pop' at the end of a sound, one doesn't need to add a 'fade-out', they just need to cutoff the sample at a spot where the amplitude's near-zero and pops won't be heard.

You know what I mean--right?

Saga Musix

Saga Musix

2016-02-04 23:34

administrator   ~0002247

Essentially all audio clips have them.

Here lies the error - you are making assumptions about audio signals that are simply not required to be true. I can easily construct a sample that won't have any zero crossings (I guess this is what really you mean, not silence), or they will at least be so far away that the sample would be playing longer than it should. Besides, a zero-crossing is not the only requirement for a click-less sample ending. If it was that sample.

Ryan Albano

Ryan Albano

2016-02-05 00:55

reporter   ~0002251

I can't recall one time where I came across a sample with no zero-crossing.
(Except maybe a square wave? You'd never hear a pop from a cut square wave anyway.) In the extremely-unlikely event someone actually needs a sound with no zero-crossing, the feature could just be disabled.

And from all my experience with audio recording/editing--yes, a zero-crossing will do. The reason a pop occurs is because there's a difference in amplitude between the current sound and its abruptly cut state. If the sound is cut at a zero-crossing (or somewhere near-enough), there's no great difference in
amplitude to begin with, so how can a pop still occur?

I'm not saying REPLACE the ramping with this. I'm just suggesting this be added as an alternative 'pop control'. Because as far as I can tell, it will do the job better 99.9% of the time, especially with higher quality samples.

Saga Musix

Saga Musix

2016-02-05 01:03

administrator   ~0002252

I can't recall one time where I came across a sample with no zero-crossing.

So you haven't listened to modules recorded with cheap 80s or 90s digital samplers that have incredibly high DC offsets? With your method, these samples could literally go on for seconds without stopping. And even with regular samples, the delay introduced by this idea would be so unpredictable that it could lead to sample smearing.

Anyway, I've had enough of this and aleady said that there are better methods that are less arbitrary. -> Closed.

Issue History

Date Modified Username Field Change
2016-01-31 23:22 Ryan Albano New Issue
2016-01-31 23:41 Ryan Albano Description Updated
2016-02-04 16:45 Saga Musix Note Added: 0002243
2016-02-04 23:25 Ryan Albano Note Added: 0002245
2016-02-04 23:34 Saga Musix Note Added: 0002247
2016-02-04 23:35 Ryan Albano Severity minor => feature
2016-02-05 00:55 Ryan Albano Note Added: 0002251
2016-02-05 01:03 Saga Musix Note Added: 0002252
2016-02-05 01:03 Saga Musix Status new => closed
2016-02-05 01:03 Saga Musix Resolution open => won't fix