Skip to main content
7 events
when toggle format what by license comment
Jul 22, 2017 at 18:18 comment added sambler For BI a single material can be assigned to a face, one material can use multiple textures, every enabled texture in the materials texture_slots is used by that material. For cycles a material can have multiple texture nodes, you would need to loop through all the nodes to find what textures it uses.
Jul 22, 2017 at 17:08 comment added Eewec I worked around the issue. Now instead of having just a few materials and having multiple textures for each and using them in various places, I'm using lots of materials with one texture associated with each. That way when I export, I only need to know which material it is and I'm good. Was a pain to go through and change everything over, but worth the ability to export. Once I changed the way I was dealing with materials/textures, the rest eventually fell into place. I'm also using Blender Internal. It just didn't want to pull the Active Texture except from the GUI.
Jul 22, 2017 at 12:57 comment added TLousky The active texture of the active material on that face should be the correct texture. In Blender Internal this will be easier to pull, while in Cycles it's harder to determine which texture is the "active" texture (unless you mean the one that's active in the node editor).
Jul 22, 2017 at 9:58 comment added Eewec I do have multiple Textures. But each texture is used on different surfaces. I'm trying to figure out how to export the ID of which texture slot is active for a given Face in the mesh as material.active_texture and material.active_texture_index give me the active slot in the Blender UI, not the active slot for the face of the mesh. Or at least they do when I try to use them.
Jul 22, 2017 at 9:38 comment added TLousky Oh, I thought you had multiple textures. For the active one you simply need to access material.active_texture, or material.active_texture_index.
Jul 22, 2017 at 9:36 comment added Eewec Thank you, But how do I find out which texture is active on a given face?
Jul 22, 2017 at 9:13 history answered TLousky CC BY-SA 3.0