libtransistor
A userland library for the Nintendo Switch
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
Typedefs | Functions
encoding.h File Reference

String encoding functions Based on https://github.com/nothings/stb. More...

#include <stdint.h>
#include <string.h>
Include dependency graph for encoding.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef uint16_t trn_char16_t
 

Functions

trn_char16_t * trn_utf8_to_utf16 (trn_char16_t *out, const char *in, size_t n)
 Converts a UTF-8 string to UTF-16 Writes at most n characters to out, returning NULL if there is an error.
 
char * trn_utf16_to_utf8 (char *out, const trn_char16_t *in, size_t n)
 Converts a UTF-16 string to UTF-8 Writes at most n characters to out, returning NULL if there is an error.
 

Detailed Description

String encoding functions Based on https://github.com/nothings/stb.