summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--autobuild.xml8
-rw-r--r--indra/llrender/llfontbitmapcache.cpp29
-rw-r--r--indra/llrender/llfontbitmapcache.h12
-rw-r--r--indra/llrender/llfontregistry.cpp4
-rw-r--r--indra/llui/lltextbase.cpp2
-rwxr-xr-xindra/newview/viewer_manifest.py2
6 files changed, 25 insertions, 32 deletions
diff --git a/autobuild.xml b/autobuild.xml
index ac7459ddca..babc7d73bc 100644
--- a/autobuild.xml
+++ b/autobuild.xml
@@ -958,9 +958,9 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>aa8be83cdfcd5cda0343ea72e7d662ca</string>
+ <string>f3e63d80bd80da03aa7f87f7bd7c5f8b</string>
<key>url</key>
- <string>freetype-2.10.1.0-windows64-72.tar.bz2</string>
+ <string>freetype-2.10.1.0-windows64-222392239.tar.bz2</string>
</map>
<key>name</key>
<string>windows64</string>
@@ -1510,9 +1510,9 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>e8b20cea748b90ea18bb63dfba06e059</string>
+ <string>340980c10153446b678625ec7af047c2</string>
<key>url</key>
- <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/491/1075/icu4c-4.8.1-windows64-500388.tar.bz2</string>
+ <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/55243/513658/icu4c-4.8.1-windows64-539138.tar.bz2</string>
</map>
<key>name</key>
<string>windows64</string>
diff --git a/indra/llrender/llfontbitmapcache.cpp b/indra/llrender/llfontbitmapcache.cpp
index 754adb14cb..2d65ec47c6 100644
--- a/indra/llrender/llfontbitmapcache.cpp
+++ b/indra/llrender/llfontbitmapcache.cpp
@@ -31,17 +31,7 @@
LLFontBitmapCache::LLFontBitmapCache()
: LLTrace::MemTrackable<LLFontBitmapCache>("LLFontBitmapCache")
- , mBitmapWidth(0)
- , mBitmapHeight(0)
- , mMaxCharWidth(0)
- , mMaxCharHeight(0)
{
- // *TODO: simplify with initializer after VS2017
- for (U32 idx = 0, cnt = static_cast<U32>(EFontGlyphType::Count); idx < cnt; idx++)
- {
- mCurrentOffsetX[idx] = 1;
- mCurrentOffsetY[idx] = 1;
- }
}
LLFontBitmapCache::~LLFontBitmapCache()
@@ -123,6 +113,9 @@ BOOL LLFontBitmapCache::nextOpenPos(S32 width, S32& pos_x, S32& pos_y, EFontGlyp
// Attach corresponding GL texture. (*TODO: is this needed?)
gGL.getTexUnit(0)->bind(image_gl);
image_gl->setFilteringOption(LLTexUnit::TFO_POINT); // was setMipFilterNearest(TRUE, TRUE);
+
+ claimMem(image_raw);
+ claimMem(image_gl);
}
else
{
@@ -145,29 +138,29 @@ void LLFontBitmapCache::destroyGL()
{
for (U32 idx = 0, cnt = static_cast<U32>(EFontGlyphType::Count); idx < cnt; idx++)
{
- for (std::vector<LLPointer<LLImageGL> >::iterator it = mImageGLVec[idx].begin(); it != mImageGLVec[idx].end(); ++it)
+ for (LLImageGL* image_gl : mImageGLVec[idx])
{
- (*it)->destroyGLTexture();
+ image_gl->destroyGLTexture();
}
}
}
void LLFontBitmapCache::reset()
{
- for (U32 idx = 0, cnt = static_cast<U32>(EFontGlyphType::Count); idx < cnt; idx++)
+ for (U32 kitty = 0, cnt = static_cast<U32>(EFontGlyphType::Count); kitty < cnt; kitty++)
{
- for (std::vector<LLPointer<LLImageRaw> >::iterator it = mImageRawVec[idx].begin(), end_it = mImageRawVec[idx].end(); it != end_it; ++it)
+ for (LLImageRaw* image_raw : mImageRawVec[kitty])
{
- disclaimMem(**it);
+ disclaimMem(image_raw);
}
- mImageRawVec[idx].clear();
+ mImageRawVec[kitty].clear();
}
for (U32 idx = 0, cnt = static_cast<U32>(EFontGlyphType::Count); idx < cnt; idx++)
{
- for (std::vector<LLPointer<LLImageGL> >::iterator it = mImageGLVec[idx].begin(), end_it = mImageGLVec[idx].end(); it != end_it; ++it)
+ for (LLImageGL* image_gl : mImageGLVec[idx])
{
- disclaimMem(**it);
+ disclaimMem(image_gl);
}
mImageGLVec[idx].clear();
mCurrentOffsetX[idx] = 1;
diff --git a/indra/llrender/llfontbitmapcache.h b/indra/llrender/llfontbitmapcache.h
index 5d0094fd69..6b339e9afd 100644
--- a/indra/llrender/llfontbitmapcache.h
+++ b/indra/llrender/llfontbitmapcache.h
@@ -68,12 +68,12 @@ protected:
static U32 getNumComponents(EFontGlyphType bitmap_type);
private:
- S32 mBitmapWidth;
- S32 mBitmapHeight;
- S32 mCurrentOffsetX[static_cast<U32>(EFontGlyphType::Count)];
- S32 mCurrentOffsetY[static_cast<U32>(EFontGlyphType::Count)];
- S32 mMaxCharWidth;
- S32 mMaxCharHeight;
+ S32 mBitmapWidth = 0;
+ S32 mBitmapHeight = 0;
+ S32 mCurrentOffsetX[static_cast<U32>(EFontGlyphType::Count)] = { 1 };
+ S32 mCurrentOffsetY[static_cast<U32>(EFontGlyphType::Count)] = { 1 };
+ S32 mMaxCharWidth = 0;
+ S32 mMaxCharHeight = 0;
std::vector<LLPointer<LLImageRaw>> mImageRawVec[static_cast<U32>(EFontGlyphType::Count)];
std::vector<LLPointer<LLImageGL>> mImageGLVec[static_cast<U32>(EFontGlyphType::Count)];
};
diff --git a/indra/llrender/llfontregistry.cpp b/indra/llrender/llfontregistry.cpp
index f2dc5771e9..1d7d930e6f 100644
--- a/indra/llrender/llfontregistry.cpp
+++ b/indra/llrender/llfontregistry.cpp
@@ -482,6 +482,8 @@ LLFontGL *LLFontRegistry::createFont(const LLFontDescriptor& desc)
font_search_paths.push_back(LLFontGL::getFontPathSystem());
#if LL_DARWIN
font_search_paths.push_back(MACOSX_FONT_PATH_LIBRARY);
+ font_search_paths.push_back(MACOSX_FONT_PATH_LIBRARY + MACOSX_FONT_SUPPLEMENTAL);
+ font_search_paths.push_back(sys_path + MACOSX_FONT_SUPPLEMENTAL);
#endif
// The fontname string may contain multiple font file names separated by semicolons.
@@ -491,8 +493,6 @@ LLFontGL *LLFontRegistry::createFont(const LLFontDescriptor& desc)
++font_file_it)
{
LLFontGL *fontp = NULL;
- font_paths.push_back(MACOSX_FONT_PATH_LIBRARY + MACOSX_FONT_SUPPLEMENTAL + *file_name_it);
- font_paths.push_back(sys_path + MACOSX_FONT_SUPPLEMENTAL + *file_name_it);
bool is_ft_collection = (std::find_if(font_collection_files.begin(), font_collection_files.end(),
[&font_file_it](const LLFontFileInfo& ffi) { return font_file_it->FileName == ffi.FileName; }) != font_collection_files.end());
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp
index 9005d70b2e..0447e7070c 100644
--- a/indra/llui/lltextbase.cpp
+++ b/indra/llui/lltextbase.cpp
@@ -208,7 +208,7 @@ LLTextBase::LLTextBase(const LLTextBase::Params &p)
mVPad(p.v_pad),
mHAlign(p.font_halign),
mVAlign(p.font_valign),
- mTextVAlign(p.text_valign.isProvided() ? p.text_valign : p.font_valign),
+ mTextVAlign(p.text_valign.isProvided() ? p.text_valign.getValue() : p.font_valign.getValue()),
mLineSpacingMult(p.line_spacing.multiple),
mLineSpacingPixels(p.line_spacing.pixels),
mClip(p.clip),
diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py
index 281777e492..85c9318b8a 100755
--- a/indra/newview/viewer_manifest.py
+++ b/indra/newview/viewer_manifest.py
@@ -140,7 +140,7 @@ class ViewerManifest(LLManifest):
self.path("*.tga")
# Include our fonts
- with self.prefix(src="../packages/fonts"):
+ with self.prefix(src="../packages/fonts",src_dst="fonts"):
self.path("*.ttf")
self.path("*.txt")