CV-SmartExport: Overview
Posted: 13 February 2018 02:11 PM   [ Ignore ]  
Total Posts:  5
Joined  2013-02-05

What are the correct places to put maps so that the .mtl file correctly links them?  For instance, in R19, where would I put a spec map in my material?

Profile
 
 
Posted: 13 February 2018 02:53 PM   [ Ignore ]   [ # 1 ]  
Moderator
Avatar
Total Posts:  5237
Joined  2011-03-03

Hi pfranks,

The ‘.mtl” file should be where the “.obj” file is. Same level in the target folder.

If you like to have the texture loaded back into Cinema4D, you need to specify the Preferences>Files>Asset Path: “path where the textures are”.
Then Cinema 4D will load it correctly.
https://help.maxon.net/us/#FOBJIMPORT2-OBJIMPORTOPTIONS_GROUP

You can open the mtl file in an text app, to see if the texture name is inside. Some application work with an absolute path. The mtl is based on your set up, relative or absolute.

If the exported file goes to another network/computer, perhaps place the images inside the same folder

R19, so far I can see here doesn’t read absolute path, I’m not certain if that is deliberate, you might check with the support, the manual leaves that open.
https://www.maxon.net/en-us/support/how-can-we-help/

However, if you create or have a scene file, that is already saved, and which has on the same folder level a tex folder with the needed textures in it, a File>Merge will place the needed texture based on the mtl in the right channel. I tested specular here, as mentioned.

All the best

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.

Photography For C4D Artists: 200 Free Tutorials: Texture, Panorama, HDRI, Camera Projection, etc.
https://www.youtube.com/user/DrSassiLA/playlists

Profile
 
 
Posted: 14 February 2018 09:08 AM   [ Ignore ]   [ # 2 ]  
Total Posts:  5
Joined  2013-02-05

Thanks for the reply, but I should’ve been more clear.  I want to know the places to put the maps while in the C4D material to make them show up in the .mtl file when I open it with a text editor.  For example, the color channel will show in the .mtl with a map, and the specularity will show up if I put it in the Layer Color texture slot under the Reflectance channel.  Is there a list of all the maps that can be applied and where they need to be added?  Bump and Normal maps don’t seem to transfer to the .mtl.

Thanks!

Profile
 
 
Posted: 14 February 2018 09:35 AM   [ Ignore ]   [ # 3 ]  
Moderator
Avatar
Total Posts:  5237
Joined  2011-03-03

Hi pfranks,

I’m not certain if you are looking for something completely different than discussed in the tutorial, like a “White Paper” for obj/mtl. I haven’t found one, but fil the whole C4D material with clearly named images, and export an obj, then you have all needed coding for mtl in regard of C4D use. The best I was able to find was this overview:
https://en.wikipedia.org/wiki/Wavefront_.obj_file

Once they are in Cinema 4D, the location shouldn’t matter. The only thing one can do, is to decide if the path is absolute or relative.
IF your main target is to export and supply it for other artists, you might create an folder and place all textures already there and start using them in C4D from that location. I would use absolute path the. (Answering the question with NO after applying the texture to a material.

However:
• Some studios like to have all texture on a specific server.
• Some people create for each project everything new and keep it in the project folder.
Just to name to very specific texture managements. Yours could be one of them or anything in between.


All the best

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.

Photography For C4D Artists: 200 Free Tutorials: Texture, Panorama, HDRI, Camera Projection, etc.
https://www.youtube.com/user/DrSassiLA/playlists

Profile
 
 
Posted: 14 February 2018 11:19 AM   [ Ignore ]   [ # 4 ]  
Total Posts:  5
Joined  2013-02-05

That Wikipedia link helps a lot, thank you.  It shows me which texture maps can be used.  I guess I can type them in manually in the .mtl, but I was looking for a way to link them automatically on export from .c4d.  It doesn’t work for all maps.  I can get the color and specularity maps to link, but not the bump.  If I put a texture in the bump channel of a material and export as .obj with the CV export, the .mtl doesn’t show a bump map entry.

Profile
 
 
Posted: 14 February 2018 11:40 AM   [ Ignore ]   [ # 5 ]  
Moderator
Avatar
Total Posts:  5237
Joined  2011-03-03

Well, pfranks, I can only point again to check this with the support, or the manual. I can’t change the application’s behavior. Note that the manual refers to the material, not to textures.
Since Autodesk is the last known owner of the app (Alias | Wavefront), I wrote to them for a White Paper. If I get a reply from them, I will share the information of course.

All the best

P.S.:
No idea how valid this is…
http://paulbourke.net/dataformats/mtl/
The extension definitions [suffix] seems questionable, and perhaps lead even to more problems.
====

Material

Materials and texture paths in OBJ format will be defined in a separate file (*.mtl). Use this setting to define if and how materials should be exported. Only UV projections will be exported. Since the OBJ and Cinema 4D material systems cannot be transferred to one another loss-free, it is often sufficient to export only material assignments (but not the material itself) using the Export Name and Default option and then replace the materials in the application used to render the scene with better/adapted materials.

The following options are available:

No Material

No *.mtl file will be exported.

Export Name and Default

All existing material assignments will be maintained and the materials themselves will be replaced by preset materials (either White or Random Colors, as defined in the Default Material setting)

Export Materials

If this option is selected, selected materials and those assigned to polygonal objects will be “translated” and exported as defined in Cinema 4D.

Tip:
it’s always recommended not to use spaces in bitmap names. Other applications can experience problems when importing these files.

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.

Photography For C4D Artists: 200 Free Tutorials: Texture, Panorama, HDRI, Camera Projection, etc.
https://www.youtube.com/user/DrSassiLA/playlists

Profile
 
 
Posted: 14 February 2018 12:18 PM   [ Ignore ]   [ # 6 ]  
Total Posts:  5
Joined  2013-02-05

It gets pretty involved, but I have enough info to figure out what I need.  Thank you for your help!

Profile
 
 
Posted: 14 February 2018 12:20 PM   [ Ignore ]   [ # 7 ]  
Moderator
Avatar
Total Posts:  5237
Joined  2011-03-03

Thanks for the feedback, pfranks, you’re welcome, even if there is no direct solution at the moment.

I tried example 12 from the last link but it stopped working all together. wink

My best wishes for your project.

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.

Photography For C4D Artists: 200 Free Tutorials: Texture, Panorama, HDRI, Camera Projection, etc.
https://www.youtube.com/user/DrSassiLA/playlists

Profile