# Texture/Material import with alphas and opacity masks help pls

**URL:** <https://forums.unrealengine.com/t/texture-material-import-with-alphas-and-opacity-masks-help-pls/461473>\
**Category:** Rendering\
**Tags:** alpha, opacity-mask, unreal-engine, UE4, question\
**Created:** [February 7, 2020, 6:39pm UTC](https://forums.unrealengine.com/t/texture-material-import-with-alphas-and-opacity-masks-help-pls/461473 "2020-02-07T18:39:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![DeXpliz1t](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DeXpliz1t](https://forums.unrealengine.com/u/DeXpliz1t)\
**Post date:** [February 7, 2020, 6:39pm UTC](https://forums.unrealengine.com/t/texture-material-import-with-alphas-and-opacity-masks-help-pls/461473/1 "2020-02-07T18:39:51Z")

</div>

ok so basically i imported an fbx file and all the materials are default…which is normal but not wanted i need to somehow import them all using the same settings but different texture samples for example: i need them to have different assigned textures but all be 2 sided, have the blend mode on masked and also have the alpha automatically connected to the opacity mask… as there are over 6000 materials to do this with… 300 something for this fbx alone and a bunch more for others… any help would be extremely appreciated as this gets old reeeeeeeal fast XD

\<3

---

<div class="post-metadata">

**Author:** ![DeXpliz1t](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DeXpliz1t](https://forums.unrealengine.com/u/DeXpliz1t)\
**Post date:** [February 7, 2020, 7:23pm UTC](https://forums.unrealengine.com/t/texture-material-import-with-alphas-and-opacity-masks-help-pls/461473/2 "2020-02-07T19:23:42Z")

</div>

I FIGURED IT OUT! FINALLY HELL YEAH!

so basically i had to create a master material out of a random dummy texture then with that material i changed the texture sample with a texturesample2d param thing then i connected everything like i would normally like connecting alpha to opacity mask and such then i created an instanced material out of that one and checked the texture parameter and stuff and then when importing i selected PARAM instead of no override on all sections and it imported with alpha to opacity 2 sided and all 😃

---

<div class="post-metadata">

**Author:** ![SavvyIndoorsman](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SavvyIndoorsman](https://forums.unrealengine.com/u/SavvyIndoorsman)\
**Post date:** [February 7, 2020, 7:34pm UTC](https://forums.unrealengine.com/t/texture-material-import-with-alphas-and-opacity-masks-help-pls/461473/3 "2020-02-07T19:34:40Z")

</div>

I don’t know of a way to automatically set those material properties on import, but **more important in your case** is, you’re going to want to consolidate those materials down into _far fewer_ ones.

Having 6,000 materials in one project would be extreme, and would make compiling materials in your project take a very long time. (Each new material that is added increases the time it takes to compile every material in your project.)

The intended way to use materials in UE4 is to have a handful of “master” materials, and create **material instances** from those master materials. This workflow not only avoids the material compile slowdown I just mentioned, but is also a faster way to work because previewing updates in the material instance editor is practically instantaneous, unlike making changes to a base material asset.

At the very least, I suggest you read up on [Instanced Materials](https://docs.unrealengine.com/en-US/Engine/Rendering/Materials/MaterialInstances/index.html) in the UE4 documentation. Maybe also check out [this video on the Unreal Engine YouTube channel](https://www.youtube.com/watch?v=sx0BlzGkahw) about using instanced materials. (Actually, it may be valuable to watch multiple videos in that “Intro to Materials” series.)

In general, I recommend finding a solution that allows you to maintain as few master materials as you can, and create only as many material instances as you need as well. Likely this will mean you won’t actually import your materials from those FBX files at all.

Depending on how many meshes you’re importing, it may still be tedious to assign your new material instances to each imported mesh, but you should only have to do this once per mesh asset, and afterward, maintaining the “material look” on each of your meshes will be _way_ simpler and easier.

---

<div class="post-metadata">

**Author:** ![SavvyIndoorsman](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SavvyIndoorsman](https://forums.unrealengine.com/u/SavvyIndoorsman)\
**Post date:** [February 7, 2020, 7:35pm UTC](https://forums.unrealengine.com/t/texture-material-import-with-alphas-and-opacity-masks-help-pls/461473/4 "2020-02-07T19:35:36Z")

</div>

Aha! You solved your own issue as I was writing my answer! =D
