ddat interop with dat js cable interop with cabal js ddat's frontend = dat-thang cable fe = cable-thang dillo support based on cel's dillo-dat bootstrap node xplatform support Signed-off-by: divo <418@cryspace.space>
18 lines
603 B
C
18 lines
603 B
C
#ifndef BASE32768_H
|
|
#define BASE32768_H
|
|
|
|
#include <stddef.h>
|
|
#include <stdint.h>
|
|
|
|
/* UTF-8 C-string form of qntm/base32768's BMP-safe Base32768 encoding. */
|
|
int base32768_encode(const uint8_t *input, size_t input_length,
|
|
char *output, size_t output_capacity);
|
|
int base32768_decode(const char *input, uint8_t *output,
|
|
size_t output_capacity, size_t *output_length);
|
|
|
|
/* Enumerate the alphabet: bits=15 selects the 32,768 main characters;
|
|
* bits=7 selects the 128 possible final padding characters. */
|
|
int base32768_codepoint_at(unsigned bits, uint32_t index, uint32_t *codepoint);
|
|
|
|
#endif
|