Update disc rendering to not conflict with atmosphere

This commit is contained in:
Emma Broman
2021-01-20 13:16:36 +01:00
parent 968d0eea64
commit 10d615cdc8
3 changed files with 14 additions and 11 deletions

View File

@@ -124,6 +124,8 @@ RenderableDisc::RenderableDisc(const ghoul::Dictionary& dictionary)
addProperty(_width);
addProperty(_opacity);
setRenderBin(Renderable::RenderBin::PostDeferredTransparent);
}
bool RenderableDisc::isReady() const {
@@ -185,7 +187,7 @@ void RenderableDisc::render(const RenderData& data, RendererTasks&) {
_shader->setUniform(_uniformCache.texture, unit);
glEnablei(GL_BLEND, 0);
glBlendFunc(GL_SRC_ALPHA, GL_ONE);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glDepthMask(false);
glDisable(GL_CULL_FACE);