Crossfade nested events and parameter

Hi,

I have some questions about fmod possibilities:

For the example I’ve created an event called Daytime . The parameter goes from 0 to 24 hour.

If in the code we call for parameter 0 (night sound) , and without transition we call 12 (day sound) [so the parameter only call 0 and 12 , not the values between ].

-Will the crossfade transition play , or it can’t and I’ll have to use the AHDSR.

-If there’s a way for this transition to play thanks to Fmod, How?

Thanks

Hi Orionye,

You won’t hear crossfades using this method.

This is because the nested event instruments are on the game parameter (“Hour”). The instruments are triggered when the parameter’s playback cursor is over them. In your case, if the parameter value is set between 5-7, what will happen is you will get both Nested Event and Nested Event (2) playing at the same time, but with reduced volume on both (volume depending on what part of the fade curves the playback cursor is on).

In order to get a crossfading to work, you will need to add AHDSR to each event instrument’s volume.

www.fmod.com/resources/documentation-studio?page=working-with-instruments.html#ahdsr-modulation

I hope this helped.
Richard

Hi Richard,

Yes this helps, thank you.

I have a Bonus question: If in the game, the parameter is evolving with real hours.
My parameter will read correctly the crossfade ? (still without AHDSR method)

Thanks again.

Hi Orionye,

Your game parameter can be made with any range (in this case 0-24) and you can pass any value into the event’s parameter in game code.

However if you are looking to cross fade, you will still need to use AHDSR and separate the event instruments. Here is an example below:

You will need to zoom into the timeline and adjust the “shared” value points (ie. at hours 7 and 18) in order to add a tiny gap by trimming one of the instruments by 0.01. This is in order for the cross fading to work correctly with AHDSR due to the way FMOD triggers instruments. Otherwise, at these shared points both instruments will play at the same time.

Thanks,
Richard