mirror of
https://github.com/PabloMK7/citra.git
synced 2025-11-03 07:08:48 +00:00
code: Use std::span where appropriate (#6658)
* code: Use std::span when possible * code: Prefix memcpy and memcmp with std::
This commit is contained in:
parent
4ccd9f24fb
commit
cf9bb90ae3
106 changed files with 362 additions and 329 deletions
|
|
@ -226,7 +226,7 @@ void DumpShader(const std::string& filename, const ShaderRegs& config,
|
|||
std::vector<nihstro::ConstantInfo> constant_table;
|
||||
for (unsigned i = 0; i < setup.uniforms.b.size(); ++i) {
|
||||
nihstro::ConstantInfo constant;
|
||||
memset(&constant, 0, sizeof(constant));
|
||||
std::memset(&constant, 0, sizeof(constant));
|
||||
constant.type = nihstro::ConstantInfo::Bool;
|
||||
constant.regid = i;
|
||||
constant.b = setup.uniforms.b[i];
|
||||
|
|
@ -234,7 +234,7 @@ void DumpShader(const std::string& filename, const ShaderRegs& config,
|
|||
}
|
||||
for (unsigned i = 0; i < setup.uniforms.i.size(); ++i) {
|
||||
nihstro::ConstantInfo constant;
|
||||
memset(&constant, 0, sizeof(constant));
|
||||
std::memset(&constant, 0, sizeof(constant));
|
||||
constant.type = nihstro::ConstantInfo::Int;
|
||||
constant.regid = i;
|
||||
constant.i.x = setup.uniforms.i[i].x;
|
||||
|
|
@ -245,7 +245,7 @@ void DumpShader(const std::string& filename, const ShaderRegs& config,
|
|||
}
|
||||
for (unsigned i = 0; i < sizeof(setup.uniforms.f) / sizeof(setup.uniforms.f[0]); ++i) {
|
||||
nihstro::ConstantInfo constant;
|
||||
memset(&constant, 0, sizeof(constant));
|
||||
std::memset(&constant, 0, sizeof(constant));
|
||||
constant.type = nihstro::ConstantInfo::Float;
|
||||
constant.regid = i;
|
||||
constant.f.x = nihstro::to_float24(setup.uniforms.f[i].x.ToFloat32());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue