namespace Poseidon
| 641 | |
| 642 | } // namespace Poseidon |
| 643 | bool NoFogNeeded(float dist2, const Shape* shape, float bRadius) |
| 644 | { |
| 645 | using namespace Poseidon; |
| 646 | // determine pesimistic fog treshold |
| 647 | float minFog = GLOB_SCENE->GetFogMinRange(); |
| 648 | ClipFlags andFog = shape->GetAndHints() & ClipFogMask; |
| 649 | ClipFlags orFog = shape->GetOrHints() & ClipFogMask; |
| 650 | if (andFog == ClipFogSky) |
| 651 | { |
| 652 | minFog = MinSkyFog; |
| 653 | } |
| 654 | if (orFog == ClipFogShadow) |
| 655 | { |
| 656 | minFog = GLOB_SCENE->GetShadowFogMinRange(); |
| 657 | } |
| 658 | // check object coordinates |
| 659 | float minDist = floatMax(minFog - bRadius, 0); |
| 660 | return (dist2 < Square(minDist)); |
| 661 | } |
| 662 | namespace Poseidon |
| 663 | { |
| 664 |
no test coverage detected