mirror of
https://github.com/AxioDL/PrimeWorldEditor.git
synced 2025-06-02 20:51:29 +00:00
Skybox rendering bugfix (model matrix wasn't being set properly so the skybox was drawing with the old model matrix, which was the XYZ overlay one)
This commit is contained in:
parent
89c1654b6a
commit
2690e79f95
@ -257,7 +257,6 @@ void CRenderer::RenderSky(CModel *pSkyboxModel, CCamera& Camera)
|
||||
if (!pSkyboxModel) return;
|
||||
|
||||
glEnable(GL_CULL_FACE);
|
||||
Camera.LoadRotationOnlyMatrices();
|
||||
|
||||
CGraphics::sMVPBlock.ModelMatrix = CMatrix4f::skIdentity;
|
||||
CGraphics::sVertexBlock.COLOR0_Amb = CVector4f(1.f, 1.f, 1.f, 1.f);
|
||||
@ -266,6 +265,7 @@ void CRenderer::RenderSky(CModel *pSkyboxModel, CCamera& Camera)
|
||||
CGraphics::UpdateVertexBlock();
|
||||
CGraphics::UpdatePixelBlock();
|
||||
CGraphics::UpdateLightBlock();
|
||||
Camera.LoadRotationOnlyMatrices();
|
||||
|
||||
glDepthRange(1.f, 1.f);
|
||||
pSkyboxModel->Draw(mOptions, 0);
|
||||
|
Loading…
x
Reference in New Issue
Block a user