C11 and C++11 both introduce the uchar.h/cuchar header defining char16_t and char32_t as explicitly 16 and 32 bit wide charac
uchar.h
cuchar
char16_t
char32_t
Sounds like you're looking for the std::codecvt type. See the example on that page for usage.