Resources

Cinema4D

Overview

Export a GLB and with realtime PBR materials embedded. Below are more detailed instructions:

Project Settings

Before you can export, ensure C4D is set up to export the color information correctly. To do this, navigate to the project settings.

Edit → Project Settings 

In the lower right-hand corner the project settings will appear:

Ensure the below are enabled:

  • Linear Workflow: Checked

  • Input Color Profile: Linear

Material Setup

We recommend using the PBR Base Material (material set up instructions below) to ensure materials export accurately. Note that material properties like Transmission and Subsurface will not export correctly.

If you are adjusting the UVs of an asset in a material node, it is important to ensure the poly-selection tag is used before applying the material that affects the assets’ UVs.

If you are using Arnold or RedShift materials, you will need to bake and convert those materials before exporting. See our “Arnold Materials Baking Guide” and “Redshift Materials Baking Guide” below. 

Creating a PBR Material

If you are not using a PBR material, it is recommended that you create one. To do this, follow the below steps.

1. Navigate to Create → Materials → New PBR Material

2. Then double-click on your material. This will open up the Material Editor.

3. On the left side of the Material Editor you will see the different material properties. We currently support Color, Reflectance, and Normal. Adjust each channel following our recommendations below.

Color

In the Color section, we deviate a bit from the Standard PBR material set up in C4D. Ensure the Albedo map is plugged into the Texture slot within the Color section.

Reflectance

In the Default Reflection layer use the below settings.

Reflectance Settings:

  • Type: CGX

  • Attenuation: Metal

  • Roughness: Apply the Roughness Map

  • Layer Color: Apply Albedo map here manually

  • Layer Mask: Apply Metallic map here manually

Normal

In the Normal Section, place your Normal Map.

Standard Material

If you are unable to create/convert a PBR version of your material you can still use the Standard material in Cinema4D, but we recommend a few tweaks.

Note: The following material channels will not export: Transmission, Fog, and Displacement.

If you are using the Standard Material, in the Reflectance tab of your material use the below settings:

  • Type: GGX

When using a standard material, ensure that you use a texture for the base color. If you use a color value, the color will not be accurate.

For our supporting channels (Metallic, roughness, and normal). Those can be found under the default specular properties.

Roughness – Controls our roughness output expanding the drop-down allows us to use a texture for our roughness channel.

Reflection Strength – This channel controls our metallic properties. Expanding the drop-down allows us to use a texture for our Metallic channel.

Bump Strength – This channel controls our Normal properties. Expanding the drop-down allows us to use a Normal map.

Mesh Preparation

After the PBR materials have been applied to the model, we recommend moving the asset to its origin.

The easiest way to do this is to select the model and zero out the transform box for X, Y, and Z.

After you move your asset to the origin you will need to freeze the transform data. To do this follow the below steps:

1. Navigate to the Coord tab:

2. Expand the drop-down for Freeze transformation.

3. Click Freeze all.

Now that the transforms are frozen, you are ready to export.

Export Settings

We recommend exporting as a GLB. You can export the entire scene or the selected object. Navigate to:

  • File → Export → GLTF(.gltf/.glb) – entire scene, or

  • File → ExportSelected → GLTF(.gltf/.glb) exports only the selection (asset should be selected)

Below are our recommended export settings:

General

  • File format: GLB

  • Scale: 1 CM

  • Current Frame: True

 

Materials

  • Textures: True

 

Optional

  • Normals: True

  • UVs: True

  • Flip Z: True

Arnold Materials Baking Guide

In this Cinema4D guide, we will walk through baking out our Arnold materials and using a PBR material to export as a .glb.

This process involves the below steps:

  • Determining Materials to Be Baked

  • Baking

  • Creating a PBR Material

  • Applying PBR Material

  • Exporting

 

Let’s dive into it!

Determine Materials To Be Baked

Materials that only use textures do not need to be baked however, materials that use additional nodes to edit the textures do need to be baked.

 

