Created
February 23, 2024 13:35
-
-
Save argentinaluiz/371eb710b650a88f70d1daf85e50c785 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<link href="https://unpkg.com/[email protected]/dist/video-js.min.css" rel="stylesheet" /> | |
<script src="https://unpkg.com/[email protected]/dist/video.min.js"></script> | |
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/videojs-contrib-eme.min.js"></script> | |
<script src="/uaparser.min.js"></script> | |
<script> | |
/* var userAgent = new UAParser(); | |
alert(JSON.stringify(userAgent.getBrowser())); */ | |
</script> | |
<style type="text/css"> | |
.vjs-matrix.video-js { | |
color: #fcca50; | |
} | |
/* Change the border of the big play button. */ | |
.vjs-matrix .vjs-big-play-button { | |
border-color: #fcca50; | |
} | |
/* Change the color of various "bars". */ | |
.vjs-matrix .vjs-volume-level, | |
.vjs-matrix .vjs-play-progress, | |
.vjs-matrix .vjs-slider-bar { | |
background: #fcca50; | |
} | |
</style> | |
</head> | |
<body> | |
<video | |
id="player" | |
class="video-js vjs-matrix vjs-default-skin vjs-big-play-centered" | |
style="height: 100%; width: 100%" | |
controls | |
preload="auto" | |
></video> | |
<script type="text/javascript"> | |
var video = videojs("player", { | |
playbackRates: [0.5, 1, 1.5, 2], | |
autoplay: true | |
}); | |
video.eme(); | |
video.src([ | |
{ | |
src: | |
"https://s3.amazonaws.com/drmsonus/code/fullcycle/devops_20/01/01_introducao.mp4/stream.mpd", | |
type: "application/dash+xml", | |
keySystems: { | |
"com.widevine.alpha": { | |
audioRobustness: 'SW_SECURE_CRYPTO', | |
videoRobustness: 'SW_SECURE_CRYPTO', | |
url: "https://widevine-dash.ezdrm.com/widevine-php/widevine-foreignkey.php?pX=AC398C&customdata=MTQ0OmFyZ2VudGluYWx1aXpAZ21haWwuY29tOjY3MTE6Y291cnNlOmNvZGU=", | |
} | |
}, | |
}, | |
]); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment