diff --git a/Source/Core/VideoCommon/GeometryShaderManager.cpp b/Source/Core/VideoCommon/GeometryShaderManager.cpp index 1bb841459d..8a687d70d0 100644 --- a/Source/Core/VideoCommon/GeometryShaderManager.cpp +++ b/Source/Core/VideoCommon/GeometryShaderManager.cpp @@ -21,7 +21,7 @@ static bool s_viewport_changed; void GeometryShaderManager::Init() { - memset(&constants, 0, sizeof(constants)); + constants = {}; // Init any intial constants which aren't zero when bpmem is zero. SetViewportChanged(); diff --git a/Source/Core/VideoCommon/PixelShaderManager.cpp b/Source/Core/VideoCommon/PixelShaderManager.cpp index 0560ecc60a..f029751363 100644 --- a/Source/Core/VideoCommon/PixelShaderManager.cpp +++ b/Source/Core/VideoCommon/PixelShaderManager.cpp @@ -21,7 +21,7 @@ bool PixelShaderManager::dirty; void PixelShaderManager::Init() { - memset(&constants, 0, sizeof(constants)); + constants = {}; // Init any intial constants which aren't zero when bpmem is zero. s_bFogRangeAdjustChanged = true; diff --git a/Source/Core/VideoCommon/VertexShaderManager.cpp b/Source/Core/VideoCommon/VertexShaderManager.cpp index aa7ea1c2a6..c7331fe446 100644 --- a/Source/Core/VideoCommon/VertexShaderManager.cpp +++ b/Source/Core/VideoCommon/VertexShaderManager.cpp @@ -203,8 +203,8 @@ void VertexShaderManager::Init() bProjectionChanged = true; bViewportChanged = false; - memset(&xfmem, 0, sizeof(xfmem)); - memset(&constants, 0, sizeof(constants)); + xfmem = {}; + constants = {}; ResetView(); // TODO: should these go inside ResetView()?