diff options
| author | Erik Kundiman <erik@megapahit.org> | 2026-09-01 18:35:23 +0800 |
|---|---|---|
| committer | Erik Kundiman <erik@megapahit.org> | 2026-09-04 21:58:53 +0800 |
| commit | 00bb3bb6f07660bd914d29a1389342bb3060d254 (patch) | |
| tree | 431f574922494d2201718f13085f17bc6bd7fb42 /indra/newview/llspatialpartition.cpp | |
| parent | a8636720129952c10cf49ab80da21bf8b340b96c (diff) | |
| parent | 4ef9f8f14b35ed388c294d53767a0dca0e890924 (diff) | |
Merge remote-tracking branch 'secondlife/release/26.4' into 26.4
Diffstat (limited to 'indra/newview/llspatialpartition.cpp')
| -rw-r--r-- | indra/newview/llspatialpartition.cpp | 37 |
1 files changed, 14 insertions, 23 deletions
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index d2c7c5e5ce..4295149fad 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -1664,13 +1664,11 @@ void renderOctree(LLSpatialGroup* group) #endif gGL.diffuseColor4f(1,0,0,group->mBuilt); - gGL.flush(); - //glLineWidth(5.f); + //gGL.setLineWidth(5.f); const LLVector4a* bounds = group->getObjectBounds(); drawBoxOutline(bounds[0], bounds[1]); - //gGL.flush(); - //glLineWidth(1.f); + //gGL.setLineWidth(1.f); gGL.flush(); const LLVOAvatar* lastAvatar = nullptr; @@ -1981,12 +1979,11 @@ void renderBoundingBox(LLDrawable* drawable, bool set_color = true) LLViewerObject* vobj = drawable->getVObj(); if (vobj && vobj->onActiveList()) { - gGL.flush(); - //glLineWidth(llmax(4.f*sinf(gFrameTimeSeconds*2.f)+1.f, 1.f)); - stop_glerror(); + //gGL.setLineWidth(llmax(4.f*sinf(gFrameTimeSeconds*2.f)+1.f, 1.f)); + //gGL.setLineWidth(4.f*(sinf(gFrameTimeSeconds*2.f)*0.25f+0.75f)); + stop_glerror(); drawBoxOutline(pos,size); - gGL.flush(); - //glLineWidth(1.f); + //gGL.setLineWidth(1.f); } else { @@ -2498,14 +2495,11 @@ void renderPhysicsShape(LLDrawable* drawable, LLVOVolume* volume, bool wireframe llassert(LLGLSLShader::sCurBoundShader != 0); LLVertexBuffer::unbind(); -#if GL_VERSION_1_1 - glVertexPointer(3, GL_FLOAT, 16, phys_volume->mHullPoints); -#endif gGL.diffuseColor4fv(color.mV); - gGL.syncMatrices(); - glDrawElements(GL_TRIANGLES, phys_volume->mNumHullIndices, GL_UNSIGNED_SHORT, phys_volume->mHullIndices); + + LLVertexBuffer::drawElements(LLRender::TRIANGLES, phys_volume->mHullPoints, nullptr, phys_volume->mNumHullIndices, phys_volume->mHullIndices); } else { @@ -2899,8 +2893,7 @@ public: if (i == 1) { - gGL.flush(); - //glLineWidth(3.f); + //gGL.setLineWidth(3.f); } gGL.begin(LLRender::TRIANGLES); @@ -2918,8 +2911,7 @@ public: if (i == 1) { - gGL.flush(); - //glLineWidth(1.f); + //gGL.setLineWidth(1.f); } } } @@ -3646,12 +3638,11 @@ bool LLSpatialPartition::isVisible(const LLVector3& v) return true; } -LL_ALIGN_PREFIX(16) -class LLOctreeIntersect : public LLOctreeTraveler<LLViewerOctreeEntry, LLPointer<LLViewerOctreeEntry>> +class alignas(16) LLOctreeIntersect : public LLOctreeTraveler<LLViewerOctreeEntry, LLPointer<LLViewerOctreeEntry>> { public: - LL_ALIGN_16(LLVector4a mStart); - LL_ALIGN_16(LLVector4a mEnd); + LLVector4a mStart; + LLVector4a mEnd; S32 *mFaceHit; LLVector4a *mIntersection; @@ -3801,7 +3792,7 @@ public: return false; } -} LL_ALIGN_POSTFIX(16); +}; LLDrawable* LLSpatialPartition::lineSegmentIntersect(const LLVector4a& start, const LLVector4a& end, bool pick_transparent, |
