TIPS FOR CREATING COMPELLING AND ENGAGING VIDEO EXPERIENCES

 

If you are like many organizations, you may still rely on free video hosting solutions like YouTube to host and manage your video content. Many consider it a “no-brainer” as these video platforms provide a free solution for a high value opportunity.

Unfortunately, there is a high cost to free. You are left with a limited framework that does not actually solve your video experience needs, and in many situations can cause long-term negative impact on your content marketing initiatives.

In order to succeed, you need to view your video content marketing in a larger context that includes the overall experience in which your customers, prospects, and partners view your videos.

How long is your video viewed? Where is your video viewed? What action does your prospect take after watching your video?

To get a better understanding, let’s take a look at one of the biggest problems marketers are faced with: centralizing and organizing video content.

Why Enterprises Need Video Portals

Simply hosting your videos with a free service breaks many Marketing 101 rules.

  • Video should be hosted and presented in a controlled and branded environment. This leads to more time spent on your website engaging with easily discoverable and relevant content.
  • Video should have a strong call to action associated with it.
  • Video should integrate with and enhance static content, while working to support SEO initiatives.

Using a premium video platform, with a toolset designed specifically for launching and maintaining branded video portals, gives you the power to control the video experience down to the look and feel of the video player and the website on which it exists. Brightcove Gallery, as part of Brightcove Marketing Studio, does just this.

As a result, your audience will be engaged and your marketing team can expect to see on average a 157% increase in organic traffic from search engines, a 105% increase of time on site, and two times overall conversion compared to a non-video marketing strategy.

Brightcove Gallery is your entryway to easily creating best-of-breed immersive customer experiences. Gallery provides robust tools and a set of templates and layouts for designing and launching video resource libraries, portals, and microsites.

Customer Examples of Video Portals

Our customers have impressed us with their video experience portal results.

For example, Emerson Process Management uses Gallery to organize and present their 900+ videos. They replaced a homegrown video portal with Brightcove Gallery, launching a video experience that supports the organization’s thousands of videos. Brightcove Marketing Studio lowered web development costs, shifting management and control to the digital marketing team.

Screenshot of Emerson Process Management's video portal powered by Brightcove

AccuWeather uses Gallery to power their VideoWall, which has thousands of on-the-street storm and weather related stories. They launched VideoWall as a key product to keep users on the site and drive revenue. Brightcove Gallery enabled AccuWeather to launch a brand new video experience product without the need for a web development team. In the first month after launch, AccuWeather saw a 63% increase in website engagement.

Screenshot of AccuWeather's video portal powered by Brightcove

Other Use Cases for Video Portals

Brightcove Gallery is not just great for external use cases. The following are a few other common uses across our customer base.

  • Internal communications. Easily launch portals for employee communication of corporate messaging, user-generated content, executive state of the union addresses, and more.
  • Marketing portals. Create a home for marketing content that drives awareness, engagement, conversion, retention, and advocacy. Gallery automatically associates a branded URL with each video, making it simple to include video in email messaging, social media sharing, sales follow up, etc.
  • Knowledge sharing. Training environments and video courses can be set up right out of the box, with easy organization and flow without the need for learning management systems and e-learning software.
  • Speaker series. Build a channel for speaker series and thought leadership, or organize speakers by events and topics that are easy to navigate.
  • Live event highlights. Create an archive of live event highlights that can be updated and reorganized in real-time during conferences and events.
  • Microsites. Quickly spin up branded microsites and video pages to support marketing initiatives, events, and more.

We hope these examples will inspire you to do amazing things with video and launch your own video experiences using Brightcove Marketing Studio.

MOBILE VIDEO ADVERTISING: OPPORTUNITIES AND CHALLENGES

In 2015, the Interactive Advertising Bureau (IAB) and eMarketer released data highlighting continued growth in mobile video viewing. However, advertising spending has not kept pace with this shift in consumer behavior, leaving significant opportunities untapped.

UNCOVERING MOBILE VIDEO ADVERTISING OPPORTUNITIES

The IAB’s Mobile Video Usage: A Global Perspective study reveals that longer videos on mobile screens are increasingly capturing global attention. Thirty-six percent of respondents reported watching videos of five minutes or longer on their smartphones daily or more frequently, with users in Turkey, Finland, and China being among the most frequent viewers of longer content. The survey, conducted across 24 countries, also found that mobile video consumption—whether short or long format—continues to rise, with the highest growth rates observed in the US (50%), Canada, and New Zealand (both 42%).

