How to stretch the Audio so it matches the Video clip length

Get answers to your questions about color grading, editing and finishing with DaVinci Resolve.
  • Author
  • Message
Offline

pbuedi

  • Posts: 28
  • Joined: Thu Mar 18, 2021 6:46 pm
  • Real Name: Patrick Buedi

How to stretch the Audio so it matches the Video clip length

PostSun May 09, 2021 10:05 am

Hi there,

I have a 8x slow motion recording from my Camera. The camera created a Video file without Audio containing the 1080p 29.97fps Video file. Playing it back, it shows the "action" 8 times slower than it happend. So far so good.

The camera also created an AC3 Audio file, containing the Audio in real-time.

Now I planned to cut the slow motion recording and speed it up to real-time where people speak and to slow-motion again where the action happens.

My plan was to sync up the Audio with the Video first and then start cutting, but it seems the Synchronize feature in the Media Pool is not for that.

My next plan was to place the Video and the Audio in the timeline, slow down the Audio to 0,125x speed, so it would match the Video clip and then just cut in the timeline. The problem is, that the speed change function for clips supports only 2 digits after the decimal, so I can only slow it down 0.12 or 0.13 times. The former is too short, the latter is too long and everything is out of sync.

I am sure there is a technique where I can achieve what I want, I just lack the creativity :lol:
So I hope someone out there can help me a bit :)


Cheers!
Offline

peterjackson

  • Posts: 1144
  • Joined: Sat Aug 18, 2018 7:12 pm
  • Real Name: Peter Jackson

Re: How to stretch the Audio so it matches the Video clip le

PostSun May 09, 2021 10:20 am

Rubberband either standone or through FFMPEG is high quality and precise.

https://breakfastquay.com/rubberband/

https://superuser.com/questions/1131923 ... deo-length

I might be mistaken, but IIRC Resolve itself also uses Rubberband.
5950x, 3090, 128GB.
Offline

pbuedi

  • Posts: 28
  • Joined: Thu Mar 18, 2021 6:46 pm
  • Real Name: Patrick Buedi

Re: How to stretch the Audio so it matches the Video clip le

PostSun May 09, 2021 11:27 am

Peter! That did the trick for me. Thank you so much! I was about to use the rubberband executable, but I think it only supports.wav, so I just went the ffmpeg route.

It took me a bit to figure out the right syntax for what I wanted to achieve, so here it is. Just in case someone else needs this.

In my case it was an AAC file, but it should work with every file format ffmpeg supports.

Code: Select all
ffmpeg.exe -i infile_to_stretch.AAC' -filter:a "rubberband=tempo=0.125" new.AAC


This will read the infile_to_stretch.aac (auto-detect the codec), stretch it 8x (factor 0.125) and write it to a new.aac AAC file which I was able to just load into resolve.

Return to DaVinci Resolve

Who is online

Users browsing this forum: Bruce Phung, Google [Bot], jhoepffner, madajank, panos_mts, Tomek Kosiorek, whippet and 200 guests