diff options
Diffstat (limited to 'indra/newview/llviewertexture.cpp')
-rw-r--r-- | indra/newview/llviewertexture.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp index c389d2122e..3ecab2c647 100644 --- a/indra/newview/llviewertexture.cpp +++ b/indra/newview/llviewertexture.cpp @@ -69,6 +69,7 @@ const S32Megabytes gMaxVideoRam(512); LLPointer<LLViewerTexture> LLViewerTexture::sNullImagep = NULL; LLPointer<LLViewerTexture> LLViewerTexture::sBlackImagep = NULL; LLPointer<LLViewerTexture> LLViewerTexture::sCheckerBoardImagep = NULL; +LLPointer<LLViewerTexture> LLViewerTexture::sDefaultPBRORMImagep = NULL; // PBR: When ORM is missing use 1,0,0 LLPointer<LLViewerFetchedTexture> LLViewerFetchedTexture::sMissingAssetImagep = NULL; LLPointer<LLViewerFetchedTexture> LLViewerFetchedTexture::sWhiteImagep = NULL; LLPointer<LLViewerFetchedTexture> LLViewerFetchedTexture::sDefaultImagep = NULL; @@ -367,6 +368,13 @@ void LLViewerTextureManager::init() LLViewerTexture::sNullImagep = LLViewerTextureManager::getLocalTexture(raw.get(), TRUE); } + // Create Default PBR ORM Texture 1,0,0 + { + LLPointer<LLImageRaw> red = new LLImageRaw(8,8,3); + red->clear(0xFF, 0x00, 0x00, 0xFF); + LLViewerTexture::sDefaultPBRORMImagep = LLViewerTextureManager::getLocalTexture(red.get(), TRUE); + } + const S32 dim = 128; LLPointer<LLImageRaw> image_raw = new LLImageRaw(dim,dim,3); U8* data = image_raw->getData(); @@ -451,8 +459,9 @@ void LLViewerTextureManager::cleanup() LLImageGL::sDefaultGLTexture = NULL; LLViewerTexture::sNullImagep = NULL; LLViewerTexture::sBlackImagep = NULL; + LLViewerFetchedTexture::sDefaultPBRORMImagep = NULL; LLViewerTexture::sCheckerBoardImagep = NULL; - LLViewerFetchedTexture::sDefaultImagep = NULL; + LLViewerFetchedTexture::sDefaultImagep = NULL; LLViewerFetchedTexture::sSmokeImagep = NULL; LLViewerFetchedTexture::sMissingAssetImagep = NULL; LLTexUnit::sWhiteTexture = 0; |