We can see in the below shader graph that we have a Color-correct node adjusting the color of our texture. To preserve this on export, we will need to bake. The supporting channels are only using a texture and do not need to be baked.

Baking

Baking is a very simple process. We’ll demonstrate how to bake the material pictured above.

1. Select the color-correct node and navigate to Texture > Write Texture.

2. The Write Texture Window will open and you can define the output path as well as few parameters for the texture. We will use the settings below:

    • Path: user defines
    • Format: PNG
    • Depth: 8 Bit/ Channel
    • Width: 1024
    • Height: 1024

3. Click OK to start the baking process. Once completed, C4D will display a completed message. 

Create, Apply PBR Materials, and Export

Since we are using Arnold as our renderer, we have access to the PBR material. We can move on to creating and applying the PBR materials. 

Reference the “Creating a PBR Material” section above to see how to create a new PBR material.

For this example, we used the below settings. Our Reflectance properties are slightly different than what is recommended above. 

Basic material properties:
We enabled the Color and Bump channels.

Color material properties:
We input the baked texture from the earlier steps into the Texture slot. 

Reflectance material properties:

  • Default Reflection: 100%
  • Default Diffuse: 0%
  • Default Reflection Type: GGX
  • Attenuation: Metal
  • Roughness: 100%
    • Texture: texture map
  •  Reflection Strength: 0% (this will control out metallic value)

Bump material properties:
We input a texture map into the Texture slot. 

Now that our material has been created, we must apply it to our asset. Drag it from the Material Manager to the object in our 3D viewport, or to the item in our scene graph.

After we have converted all of our Arnold Materials to PBR materials, we are ready to export.
If there is anything in your scene you do not wish to export, ensure that both circles next to the asset in the scene graph are set to red.

Reference the “Export Settings” section above to see our recommended export settings. 

Redshift Materials Baking Guide

In this guide, we will walk through baking out our Cinema4D Redshift Materials and replacing them with Standard Materials to export the asset as a .glb.

This process involves the below steps:

  • UVs

  • Determining Materials to Be Baked

  • Preparing Materials for Baking

  • Baking

  • Creating a Standard Material and Applying to the Object

  • Exporting

Let’s dive into it!

UVs

Your material configuration will determine the type of baking you will be doing and if you need to UV your asset. For most materials, we can bake to a plane and not touch the UVs of our mesh. We will be baking onto a polygon plane with a simple planar projection map. Since the target mesh is displaying the output of the material correctly, we simply need to convert the material output to a texture.

If you source your mesh in your material (i.e. if you use a curvature node, for example), you will need to UV the mesh and bake onto the mesh.

It’s advised to avoid using camera position in your materials if you will be baking since these will not translate.

Determine Materials To Be Baked

If your material is using a value for the color channel, you will need to replace it with a texture to ensure the color is preserved.

 

This is another example of a material where we will need to bake out the base color.

 

If we have any nodes affecting the texture input or using procedural nodes, then we will need to bake.

Preparing Materials for Baking

Material Using Multiple Node Inputs for Base Color

Now that we have identified the channels that we need to bake we need to store that information into an AOV so that we can bake it to a texture. To do this, create a “Store Color To AOV” Node in our shader graph.

In this node, we can define a custom AOV or select one we have created previously. Select the newly created AOV node and shift select the parameters tab to bring up all of its options.

Now we can create a custom AOV channel.

To do this:

1. Click the drop-down under AOV name 0. Select ‘Add New Custom AOV’.


2. Name the custom AOV. 

3. Now connect the out color of the “RS Color Connect” node to the “RS Store Color to AOV” node in the “AOV input 0” input.


4. Now we can connect the out color of the “RS store color to AOV” node to the “RS Material” in the Color input. 


After applying the Store AOV node, the color of your material might appear incorrectly. This can be fixed by adding a color mix node.

