My propose is draw video frame to canvas and draw thing else on canvas. I have test it success in video link without Widevine.
var canvas = document.getElementById("canvasDraw");
canvas.style.width = 1280;
canvas.style.height = 720;
var context = canvas.getContext('2d');
var video = document.getElementById('video');
function draw() {
context.drawImage(video, 0, 0, 1280, 720);
setTimeout(draw, 1000 / 30);
}
video.onplay = function () {
setTimeout(draw, 1000 / 30);
}
But when I using widevine drm the frame came out is black but the audio is still playing.
Can someone help me with this ?
This is the widevine link I get from shaka-player demo
https://storage.googleapis.com/shaka-demo-assets/sintel-widevine/dash.mpd