blender29python各种活动

山西白癜风QQ交流群 http://www.ruidunet.cn/guanzhu/2833.html

如何通过BlenderPythonAPI从脚本访问blender活动对象:

活动窗口(在其中发生当前操作):bpy.context.area.spaces.active

活动场景:bpy.context.screen.scene

活动(选定)网格:bpy.context.active_object

活动(选定)材质节点(在NODE_EDITOR窗口中):bpy.context.active_object.active_material.node_tree.nodes.active

活动(选定)材料节点(在合成窗口中):bpy.context.scene.node_tree.nodes.active

窗口中的当前TEXT_EDITOR文本:bpy.context.area.spaces.active.text.as_string()

活动(选定)UV贴图:bpy.context.active_object.data.uv_layers.active

用户首选项窗口中的当前页面:bpy.context.user_preferences.active_section

当前世界:bpy.context.scene.world

当前世界节点树(环境):bpy.context.scene.world.node_tree




转载请注明:http://www.aierlanlan.com/rzgz/3378.html