fix(techset): write complete Direct3D 9 shader bytecode (#1004)

* fix(techset): write Direct3D 9 shader bytecode bounds

* chore: extract shader dumping tests into separate sections

---------

Co-authored-by: Jan Laupetin <[email protected]>
This commit is contained in:
LVEIceFire
2026-09-20 23:57:33 +02:00
committed by GitHub
co-authored by Jan Laupetin
parent 6ca37c43fa
commit 2547516e39
3 changed files with 55 additions and 2 deletions
@@ -64,7 +64,7 @@ namespace
shaderFile->write(pixelShader.prog.loadDef.program, pixelShader.prog.loadDef.programSize);
#else
shaderFile->write(reinterpret_cast<const char*>(pixelShader.prog.loadDef.program),
static_cast<std::streamsize>(pixelShader.prog.loadDef.programSize) * sizeof(GfxPixelShaderLoadDef::program));
static_cast<std::streamsize>(pixelShader.prog.loadDef.programSize) * sizeof(*pixelShader.prog.loadDef.program));
#endif
}
@@ -79,7 +79,7 @@ namespace
shaderFile->write(vertexShader.prog.loadDef.program, vertexShader.prog.loadDef.programSize);
#else
shaderFile->write(reinterpret_cast<const char*>(vertexShader.prog.loadDef.program),
static_cast<std::streamsize>(vertexShader.prog.loadDef.programSize) * sizeof(GfxVertexShaderLoadDef::program));
static_cast<std::streamsize>(vertexShader.prog.loadDef.programSize) * sizeof(*vertexShader.prog.loadDef.program));
#endif
}