The /video/merge Robot
We offer a variety of video encoding features like optimizing for different devices, merging, injecting ads, changing audio tracks, or adding company logos.
The /video/merge Robot composes a new video by adding an audio track to existing still image(s) or video.
This Robot is perfect for music studios that want to turn music tracks into videos without manually recording one. Use an album cover instead and export the result to your video-sharing website of choice. We also offer the replacement of the audio track on a video.
||(required) String / Array of Strings / Object||
GeneralSpecifies which Step(s) to use as our input.
Special Step namesA special Step name is
Providing several Steps as inputYou can add arrays to
That's likely all you need to know about
› Advanced use cases
Step bundlingSome Robots can gather several Step results for a single invocation. For example, the /file/compress Robot would normally create one archive for each file passed to it. If you'd set
This is also a crucial parameter for the /video/adaptive Robot, otherwise you'll generate 1 playlist for each viewing quality.
Keep in mind that all input Steps must be present in your Template. If one of them is missing (for instance it is rejected by a filter), no result is generated because the Robot waits indefinitely for all input Steps to be finished. Here's a demo that showcases Step bundling.
Group by originalSticking with the /file/compress Robot example, you can set
FieldsYou can be more discriminatory by only using files that match a field name by setting the
Use AsSometimes Robots take several inputs. For instance, the /video/merge Robot can create a slideshow from audio and images. You can map different Steps to the appropriate inputs. Example:
Sometimes the ordering is important, for instance, with our concat Robots. In these cases, you can add an index that starts at 1. You can also optionally filter by the multipart field name. Like in this example, where all files are coming from the same source (end-user uploads), but with different
For times when it is not apparent where we should put the file, you can use Assembly Variables to be specific. For instance, you may want to pass a text file to the /image/resize Robot to burn the text in an image, but you are burning multiple texts, so where do we put the text file? We use specify it via
||Generates the video according to pre-configured video presets.
If you specify your own FFmpeg parameters using the Robot's
||Width of the input image||Width of the generated video, in pixels.|
||Height of the input image||Height of the generated video, in pixels.|
||If the given width/height parameters are bigger than the input image's dimensions, then the
||The background color of the resulting video the "rrggbbaa" format (red, green, blue, alpha) when used with the
||When merging images to generate a video this is the input framerate. A value of "1/5" means each image is given 5 seconds before the next frame appears (the inverse of a framerate of "5"). Likewise for "1/10", "1/20", etc. A value of "5" means there are 5 frames per second.|
||When merging images to generate a video this is the desired target duration in seconds. The float value can take one decimal digit. If you want all images to be displayed exactly once, then you can set the duration according to this formula:
||When merging a video and an audio file, and when merging images and an audio file to generate a video, this is the desired delay in seconds for the audio file to start playing. Imagine you merge a video file without sound and an audio file, but you wish the audio to start playing after 5 seconds and not immediately, then this is the parameter to use.|
||Selects the FFmpeg stack version to use for encoding.
These versions do not reflect any real
FFmpeg versions, they reflect our own internal (non-semantic)
versioning for our custom FFmpeg builds.
The current recommendation is to use
||A parameter object to be passed to FFmpeg. For available options, see the FFmpeg documentation. If a preset is used, the options specified are merged on top of the ones from the preset.|
Our /video/merge Robot can be used in combination with other Robots, to create powerful workflows unique to your use case. Here are a few example scenarios that you can try live on our website:
- Add an audio track to video footage
- Convert any video to animated GIF
- Generate a video from an image sequence
- Join multiple videos sharing one audio track
- Merge an audio and a video file
- Merge an audio file and an image to generate a video
Transloadit is a SaaS with a subscription model.
Our /video/merge Robot counts towards your plan's data at a normal rate. It charges at minimum 0MB whenever it is used. Assuming the Startup Plan and an average video size of 80MB, you could merge 102 videos for $49/month.
Just like with your mobile plan, pricing goes down considerably when you commit to larger monthly volumes. You can adjust this every month. More info and available plans on our Pricing page.
Blog posts about the /video/merge Robot
We wrote the following posts about the /video/merge Robot on our blog:
- Tutorial: Using /video/merge to develop video slideshows June 14, 2019
- Happy 2016 from Transloadit December 31, 2015
- Upgrading Encoding Engines July 31, 2015
- Kicking Transloadit Into Gear for the New Year February 1, 2015
- On Upgrades & Goodbyes August 8, 2014
- A Happy 2014 from Transloadit! January 14, 2014
- Merging Image and Audio Files to Create Videos August 7, 2013