Fix invalid silence trimmer end-of-input behavior (multiple EndOfInputs)
This caused an export bug when: a) normalizing b) adding silence to end c) having more than one channel The sound was corrupted by repeating each jack frame as many times as there were channels.
This commit is contained in:
parent
f2300164d7
commit
3fca030603
@ -131,6 +131,9 @@ class SilenceTrimmer
|
||||
}
|
||||
in_end = c.has_flag (ProcessContext<T>::EndOfInput);
|
||||
|
||||
// If adding to end, delay end of input propagation
|
||||
if (add_to_end) { c.remove_flag(ProcessContext<T>::EndOfInput); }
|
||||
|
||||
framecnt_t frame_index = 0;
|
||||
|
||||
if (in_beginning) {
|
||||
@ -208,6 +211,7 @@ class SilenceTrimmer
|
||||
|
||||
// Finally, if in end, add silence to end
|
||||
if (in_end && add_to_end) {
|
||||
c.set_flag (ProcessContext<T>::EndOfInput);
|
||||
|
||||
if (debug_level (DebugVerbose)) {
|
||||
debug_stream () << DebugUtils::demangled_name (*this) <<
|
||||
|
Loading…
Reference in New Issue
Block a user