Merge pull request #15447 from SamGondelman/materialData

Case 22329: Don't try to bake materialURL if it points to materialData
This commit is contained in:
Shannon Romano 2019-04-24 09:26:52 -07:00 committed by GitHub
commit 4148ebfd18
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -409,7 +409,10 @@ void DomainBaker::enumerateEntities() {
// Materials
if (entity.contains(MATERIAL_URL_KEY)) {
addMaterialBaker(MATERIAL_URL_KEY, entity[MATERIAL_URL_KEY].toString(), true, *it);
QString materialURL = entity[MATERIAL_URL_KEY].toString();
if (!materialURL.startsWith("materialData")) {
addMaterialBaker(MATERIAL_URL_KEY, materialURL, true, *it);
}
}
if (entity.contains(MATERIAL_DATA_KEY)) {
addMaterialBaker(MATERIAL_DATA_KEY, entity[MATERIAL_DATA_KEY].toString(), false, *it, _destinationPath);