Now, we can connect the outcolor of our color-correct node to input one of our color mix and connect the output of our Store RGB to Input 2.

Now, we can connect the out color of our color mix to the Base color of our RS material.

 

Now our material renders correctly and we are storing the color information in our AOV.
We can define multiple bake AOV in our material, but for our example, we only have one channel to bake. To define multiple AOVs, simply repeat the process and create a new AOV for the channel you are baking.

Materials Using A Base Color Value

If you have a material that uses a base color value instead of a texture, we will need to make some edits in our shader graph to allow us to export this correctly.

Select your material that uses values instead of textures and open the shader graph.

 

This simple material uses a color value to drive our base color. C4D has some issues exporting these values, so it is recommended to use a texture. If you can not create a texture in Photoshop, we can easily set up our material to bake out the base color.

 

To get started, we will need to create a color constant node in our shader graph.

Click on our Redshift material and right-click on the color value, and select Copy.

 

Now select our color constant node, and under the color value right-click and select paste.

 

Now we need to create a “store Aov to color” node and a Color Mix node and set up our material like we did in our previous material.

 

Now that we have prepared our material, we are ready to bake, since we do not have to bake to our original mesh, we will be baking onto a plane. This will allow us to transfer the material properties to a texture and leave our meshes UVs as is.

Baking

To create a plane, navigate to Create>Mesh>Plane.

 

This will create a polygon plane at the origin of our scene.

 

We will need to move the plane so that it is not intersecting with our asset. If we do not move it, there will be bake errors.

Now that we have moved it, we need to make the plane editable. To do this right click on our plane and select make editable.

 

After we do this, you will notice we have a UV tag applied to our plane.

 

If we shift double-click the UV tag, we can have a look at our assets UVs.

 

Now that we have confirmed our baking plane UVs are good, we can apply our material by dragging the material onto our baking plane.

 

Before we can bake, we will need to adjust a setting in our Render AOVs and create a baking set. To Adjust our AOVs, navigate to Render> RS AOV MANAGER.

Here, we can see the AOVs in our scene and we will need to check Direct for any of the AOVs we previously created. In our case, it was just the BaseColor AOV.

If we click on our AOV, we can bring up our output settings.

We can change the bake output here from EXR to .png by clicking on the drop-down for Format and selecting .png.

 

To ensure we save out the correct file format we will need to edit a render setting. To do this, navigate to Render> Edit Render Settings.

 

This opens our Render Settings window. From here Navigate to Redshift.

Now we need to Uncheck “Multi-Part EXR”. This will allow us to save the bake output in the file format we defined previously.

With that done we can now create a bake set.

To do this, select our baking plane and navigate to Redshift>Tools>Texture Baking>Create Bake Set from Selection.

This will create an RS BakeSet node in our scene graph.

In our BakeSet we can define our texture size and allows us to quickly initiate the baking process.

We recommend setting the texture size to at least 1024 x 1024.

 

After setting our texture size we can click bake, this will bring the “Bake Textures” window.

Here we can set the output location of our bake by defining the output folder. Under AOVs we will want to disable the “Default Beauty AOV”. After Setting the output folder and ensuring that Default Beauty is unchecked click Bake.


This will initiate the baking process. After it is complete, you should see the texture in the output folder.

Create, Apply a Standard Material, and Export

With the base color baked we can now create a new Standard Material and adjust the properties to match the Redshift material.

Follow the “Standard Material” section earlier in this guide to create a new Standard Material.

Below are the settings we used for this material. Note that we’ve changed the Attenuation from Additive to Metal. 

 

After we have converted all of our materials from Redshift Materials to Standard Materials we are ready to export.

If there is anything in your scene you do not wish to export, ensure that both circles next to the asset in the scene graph are set to red.

Reference the “Export Settings” section above to see our recommended export settings. 

On This Page

Accelerate Your
Digital Transformation

Learn how our platform can automate your 3D process.

Tap the magnifying glass to the left of your screen to search our resources.