Regarding advertising, 28% of respondents indicated they often see the same ads on mobile video as on TV. However, 80% expressed a desire for more personalized advertising experiences, highlighting an unmet need for better-targeted campaigns.

EMARKETER’s report also emphasizes the rapid growth in mobile video viewing but focuses on the disparity between consumer habits and ad spending. While mobile video accounts for 51% of viewing minutes, it receives only one-third of total ad spending, illustrating a clear gap in monetization.

OVERCOMING CHALLENGES TO MOBILE VIDEO ADVERTISING

Mobile video advertising has faced several challenges, including format inconsistencies, differences between mobile web and in-app ads, and concerns about delivering a seamless consumer experience. To address these challenges, Brightcove offers Once VOD, an industry-leading cloud-based ad and stream-stitching solution.

With Once VOD, media companies can deliver a seamless and consistent ad-supported video experience across all devices, optimizing reach, ad inventory, and revenue. Brightcove Once VOD supports smooth streaming in the Brightcove HTML5 player and iOS and Android video SDKs, creating a more interactive user experience. Additionally, Once VOD provides content providers with a highly configurable in-player ad solution. By abstracting ad insertion technology to the server, it allows for enhanced control of the player experience while supporting client-side reporting and measurement.

This powerful combination of Brightcove products ensures media companies can capitalize on the growing demand for mobile video while delivering high-quality, engaging, and monetized content to their audiences.

A LIVE LOOK AT LUXURY: HOW SOTHEBY’S USES VIDEO

Known for prestige and luxury, Sotheby’s is one of the world’s oldest and largest auction houses, selling fine and decorative art, jewelry, real estate, and collectibles, with 90 locations in 40 countries, doing roughly $6 billion in annual revenue. With its brand defining elegance and prominence, it’s hard to not want to get a peek at some of their remarkable items.

To open its doors and its brand to more buyers, Sotheby’s has partnered with Brightcove to deliver live auction experiences to viewers across the globe. In fact, today Sotheby’s will hold its CONTEMPORARY LIVING sale, a live streamed auction that is open to the public and will give viewers a unique look at some of the extraordinary items they sell.

Much has changed since the days of on-site auction houses in New York City and London, where buyers would flock to bid and secure deals on the latest collectibles. By providing live-streamed auction events, Sotheby’s will expand its reach to audiences around the world, provide greater exposure to art and collectibles, and strengthen its brand by delivering a convenient, mobile-friendly experience that buyers are increasingly demanding.

Founded in 1744, Sotheby’s has constantly strived to bring the highest quality inventory to buyers regardless of their geographic location, and the CONTEMPORARY LIVING sale live event is the latest example of Sotheby’s commitment to quality and innovation.

We’re proud to power Sotheby’s live auctions and are committed to helping them deliver real-time experiences that engage buyers online wherever they may be, creating awareness and driving more revenue for the auction house.

The key to strengthening competitiveness is internal communication. Using videos to improve brand value. Deepening” information communication.

STRENGTHENING THE SYSTEM TO ENABLE EMPLOYEES TO SHARE THE SAME VALUES

Omron Corporation, a major electronics manufacturer headquartered in Kyoto, is a global company with regional management bases in eight regions around the world, including Japan. Tsutomu Igaki, an executive officer in charge of the company’s communication activities, talks about the difficulties of communication within a large company like this “As our business expanded, our organization grew larger. As we moved forward with our business, with various organizations working together, including regional integration management bases, business companies, and headquarters of each domestic business division, as well as sales and manufacturing subsidiaries, the problem of internal communication came to the fore. If the message from the top management does not reach each base smoothly, the pace of each group company will be disrupted. To avoid this, we have been working on reviewing the system of information transmission as an important management issue.” The key word is “brand”. If all employees do not have a correct understanding of what the value of the Omron brand is, it will not be possible to convey its appeal to customers and partners. The company believed that in order to promote employees’ understanding of the brand, it was essential to reform communication involving all employees globally. Of course, Omron has been working to improve internal communication. Specifically, it has been actively disseminating information using paper-based in-house newsletters and text content on the intranet.

We want to use Video Cloud as a weapon to accelerate collaboration and open innovation both within and outside the company.

Tsutomu Igaki
Executive Officer, Global Investor & Brand Communications Headquarters, OMRON Corporation

