Minor: Ajout Light Shader
This commit is contained in:
parent
d286e71ebe
commit
1bba2047b1
@ -1027,19 +1027,19 @@ bool ApplicationClass::Render(float rotation, float x, float y, float z, float t
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
//// Setup matrices.
|
// Setup matrices.
|
||||||
//rotateMatrix = XMMatrixRotationY(rotation);
|
rotateMatrix = XMMatrixRotationY(rotation);
|
||||||
//translateMatrix = XMMatrixTranslation(-10.0f, -2.0f, -20.0f);
|
translateMatrix = XMMatrixTranslation(-10.0f, -2.0f, -20.0f);
|
||||||
//worldMatrix = XMMatrixMultiply(rotateMatrix, translateMatrix);
|
worldMatrix = XMMatrixMultiply(rotateMatrix, translateMatrix);
|
||||||
|
|
||||||
// Render the model using the transparent shader.
|
// Render the model using the transparent shader.
|
||||||
//m_Model->Render(m_Direct3D->GetDeviceContext());
|
m_Model->Render(m_Direct3D->GetDeviceContext());
|
||||||
|
|
||||||
//result = m_ShaderManager->RenderlightShader(m_Direct3D->GetDeviceContext(), m_Model->GetIndexCount(), worldMatrix, viewMatrix, projectionMatrix, m_Model->GetTexture(0), m_Lights[0]->GetDiffuseColor(), m_Lights[0]->GetPosition());
|
result = m_ShaderManager->RenderlightShader(m_Direct3D->GetDeviceContext(), m_Model->GetIndexCount(), worldMatrix, viewMatrix, projectionMatrix, m_Model->GetTexture(0), diffuseColor, lightPosition);
|
||||||
//if (!result)
|
if (!result)
|
||||||
//{
|
{
|
||||||
// return false;
|
return false;
|
||||||
//}
|
}
|
||||||
|
|
||||||
// Turn off alpha blending.
|
// Turn off alpha blending.
|
||||||
m_Direct3D->DisableAlphaBlending();
|
m_Direct3D->DisableAlphaBlending();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user