Video Transcoding, Dynamic Ingest, and APIs: An Overview


Welcome to the second post of a technical-focused series of articles. We previously discussed the flexibility of the Brightcove player, supplying examples of how you can customize the HTML5 online video player for your needs. In this article, we’ll be talking transcoding and the benefits of Dynamic Ingest (DI). Let’s get started.

What is Video Transcoding?

When a video is uploading to a video platform, the system takes the video file, (it could be in any format - mkv, mov, mp4, etc) and creates renditions from it that are the suitable for playback across a vast array of devices and browsers and optimal for streaming. This is because your initial video file may not have been suitable for playback on all devices or for streaming. So transcoding is essential for ensuring that your video file can play across the internet in varied locations and across all devices and browsers. In the past, it was FLV and MP4 based renditions that were created. As we have moved to mobile-first, these options are going to the wayside in favor of HLS and DASH.

Rendition setting controls the video and audio bitrate, resolution, constant/variable bitrate, among other factors of the output file. In the past, we were limited to 10 renditions per account and, if a customer wanted a Digital Rights Management (DRM) technology applied to the content, a separate Video Cloud account would have to created. (DRM is a topic I will cover in a later article.) But the modern customer needs a more flexible solution. This is where Dynamic Ingest comes in, because it is a robust framework where you can tell the system exactly how to create the renditions. For example, you can specify that for a 1080p 7Mbps video file, 12 renditions will be created of varying bitrates and resolutions from 1080p to 240p in MP4 and HLS. The system allows for multiple profiles to be defined for an account, which means that a single Video Cloud account can contain a variety of rendition types, such as MP4, HLSe, and PlayReady.

How Does Dynamic Ingest Work?

The Dynamic Ingest system is built on top of Zencoder, another Brightcove product, which provides a cloud-based, elastic transcoding solution. Elastic means that as the number of requests increases, Zencoder can spawn more instances and increase the system capacity as necessary. Even under load, Zencoder can efficiently and quickly create target renditions. In fact, if you have uploaded content in the new Brightcove studio, you are using Dynamic Ingest and, ultimately, Zencoder. Cloud computing at its best!

Using Dynamic Ingest with APIs

Dynamic Ingest is pull-based. That means the video file can reside on a HTTP/HTTPS server or even a secure S3 bucket with the right credentials, and DI will pull in the video file and then transcode to create the renditions specified. By moving to a pull-based system, we have seen quicker times to get the video file and thus the transcoding process finishes that much faster.

[Update] Dynamic Ingest also supports push-based. That means Brightcove will provide a secure upload location. The approach is very similar to the pull-based; after making the CMS call to create the video object, request an Upload URL and then upload the file to that location. And please remember to enable the Push Files operation to your Client ID and Secret pair. Visit our Dynamic Ingest API guide for more details on the Source File Upload API.

How to use Dynamic Ingest with APIs only:

  1. Create a Client ID & Secret in your Video Cloud account.
  2. Using the Client ID & Secret, request a short-run token.
  3. Create a Video object using the CMS API plus define the metadata for this video object
  4. If successful, the response will return a Video ID.
  5. Using this Video ID, create a Dynamic Ingest request by specifying the location of the video file and the profile to use.
  6. If successful, the system pull in the video file and then transcode the file as per the profile specified.
  7. Notifications of video progress can be sent to an endpoint you specify.

The benefits of Dynamic Ingest are broad and varied depending on your use case. Did you know you can re-transcode your video using Dynamic Ingest? Just by issuing the right API request, you can programmatically retranscode the video using another profile. Dynamic Ingest can also be used to ingest custom thumbnails, video stills and even caption files.

Hope you enjoyed this introductory article on transcoding and Dynamic Ingest and it has provided the material to get you started with a very powerful API to automate your workflow.

Join me next time, when I will cover CMS connectors.