bastimeyer · GitHub

Copying this from my post of the 6.4.2 release pull request:


Old recordings with the faulty output which FFmpeg 6.1 now rejects need to be remuxed using an older FFmpeg version.

#!/usr/bin/env bash
for file in $(find . -type f -name "*.mp4" -print); do
  ffprobe -v quiet "${file}" && continue  # ffprobe >=6.1 returns status code >0 for those faulty mp4 containers
  echo "Remuxing ${file}"
  /path/to/older/ffmpeg -v error -i "${file}" -c copy -f mp4 "${file}.new" \
    && touch -c -r "${file}" "${file}.new" \
    && rm "${file}" \
    && mv "${file}.new" "${file}"
done

Where you can get an older FFmpeg build depends on your OS, but here are some relevant links:

Read the original on github.com ↗