VideoTranscode
VideoTranscode[video,"format"]
converts video to the specified format.
VideoTranscode[video,service]
converts video to the specification recommended by the specified service.
VideoTranscode[{v1,v2,…},…]
converts all vi videos to have conforming properties with respect to the given specification.
Details and Options
- VideoTranscode can be used to convert between video containers and codecs, or to prepare videos suitable for different video services.
- The "format" can be any of the supported video formats in $VideoEncoders or Inherited.
- The service can be any of the following:
-
"Facebook" regular Facebook video feed specification "Instagram" Instagram in-feed video and video ads specification "LinkedIn" LinkedIn shared video specification "Snapchat" Snapchat video specification "Twitter" Twitter video specification "YouTube" recommended YouTube video specification - Most services automatically transcode video files when necessary. Use VideoTranscode to make sure the file is prepared for a particular service and reduce the file size, which enables faster upload.
- VideoTranscode[video] is effectively equivalent to VideoTranscode[video,Inherited], when possible.
- By default, VideoTranscode places the new video under the "Video" directory in $WolframDocumentsDirectory.
- The following options can be given:
-
AudioEncoding Automatic audio encoding to use BitRate Automatic approximate bit rate to use CompressionLevel Automatic compression level to use ConformationMethod Automatic how to conform frames into the specified raster size FrameRate Automatic number of frames shown per second GeneratedAssetLocation $GeneratedAssetLocation location of the generated asset OverwriteTarget False whether to overwrite an existing file RasterSize Automatic pixel dimensions SampleRate Automatic audio samples per second for each channel SubtitleEncoding Automatic subtitle encoding to use VideoEncoding Automatic video encoding to use VideoTransparency False whether the output video should have a transparency channel - VideoTranscode supports video containers and codecs specified by $VideoEncoders and $VideoDecoders.
Examples
open allclose allScope (4)
Convert a Video object to any of the supported file formats:
Convert a video to a format suitable for YouTube:
All of the services only accept videos with a single audio and video track:
Options (12)
AudioEncoding (2)
BitRate (1)
CompressionLevel (1)
Transcode video using default compression:
The choice of encoders affects the amount by which a file can be compressed:
When the bit rate is specified, the value of the CompressionLevel option is not used:
FrameRate (1)
By default, VideoTranscode preserves the frame rate (rounds to the nearest integer value):
GeneratedAssetLocation (1)
By default, generated video files are stored in $WolframDocumentsDirectory:
RasterSize (1)
By default, VideoTranscode preserves the raster size:
Specify the raster width to use while preserving the aspect ratio:
SampleRate (1)
By default, VideoTranscode preserves the sample rate:
Text
Wolfram Research (2020), VideoTranscode, Wolfram Language function, https://reference.wolfram.com/language/ref/VideoTranscode.html (updated 2023).
CMS
Wolfram Language. 2020. "VideoTranscode." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2023. https://reference.wolfram.com/language/ref/VideoTranscode.html.
APA
Wolfram Language. (2020). VideoTranscode. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/VideoTranscode.html