We're developing an embeddable browser and at the moment we're in the process of adding MSE support (specifically targeting YouTube embedded videos, in order to be able to play higher quality videos).
We currently only support WebM (VP8/VP9 + vorbis) encoded videos. One of the issues we are facing right now is that YouTube refuses to serve us WebM videos and just falls back to non-MSE playback in most cases. This is an example of a video which is being served to us using MSE in WebM format. We are returning true
to all video/webm
and audio/webm
(except opus) isTypeSupported
calls.
How can we get YouTube to serve us WebM videos whenever possible? The way we're testing at the moment is either by directly opening a video through the YouTube website or by using an page which contains a single iframe
for the video:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>MSE Demo</title>
</head>
<body>
<iframe width="560" height="315" src="https://www.youtube.com/embed/YQKgBmb2WoU" frameborder="0" allowfullscreen></iframe>
</body>
</html>
This is the user agent we are currently identifying as:
Mozilla/5.0 (Windows NT 6.2; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.86 Safari/537.36