“However, it was difficult to get the top management and employees around the world to share the same vision. We were looking for a new system to convey messages more deeply and in a timely manner to employees who directly interact with customers” (Mr. Igaki)

Using video to appeal to the emotional side of the viewer

This is why the company turned its attention to video. Omron currently uses Brightcove’s Video Cloud as an internal communication tool. By uploading video content to the cloud, they have achieved secure video distribution. Because it is compatible with multiple devices, employees can view videos on their PCs or smart devices anytime, anywhere.

Mr. Igaki cites “the ability to enhance the appeal of content” as one of the benefits of video. “Even with static content such as text and photos, you can convey who is speaking and what they are saying. But with video, you can add an emotional element. You can deliver content that appeals to the hearts and minds of viewers, including things like the strength of the voice, facial expressions, gestures, and background music” (Mr. Igaki). He thought that it would be effective in promoting understanding of intangible things like brand value, because it is easy to convey subtle nuances.

Why did they choose Video Cloud from among the many services available? In fact, Omron had previously been using satellite broadcasting to deliver video. However, in this case, they needed to have their own infrastructure, which required a considerable management cost, and because it was not possible to connect with overseas offices, they recorded the video on DVDs and mailed them out.

“With a cloud service, you can use the functions as a service without having to build your own infrastructure. We also adopted it because we valued the fact that it allows you to quickly send information both domestically and overseas, and that it supports both live streaming and on-demand viewing,” says Mr. Igaki.

Another thing that became possible after starting to use Video Cloud was the analysis of video viewing conditions. It is possible to analyze things such as the total number of accesses and which parts are being viewed in detail, so the results can be used in the production of the next content.

Mr. Igaki explains, “For example, we have found that the number of views increases when employees appear in the videos, and that we can prevent people from leaving by adjusting the timing of scene changes, so we are able to use this information to create more effective content.”

Towards an information transmission platform that seamlessly connects the inside and outside of the company

Currently, the company regularly distributes top management messages in three languages (Japanese, English and Chinese) to its bases around the world. In addition, the company also distributed a series of videos for two years from fiscal 2017, when the current medium-term management plan started, to deepen understanding of the plan’s content. Furthermore, the company holds an event on its anniversary of founding, which is positioned as a day to “return to the corporate philosophy and reflect on its spirit once again,” and the event was also broadcast live. Compared to the time when the intranet was text-based, the number of accesses to the intranet has increased significantly.

“Another reason for adopting Video Cloud was to integrate internal and external (external-facing) communications. We want to accelerate our efforts in this area in the future,” says Mr. Igaki.

In today’s world, where the technologies and know-how required for business are becoming increasingly diverse, it is becoming more difficult for a single company to provide the products and services that the market demands. The approach of promoting research and development in collaboration with multiple partners is becoming more common, and this is expanding the scope of companies with which strategic policies should be shared.

Mr. Igaki says, “We want to use Video Cloud as a weapon to accelerate collaboration and open innovation both within and outside the company.”
Omron aims to further enhance its brand value through reforming internal communication. The company’s approach using cloud services will provide important hints for many companies.

TVNZ LAUNCHES ENHANCED VIDEO ON DEMAND SERVICE

Our long-standing customer, TVNZ, is continuing its partnership with Brightcove to power its enhanced on-demand video service, TVNZ OnDemand. As New Zealand’s largest television broadcaster and a Brightcove customer since 2011, TVNZ has upgraded its service to offer viewers exclusive programs and improved playback across desktop, iOS and Android apps, and Samsung Smart TV devices.  

With Brightcove, TVNZ OnDemand now provides a more personalized viewing experience, allowing users to create their own program lists and receive tailored recommendations for additional content they might enjoy.

Since its launch in 2007, TVNZ OnDemand has seen consistent growth, reaching a record 6.3 million streams in October 2014. By the end of 2014, TVNZ reported a more than 50% year-over-year increase in viewership. With the enhanced TVNZ OnDemand service, viewers can continue enjoying their favorite content, including New Zealand’s beloved Shortland Street, The Big Bang Theory, and ONE News. The platform also introduces new exclusive content, such as special episodes of Shortland Street.

TVNZ leverages Brightcove’s advanced transcoding capabilities and built-in digital rights management (DRM) to ensure robust content protection. Additionally, our monetization features and integrations with third-party ad tech providers, such as DoubleClick, enable TVNZ to deliver seamless ad-supported video experiences across all devices.

UNDERSTANDING THE POWER OF VIDEO

