Skip to content

Commit 5d0586b

Browse files
committed
Adjust planetary atmosphere display for consistency
May help with issue #134 or may be entirely unrelated.
1 parent 923b3fd commit 5d0586b

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/Core/Entities/OOPlanetEntity.m

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,12 @@ - (void) drawImmediate:(bool)immediate translucent:(bool)translucent
565565
}
566566

567567
// 500km squared
568-
if (magnitude2(cameraRelativePosition) > 250000000000.0)
568+
// if (magnitude2(cameraRelativePosition) > 250000000000.0)
569+
/* Temporarily for 1.82 make this branch unconditional. There's an
570+
* odd change in appearance when crossing this boundary, which can
571+
* be quite noticeable. There don't appear to be close-range
572+
* problems with doing it this way all the time, though it's not
573+
* ideal. - CIM */
569574
{
570575
/* at this distance the atmosphere is too close to the planet
571576
* for a 24-bit depth buffer to reliably distinguish the two,
@@ -580,6 +585,7 @@ - (void) drawImmediate:(bool)immediate translucent:(bool)translucent
580585
OOGLPopModelView();
581586
}
582587
}
588+
#if OOLITE_HAVE_FIXED_THE_ABOVE_DESCRIBED_BUG_WHICH_WE_HAVENT
583589
else
584590
{
585591
/* At close range we can do this properly and draw the
@@ -599,7 +605,7 @@ - (void) drawImmediate:(bool)immediate translucent:(bool)translucent
599605
[_planetDrawable renderOpaqueParts];
600606
}
601607
}
602-
608+
#endif
603609

604610
if ([UNIVERSE wireframeGraphics]) OOGLWireframeModeOff();
605611
}

0 commit comments

Comments
 (0)