summaryrefslogtreecommitdiff
path: root/indra/llrender
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llrender')
-rw-r--r--indra/llrender/llcubemap.cpp3
-rw-r--r--indra/llrender/llfontfreetype.cpp1
-rw-r--r--indra/llrender/llfontgl.cpp2
-rw-r--r--indra/llrender/llimagegl.cpp4
4 files changed, 8 insertions, 2 deletions
diff --git a/indra/llrender/llcubemap.cpp b/indra/llrender/llcubemap.cpp
index 254288a86e..26bd925f03 100644
--- a/indra/llrender/llcubemap.cpp
+++ b/indra/llrender/llcubemap.cpp
@@ -111,6 +111,9 @@ void LLCubeMap::initRawData(const std::vector<LLPointer<LLImageRaw> >& rawimages
// Yes, I know that this is inefficient! - djs 08/08/02
for (int i = 0; i < 6; i++)
{
+ LLImageDataSharedLock lockIn(rawimages[i]);
+ LLImageDataLock lockOut(mRawImages[i]);
+
const U8 *sd = rawimages[i]->getData();
U8 *td = mRawImages[i]->getData();
diff --git a/indra/llrender/llfontfreetype.cpp b/indra/llrender/llfontfreetype.cpp
index e964d1586f..11a379d70f 100644
--- a/indra/llrender/llfontfreetype.cpp
+++ b/indra/llrender/llfontfreetype.cpp
@@ -669,6 +669,7 @@ U8 LLFontFreetype::getStyle() const
void LLFontFreetype::setSubImageLuminanceAlpha(U32 x, U32 y, U32 bitmap_num, U32 width, U32 height, U8 *data, S32 stride) const
{
LLImageRaw *image_raw = mFontBitmapCachep->getImageRaw(bitmap_num);
+ LLImageDataLock lock(image_raw);
llassert(!mIsFallback);
llassert(image_raw && (image_raw->getComponents() == 2));
diff --git a/indra/llrender/llfontgl.cpp b/indra/llrender/llfontgl.cpp
index 15fddbc99f..484fa9d82c 100644
--- a/indra/llrender/llfontgl.cpp
+++ b/indra/llrender/llfontgl.cpp
@@ -1110,7 +1110,7 @@ LLFontGL* LLFontGL::getFontDefault()
std::string LLFontGL::getFontPathSystem()
{
#if LL_DARWIN
- // HACK for Mac OS X
+ // HACK for macOS
return "/System/Library/Fonts/";
#elif LL_WINDOWS
diff --git a/indra/llrender/llimagegl.cpp b/indra/llrender/llimagegl.cpp
index c6fd824c4e..6315b2cd7c 100644
--- a/indra/llrender/llimagegl.cpp
+++ b/indra/llrender/llimagegl.cpp
@@ -56,7 +56,7 @@ const F32 MIN_TEXTURE_LIFETIME = 10.f;
U32 wpo2(U32 i);
-// texture memory accounting (for OS X)
+// texture memory accounting (for macOS)
static LLMutex sTexMemMutex;
static std::unordered_map<U32, U64> sTextureAllocs;
static U64 sTextureBytes = 0;
@@ -1887,6 +1887,8 @@ BOOL LLImageGL::readBackRaw(S32 discard_level, LLImageRaw* imageraw, bool compre
}
//-----------------------------------------------------------------------------------------------
+ LLImageDataLock lock(imageraw);
+
if (is_compressed)
{
LLGLint glbytes;