MCPcopy Create free account
hub / github.com/Monibuca/engine / PutBE

Function PutBE

util/big_endian.go:7–12  ·  view source on GitHub ↗
(b []byte, num T)

Source from the content-addressed store, hash-verified

5}
6
7func PutBE[T Integer](b []byte, num T) []byte {
8 for i, n := 0, len(b); i < n; i++ {
9 b[i] = byte(num >> ((n - i - 1) << 3))
10 }
11 return b
12}
13
14func ReadBE[T Integer](b []byte) (num T) {
15 num = 0

Callers 8

PlayBlockMethod · 0.92
CompleteAVCCMethod · 0.92
CompleteAVCCMethod · 0.92
AVCC2FLVFunction · 0.92
WritePMTPacketFunction · 0.92
WriteFloat64Method · 0.85
WriteUint24Method · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected