Download

Cinema 4D Materials

I am exporting a static mesh at a FBX 2014. I there are many sub objects with the same material, for example a metal material, plastic material, padding material, ect. Basically, UE4 makes a material for each time that material is applied, even if its the same material. So I get 25 different brushed metal materials, because they are on separate pieces of geometry. Is there anyway to make it so I only get one material for that brushed metal. I usually have to go and replace all of those with a brushed metal that I already have in UE 4. Any help with this would be great. Thanks.

Depending on what you want, there are several possibilities.

  1. combine the polygon selections that share the same material into a single selection.
  2. bake your materials into a color ID map and use it e.g. in Substance Painter or Quexie to generate your PBR material values.

for 1:
you should combine seperate objects into a single mesh with polygon selections (select them, right click, combine objects)
If you combine objects that have a different material assigned, it will auto-create polygon selections and assign the materials to them.
If you allready have polygon selections assigned to parts of your meshes that are going to be combinewd, it’ll keep them.
Depending on your naming conventions of those selections, you might need to combine selections of the same material into one selection.

You might want to edit your UV map for the mesh too, unless you won’t use any textures or lightmaps at all.

2:
This is the more advanced method that requires some knowledge of how to use generate color ID maps and use them top create your maps for PBR rendering.
You’ll need some advanced UV mapping knowledge for this, since a good UV map is a key to success in this.

As far as optimisation goes, method 2 has far less overhead and will render faster in realtime but take up more texture memory, which might increase loading times a little.
Method 1 on the other hand is less efficient in rendering, since it increases the draw calls a lot, increases the number of materials and shader instructions and therefor reduces fps.

If you are planning to create an interior ArchVis Scene, you might be ok with M1, but for a game enviroment i’d recomend M2 for sure.

Also it doesn’t hurt to learn UV mapping and Material creation, since this comes in handy for a lot of purpose.

BTW: Cinema 4D has a very good integrated help manual.
To access it, just right click on something you want to know more about (e.g. the material Tag) and choose help from the context menue.

I’ve learnt a lot about 3D in general just by reading the C4D dokumentation pdf (long time ago).
Nowdays it’s all in the help menue, but still a lot of vital information.

I ran into this exact problem a few weeks ago, here’s the solution:

  • Import all the materials, let it create 25 brushed metal materials.
  • Choose one of those brushed metal materials to be your “master”, I’d rename it something like “M_Metal_Master”.
  • Select all the brushed metal materials and right click -> Asset Actions -> Replace References.
  • In the Replace References window select the “_Master” material.
  • In your case you probably don’t need to save the dirtied assets. Leaving this unchecked will remove the 24 other metal materials from your project.
  • Hit the Consolidate Assets button.

Now you should see that all the references to your other 24 materials have been replaced by references to your _Master material.

Thanks Kraid, and Paul.

@ Karid, I’m familiar with both techniques. Pretty well versed at game asset creation, but thought it odd that it imports so many materials, even when they are the same.

@Paul. That is exactly what I’m looking for! That helps a bunch.

I have one more question that is in a similar vein. In C4D I merged quite a few objects into a single static mesh. By doing this C4D creates a lot of selections sets. In UE4 it will read in all these, which are great, but many are duplicates. Do you have any tips for unifiying these based on the materials. Basically, if I have 25 chrome selections sets and I want to convert those to one. Is there anyway to do those quickly rather than by hand. Thanks again!

Hey Andy, glad that solution worked for you.

For your other question, I don’t think there’s a way to combine based on materials, so I think the easiest thing to do would be:

  • in Cinema 4D CMD+Click (or control+click if you’re on Windows) all the Polygon Selection tags you’d like to combine.
  • in your Attributes window you should see something like “Name <<Multiple Values>>”
  • Choose “Select Polygons” to select all the polygons associated with those selection tags.
  • In the object window delete all the selection tags, then with your polygons still selected, in the main C4D menu go to Select -> Set Selection.

This will create a new polygon selection tag with all those polygons you had selected. Not ideal I’ll admit, but that’s the easiest way I can think of off the top of my head.

Thanks for the reply Paul. That’s the exact process I’ve been doing. If I find a faster way I’ll share with you guys. Thanks again for all the help!

If you don’t want C4D to create lots of selection sets on combining objects, you should combine all objects using the same material first.
So first all chrome parts, next all brushed metal parts and so on. Last step is combining all the objects with different materials to one object.

Ofc. if there are pre-existing polygon selections on the seperated objects these will carry over to the combined objects as well.
But what’s the point in having a polygon selection for a material that covers the whole object anyway? (delete that before combining)

Also, Cinema will only combine materials with the exact same settings, so if you customized let’s say the material projection of a material to Cubic or Sphere while the others are on UVW,
it’ll create an extra Tag for the material with a selection assigned to keep the customized material values intact.

All of this behavior has it’s purpose and is meant to be that way. (e.g. for texture baking several Materials with different projections to a single UVW map)
So if you don’t get the desired result, it’s not the programs fault.