混合节点#

混合节点。

将两幅图像混合在一起,类似于图像编辑程序混合两个图层。

Important

自 Blender 3.4 起,着色器与几何节点编辑器中的该节点已更新。使用新节点保存的文件将不能向后兼容。

输入#

系数

前景图像的不透明度。

图像/A/颜色1

背景图像,决定了输出尺寸。

图像/B/颜色2

前景图像。

需注意,与图像编辑程序将前景图层置于顶部的做法不同,Blender 中的前景槽位于底部。

属性#

数据类型 着色器编辑器 几何节点编辑器

要混合的数据类型:浮点、矢量,或颜色。

系数模式 着色器编辑器 几何节点编辑器
均衡

相同的单个系数应用于全部三个矢量坐标中。

非均匀

您可以指定不同的系数到每个矢量坐标。

混合模式

要使用的 混合模式

混合

常规alpha混合。在图像编辑程序中一般被称作 正常

变暗

For each color component, takes the smallest of the two values being blended.

正片叠底(相乘)

Multiplies the colors component by component. Blending with a white pixel (value 1.0) has no effect, while blending with a black one (0.0) always results in black.

颜色加深

Inverts the background color, divides it by the foreground color, and inverts the result.

变亮

For each color component, takes the largest of the two values being blended.

滤色

反转两种颜色,再相乘,然后反转相乘后的结果。

颜色减淡

Divides the background color by the inverted foreground color.

相加

将两种颜色相加。

叠加

如果前景色亮度低于 0.5,执行正片叠底混合,否则执行滤色混合。

柔光

类似于叠加,但较为不明显。

线性光

Applies Linear Burn blending (background + foregound - 1) if the foreground color's lightness is below 0.5, or Linear Dodge (background + foreground) if it's above.

差值

For each component, subtracts the lower value from the higher value.

排除

两种颜色相加,然后减去其乘积两次。

相减

Subtracts the foreground color from the background color.

相除

Divides the background color by the foreground color.

色相

Combines the saturation and value of the background color with the hue of the foreground color.

饱和度

Combines the hue and value of the background color with the saturation of the foreground color.

颜色

Combines the value of the background color with the hue and saturation of the foreground color.

明度

Combines the hue and saturation of the background color with the value of the foreground color.

使用 Alpha

Whether to use the alpha channel of the foreground image during mixing. The alpha channel of the background image is always used.

钳制/钳制结果

将输出值限制在0.0到1.0之间。

钳制系数 着色器编辑器 几何节点编辑器

将系数限制在0.0到1.0之间。

输出#

图像/结果/颜色

混合操作的结果。

示例#

Below are examples of blending modes, as well as some practical use cases.

../../../../_images/compositing_types_color_mix_blend-modes.png

Blending a colored pattern with a flat color (top row) and a circular mask (bottom row).#

修正过曝#

如下所示的合成配置展示了如何通过压暗和增强对比度来修复一个过曝的渲染。

../../../../_images/compositing_types_color_mix_contrast-enhancement.png

Example node setup showing two RGB Curves nodes and a Mix node for composition.#

The top RGB曲线节点 darkens the image by linearly scaling each color value to a smaller one.

The bottom curve node increases constract by making small values smaller and large values larger.

最后,由混合节点来混合两者。

水印图像#

In the old days, a pattern was pressed into the paper mush as it dried, creating a mark that identified who made the paper and where it came from. The mark was barely perceptible except in just the right light. Probably the first form of subliminal advertising.

Nowadays, people watermark their images to identify them as personal intellectual property, for subliminal advertising of the author or hosting service, or simply to track their image's proliferation throughout the web.

Blender provides a complete set of tools for you to both encode your watermark and to tell if an image has your watermark.

在图像中设置水印#

First, construct your own personal watermark. You can use your name, a word, or a shape or image not easily replicated. While neutral gray works best using the encoding method suggested, you are free to use other colors or patterns. It can be a single pixel or a whole gradient; it is up to you.

In the example below, we are encoding the watermark in a specific location in the image using the Translate node; this helps later because we only have to look at a specific location for the mark. We then use the RGB to BW node to convert the color image to grayscale numbers, which we then feed into the Map Range node to reduce the mark to one-tenth of its original intensity.

The Add node (Mix node with blending mode Add) adds the corresponding pixels, making the ones containing the mark ever-so-slightly brighter.

../../../../_images/compositing_types_color_mix_watermark-encode.png

在图像中嵌入水印。#

当然,如果想让人们注意到你的水印标记,请不要把它缩的太小,或者你可以把它变成对比色。当然也有许多其他的方法,比如使用其他混合设置和更高级的功能,你可以随意尝试!

为你的水印解码图像#

When you see an image that you think might be yours, use the node tree below to compare it to your stock image (pre-watermarked original). In this tree, the Mix node is set to Difference, and the Map Value node amplifies any difference. You can see how the original mark clearly stands out.

../../../../_images/compositing_types_color_mix_watermark-decode.png

检查图像的水印。#