mirror of
https://github.com/AxioDL/PrimeWorldEditor.git
synced 2025-12-16 08:27:01 +00:00
Bunch of backend rendering reshuffling; getting rid of DrawAsset, adding convenience functions, renaming some things
This commit is contained in:
@@ -45,7 +45,7 @@ void CGraphics::Initialize()
|
||||
mpPixelBlockBuffer = new CUniformBuffer(sizeof(sPixelBlock));
|
||||
mpLightBlockBuffer = new CUniformBuffer(sizeof(sLightBlock));
|
||||
|
||||
sLightMode = WorldLighting;
|
||||
sLightMode = eWorldLighting;
|
||||
sNumLights = 0;
|
||||
sWorldLightMultiplier = 1.f;
|
||||
|
||||
@@ -162,6 +162,14 @@ void CGraphics::SetDefaultLighting()
|
||||
UpdateVertexBlock();
|
||||
}
|
||||
|
||||
void CGraphics::SetupAmbientColor()
|
||||
{
|
||||
if (sLightMode == eWorldLighting)
|
||||
sVertexBlock.COLOR0_Amb = sAreaAmbientColor.ToVector4f() * sWorldLightMultiplier;
|
||||
else
|
||||
sVertexBlock.COLOR0_Amb = skDefaultAmbientColor.ToVector4f();
|
||||
}
|
||||
|
||||
void CGraphics::SetIdentityMVP()
|
||||
{
|
||||
sMVPBlock.ModelMatrix = CMatrix4f::skIdentity;
|
||||
|
||||
Reference in New Issue
Block a user