llprimitive merge

This commit is contained in:
Shyotl
2016-04-08 19:32:13 -05:00
parent 691a5395ca
commit d40256fb31
10 changed files with 72 additions and 31 deletions

View File

@@ -137,7 +137,7 @@ S32 LLPrimTextureList::copyTexture(const U8 index, const LLTextureEntry& te)
// we're changing an existing entry
llassert(mEntryList[index]);
delete (mEntryList[index]);
if (&te)
if (te != LLTextureEntry::null)
{
mEntryList[index] = te.newCopy();
}
@@ -377,6 +377,16 @@ S32 LLPrimTextureList::setMaterialParams(const U8 index, const LLMaterialPtr pMa
return TEM_CHANGE_NONE;
}
LLMaterialPtr LLPrimTextureList::getMaterialParams(const U8 index)
{
if (index < mEntryList.size())
{
return mEntryList[index]->getMaterialParams();
}
return LLMaterialPtr();
}
S32 LLPrimTextureList::size() const
{
return mEntryList.size();