VideoSW: Clear normal vertex data.

This data might not be initialized but used for lighting.
This matches our ShaderGen usage in VertexShaderGen.cpp:166.
This commit is contained in:
degasus 2015-12-19 10:51:42 +01:00
parent e638775bc7
commit 5e9ab28ed1

View file

@ -196,6 +196,7 @@ void SWVertexLoader::LoadVertex()
// transform this vertex so that it can be used for rasterization (outVertex)
OutputVertexData* outVertex = m_SetupUnit->GetVertex();
TransformUnit::TransformPosition(&m_Vertex, outVertex);
memset(&outVertex->normal, 0, sizeof(outVertex->normal));
if (g_main_cp_state.vtx_desc.Normal != NOT_PRESENT)
{
TransformUnit::TransformNormal(&m_Vertex, m_CurrentVat->g0.NormalElements, outVertex);