rB15186f4259a2e0611a64a3aed8db8858e8ca081f.. _bpy.types.ShaderNodeObjectInfo:

物体信息节点

物体信息节点。

物体信息 节点提供有关物体实例的信息。它可以方便地为指定了同一材质的不同实例提供变化的材质效果,比如根据手动设置的物体索引编号,根据物体的位置,或是根据不同实例随机产生变化。例如,使用噪波纹理节点可以提供随机颜色,或者使用颜色渐变节点来提供可供随机选择的颜色范围。

输入

该节点没有输入项。

属性

这个节点没有属性。

输出

位置

物体在世界空间中的位置。

颜色

Object color, same as Color in the Properties ‣ Object Properties ‣ Viewport Display.

Alpha

The Alpha Channel component of the object’s viewport display color (see the Color output for more details).

物体编号

Object pass index, same as Pass Index in the Properties ‣ Object Properties ‣ Relations.

材质编号

Material pass index, same as Pass Index in the Properties ‣ Material ‣ Settings.

随机

单个对象实例的唯一随机数。

Note

该节点仅适用于材质着色器节点,对光和世界着色器节点不起作用。

例子

../../../_images/render_shader-nodes_input_object-info_example.png

../../../_images/render_cycles_render-settings_motion-blur_example-cubes.jpg

点击 示例文件 ,可下载上图中的blender文件。