User Tools

Site Tools


Importing to C4D

After exporting a mesh from the SpeedTree Modeler, you can use the included Cinema4D python script to load it into Cinema4D and recreate the materials as closely as possible.

You can run the script by choosing the Script / User Scripts / Run Script menu item. Or you can load it into the Script Manager and run from there.

Note: For the plugin to automatically be available in the User Scripts menu, you can place it in your script folder. Cinema4D can open this folder for you by choosing the Scripts / User Scripts / Script Folder menu item.

Importing

When the script is run, it will prompt you to load a SpeedTree Material (.stmat) file. You don't need to worry about the format of the actual mesh exported from the SpeedTree Modeler, as that information is stored in the “.stmat” file. The script will load the appropriate mesh as best it can, and replace the materials with new ones based on the material information from the SpeedTree Modeler stored in the “.stmat” file.

Extending the Script

If you wish to change how the materials are created, or add completely new material types, the script has been designed to be easily extensible in this manner.

All you need to do is change the MakeMaterial function in the python script, and the rest of the script will handle connecting it to the model appropriately.