From 256ba880039b2fa5f7c2290fa4168bab1bbc1069 Mon Sep 17 00:00:00 2001 From: Ansariel Date: Sun, 10 May 2020 23:13:53 +0200 Subject: [PATCH] Re-add particle rendering optimization from dbfcd6c9c5709b74365c2538ba312685b09d22bf LL got lost for over 7 years now... --- indra/newview/lldrawpoolalpha.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/indra/newview/lldrawpoolalpha.cpp b/indra/newview/lldrawpoolalpha.cpp index 536eaffe0c..a0b69aa9ee 100644 --- a/indra/newview/lldrawpoolalpha.cpp +++ b/indra/newview/lldrawpoolalpha.cpp @@ -821,7 +821,11 @@ void LLDrawPoolAlpha::renderAlpha(U32 mask, S32 pass) // If this alpha mesh has glow, then draw it a second time to add the destination-alpha (=glow). Interleaving these state-changing calls is expensive, but glow must be drawn Z-sorted with alpha. if (current_shader && draw_glow_for_this_partition && - params.mVertexBuffer->hasDataType(LLVertexBuffer::TYPE_EMISSIVE)) + // Re-add particle rendering optimization + //params.mVertexBuffer->hasDataType(LLVertexBuffer::TYPE_EMISSIVE)) + params.mVertexBuffer->hasDataType(LLVertexBuffer::TYPE_EMISSIVE) && + (!params.mParticle || params.mHasGlow)) + // { LL_RECORD_BLOCK_TIME(FTM_RENDER_ALPHA_EMISSIVE);