Skip to content

Commit

Permalink
Fix regression
Browse files Browse the repository at this point in the history
Scroll attenuation seems to disable ambient fog. If scroll attenuation is enabled it's telling the h/w to draw the real3d spot light on fog for the scroll fog layer. This should fix a regression where the background disappears on sega rally.
  • Loading branch information
dukeeeey committed Nov 9, 2023
1 parent a8976b5 commit f9a0901
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Src/Graphics/New3D/New3D.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,10 @@ void CNew3D::DrawAmbientFog()
continue;
}

if (n.viewport.scrollAtt > 0.0f) {
continue; // scroll attenuation indicates scroll fog layer
}

if (n.viewport.fogParams[6] < fogAmbient) {
nodePtr = &n;
fogAmbient = n.viewport.fogParams[6];
Expand Down

0 comments on commit f9a0901

Please sign in to comment.