diff options
| author | Geenz <geenz@geenzo.com> | 2013-01-25 17:54:38 -0500 |
|---|---|---|
| committer | Geenz <geenz@geenzo.com> | 2013-01-25 17:54:38 -0500 |
| commit | 5f03e197f4cfb43de93dc42b16b54beafccd376a (patch) | |
| tree | 77fe17e9c36021148c18f7f9f33aae5abcd100c0 /indra/newview/llface.cpp | |
| parent | cc7ae8fbd1fc249f77ced95171e5c22e48adedb6 (diff) | |
Trying to set materials up for rendering! Yay!
Diffstat (limited to 'indra/newview/llface.cpp')
| -rwxr-xr-x | indra/newview/llface.cpp | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index 605cb81c10..01cbfafe16 100755 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -316,6 +316,48 @@ void LLFace::setTexture(LLViewerTexture* tex) mTexture = tex ; } +void LLFace::setNormalMap(LLViewerTexture* tex) +{ + if(mNormalMap == tex) + { + return ; + } + + if(mNormalMap.notNull()) + { + mNormalMap->removeFace(this) ; + removeAtlas() ; + } + + if(tex) + { + tex->addFace(this) ; + } + + mNormalMap = tex ; +} + +void LLFace::setSpecularMap(LLViewerTexture* tex) +{ + if(mSpecMap == tex) + { + return ; + } + + if(mSpecMap.notNull()) + { + mSpecMap->removeFace(this) ; + removeAtlas() ; + } + + if(tex) + { + tex->addFace(this) ; + } + + mSpecMap = tex ; +} + void LLFace::dirtyTexture() { LLDrawable* drawablep = getDrawable(); |
