mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 11:43:49 +00:00
update macro
Added get##name##File to macro that will check to make sure the asset is not null before getting the image file.
This commit is contained in:
parent
a52069bbc5
commit
aa3f07e339
5 changed files with 13 additions and 9 deletions
|
|
@ -478,9 +478,7 @@ void ProcessedMaterial::_setStageData()
|
|||
inputKey[2] = mMaterial->mMetalChan[i];
|
||||
inputKey[3] = 0;
|
||||
mStages[i].setTex(MFT_OrmMap,
|
||||
_createCompositeTexture(mMaterial->getAOMapAsset(i).notNull() ? mMaterial->getAOMapAsset(i)->getImageFile() : "",
|
||||
mMaterial->getRoughMapAsset(i).notNull() ? mMaterial->getRoughMapAsset(i)->getImageFile() : "",
|
||||
mMaterial->getMetalMapAsset(i).notNull() ? mMaterial->getMetalMapAsset(i)->getImageFile() : "",
|
||||
_createCompositeTexture(mMaterial->getAOMapFile(i), mMaterial->getRoughMapFile(i), mMaterial->getMetalMapFile(i),
|
||||
"", inputKey, profile));
|
||||
if (!mStages[i].getTex(MFT_OrmMap))
|
||||
mMaterial->logError("Failed to dynamically create ORM Config map for stage %i", i);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue