Hi Zack,

  ChimeraX does not use textures for coloring most models.  Instead it uses vertex colors.  The OBJ format does not support vertex colors.  Elaine mentioned the web page which describes how you can get ChimeraX to produce texture colors in simple cases where you just have a discrete set of colors

https://www.rbvi.ucsf.edu/chimerax/data/texture-may2021/export_3d.html

That does not use a .mtl file.  ChimeraX puts the texture coordinates into the .obj file and the instructions on the above web page tell you how to write out the texture image as a .png file.  To use these in 3D modeling software you would have to open the .obj file and then assign the .png file as the texture image in that 3D modeling software.

   I agree it would be helpful if ChimeraX output a .mtl file (material file) which includes color information, but currently it only outputs single color models, for example for 3D printing, unless you use the steps described in the above web page to output a texture.

Tom


On Dec 3, 2023, at 9:05 AM, Berndsen, Zachary via ChimeraX-users <chimerax-users@cgl.ucsf.edu> wrote:

Hi Elaine,

Thanks for the fast response. It is sometimes hard to distinguish standard chimera from X documentation, so my apologies. I am working with 3D graphics programs to design cover art and obj and mlt files are both required for surface textures AND color information. I will see if I can work with the gltf file, though I know it is not nearly as common as the mlt file. Perhaps in the future the mlt file export can be integrated into ChimeraX as well, as I know standard chimera is being phased out, plus, X has far superior rendering capabilities. If I cannot use the gltf file, I can just generate an equivalent scene in standar chimera and export from there.

Thanks again,

Zack
 
Zachary Berndsen, Ph.D.
Assistant Professor
Department of Biochemistry
University of Missouri Columbia
 
 

From: Elaine Meng <meng@cgl.ucsf.edu>
Date: Sunday, December 3, 2023 at 10:41
AM
To: Berndsen, Zachary <zberndsen@missouri.edu>
Cc: chimerax-users@cgl.ucsf.edu <chimerax-users@cgl.ucsf.edu>
Subject: Re: [chimerax-users] Exporting scene with .obj and .mtl file

WARNING: This message has originated from an External Source. This may be a phishing expedition that can result in unauthorized access to our IT System. Please use proper judgment and caution when opening attachments, clicking links, or responding to this email.

Hi Zack,
You must be looking at the Chimera documentation.  ChimeraX is different, and as far as I know does not save mtl.

There is a detailed description of saving GLTF and OBJ from ChimeraX here:

<https://nam02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.rbvi.ucsf.edu%2Fchimerax%2Fdata%2Ftexture-may2021%2Fexport_3d.html&data=05%7C01%7Czberndsen%40missouri.edu%7Cc70b7023d5cb4a12f20008dbf41ec104%7Ce3fefdbef7e9401ba51a355e01b05a89%7C0%7C0%7C638372185151854400%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=VElY0TeZaiJlz19NzEaXNPs2z4ilmVRsQzBLpCZOxTs%3D&reserved=0>

I hope this helps,
Elaine
-----
Elaine C. Meng, Ph.D.
UCSF Chimera(X) team
Department of Pharmaceutical Chemistry
University of California, San Francisco

> On Dec 3, 2023, at 6:08 AM, Berndsen, Zachary via ChimeraX-users <chimerax-users@cgl.ucsf.edu> wrote:
>
> Hello,
>
> I need to export an obj file along with the associated mtl file, however, under the “file > save” option, there is only an option for saving as .obj, not .mtl. I read in the online documentation that there should be the capability to “export a scene” which saves an obj and mtl file, however I do not see this option when using v 1.6.1. Is this still supported?
>
> Thanks,
>
> Zack

_______________________________________________
ChimeraX-users mailing list -- chimerax-users@cgl.ucsf.edu
To unsubscribe send an email to chimerax-users-leave@cgl.ucsf.edu
Archives: https://mail.cgl.ucsf.edu/mailman/archives/list/chimerax-users@cgl.ucsf.edu/