Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Normalize point source color #2021

Merged
merged 8 commits into from
Dec 23, 2023
4 changes: 2 additions & 2 deletions src/celengine/render.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2966,13 +2966,13 @@ void Renderer::renderPlanet(Body& body,
}
}

if (body.isVisibleAsPoint())
if (body.isVisibleAsPoint() && body.getSurface().color.toVector3().maxCoeff() > 0.0f)
JiliTheSpaceboy marked this conversation as resolved.
Show resolved Hide resolved
{
renderObjectAsPoint(pos,
body.getRadius(),
appMag,
discSizeInPixels,
body.getSurface().color,
body.getSurface().color / body.getSurface().color.toVector3().maxCoeff(),
JiliTheSpaceboy marked this conversation as resolved.
Show resolved Hide resolved
false, false, m);
}
}
JiliTheSpaceboy marked this conversation as resolved.
Show resolved Hide resolved
Expand Down