Use bpy.types.Mesh.materials, bmesh data doesnt know about materials,
only their index - this is the case in our C code too.

On Fri, Jun 1, 2012 at 12:13 PM, Antonio Ospite
<[email protected]> wrote:
> Hi,
>
> I am playing with the bmesh API for VRM[1].
>
> There are still a couple of things I miss, one of them is: how can
> I access mesh materials from the bmesh interface?
>
> I see that there is a bmesh.types.BMFace.material_index but there is
> not a bmesh.types.BMesh.materials so I am not able to retrieve the
> actual material of a face using only the bmesh API.
>
> Can bmesh.types.BMesh.materials be added?
> Or am I supposed to keep using bpy.types.Mesh.materials to retrieve mesh
> materials?
>
> Thanks,
>   Antonio
>
> [1] http://vrm.ao2.it/
>
> --
> Antonio Ospite
> http://ao2.it
>
> A: Because it messes up the order in which people normally read text.
>   See http://en.wikipedia.org/wiki/Posting_style
> Q: Why is top-posting such a bad thing?
> _______________________________________________
> Bf-python mailing list
> [email protected]
> http://lists.blender.org/mailman/listinfo/bf-python



-- 
- Campbell
_______________________________________________
Bf-python mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-python

Reply via email to