“A picture is worth a thousand words” – this timeless saying is truer today than ever. With the exponential growth of data exchange in both private and business sectors, consumers increasingly seek maximum information with minimal effort. It’s no surprise, then, that videos, which tell stories at approximately 24 frames per second, have emerged as one of the most effective tools for brands to engage with their audiences.

Rather than speculate on the value of video, Brightcove partnered with the Aberdeen Group to study the return on investment (ROI) of video marketing. The findings confirm what many marketers already suspect: video is a cost-effective and impactful marketing tool. Below are some of the key insights.

BENEFITS OF VIDEO

The global average conversion rate for companies using video content is 4.8%, compared to just 2.9% for those that don’t. This means companies leveraging video need 37% fewer unique website visitors to generate the same number of leads. For example, a website without video requires 137,000 visitors to produce as many leads as a video-enabled site with just 100,000 visitors. The numbers speak for themselves.

WHY VIDEO MATTERS NOW

Video as a communication channel is not a new concept. However, the landscape has shifted as technological advancements have dramatically reduced the cost of producing high-quality videos. No longer do you need high-tech cameras and expensive equipment to create engaging content. Freelancers and small agencies can now produce professional videos on relatively modest budgets, democratizing the medium and making it more accessible to businesses of all sizes.

EASIER ROI CALCULATION

As with all marketing investments, tracking and measuring success is essential. Video marketing is no exception, and it offers unique metrics that make calculating ROI simpler. Here’s how video provides actionable insights.

  • Time-based metrics: Video has a time element, enabling brands to measure how often and how long videos are watched. If viewers watch a video through to the end, it’s a clear indicator of success. If they drop off midway, the video likely needs improvement.
  • Cross-channel reach: Video can be shared across multiple channels and its performance tracked on each platform. This versatility makes video a valuable asset. To maximize its effectiveness, brands must ensure their video content works seamlessly on PCs, smartphones, and tablets.

INVESTMENT VS ROI

Although video content creation often requires more time and upfront investment than other digital marketing assets, it delivers results that are easier to measure and evaluate. According to the Aberdeen study, top-performing companies—those in the top 20% of their industries—utilize video content 95% of the time. These companies prioritize video marketing over other forms of digital media, recognizing its superior ROI potential.

With increasing pressure on marketers to demonstrate the value of their efforts, video proves its worth by driving higher conversion rates. The diverse range of available channels also creates opportunities to engage with customers across different demographics. A successful strategy considers these varied communication channels and tailors video content accordingly.

GETTING STARTED: KEY TIPS

  • Convince decision-makers: Video creation requires an investment, so it’s essential to get leadership buy-in early. Use the compelling data from the study to highlight the advantages of video marketing for customer retention and lead generation.
  • Optimize for multiple devices: Consumers engage with brands on a variety of devices, including laptops, tablets, and smartphones. Ensure your web content is optimized for all screen sizes, considering how the viewing experience differs across devices.
  • Leverage a video management solution: Use tools like Brightcove Marketing Studio to enhance video quality and simplify workflows. There’s no point in creating perfect content if your audience can’t access or enjoy it seamlessly.

With video marketing proving its ability to engage, convert, and retain customers, now is the time to prioritize video as a core part of your marketing strategy. Start small, measure your results, and refine your approach for maximum impact. Video’s potential is limitless, and the benefits are well worth the investment.

VIDEO MOVES BUSINESS: RETAINING MOBILE CUSTOMERS

No provider can afford to limit its offerings to desktop users. Mobility defines our modern lifestyle, so you need to reach customers anytime, anywhere, on any device. But how likely is it that your target audience will engage with overcrowded, static ads on their smartphones and tablets if these ads obscure the content they want to see? The limitations of small screens can be overcome with mobile videos. By delivering high-quality visuals and sound, you can capitalize on the growing popularity of mobile video content.

Mobile videos are no longer just for kids or teenagers. Approximately 74% of German online users watch online TV and video content at least occasionally. Moreover, the number of mobile internet users in Germany continues to grow. According to the Federal Statistical Office, one in two German internet users now accesses the internet on the go. In 2013, this figure reached 29.7 million people, a 43% increase compared to 2012. Video-on-demand (VOD) is currently the fastest-growing segment of the German video market, and demand for video content on all platforms is rapidly rising, with no signs of slowing down. Forecasts predict that mobile video will account for 66% of total mobile data traffic by 2017.

