开发者

Blender 2.5 Python find uv layer image

I have a mesh in blender with one uv layer that is mapped to an image. From python I want to access the properties of that image (for example name, width and height).

I can get the uv layer like this:

ob = context.active_object
me = ob.data
uv_layer = me.uv_textures[0]

# does not work:
img = uv_layer.image  

In blender 2.4x it was possible to do this: img = me.faces[0].image

How can I acce开发者_JS百科ss the image object in Blender 2.5 ?


Ok, found out how to do it:

img = me.uv_textures[0].data.values()[0].image
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