Has anyone had any success recompiling this for Linux? On UE 4.27, the built in Clang 11 compiler only throws up 18 errors on /ffx-fsr2-api/ffx_fsr2.cpp and 2 errors on /ffx-fsr2-api/vk/ffx_fsr2_vk.cpp.
I reduced ffx_fsr2.cpp’s 18 errors down to 4 by replacing every wscpy_s with a wscpy.
Here’s the problem code in ffx_fsr2.cpp. No matter how I rearrange it, it keeps saying the {} brackets are in the wrong place.
const float matrix_elem_c[2][2] = {
{{fQ,}} // non reversed, non infinite
-1.0f - FLT_EPSILON, // non reversed, infinite
{{fQ,}} // reversed, non infinite
0.0f + FLT_EPSILON // reversed, infinite
};
const float matrix_elem_e[2][2] = {
{{fQ * fMin,}} // non reversed, non infinite
-fMin - FLT_EPSILON, // non reversed, infinite
{{fQ * fMin,}} // reversed, non infinite
fMax, // reversed, infinite
};
The other problem is "Source/ffx-fsr2-api/vk/ffx_fsr2_vk.cpp:1329:5: error: no template named ‘wstring_convert’ in namespace ‘std’; did you mean ‘TStringConvert’?
std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>> converter;
So I tried TStringConvert instead of std::wstring_convert and clang had no idea what I was talking about. (Hell, I had no idea what I was trying to tell it either!)
“error: too few template arguments for class template ‘TStringConvert’
TStringConvert<std::codecvt_utf8_utf16<wchar_t>> converter;”
Not knowing a lot about C++ doesn’t help. Being on vsCode without intellisense doesn’t help either. From what I understand, the clang and gcc compilers handle certain commands differently from windows compilers. If someone could help me fix these 2 errors, I can build FSR 2 for Linux! Thanks in advance!