[5.7 Preview] FBX Materials getting imported as instances instead of "standalone" materials

  1. Open Blender (or any DCC of choice, im not sure if it matters in that case, all is needed is a FBX file containing mesh with assigned texture)
  2. Create any kind of primitive mesh (like UV Sphere), create a new material and assign an image texture to it
  3. Export FBX file
  4. Import FBX file in UE 5.7 Preview via Interchange by drag and dropping into the content browser

Despite “Material Import” setting set to “Import as Materials”, and not to “Import as Material Instances” the materials are getting imported as instances of “PhongSurfaceMaterial” master material from the Interchange Framework content. I have checked and this doesnt happen in the latest stable 5.6 version of UE.

Hello @e36 thank you for the report and appologies for the disruption.

We are aware of it and in 5.8 the option will be removed altogether. As of now FBX import only generates Material Instances in a similar way to glTF. We are aware the UI is thus misleading but the 5.7 remaining timeline did not allow to get it done for 5.7 release.

We also noticed some visual differences between the Material import from 5.6 and Material Instances imports in 5.7, work is being done to close the gap for 5.7 release.

Apart from the misleading/broken UI, do you require the creation of Materials when you import FBX? If yes could you explain that process?

This bug comes from the current work done to move FBX import process to rely exclusively on Material Instances. This work is done because materials defined in FBX can be expressed using instance of a single master material and it is more performant to use Material Instance than independent Materials.

You can still rely on automatic material replacement during import, so that UE searches for material among the assets in your content folder. You can also make custom pipeline to change the Material Instance that UE will use to generate the material when importing the FBX.

Thanks for the comprehensive reply. So if i understand correctly, the ability to choose between independent materials and creating material instances upon import will be removed and will be set to creating material instances by default?

Can you provide any learning resources or documentation on how to prepare such “Master Material” for such material instances for FBX import interchange (or format like GLTF), in particular what nodes are supported and how to make them being recognized in the material graph on import (so that base color texture from FBX file goes into the base color texture sample inside the graph etc.)? I have once tried making one but i wasnt entirely sure to what extent the material translation is implemented.

I was previously looking for various means to interchange content from Blender like materials or meshes already (for example batch importing static meshes with various material types) and i couldnt settle on anything specific due to lack of documentation on such things along with my lack of knowledge which format is best for what, let it be FBX or GLTF or any other one.

I’m using uefn and cant import anything because of this! I just want to make my game what can i do? other than create 100’s of materials?

The main reason to switch to material instances is actually to reduce the number of material that are created. Many materials will eat away your UEFN publishing memory budget. There is no point to have 100 materials if the difference is only basecolor, or roughness value etc. In short most situation can be covered with one for opaque materials, one for masked and one for transparent materials.

Workarounds will depend on your context, why do you need materials and not material instances?

If you do not like the current master material used to generate material instance, you can make your own, and in the import window select import as material instance and put your own as parent material. If you name your material parameters in a specific way, the editor will generate instance of your material but using the values from the FBX material description.

@UE_FlavienP When importing FBX in 5.7.0, if you set your own master material to be used as parent, it still creates material instances with the FBXLegacyPhongSurfaceMaterial as the parent instead.

A feature request; if you don’t use ‘combine meshes‘ it creates several meshes called Mesh1, Mesh2 etc. Would be nice if it would use the base name of the object and add a mesh1, mesh2 etc to the name instead. At the moment, if you import several fbx objects into the same folder without combine meshes, you will probable overwrite some objects. This could be prevented if they were imported as Walls_mesh1, Walls_mesh2, Roof_mesh1, Roof_mesh2 etc.

Edit: also, if you enable ‘generate lightmap uvs‘ it sets a value for the ‘min lightmap resolution’ in the build settings but leaves the ‘lightmap resolution‘ in the general settings to a value of 4. It would be nice if that one was at least the same value as the min lightmap resolution.

What if those 100 Materials don’t use the same basecolor? I’m completely dumbfounded importing as Instances is going to be made default without (if I’m reading this correctly) the inability to import as just a Material. This will skyrocket the time it takes for me to import anything with materials and will force me to create all materials from scratch in Unreal now. I am so tired of every new update to every program ever ruining things that worked perfectly fine for over a decade. I have thousands of materials and now whenever I import a model that uses my existing materials in Unreal it just imports Material Instance copies with all the wrongs settings. This change is enough to ruin my entire project.

In that case the editor should create 100 material instances, all using the same parent material but with a specific value on the basecolor.

In short, the editor has a preset of materials for opaque, masked, translucent material types. When you import an fbx it will select the preset based on the type of material and then assign the material parameters from fbx on the material.

That also works with custom materials: if you force the editor to import materials using a custom parent material, the editor will also apply the basecolor and other parameters. The only requirement is that your parent material uses material parameters with the appropriate names. You can have a look at how FBXLegacyPhongSurfaceMaterial or PhongSurfaceMaterial are made.

Here is a non exhaustive list of material parameters the editor will fill, based on FBX file content, on any material instance for FBX import.

AmbientColor, AmbientColorMap, AmbientColorMapWeight

DiffuseColor, DiffuseColorMap, DiffuseColorMapWeight

SpecularColor, SpecularColorMap, SpecularColorMapWeight

EmissiveColor, EmissiveColorMap, EmissiveColorMapWeight

Shininess, ShininessMap, ShininessMapWeight

Opacity, OpacityMap, OpacityMapWeight

OpacityMask, OpacityMaskMap

etc.