summaryrefslogtreecommitdiff
path: root/indra/newview/llhudnametag.cpp
diff options
context:
space:
mode:
authorBrad Linden <brad@lindenlab.com>2024-10-01 12:44:13 -0700
committerBrad Linden <brad@lindenlab.com>2024-10-01 12:44:13 -0700
commit002a81ccf5a64fd08e29811a6edea36f2e0408be (patch)
tree1ca8b593778d904d5f280aff94be2288d73567af /indra/newview/llhudnametag.cpp
parent59ed2d55a1d84ecf879ff564aaf02744f2dc7c7a (diff)
parent690f099519e155220535e07539238139b16da99f (diff)
Merge remote-tracking branch 'origin/release/2024.09-ExtraFPS' into develop
Diffstat (limited to 'indra/newview/llhudnametag.cpp')
-rw-r--r--indra/newview/llhudnametag.cpp23
1 files changed, 2 insertions, 21 deletions
diff --git a/indra/newview/llhudnametag.cpp b/indra/newview/llhudnametag.cpp
index 66130a2744..8ad07efd1f 100644
--- a/indra/newview/llhudnametag.cpp
+++ b/indra/newview/llhudnametag.cpp
@@ -291,15 +291,6 @@ void LLHUDNameTag::renderText()
LLVector3 render_position = mPositionAgent
+ (x_pixel_vec * screen_offset.mV[VX])
+ (y_pixel_vec * screen_offset.mV[VY]);
- bool reset_buffers = false;
- const F32 treshold = 0.000001f;
- if (abs(mLastRenderPosition.mV[VX] - render_position.mV[VX]) > treshold
- || abs(mLastRenderPosition.mV[VY] - render_position.mV[VY]) > treshold
- || abs(mLastRenderPosition.mV[VZ] - render_position.mV[VZ]) > treshold)
- {
- reset_buffers = true;
- mLastRenderPosition = render_position;
- }
LLGLDepthTest gls_depth(GL_TRUE, GL_FALSE);
LLRect screen_rect;
@@ -323,11 +314,6 @@ void LLHUDNameTag::renderText()
for(std::vector<LLHUDTextSegment>::iterator segment_iter = mLabelSegments.begin();
segment_iter != mLabelSegments.end(); ++segment_iter )
{
- if (reset_buffers)
- {
- segment_iter->mFontBufferLabel.reset();
- }
-
// Label segments use default font
const LLFontGL* fontp = (segment_iter->mStyle == LLFontGL::BOLD) ? mBoldFontp : mFontp;
y_offset -= fontp->getLineHeight();
@@ -343,7 +329,7 @@ void LLHUDNameTag::renderText()
}
LLColor4 label_color(0.f, 0.f, 0.f, alpha_factor);
- hud_render_text(segment_iter->getText(), render_position, &segment_iter->mFontBufferLabel, *fontp, segment_iter->mStyle, LLFontGL::NO_SHADOW, x_offset, y_offset, label_color, false);
+ hud_render_text(segment_iter->getText(), render_position, *fontp, segment_iter->mStyle, LLFontGL::NO_SHADOW, x_offset, y_offset, label_color, false);
}
}
@@ -365,11 +351,6 @@ void LLHUDNameTag::renderText()
for (std::vector<LLHUDTextSegment>::iterator segment_iter = mTextSegments.begin() + start_segment;
segment_iter != mTextSegments.end(); ++segment_iter )
{
- if (reset_buffers)
- {
- segment_iter->mFontBufferText.reset();
- }
-
const LLFontGL* fontp = segment_iter->mFont;
y_offset -= fontp->getLineHeight();
y_offset -= LINE_PADDING;
@@ -393,7 +374,7 @@ void LLHUDNameTag::renderText()
text_color = segment_iter->mColor;
text_color.mV[VALPHA] *= alpha_factor;
- hud_render_text(segment_iter->getText(), render_position, &segment_iter->mFontBufferText, *fontp, style, shadow, x_offset, y_offset, text_color, false);
+ hud_render_text(segment_iter->getText(), render_position, *fontp, style, shadow, x_offset, y_offset, text_color, false);
}
}
/// Reset the default color to white. The renderer expects this to be the default.