SH-2963 Fix for highlight transparent not highlighting 100% transparent objects.
This commit is contained in:
@@ -139,6 +139,7 @@ public:
|
||||
PASS_ALPHA,
|
||||
PASS_ALPHA_MASK,
|
||||
PASS_FULLBRIGHT_ALPHA_MASK,
|
||||
PASS_ALPHA_INVISIBLE,
|
||||
NUM_RENDER_TYPES,
|
||||
};
|
||||
|
||||
|
||||
@@ -344,6 +344,7 @@ void LLDrawPoolAlpha::render(S32 pass)
|
||||
|
||||
pushBatches(LLRenderPass::PASS_ALPHA_MASK, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0, FALSE);
|
||||
pushBatches(LLRenderPass::PASS_FULLBRIGHT_ALPHA_MASK, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0, FALSE);
|
||||
pushBatches(LLRenderPass::PASS_ALPHA_INVISIBLE, LLVertexBuffer::MAP_VERTEX | LLVertexBuffer::MAP_TEXCOORD0, FALSE);
|
||||
|
||||
if(shaders)
|
||||
{
|
||||
|
||||
@@ -3692,10 +3692,10 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group)
|
||||
else
|
||||
{
|
||||
if (te->getColor().mV[3] > 0.f)
|
||||
{
|
||||
{ //only treat as alpha in the pipeline if < 100% transparent
|
||||
drawablep->setState(LLDrawable::HAS_ALPHA);
|
||||
alpha_faces.push_back(facep);
|
||||
}
|
||||
alpha_faces.push_back(facep);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -4223,7 +4223,11 @@ void LLVolumeGeometryManager::genDrawInfo(LLSpatialGroup* group, U32 mask, std::
|
||||
if (is_alpha)
|
||||
{
|
||||
// can we safely treat this as an alpha mask?
|
||||
if (facep->canRenderAsMask())
|
||||
if (facep->getFaceColor().mV[3] <= 0.f)
|
||||
{ //100% transparent, don't render unless we're highlighting transparent
|
||||
registerFace(group, facep, LLRenderPass::PASS_ALPHA_INVISIBLE);
|
||||
}
|
||||
else if (facep->canRenderAsMask())
|
||||
{
|
||||
if (te->getFullbright() || LLPipeline::sNoAlpha)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user