mwg API
    Preparing search index...

    Function loopRegionFromTags

    • The loop region in seconds for decoded audio, from a file's declared tags: the start, and the start plus the length (or the end of the buffer when no length is declared). Null when the tags name no usable region inside the buffer.

      Parameters

      Returns LoopRegion | null

      import { loopRegionFromTags } from '@datamoc/mwg/audio';

      console.log(loopRegionFromTags({ loopStart: 44100, loopLength: 44100 }, 44100, 10)); // { start: 1, end: 2 }