First release
This commit is contained in:
commit
fa6c85266e
2339 changed files with 761050 additions and 0 deletions
16
node_modules/@videojs/vhs-utils/es/decode-b64-to-uint8-array.js
generated
vendored
Normal file
16
node_modules/@videojs/vhs-utils/es/decode-b64-to-uint8-array.js
generated
vendored
Normal file
|
@ -0,0 +1,16 @@
|
|||
import window from 'global/window';
|
||||
|
||||
var atob = function atob(s) {
|
||||
return window.atob ? window.atob(s) : Buffer.from(s, 'base64').toString('binary');
|
||||
};
|
||||
|
||||
export default function decodeB64ToUint8Array(b64Text) {
|
||||
var decodedString = atob(b64Text);
|
||||
var array = new Uint8Array(decodedString.length);
|
||||
|
||||
for (var i = 0; i < decodedString.length; i++) {
|
||||
array[i] = decodedString.charCodeAt(i);
|
||||
}
|
||||
|
||||
return array;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue