Hello, I need help finding the right encoding settings for my video. I can get it to play. However, it will not loop. When I try targeting a different media file, it will play and loop.
Attached below is the media file that is having trouble and will not loop. I’m using Davinci resolve. Here’s my question: What can I do to fix the encoding? What tools could I use to analyze the encoding and identify problems with it?
I would love to upload the correctly working media file, but it’s a part of a paid asset. I don’t want to upload something I don’t own. If there are tools to analyze that file, I could report the stats here.
As an update, I’ve found that MP4s that feature these two fields will not loop. You can view the Codec data by using VLC. Load the video and do Tools > Codec Information.
Also, here is the command in batch format in case you want to skip opening a terminal. You can just drag and drop your video file onto the .bat file, and it will automatically copy and fix it for you. Easy!
@echo off
setlocal
:: Check if a file was dragged onto the .bat file
if "%~1"=="" (
echo Please drag and drop an MP4 file onto this script.
pause
exit /b
)
:: Get the full input file path
set "input=%~1"
:: Get the file name without extension
set "filename=%~n1"
:: Get the file extension (in case you want to check it's actually .mp4)
set "ext=%~x1"
:: Build the output file name: {NAME}-Fixed.mp4
set "output=%~dp1%filename%-Fixed.mp4"
:: Run ffmpeg command
ffmpeg -i "%input%" -map_metadata -1 -c copy "%output%"
echo Done.
pause