initial commits

master
Charles Iliya Krempeaux 2023-10-27 13:39:11 -07:00
parent edc45e6409
commit fb7e711cd9
1 changed files with 5 additions and 6 deletions

View File

@ -1,15 +1,14 @@
package hexadeca
package hexadecarunes
import (
"sourcecode.social/reiver/go-hexadeca/enc/runes"
"sourcecode.social/reiver/go-hexadeca/symbols/rune"
)
func EncodeUint32(value uint32, symbolFunc func(byte)rune) (r7 rune, r6 rune, r5 rune, r4 rune, r3 rune, r2 rune, r1 rune, r0 rune) {
r7, r6 = hexadecarunes.EncodeByte(byte(0x000000ff & (value >> (8 * 3))), symbolFunc)
r5, r4 = hexadecarunes.EncodeByte(byte(0x000000ff & (value >> (8 * 2))), symbolFunc)
r3, r2 = hexadecarunes.EncodeByte(byte(0x000000ff & (value >> (8 ))), symbolFunc)
r1, r0 = hexadecarunes.EncodeByte(byte(0x000000ff & value ), symbolFunc)
r7, r6 = EncodeByte(byte(0x000000ff & (value >> (8 * 3))), symbolFunc)
r5, r4 = EncodeByte(byte(0x000000ff & (value >> (8 * 2))), symbolFunc)
r3, r2 = EncodeByte(byte(0x000000ff & (value >> (8 ))), symbolFunc)
r1, r0 = EncodeByte(byte(0x000000ff & value ), symbolFunc)
return
}