光线传送 BSDF

仅限 Cycles

光线传送 BSDF 节点可将照到场景中的其他位置传送过来。该节点可用于渲染视觉特效中的传送门效果,以及其他产品级的渲染技巧。

就像 透射 BSDF 材质一样,它也会传送渲染通道,而且受到光程最大透射次数的限制。

Note

  • 光线传送 BSDF 节点仅允许光线单向通过。若要光线双向传输,需在目标位置也添加一个传送门。

  • 传送门的光线采样效率较低。这会导致来自传送门另一侧光源的噪点显著增加。特别是小型光源可能出现严重噪点,甚至光线根本没有透过传送门。

输入

颜色

Tint rays passing through the portal.

位置

Ray start position at new location. Defaults to the current position, matching the Position output of the Geometry node.

方向

Ray direction at the new location. Defaults to the current view direction, which is the same as the negation of the Incoming output of the Geometry node.

属性

该节点没有属性。

输出

BSDF

标准着色器输出。

示例

One use case for the Ray Portal BSDF is to connect two spaces together to create effects like a portal to an alternative dimension, or "impossible spaces" where something is bigger or smaller on the inside than expected.

To set up a Ray Portal BSDF for a technique like this, augment the Position and Incoming outputs of the Geometry node to set the exit point and direction of the ray through the portal. Here are some examples:

简单偏移

../../../_images/render_shader-nodes_ray-portal-bsdf_simple-ray-offset-nodes.jpg

This simple node setup offsets the ray position. In this example, the ray is offset 0 units along the X axis, 4 units along the Y axis, and 5 units along the Z axis.

传送门

../../../_images/render_shader-nodes_ray-portal-bsdf_gateway-example.jpg
../../../_images/render_shader-nodes_ray-portal-bsdf_ray-augmentation-nodes.jpg

In this example, the Location of Portal Target and Rotation of Portal Target vectors are obtained from a target portal object using Drivers.

Camera Feed

Along with augmenting rays, the ray position and ray direction can be replaced, for effects like a camera feed on a screen.

../../../_images/render_shader-nodes_ray-portal-bsdf_portal-to-screen-example.jpg

Using the Ray Portal BSDF to replicate the effect of a camera feed on a screen.

../../../_images/render_shader-nodes_ray-portal-bsdf_portal-to-screen-nodes.jpg

Node setup for replicating a camera feed like effect on a screen.