diff options
| author | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2025-08-14 11:17:35 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-08-14 11:17:35 +0300 |
| commit | 6f072c2121fcb6f00ccc773d0ff4edc5cbfb013b (patch) | |
| tree | 62c4967d6be428907691f133e794654b25c5d140 /indra/newview/llinspecttexture.cpp | |
| parent | 8145d99f80d55c4da88adb6909386bd5c25fd743 (diff) | |
| parent | d859557c1865b0636ce2a407d2e7b814fbfc1eb6 (diff) | |
Merge 2025.06 into develop
Merge 2025.06 into develop
Diffstat (limited to 'indra/newview/llinspecttexture.cpp')
| -rw-r--r-- | indra/newview/llinspecttexture.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/indra/newview/llinspecttexture.cpp b/indra/newview/llinspecttexture.cpp index 24dbe61bad..9f0d236826 100644 --- a/indra/newview/llinspecttexture.cpp +++ b/indra/newview/llinspecttexture.cpp @@ -115,7 +115,6 @@ public: protected: LLPointer<LLViewerFetchedTexture> m_Image; - S32 mImageBoostLevel = LLGLTexture::BOOST_NONE; std::string mLoadingText; }; @@ -128,12 +127,8 @@ LLTexturePreviewView::LLTexturePreviewView(const LLView::Params& p) LLTexturePreviewView::~LLTexturePreviewView() { - if (m_Image) - { - m_Image->setBoostLevel(mImageBoostLevel); m_Image = nullptr; } -} void LLTexturePreviewView::draw() { @@ -153,18 +148,18 @@ void LLTexturePreviewView::draw() bool isLoading = (!m_Image->isFullyLoaded()) && (m_Image->getDiscardLevel() > 0); if (isLoading) LLFontGL::getFontSansSerif()->renderUTF8(mLoadingText, 0, rctClient.mLeft + 3, rctClient.mTop - 25, LLColor4::white, LLFontGL::LEFT, LLFontGL::BASELINE, LLFontGL::DROP_SHADOW); - m_Image->addTextureStats((isLoading) ? MAX_IMAGE_AREA : (F32)(rctClient.getWidth() * rctClient.getHeight())); + + m_Image->setKnownDrawSize(MAX_IMAGE_SIZE, MAX_IMAGE_SIZE); } } void LLTexturePreviewView::setImageFromAssetId(const LLUUID& idAsset) { - m_Image = LLViewerTextureManager::getFetchedTexture(idAsset, FTT_DEFAULT, MIPMAP_TRUE, LLGLTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE); + m_Image = LLViewerTextureManager::getFetchedTexture(idAsset, FTT_DEFAULT, MIPMAP_TRUE, LLGLTexture::BOOST_THUMBNAIL); if (m_Image) { - mImageBoostLevel = m_Image->getBoostLevel(); - m_Image->setBoostLevel(LLGLTexture::BOOST_PREVIEW); m_Image->forceToSaveRawImage(0); + m_Image->setKnownDrawSize(MAX_IMAGE_SIZE, MAX_IMAGE_SIZE); if ( (!m_Image->isFullyLoaded()) && (!m_Image->hasFetcher()) ) { if (m_Image->isInFastCacheList()) |
