Loop 2 audio clips of different length independantly

Hi there,

I have 2 audio tracks - each have clips of different lengths. How do I loop them independently of each other while playing simultaneously?

One is level atmosphere / environment and the other is a heartbeat that I need to loop alongside it.

Any ideas? Shiuld I be using a multi instrument instead?

Thanks in advance

There’s a few different ways to do this. Assuming you just need both instruments to loop without variation, the simplest option is to place both instruments on a timeline sheet or parameter sheet (if they’re not on one already), set them to asynchronous mode and loop instrument mode (by selecting each instrument and clicking its “Async” and “Loop Instrument” buttons). If they’re on a timeline sheet and not some other parameter sheet, position a loop region or sustain point over them such that the timeline playback position never moves off their trigger regions.

Thank you Joseph, this worked perfectly.

Can I also ask (and this may be a stupid question), for this event, I have basically some atmos / enviro looping. It’s simple looped atmos for a menu screen that launches and then stops upon return to normal gameplay.

I have an AHDSR for volume release setup for when I hit stop - everything is looping nice and everything is ready to rock.

My question is this - when FMOD exposes this event in Unity, will it automatically adhere to the ‘stop play’ commands. In other words, does Unity have a build in ‘event end’ command that tells the event to stop playing (when player clicks off of this menu) and will this then trigger FMOD’s AHDSR volume release for a smooth fadeout?

Basically, I don’t need to add any other kind of ‘stop playing’ or ‘event has ended’ command element to my FMOD event? Unity will just handle this triggering of stopping the event?

The Studio API has two different stop modes that may be used when stopping an event instance: FMOD_STUDIO_STOP_ALLOWFADEOUT and FMOD_STUDIO_STOP_IMMEDIATE. As the names suggest, FMOD_STUDIO_STOP_ALLOWFADEOUT makes the event instance begin its stopping behaviour, including any AHDSR modulator release periods on the event’s properties, whereas FMOD_STUDIO_STOP_IMMEDIATE stops the event immediately without waiting for its stopping behavior.

Both of these stop modes are available in the Unity integration. A Studio event emitter’s advanced options includes an allow fadeout checkbox that does what you would expect, an FMOD event playable has a stop mode property, and these properties can also be set via script.