diff options
| author | Dave Houlton <euclid@lindenlab.com> | 2021-02-02 16:11:44 +0000 |
|---|---|---|
| committer | Dave Houlton <euclid@lindenlab.com> | 2021-02-02 16:11:44 +0000 |
| commit | de711c213820521aa8afcf991b4af561db54aede (patch) | |
| tree | 108e7d0dcb12f6f827d78a0a30b28e33a8cb95f0 /indra/llrender/llimagegl.cpp | |
| parent | 25186d07acdeb3ba079594f8f0f8677626b1baf6 (diff) | |
| parent | 7af677ab442b4bb28f009f3715b8913aecd565fa (diff) | |
Merged in DV528-rebase-6.4.13 (pull request #461)
DRTVWR-528 rebase to 6.4.13
Diffstat (limited to 'indra/llrender/llimagegl.cpp')
| -rw-r--r-- | indra/llrender/llimagegl.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/indra/llrender/llimagegl.cpp b/indra/llrender/llimagegl.cpp index 3b6a49735e..0151d20128 100644 --- a/indra/llrender/llimagegl.cpp +++ b/indra/llrender/llimagegl.cpp @@ -1386,6 +1386,15 @@ BOOL LLImageGL::createGLTexture(S32 discard_level, const LLImageRaw* imageraw, S return FALSE; } + if (mHasExplicitFormat && + ((mFormatPrimary == GL_RGBA && mComponents < 4) || + (mFormatPrimary == GL_RGB && mComponents < 3))) + + { + LL_WARNS() << "Incorrect format: " << std::hex << mFormatPrimary << " components: " << (U32)mComponents << LL_ENDL; + mHasExplicitFormat = FALSE; + } + if( !mHasExplicitFormat ) { switch (mComponents) |
