amazon-web-servicesvideo-processingamazon-elastic-transcoder

AWS Elastic Transcoder throws error when merging different mp4 files with audio and without audio


I need to merge different videos using AWS Elastic Transcoder. However, the job fails because there is a video with no audio. I get below error:

At least one media file doesn't match the others. All media files must have either audio or no audio.

Reading the documentation seems as it is only possible to add a MOS track with mxf files.

Has anyone run into the same problem and found a solution? Thanks in advance.


Solution

  • A possible solution is to check if the video files have audio using MediaInfo and in case they haven't add an audio track using Ffmpeg.

    These functionalities can be wrapped into Lambda functions and MediaInfo / Ffmpeg used as Lambda Layers.