Hi! how you folks doing? i hope you are doing great and making awesome art!
Haven’t found a thread or threads that specifically points to material optimization. If im mistaken please, point out as much reference as you can, but for now i would like to ask some questions and maybe centralize all the references and comments in one post.
Im working on a VR project for HTC Vive, and being the only env artist in there (a newbie is gonna be added soon) i have to be my own tech artist, which is exciting and terrifying at the same time. These are my first questions after reading a few articles (2 of which i share below):
-
It is suggested to combine meshes into the same material, usually creating a texture atlas if needed, two questions arise:
– Does this suggestion apply even if the meshes aren’t in the same .fbx? Mesh A and Mesh B are imported into the engine as separate files, but then the same material is applied inside the engine. Is there any difference if a import them as one file? or it doesn’t matter?. – In the pipeline we are creating the minimun texture resolution per asset that works well is 1K (let’s say for the Base Color), if we combine 4 of those assets into one material and pretend to keep the same resolution restriction, then we would have each asset with a 512×512 square of resolution assigned to it in the atlas, and some assets look bad. What’s the tradeoff of having one material assigned to 4 assets but with a 2K resolution texture set (or even greater if we, for example, group 16 assets into one atlas), it is still worth it to combine meshes into one material?
-
What about bleding materials?. For example, Unreal Engine does support a lot of blending options, what would be better from an optimization POV: to have two materials combined using a blending node inside another material, or to create one material that asks as inputs two of each textures and combines it directly inside of it?. It seems that the later option is the best, specially if we are doing blending using vertex info, because one material is (roughly) one draw call, instead of at least 2 drawcalls that are blended together. Did i get that right? any other thoutgh on blending, because it is insanely important for env art.
-
It’s usual practice to have a Master Material in Unreal Engine which then is instanced for. In our case it is needed for our Master Material to support some blending options for some 3D assets, but for other 3D assets there is no blending needed, actually, our project uses photogrammetry and we tested results with just a material with Albedo, Roughness and Normal simply plugged into it and it looks great for us. The question is: what would be more efficient, to keep that Master Material for all the meshes, or create 2 masters, one that handles blending and one that is a lot simpler? as i understood it, having one material is more effective, but i want to take into account shader instructions to make a better judgement.
I do and totally understand that much of this is content and project dependent that needs to be profiled properly, but i also do need some starting point for comparisson sake.
The articles that are my main references:
https://simonschreibt.de/gat/renderhell/
Thanks everyone!