Mobile video offers more than entertainment—it can significantly boost customer engagement, particularly for brands. The average click-through rate (CTR) of mobile video campaigns surged by over 265%, reaching 13.64% between Q4 2012 and Q3 2013. Additionally, nearly 40% of consumers report that video increases the likelihood of making a purchase via mobile devices.

To stay competitive, make video a core component of your mobile strategy. Position your product where today’s two biggest online trends—digital video and mobile technology—intersect. This approach ensures your message reaches a wide audience and attracts customers wherever they are.

HOW TO RECORD, UPLOAD, AND TRANSCODE VIDEO WITH WEBRTC

Video on the web continues to grow by leaps and bounds. One of the ways it’s growing can be demonstrated through WebRTC and using the APIs individually. We built a simple example of using getUserMedia to request a user’s webcam and display it in a video element. To take this a step further, let’s take that example and use it to save, then transcode content directly from the browser.

Creating a getUserMedia Example
Before we start on taking things further, let’s take a look at the initial, simpler example. All we’ll do here is request a user’s video stream, and show that in a video element on the page. We’ll be using jQuery for the more advanced example, so we’ll go ahead and start using it here.

// Do the vendor prefix dance
navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia ||
navigator.mozGetUserMedia || navigator.msGetUserMedia;

// Set up an error handler on the callback
var errCallback = function(e) {
console.log(‘Did you just reject me?!’, e);
};

// Request the user’s media
function requestMedia(e) {
e.preventDefault();

// Use the vendor prefixed getUserMedia we set up above and request just video
navigator.getUserMedia({video: true, audio: false}, showMedia, errCallback);
}

// Actually show the media
function showMedia(stream) {
var video = document.getElementById(‘user-media’);
video.src = window.URL.createObjectURL(stream);

video.onloadedmetadata = function(e) {
console.log(‘Locked and loaded.’);
};
}

