Multimic Samples


  • administrators

    Handling multi channel samples

    Having multiple microphone positions is a pretty standard feature of todays sample libraries. A sampler should be designed to be as efficient as possible as well as having a workflow that supports multi channel samples.

    HISE has a dedicaded system for multimic samples that meets the following requirements:

    1. Each mic position must be purgable to unload it from memory. Also, this feature must be as easy as possible.
    2. Once the samples are loaded into the sampler, the workflow should not be any different than working with a single mic sample. Having to select all multimic samples manually before making changes (like changing the micro tune or the sample start) is both tedious and error-prone.
    3. Increase the performance. By combining multimic samples, envelopes and modulators only need to be calculated once for all channels.
    4. Allow a flexible routing. Effects must be applicable to either individual channels or the (stereo) mix of all positions. Also surround samples should be possible.

    All these requirements are met using one simple trick:

    A multimic sample consists of multiple audio files (from now on called siblings) that are merged into one virtual sample and treated as a single audio file.

    This allows purging of individual channels (using multichannel audio files directly would not be possible, because you can't unload parts of a audio file without rewriting the complete audio file engine.)

    The workflow is pretty straight forward: Load all single mic samples into the sampler, map them as needed and then merge them into multimic samples.

    Merging samples opposes some restrictions. They need to have these things in common:

    • Same sample length & sample rate. If the second channel was shorter than another, it would become a problem.
    • *Every sample needs a multimic sibling for each channel. Once a sampler is in multimic mode, all samples need the same channel amount. (Of course you are free to add another sampler with another channel configuration.)

    If the merging is successfull, the channel amount of the sampler is changed and the multimic samples are treated as one sample. Changing properties of the multimic sample changes the property of all embedded single mic sample.

    Also a multimic sample is treated like one voice (so all modulators are calculated only once).

    You can apply different effects on the sampler itself (a gain effect for each channel pair is almost obligatory.) You can then submix them in your container to get one stereo channel that can be processed by another FX.

    The Merging

    The process of merging samples into multimic samples is handled by a dedicaded window.

    1. Load all samples into the sampler.
    2. Map them on the position they belong (note, velocity, RR group). Make sure every sample has the same amount of siblings (=single samples with the same note, velocity & RR group properties).
    3. Select all samples (Cmd + A when the sample editor has focus).
    4. Right click on the map editor and choose Tools -> Merge multimic samples

    Now you should see this dialog window:

    Separator:
    the file name separator token (also used by the file name import parser).

    Select Token:
    The selected separator divides the filename into multiple tokens (=parts that contain various information). You can now select the token that identifies the mic position.

    Selecting the token also acts as "Refresh Merge Status". So if you change the Separator or the Detection Mode, you'll need to reselect the token again to refresh the merge status.

    Select detection mode:

    Option Description
    Mapping Data: The tokens are discarded and only the mapping data is used to identify siblings.
    Filename the mapping data is discarded and only the filename tokens are used to identify the tokens
    Mapping Data and filenames both mapping data and filenames must match to get a multimic sample.

    Status:
    A message label that displays the current state.

    This sounds complicated at first, but let's take an example. We load two samples:

    Sustain_A2_RR2_Close.wav
    Sustain_A2_RR2_Far.wav

    We move them until they overlap completely (and are in the same RR Group).

    In the merge window we choose:

    • the Separator _
    • the last Token Close
    • the selection Type Mapping Data

    The status text field should show:

    1 multisamples with 2 channels found. Press OK to convert.

    Pressing OK merges all samples and replace them with only one zone. Also the channel amount of the sampler changed (which can be checked by clicking on the routing button).
    Also all single mic samples are replaced by one multimic sample (so they won't show up in the Sampler Table or the Map Editor anymore)

    How does it work

    In order to understand the error messages, it is important to know how the process works.

    1. It counts the number of different token values to get the number of mic positions.
    2. It iterates over all single mic samples and either creates a new multimic sample or adds it as sibling to an existing multimic sample.

    Handling Errors

    The restictions for the samples for successfully merging are pretty tight: If only one sample doesn't meet the requirements, the whole process will be aborted. This is because after merging, HISE needs to assume correct multimic behaviour to save runtime checks to increase performance during playback.
    In this case the status message label displays the faulty sample name and a error message that helps finding out how to fix the problem.

    These error messages can be displayed:

    Mixing different channel amounts

    Error Message:
    There are already multimic samples in this sampler. Extract them back to single mics and remerge them.

    You can't mix multimic samples and single mic samples within one sampler. If you want to add more samples, you would need to extract the multimic samples back to single mics, add the single mics and then remerge them back into multimics.
    Another possibility would be using a dummy sampler to create new multimic samples and copy & paste them into your real sampler when they are sucessfully merged in the other sampler.

    Merge a selection of samples

    Error Message:
    You have to select all samples for the merge.

    The merge operation needs to be done on all samples at once. (It could be automatically select all samples, but this is a safety procedure to make sure you do the merging conciously).

    Unequal sample length

    Error Message:
    Unequal length at Sample #: $FileName$

    This error message occurs if a sibling of a sample that should be merged into a multimic sample differs in the length. This is also the case if the files have the equal length, but the sample start of one sample differs from the other.

    To solve this problem, check out the sample (and the sibling samples) named in the error message and either set them to the same length or rename them if they false positive match.

    Missing sibling sample for a channel

    Error Message:
    # missing channel(s) - MISSING_CHANNEL at Sample #: FILE_NAME

    This error message occurs if one multimic sample could not find a sample for a specific channel (CHANNEL_NAME). The FILE_NAME will be the name of the first mic position sample of this multimic sample. If we take the example from above, but don't supply the second sample (Sustain_A2_RR2_Far.wav), the error message would yield:

    1 missing channel(s): Far at Sample 1: Sustain_A2_RR2_Close.wav


Log in to reply

Looks like your connection to Multimic Samples was lost, please wait while we try to reconnect.