Answers.Body: <p>Since MS players don't support editlists, you'll have to pad the audio to achieve the offset in a compatible manner.</p>
  <p><code>ffmpeg -i video.mp4 -itsoffset 5 -i video.mp4 -map 0:v -map 1:a -c:v copy -af aresample=async=1:first_pts=0 -y out.mp4</code></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-07-15T17:02:14.120Z
Answers.LastActivityDate: 2024-07-15T17:02:14.120Z
Answers.UserDisplayName: Gyan
Body: <p>I'm encountering visual artifacts (screen corruption) and unexpected time jumps when playing a video file generated by FFmpeg in Windows Media Player and Microsoft Movies &amp; TV. The same video plays correctly in PotPlayer, MPV, and VLC.</p>
  <p>The command I used to delay the audio by 5 seconds was:</p>
  <pre><code>ffmpeg -y -hide_banner -i video.mp4 -itsoffset 5 -i video.mp4 -map 0:v -map 1:a -c copy out.mp4
  </code></pre>
  <p>The output video works as expected in most modern players but exhibits <strong>visual corruption</strong> and <strong>automatically skips to the 00:05 timestamp</strong> in Microsoft's players.</p>
  <p>I tried removing the <code>-c copy</code> option from the command, or changing the output format to <code>mkv</code>, but neither solved the problem. This is not a problem with the encoding, but with the player's support for MPEG-4 edit list tables.</p>
  <p>I aim to produce a video with FFmpeg that will play without issues on any player, including very old ones. Is there a way to tweak FFmpeg parameters or use alternative strategies to ensure the output video is universally compatible across all media players?</p>
  
Tags: <ffmpeg><sync><formats>
Title: FFmpeg -itsoffset causes visual artifacts and time jumps in WMP and Movies & TV
UserDisplayName: aax Feng
ThreadText: # FFmpeg -itsoffset causes visual artifacts and time jumps in WMP and Movies & TV
  
  (Asked by: username_0 on 2024-07-15)
  
  I'm encountering visual artifacts (screen corruption) and unexpected time jumps when playing a video file generated by FFmpeg in Windows Media Player and Microsoft Movies & TV. The same video plays correctly in PotPlayer, MPV, and VLC.
  
  The command I used to delay the audio by 5 seconds was:
  
  ```
  ffmpeg -y -hide_banner -i video.mp4 -itsoffset 5 -i video.mp4 -map 0:v -map 1:a -c copy out.mp4
  
  ```
  
  The output video works as expected in most modern players but exhibits **visual corruption** and **automatically skips to the 00:05 timestamp** in Microsoft's players.
  
  I tried removing the `-c copy` option from the command, or changing the output format to `mkv`, but neither solved the problem. This is not a problem with the encoding, but with the player's support for MPEG-4 edit list tables.
  
  I aim to produce a video with FFmpeg that will play without issues on any player, including very old ones. Is there a way to tweak FFmpeg parameters or use alternative strategies to ensure the output video is universally compatible across all media players?
  
  **Tags:** ffmpeg, sync, formats
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2024-07-15. Score: 0 | Accepted answer
  
  Since MS players don't support editlists, you'll have to pad the audio to achieve the offset in a compatible manner.
  
  `ffmpeg -i video.mp4 -itsoffset 5 -i video.mp4 -map 0:v -map 1:a -c:v copy -af aresample=async=1:first_pts=0 -y out.mp4`
  
  
  ---
  
  