summaryrefslogtreecommitdiff
path: root/indra/llrender/llvertexbuffer.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2024-09-30 18:28:00 +0300
committerAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2024-10-02 19:25:11 +0300
commit83a4d86ecf741b5d97c6fd6cbc10d57eb4619699 (patch)
tree7f37beaaf1fd8815a0a7fabc492bffd6fa9fa944 /indra/llrender/llvertexbuffer.cpp
parent3bbcc4b16575ac684074d1a5a9f1fc33f8fa5286 (diff)
viewer#2762 Restore LLFontVertexBuffer for HUD
Diffstat (limited to 'indra/llrender/llvertexbuffer.cpp')
-rw-r--r--indra/llrender/llvertexbuffer.cpp24
1 files changed, 23 insertions, 1 deletions
diff --git a/indra/llrender/llvertexbuffer.cpp b/indra/llrender/llvertexbuffer.cpp
index 6f4828397a..12ae36f4bb 100644
--- a/indra/llrender/llvertexbuffer.cpp
+++ b/indra/llrender/llvertexbuffer.cpp
@@ -604,7 +604,7 @@ public:
static LLVBOPool* sVBOPool = nullptr;
-void LLVertexBufferData::draw()
+void LLVertexBufferData::drawWithMatrix()
{
if (!mVB)
{
@@ -642,6 +642,28 @@ void LLVertexBufferData::draw()
gGL.popMatrix();
}
+void LLVertexBufferData::draw()
+{
+ if (!mVB)
+ {
+ llassert(false);
+ // Not supposed to happen, check buffer generation
+ return;
+ }
+
+ if (mTexName)
+ {
+ gGL.getTexUnit(0)->bindManual(LLTexUnit::TT_TEXTURE, mTexName);
+ }
+ else
+ {
+ gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
+ }
+
+ mVB->setBuffer();
+ mVB->drawArrays(mMode, 0, mCount);
+}
+
//============================================================================
//static