Repository navigation
Elektron Tonverk: loops are written as the Tonverk loads them - #491
Open
douglas-carmichael wants to merge 2 commits into
Open
douglas-carmichael wants to merge 2 commits into
douglas-carmichael wants to merge 2 commits into
Conversation
8 of 32 converted presets showed up in the preset menu of the Tonverk but could not be loaded. Each of them has a loop which ends on the last frame of its sample or whose cross-fade is longer than the audio in front of the loop start. The loops of the factory samples always end at least one frame before the end of their sample (120 of them exactly one frame before it) and their cross-fades are always shorter than the audio in front of the loop start, which the Tonverk cross-fades the end of the loop with. After trimming, a sample whose loop ends on its last frame gets the first frame of the loop appended - the frame which follows the loop end when it plays - so the loop and the sound stay the same, and a longer cross-fade is shortened to the audio in front of the loop start; the shortening is logged. Both the preset and the multi-sample writer do this.
Shortening a cross-fade to the audio in front of the loop start makes the loops click which the source cross-fades over a jump: in 'Lush Choir' and 'Crocketts Revenge' the loops start at frame 0, so their cross-fade became 0, over a jump of 18 to 55 times the normal change between two frames. A cross-fade which does not fit now moves the loop start forward until 256 frames of the sample are left in front of the cross-fade (the factory cross-fades leave at least 198), so the cross-fade blends the end of the loop into the audio which the loop skips, like a sampler which cross-fades into the start of the loop. A cross-fade which covers most of the loop is limited to half of the remaining loop (the factory cross-fades are at most 71.5% of their loop). The start of a single-cycle loop is not moved, since its length is its pitch; its cross-fade is shortened instead. Every changed loop is logged.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With the category and tags of #490, Michael Oakley's 32 TAL-Sampler presets converted to Tonverk presets show up in the preset menu of the Tonverk, but 8 of them cannot be loaded: The Call Of Africa, Prophet Voices, Power Brass, PPG Power Keys, Lush Choir, John Hughes Movies, Domino Dancing and Crocketts Revenge. Each of them breaks one of two rules which all 3,388 looped samples of the factory library follow:
clampLoopsclamps a loop end to the last frame, and the converted loops of John Hughes Movies, Prophet Voices, Power Brass, The Call Of Africa, PPG Power Keys, Lush Choir and Crocketts Revenge end there - the end of the source sample.Domino Dancing breaks only the second rule, and John Hughes Movies, Prophet Voices, Power Brass and The Call Of Africa only the first, so each rule alone stops a preset from loading. None of the 24 presets which load breaks either rule.
Changes
Both the preset writer and the multi-sample writer, after trimming a sample and clamping its loops:
fitLoopCrossfades: a cross-fade which does not fit moves the loop start forward until 256 frames of the sample are left in front of the cross-fade (the factory cross-fades leave at least 198), so the cross-fade blends the end of the loop into the audio which the loop skips, like a sampler which cross-fades into the start of the loop. A cross-fade which covers most of the loop is limited to half of the remaining loop (the factory cross-fades are at most 71.5% of their loop). The start of a single-cycle loop (up to 512 frames) is not moved, since its length is its pitch; its cross-fade is shortened instead. Every changed loop is logged.addFrameBehindLoop: a sample whose (first) loop ends on its last frame gets one more frame, a copy of the first frame of the loop. That is the frame which follows the loop end when the loop plays, so the loop and the sound stay as they are.The first commit shortened a cross-fade which did not fit. That made the loops click which the source cross-fades over a jump: the loops of Lush Choir and Crocketts Revenge start at frame 0, so their cross-fade became 0, over a jump of 18 to 55 times the normal change between two frames. The second commit moves the loop start instead.
CHANGELOG and README-FORMATS describe both. The CHANGELOG entry adds an
Elektron Tonverk Presetblock at the same place as #490, so whichever of the two is merged second needs both bullets under one heading.Verification
smplchunks. The files of the other 24 presets are byte-identical.