// Set up a click handler to kick off the process
$(function() {
$(‘#get-user-media’).click(requestMedia);
});

Now we just need the “Get Media” button and the video element, and we’re ready to go. After clicking the button and allowing the browser access to your camera, the end result should look something like this.

simple screenshot

This demo should work Firefox, Chrome, or Opera.

Now you have access to the webcam through the browser. This example is fun but pretty useless since all we can do is show someone themselves.

Setting Up the Media Recorder
Note: As of 2014, Firefox is the only browser that’s implemented the MediaRecorder API. If you want to make this work in Chrome as well, there are projects such as RecordRTC and MediaStreamRecorder.

We need a simple server-side component for this example, but it only needs to do two things:

Return a valid AWS policy so we can upload directly from their browser
Submit an encoding job to Zencoder
We like to use the Express framework for Node with examples like this, but if you’re more comfortable using something else, like Sinatra, feel free to ignore this example and use whatever you’d like. Since we’re more concerned about the client-side code, we’re not going to dig into the server-side implementation.

var S3_BUCKET = ‘YOUR-S3-BUCKET-NAME’;

<p>var express = require(‘express’);
var path = require(‘path’);
var logger = require(‘morgan’);
var bodyParser = require(‘body-parser’);
var crypto = require(‘crypto’);
var moment = require(‘moment’);
var AWS = require(‘aws-sdk’);
var s3 = new AWS.S3({ params: { Bucket: S3_BUCKET }});
var zencoder = require(‘zencoder’)();

var app = express();

app.set(‘port’, process.env.PORT || 3000);
app.use(logger(‘dev’));
app.use(bodyParser.json());
app.use(bodyParser.urlencoded());
app.use(express.static(path.join(__dirname, ‘public’)));

app.post(‘/process’, function(req, res) {
// Build up the S3 URL based on the specified S3 Bucket and filename included
// in the POST request body.
var input = ‘https://’+S3_BUCKET+’.s3.amazonaws.com/’+req.body.filename;
createJob(input, req.body.email, function(err, data) {
if (err) { return res.send(500, err); }

res.send(200, data);

});
});

app.post(‘/upload’, function(req, res) {
var cors = createS3Policy();
res.send(201, { url: ‘https://’+S3_BUCKET+’.s3.amazonaws.com/’, cors: cors });
});

function createS3Policy() {
var policy = {
“expiration”: moment().utc().add(‘days’, 1).toISOString(),
“conditions”: [
{ “bucket”: S3_BUCKET },
{ “acl”:”private” },
[ “starts-with”, “$key”, “” ],
[ “starts-with”, “$Content-Type”, “” ],
[ “content-length-range”, 0, 5368709120 ]
]
};

var base64Policy = new Buffer(JSON.stringify(policy)).toString(‘base64’);
var signature = crypto.createHmac(‘sha1’, AWS.config.credentials.secretAccessKey).update(base64Policy).digest(‘base64’);

return {
key: AWS.config.credentials.accessKeyId,
policy: base64Policy,
signature: signature
};
}

function createJob(input, email, cb) {
var watermark = {
url: ‘https://s3.amazonaws.com/zencoder-demo/blog-posts/videobooth.png’,
x: ‘-0’,
y: ‘-0’,
width: ‘30%’
};

zencoder.Job.create({
input: input,
notifications: [ email ],
outputs: [
{ format: ‘mp4’, watermarks: [watermark] },
{ format: ‘webm’, watermarks: [watermark] }
]
}, cb);
}

var server = app.listen(app.get(‘port’), function() {
console.log(‘Express server listening on port ‘ + server.address().port);
});

This example should mostly work out-of-the-box, but you’ll need to have AWS configurations already set up, as well as a ZENCODER_API_KEY\ environment variable. You’ll also need to have CORS configured on the bucket you use. Here’s an example CORS configuration that will work:

<?xml version=”1.0″ encoding=”UTF-8″?> <CORSConfiguration xmlns=”http://s3.amazonaws.com/doc/2006-03-01/”> <CORSRule> <AllowedOrigin>\*</AllowedOrigin> <AllowedMethod>POST</AllowedMethod> <AllowedHeader>\*</AllowedHeader> </CORSRule> </CORSConfiguration>

Recording User Media
In the simple example above, we requested a user’s media using the getUserMedia API, so now we need a way to record that content. Luckily, there’s an API called MediaRecorder. Firefox is the only browser that currently supports it (as of version 25), but there are projects like Whammy that can act as a pseudo-shim for other browsers.

The API is simple. We just need to take the same stream we used for playback in the previous example, and use it to create a new instance of MediaRecorder. Once we have our new recorder, all we have to do is call start() to begin recording, and stop() to stop.

var recorder = new MediaRecorder(this.stream);
recorder.start(); // You’re now recording!
// …A few seconds later…
recorder.stop();

Getting the Recorded Media
Ok, we started and stopped a webcam recording. Now how do we see it?

You can listen for the ondataavailable event on the instance of MediaRecorder we created to record. When it’s done, it will include a new Blob that you can play back just like you did the original user media.

// We’ll keep using the same recorder
recorder.ondataavailable = function(e) {
var videoBlob = new Blob([e.data], { type: e.data.type });
var player = document.getElementById(‘playback-video-el’);
var blobUrl = URL.createObjectURL(videoBlob);
player.src = blobUrl;
player.play();
}

If you’ve been following along and building out these examples, right about now you’re probably trying to replay the video and getting frustrated. Sadly, nothing you do “right” is going to work here. Using autoplay on the video element nor calling play() or setting currentTime on the ended event is going to do what you want.

This seems to simply be a Firefox issue with playing back these blobs. The functional workaround is to simply replace the source on the ended event if you want the video to loop.

player.onended = function() {
video.pause();
video.src = blobUrl;
video.play();
}

This blob you have is a (mostly) functional WebM video. If you create an anchor tag with this blob url as the source, you can right click and save the file locally. However, even locally, this file doesn’t behave quite right (OS X seems to think it’s an HTML file).

This is where Zencoder fits nicely into the picture. Before we can process it, we need to get the file online so Zencoder can access it. We’ll use one of the API endpoints we created earlier, /upload to grab a signed policy, then use that to POST the file directly to S3 (I’m using jQuery in this example).

function uploadVideo(video) {
$.post(‘/upload’, { key: “myawesomerecording.webm” }).done(function(data) {
// The API endpoint we created returns a URL, plus a cors object with a key, policy, and signature.
formUpload(data.url, data.cors.key, data.cors.policy, data.cors.signature, filename, recording);
});

function formUpload(url, accessKey, policy, signature, filename, video) {
var fd = new FormData();</p>

fd.append(‘key’, filename);
fd.append(‘AWSAccessKeyId’, accessKey);
fd.append(‘acl’, ‘private’);
fd.append(‘policy’, policy);
fd.append(‘signature’, signature);
fd.append(‘Content-Type’, “video/webm”);
fd.append(“file”, video);

$.ajax({
type: ‘POST’,
url: url,
data: fd,
processData: false,
contentType: false
}).done(function(data) {
cb(null);
}).fail(function(jqxhr, status, err) {
cb(err);
});
}
}

uploadVideo(videoBlob);

Now you’ve got a video on an S3 bucket, so all we have to do is actually process it. If you noticed, we added an email to the /process endpoint earlier so we can get the job notification (including download links for the video) sent directly to us when it’s done.

function process(email, filename) {
$.post(‘/process’, {
filename: filename,
email: email
}).done(function(data) {
console.log(‘All done! you should get an email soon.’);
}).fail(function(jqXHR, error, data) {
console.log(‘Awww…sad…something went wrong’);
});
};

process(‘[email protected]’, “myawesomerecording.webm”);

A few seconds later, you should get an email congratulating you for your brand new, browser-recorded videos. The links included are temporary, so make sure you download them within 24 hours or change the API endpoint we created to upload the outputs to a bucket you own.

We’ve created a demo to showcase this functionality, including some minor styling and a not-so-fancy interface. It’s called VideoBooth, but feel free to clone the project and run with it. You can also play with the working demo on Heroku.

videobooth screenshot

REDUNDANT TRANSCODING FOR LIVE STREAMING

From a reliability perspective, one of the great things about VOD transcoding is the ability to simply try again. If anything goes wrong during the transcoding process, we can simply re-run the process from the beginning. The worst effect of a hiccup is a job takes a little longer, which is unfortunate, but the end result is a transcoded file is delivered to the customer and all is well.

During a live event, however, we don’t have the luxury of simply trying again. Since these events are transcoded in real-time, we only have one chance to deliver a perfect transcode to end-users; a blip anywhere along the way can mean an interruption. No matter how reliable the system is, you never know when something like a power supply or network card is going to fail, so redundancy is crucial for high profile events.

To account for this, we announced redundant transcoding for live streams. In a nutshell, if redundant_transcode is enabled, and at least one secondary_url is specified, Zencoder will transparently create a new job using any secondary URLs specified in the outputs of the original request. This job has all the same settings of the original, with the important distinction of being run in the nearest transcoding region of an entirely different cloud provider.

Let’s look at an example:

{
  "redundant_transcode": true,
  "live_stream": true,
  "region": "us-virginia",
  "output": [
    {
      "label": "super-important-stream",
      "url": "rtmp://primary.example.com/live/stream",
      "secondary_url": "rtmp://backup.example.com/live/stream",
      "live_stream": true
    },
    {
      "label": "not-as-important-stream",
      "url": "rtmp://primary.example.com/live/stream",
      "live_stream": true
    }
  ]
}

 

This will return one stream name, but two stream URLs: one primary and one redundant.

{
  "stream_name": "as230d982389askdfsdkjf2380ejd93d93dj",
  "outputs": [
    {
      "label": "super-important-stream",
      "url": "rtmp://primary.example.com/live/stream",
      "id": 260281679
    },
    {
      "label": "not-as-important-stream",
      "url": "rtmp://primary.example.com/live/stream",
      "id": 260281680
    }
  ],
  "stream_url": "rtmp://live01.us-va.zencoder.io:1935/live",
  "redundant_job_id": 12345678,
  "redundant_stream_url": "rtmp://backup-endpoint.zencoder.io:1935/live",
  "id": 98091238
}

 

You can then set up your encoder to stream to both simultaneously. The example below is using Flash Media Live Encoder, but most encoders support a primary and backup stream url with little additional setup.

Flash Media Live Encoder screenshot

With this setup, if Amazon East were to go down, the backup stream would continue happily on Google Compute Engine without any problems. Assuming you’re using a CDN with proper backup urls, such as Akamai, the playback URLs would continue to work as if nothing happened.

For simplicity sake, we only discussed adding a backup URL to a single encoder. This would mitigate any issues downstream of the encoder, but the stream is still at risk if the encoder is unable to publish for any reason. The backup URL, however, could be set up on a separate encoder, which could be on an entirely different network to be as safe as possible.

Notes

  • Since a stream needs to be pushed to both the primary and backup endpoint, this will double the bandwidth necessary to publish a stream.
  • The backup job is billed as a separate job at standard live rates.
  • Akamai will attempt to align the primary and backup streams before playback, so there may be a short interruption during the transition between streams.