Parameter
参数
灯光
To choose which light the node will test, Drag & drop the light’s name into this box.
要选择测试哪个灯光节点,请将灯光的名称拖放到此框中。
阈值[-∞ . . + ∞]
With the help of this value, you can use the PLight node to control actions based on the brightness of a light source at a particular position in 3D space (defined by the Position values).
有了这个值的帮助,您可以使用 PLight 节点根据3D 空间中特定位置(由位置值定义)的光源亮度来控制操作。
The node outputs a Boole value of either True or False depending on whether the light’s intensity exceeds the Threshold value at this position in 3D space. The node’s On port outputs the value False if the light’s brightness is less than or the same as the Threshold, or True if it exceeds the Threshold. A Threshold of 1 equals a light intensity of 100%.
节点输出一个 Boole 值,真或假取决于光的强度是否超过阈值在这个位置的三维空间。如果光的亮度小于或等于阈值,则节点的 On 端口输出值 False,如果超过阈值,则输出值 True。阈值1等于光强度的100% 。
For example, suppose you want a PStorm node to emit particles only when a light’s intensity exceeds 50% at the world coordinates 200,10,-50. In this case, you would create a PLight node, Drag & drop the name of the light into the Light box, set the Position values to 200,10,-50 and the Threshold value to 0.5 (0.5 x 100 = 50%). You would then connect the PLight node to the PStorm node via their On ports.
例如,假设您希望 PStorm 节点只在世界坐标200、10、-50处光强超过50% 时发射粒子。在这种情况下,您将创建一个 PLight 节点,将灯的名称拖放到 Light 框中,将 Position 值设置为200,10,-50,并将 Threshold 值设置为0.5(0.5 x 100 = 50%)。然后,您将通过它们的 On 端口将 PStorm 节点连接到 PStorm 节点。
颜色
If you want to control actions based on the color of a light source at a particular position in 3D space (defined by the Position values), enable Color and set Threshold to 0 (if you don’t set the Threshold to 0, the light’s brightness will be evaluated also).
如果你想基于光源在3D 空间特定位置的颜色来控制动作(由位置值定义) ,启用颜色并将阈值设置为0(如果你没有将阈值设置为0,光的亮度也将被评估)。
The node will output a Boole value of True or False depending on whether the light’s color is the same as (or similar to, depending on the Color Variation setting) the color defined by the Color setting at this position in 3D space. The node’s On port outputs True if the two colors are the same/similar, otherwise it gives the value False.
节点将输出一个 Boole 值 True 或 False,这取决于光的颜色是否与3D 空间中这个位置的 Color 设置定义的颜色相同(或类似,取决于颜色变化设置)。如果两个颜色相同/相似,则节点的 On 端口输出 True,否则它将给出值 False。
颜色
If you want to control actions based on a light’s color and brightness, in addition set the Threshold value to the desired brightness. See Threshold, above. The node’s On port will then only output the value True if the light’s brightness exceeds the Threshold value and the light’s color is the same/similar color as the Color setting.
如果您希望根据光线的颜色和亮度控制操作,另外还可以将阈值设置为所需的亮度。参见上面的 Threshold。如果光的亮度超过阈值,并且光的颜色与 Color 设置相同或相似,那么节点的 On 端口将只输出值 True。
颜色变化[0. . 100% ]
The Color Variation setting defines how similar — defined as a percentage — the light’s color and the Color setting must be in order to produce a True value. For example, with a value of 0%, the colors must match exactly in order to produce an output of True, while a value of 100% means the colors will match regardless.
色彩变化设置定义了为了产生真值,光的颜色和色彩设置必须有多么相似(定义为百分比)。例如,如果值为0% ,则颜色必须完全匹配才能生成 True 的输出,而如果值为100% ,则意味着无论如何颜色都将匹配。
位置[ XYZ ]
This value defines position at which the light’s value(s) should be checked.
这个值定义了灯光值应该被检查的位置。
正常
A normal is a directional vector with a length of 1, which is often used to help calculate the shading of a polygon surface. A normal can be passed to this port in order to influence the light intensity at a given position.
法线是一个长度为1的方向矢量,它通常用于帮助计算多边形曲面的着色。为了影响给定位置的光强,可以将法线传递到这个端口。
If no vector is present, a normal that points towards the light source will be generated automatically. The light will thus fall orthogonally (at right-angles) onto the virtual surface and will therefore be at its maximum brightness.
如果没有矢量存在,则会自动生成指向光源的法线。因此,光将垂直地(以直角)落在虚拟表面上,因此将达到其最大亮度。
Keep in mind that a normal pointing towards the light rays themselves, rather than at the light object, will cause the light to shine onto the backface of a surface. Thus an intensity of 0 may result, even if the light illuminates the exact given position.
请记住,一个正常的指向光线本身,而不是指向发光物体,会导致光线照射到表面的背面。因此,即使光照亮了确切的给定位置,也可能会产生0的强度。
Additional input ports:
其他输入端口:
动画时间
Since the node’s parameters can be keyframe animated, by default the Cinema 4D time is used internally to ensure that the values are interpolated correctly. However, you can pass your own time value to this port. This should be of the data type Time, which is a Real number in the simplest case. If no value is passed, Cinema 4D’s time is used.
由于节点的参数可以是关键帧动画,默认情况下 Cinema 4D 时间在内部使用,以确保值被正确插值。但是,您可以将自己的时间值传递到此端口。这应该是数据类型 Time,在最简单的情况下,它是一个实数。如果没有值传递,使用 Cinema 4D 的时间。
关于•
Outputs a Boole value of either True or False depending on the light’s brightness and/or color at a particular position in 3D space (defined by the Position values). See Threshold and Color On, Color, Color Variation above.
根据光线的亮度和/或3D 空间中特定位置的颜色(由位置值定义) ,输出 Boole 值为 True 或 False。参见上面的阈值和颜色,颜色,颜色变化。
强度[-∞ . . + ∞]•
Outputs the brightness of the light as a Float value at the position defined by the Position values. An Intensity value of 0 represents 0% brightness, a value of 1 represents 100% brightness.
将光线的亮度输出为位置值定义的位置处的浮点值。强度值0代表0% 的亮度,值1代表100% 的亮度。
颜色•
Outputs the RGB color of the light at the position defined by the Position values.
在位置值定义的位置输出光的 RGB 颜色。
方向•
Outputs the directional vector between the light’s position and the position defined by the Position values. This vector can also be calculated manually by subtracting the light’s position from the Position values.
输出光的位置和位置值定义的位置之间的方向矢量。这个矢量也可以通过从位置值中减去光线的位置来手动计算。