rsx: Code cleanup. Fixes several dozen warnings

- Wrap unused parameters as comments to prevent C1400
- Fix sized variable conversions with explicit casts
This commit is contained in:
kd-11 2017-06-18 17:53:02 +03:00
parent 11317acdbe
commit b2e906f4cc
32 changed files with 121 additions and 99 deletions

View file

@ -106,7 +106,7 @@ std::string compareFunctionImp(COMPARE f, const std::string &Op0, const std::str
}
}
void insert_d3d12_legacy_function(std::ostream& OS)
void insert_d3d12_legacy_function(std::ostream& OS, bool is_fragment_program)
{
OS << "float4 lit_legacy(float4 val)";
OS << "{\n";
@ -121,6 +121,9 @@ void insert_d3d12_legacy_function(std::ostream& OS)
OS << " return result;\n";
OS << "}\n\n";
if (!is_fragment_program)
return;
OS << "uint packSnorm2x16(float2 val)";
OS << "{\n";
OS << " uint high_bits = round(clamp(val.x, -1., 1.) * 32767.);\n";