cleanup
This commit is contained in:
@@ -57,12 +57,6 @@ void psxsplash::Renderer::SetFog(const FogConfig& fog) {
|
||||
}
|
||||
}
|
||||
|
||||
void psxsplash::Renderer::writeFogRegisters() {
|
||||
// Per-vertex fog is now computed manually in processTriangle (no DPCT).
|
||||
// DQA/DQB/RFC/GFC/BFC are no longer needed for fog.
|
||||
// The fog color is used directly via m_fog.color in the fogBlend function.
|
||||
}
|
||||
|
||||
psyqo::Vec3 psxsplash::Renderer::computeCameraViewPos() {
|
||||
::clear<Register::TRX, Safe>();
|
||||
::clear<Register::TRY, Safe>();
|
||||
@@ -270,7 +264,7 @@ void psxsplash::Renderer::Render(eastl::vector<GameObject*>& objects) {
|
||||
auto& ditherCmd = balloc.allocateFragment<psyqo::Prim::TPage>();
|
||||
ditherCmd.primitive.attr.setDithering(true);
|
||||
ot.insert(ditherCmd, ORDERING_TABLE_SIZE - 1);
|
||||
writeFogRegisters();
|
||||
|
||||
psyqo::Vec3 cameraPosition = computeCameraViewPos();
|
||||
int32_t fogFarSZ = m_fog.fogFarSZ;
|
||||
for (auto& obj : objects) {
|
||||
@@ -301,7 +295,7 @@ void psxsplash::Renderer::RenderWithBVH(eastl::vector<GameObject*>& objects, con
|
||||
auto& ditherCmd2 = balloc.allocateFragment<psyqo::Prim::TPage>();
|
||||
ditherCmd2.primitive.attr.setDithering(true);
|
||||
ot.insert(ditherCmd2, ORDERING_TABLE_SIZE - 1);
|
||||
writeFogRegisters();
|
||||
|
||||
Frustum frustum; m_currentCamera->ExtractFrustum(frustum);
|
||||
int visibleCount = bvh.cullFrustum(frustum, m_visibleRefs, MAX_VISIBLE_TRIANGLES);
|
||||
psyqo::Vec3 cameraPosition = computeCameraViewPos();
|
||||
@@ -510,7 +504,7 @@ void psxsplash::Renderer::RenderWithRooms(eastl::vector<GameObject*>& objects,
|
||||
auto& ditherCmd3 = balloc.allocateFragment<psyqo::Prim::TPage>();
|
||||
ditherCmd3.primitive.attr.setDithering(true);
|
||||
ot.insert(ditherCmd3, ORDERING_TABLE_SIZE - 1);
|
||||
writeFogRegisters();
|
||||
|
||||
psyqo::Vec3 cameraPosition = computeCameraViewPos();
|
||||
int32_t fogFarSZ = m_fog.fogFarSZ;
|
||||
int32_t camX = m_currentCamera->GetPosition().x.raw();
|
||||
|
||||
Reference in New Issue
Block a user