One small problem arose, when I do like this, then everything is fine:
std::cout << std::filesystem::current_path().parent_path().append("Resources").append("Shaders").string().c_str() << std::endl; In this case, the correct path is displayed, but as soon as I do this:
std::filesystem::path path = std::filesystem::current_path().parent_path().append("Resources").append("Shaders"); const char* shadersPath = path.string().c_str(); // ΠΈΠ»ΠΈ u8string().c_str() std::cout << shadersPath << std::endl; As a result, I get a problem with the encoding:
ββββββββββββββββββββββββββββββββββββββββββββββββββ ββββββββββββββββββββββββββββββββββ K
What could be the problem? I need to get exactly C string in ANSI or UTF-8
path.string()? - VTTMultibyteToWideCharfunction. Then to print convert the path back to wchar_t - VTT