Download

How to sync audio with video while rendering?

Hi, this is my first topic so apologies if i am doing it wrong…

I have a Niagara effect that reacts to an ambient sound placed in the level via a Niagara Module Script (screenshot attached). I want to render the scene in sequencer or movie render queue but unfortunately when doing so the audio plays in realtime while the effect naturally takes a little longer to render meaning that the reactive effect is out of sync with the sound.

I am wondering/hoping that there is a way to bake (?) the audio so that it will render in sync with the effect… Or perhaps there is a way to extract the audio spectrum, feed it to the Audio spectrum node in the module script over the same duration as the song… would that work? and how might i do it if it would - I am new to niagara and blueprints so any and all help would make me eternally grateful!

No one can help? I really really don’t want to have to screen record in order to get it to sync. The quality in comparison will be abysmal

Either:

  1. Render only the video, and add the audio in a video editing app (like blender).
  2. Delay the audio track until it syncs up with the effect.

Hi Midgunner66,

Thanks for the reply, the problem with solution 1 is that the video effect is directly affected by the audio (the audio in game makes it move, reacting in real time) which is why when it goes out of sync the video effect is no longer reacting the audio and won’t render properly.

As for solution 2, do you mean a way to capture the spectrum data and play it back over the duration of the song, in effect, allowing the niagara to react to the music without requiring realtime and therefore being able to render for however long it takes and remain synced. If so, do you have any idea how? Even some buzz words might help that i could research into, thanks!

Not what I meant, but what you suggested is a great idea. I found some nodes that are similar to the one you’re using in your graph: Sound Visualization | Unreal Engine Documentation. They let you sample audio at a specific time, so you can use that to keep it in sync.