diff options
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/llhudeffectpointat.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/linden/indra/newview/llhudeffectpointat.cpp b/linden/indra/newview/llhudeffectpointat.cpp index 7ab03f2..35131cc 100644 --- a/linden/indra/newview/llhudeffectpointat.cpp +++ b/linden/indra/newview/llhudeffectpointat.cpp | |||
@@ -4,7 +4,7 @@ | |||
4 | * | 4 | * |
5 | * $LicenseInfo:firstyear=2002&license=viewergpl$ | 5 | * $LicenseInfo:firstyear=2002&license=viewergpl$ |
6 | * | 6 | * |
7 | * Copyright (c) 2002-2008, Linden Research, Inc. | 7 | * Copyright (c) 2002-2009, Linden Research, Inc. |
8 | * | 8 | * |
9 | * Second Life Viewer Source Code | 9 | * Second Life Viewer Source Code |
10 | * The source code in this file ("Source Code") is provided by Linden Lab | 10 | * The source code in this file ("Source Code") is provided by Linden Lab |
@@ -328,13 +328,13 @@ void LLHUDEffectPointAt::render() | |||
328 | update(); | 328 | update(); |
329 | if (sDebugPointAt && mTargetType != POINTAT_TARGET_NONE) | 329 | if (sDebugPointAt && mTargetType != POINTAT_TARGET_NONE) |
330 | { | 330 | { |
331 | LLGLSNoTexture gls_no_texture; | 331 | gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); |
332 | 332 | ||
333 | LLVector3 target = mTargetPos + mSourceObject->getRenderPosition(); | 333 | LLVector3 target = mTargetPos + mSourceObject->getRenderPosition(); |
334 | gGL.pushMatrix(); | 334 | gGL.pushMatrix(); |
335 | gGL.translatef(target.mV[VX], target.mV[VY], target.mV[VZ]); | 335 | gGL.translatef(target.mV[VX], target.mV[VY], target.mV[VZ]); |
336 | glScalef(0.3f, 0.3f, 0.3f); | 336 | glScalef(0.3f, 0.3f, 0.3f); |
337 | gGL.begin(LLVertexBuffer::LINES); | 337 | gGL.begin(LLRender::LINES); |
338 | { | 338 | { |
339 | gGL.color3f(1.f, 0.f, 0.f); | 339 | gGL.color3f(1.f, 0.f, 0.f); |
340 | gGL.vertex3f(-1.f, 0.f, 0.f); | 340 | gGL.vertex3f(-1.f, 0.f, 0.f); |
@@ -441,8 +441,10 @@ bool LLHUDEffectPointAt::calcTargetPosition() | |||
441 | 441 | ||
442 | mTargetPos -= mSourceObject->getRenderPosition(); | 442 | mTargetPos -= mSourceObject->getRenderPosition(); |
443 | 443 | ||
444 | if (!mTargetPos.isFinite()) | 444 | if (!llfinite(mTargetPos.lengthSquared())) |
445 | { | ||
445 | return false; | 446 | return false; |
447 | } | ||
446 | 448 | ||
447 | if (mSourceObject->isAvatar()) | 449 | if (mSourceObject->isAvatar()) |
448 | { | 450 | { |