Updated on 2023-09-20 GMT+08:00

Functions

MPC helps you transcode audio and video files stored in OBS buckets so that the output files can be played on a broad range of devices. It also supports snapshot capturing and watermarking.

Media Transcoding

Media transcoding is to convert an audio or video file into one or more output formats. This involves changing the parameters of the media file such as the format, codec, bitrate, and frame rate.

Parameter

Description

Input format

  • Input file formats: MP4, TS, MOV, FLV, MPG, MXF, WMV, ADTS, AVI, MKV, MPEG, GIF, and WAV
  • Video codecs: H.264, H.265, MPEG-2, MPEG-4, MJPEG, VP6/7/8/9, WMV1/2/3, and ProRes 422
  • Audio codecs: AAC, AC3, EAC3, HE-AAC, MP2, MP3, PCM (s161e, s16be, s241e, s24be, DVD), and WMA
  • Subtitle format: SRT file in UTF-8

Output format

  • Output file formats: DASH, HLS, MP4, MP3, and ADTS
  • Video codecs: H.264 and H.265
  • Audio codecs: HE_AAC, AAC, and MP3
  • Image file format: GIF

Audio extraction

Extract audio from a video.

Mute video

Remove sound from a video.

Subtitling

Add subtitles to a video.

Watermarking

During transcoding, add static image/text watermarks to videos for copyright protection.

The transcoded audio and video specifications can be customized based on your needs. For details, see Table 1, Table 2, Table 3, and Table 4.

Table 1 Video encoding parameters

Parameter

Description

Video Codec

The value can be H.264 or H.265. The default value is H.264.

Resolution (video width and video height)

  • H.264
    • Video width: [32, 4096] or 0. The unit is px.
    • Video height: [32, 2880] or 0. The unit is px.
  • H.265
    • Video width: [160, 4096] or 0. The unit is px.
    • Video height: [96, 2880] or 0. The unit is px.

If the video width and height are both set to 0, the transcoded video is produced based on the original resolution. If the video bandwidth or height is set to 0, the corresponding value is adjusted based on the original size.

Bitrate

Video bitrate. The value can be 0 or ranges from 40 to 30,000. The unit is kbit/s.

If this parameter is set to 0, an output file is generated at the adaptive bitrate.

Maximum I-Frame Interval

Maximum interval between I frames in a key frame. The value ranges from 2 to 5.

Maximum Consecutive B-Frames

Maximum number of consecutive B-frames in a key frame. The value ranges from 0 to 7.

Profile

Encoding profile.

  • If the video codec is H.264, BASE, MAIN, and HIGH are available.
  • If the video codec is H.265, only MAIN is available.

FPS

Video frame rate. The value is 0 or ranges from 5 to 30.

If this parameter is set to 0, an output file is generated at the original frame rate.

Maximum Reference Frames

Maximum number of reference frames.

  • If the video codec is H.264, the value ranges from 1 to 8.
  • If the video codec is H.265, the value is always 4.

Quality

Video encoding level. There are three levels. A larger value indicates higher encoding quality and longer transcoding time.

Black Bar Removal

Automatically detect and remove black bars from your video.

Table 2 Video processing parameters

Parameter

Description

Video rotation angle

Rotate a video clockwise. Videos can be simply rotated by 90 degrees, 180 degrees, and 270 degrees.

Adaptive resolution

The following options are available:

  • SHORT: Adaptive width
  • LONG: Adaptive height
  • None: Do not adapt.
Table 3 Audio encoding parameters

Parameter

Description

Audio Codec

The available options are AAC, HE_AAC1, HE_AAC2, and MP3. The default value is AAC.

Sampling Rate

The value can be AUTO, 22050 Hz, 32000 Hz, 44100 Hz, 48000 Hz, or 96000 Hz. The default value is AUTO.

Bitrate

Audio bitrate. The value can be 0 or ranges from 8 to 1000. The unit is kbit/s.

Audio Channel

Number of audio channels. The value can be 1 or 2.

Table 4 Video processing parameters

Parameter

Description

Volume control

Two methods are supported:

  • auto: adjusts the volume automatically
  • dynamic: adjusts the volume manually

Volume adjustment amplitude

The value range is [-15, 15], and the unit is dB.

Transcoding Templates

MPC provides plenty of built-in transcoding templates to meet your diverse requirements. You can also create a transcoding template to target your specific scenario.

  • Preset templates: You can directly use these templates without any other configuration. There are audio templates, audiovisual templates, and low bitrate HD templates, covering all output formats, encoding formats, and common resolutions and bitrates. Based on the number of output files, preset templates are classified into the following types:
    • One-in one-out transcoding template: Only one file is output.
    • One-in multiple-out transcoding template: A maximum of nine files can be output.
  • Custom templates: Set the video and audio parameters based on your needs. A custom template can be one-in one-out or one-in multiple-out. A maximum of six output specifications can be configured for a one-in multiple-out template.

Low Bitrate HD

MPC uses perceptual coding to analyze each scenario, action, content, and texture in a video, achieving lower bitrate and bandwidth usage at a given video quality.

Video Watermark

  • You can add both image and text watermarks to videos.
  • The input format can be PNG, JPG, or JPEG.
  • A maximum of two static images can be overlaid on an output video per frame.
  • A maximum of ten static images can be overlaid on each output video.
  • The resolution of a watermark is between 8 x 8 and 4096 x 4096. The size of the watermark cannot exceed 10 MB.

Snapshot Capturing

You can capture a snapshot from a video and save it as a JPG file during transcoding or at any other time. The following two capturing methods are supported:

  • By interval: Take snapshots at regular intervals. The default interval is 12s.
  • At fixed time: Take snapshots at specified time points.