MCPcopy Create free account
hub / github.com/microsoft/SandDance / encodeChunk

Function encodeChunk

docs/tests/v2/es6/js/sanddance.js:78227–78238  ·  view source on GitHub ↗
(uint8, start, end)

Source from the content-addressed store, hash-verified

78225}
78226
78227function encodeChunk (uint8, start, end) {
78228 var tmp
78229 var output = []
78230 for (var i = start; i < end; i += 3) {
78231 tmp =
78232 ((uint8[i] << 16) & 0xFF0000) +
78233 ((uint8[i + 1] << 8) & 0xFF00) +
78234 (uint8[i + 2] & 0xFF)
78235 output.push(tripletToBase64(tmp))
78236 }
78237 return output.join('')
78238}
78239
78240function fromByteArray (uint8) {
78241 var tmp

Callers 1

fromByteArrayFunction · 0.70

Calls 1

tripletToBase64Function · 0.70

Tested by

no test coverage detected