Shading

阴影

 

Redshift supports a number of different attributes that can be used for shading inside the RS Shader Graph. You can access these differnt attributes via the shader graph through differnt User Data Nodes by using the  button to have a dropdown menu of differnt options. Alternatively, if you the know the attribute exact name you can type it in as well.

红移支持许多不同的属性,可用于在 RS 着色器图形内部的阴影。您可以通过着色器图通过不同的用户数据节点访问这些不同的属性,使用按钮有一个不同选项的下拉菜单。或者,如果您知道属性的确切名称,您也可以键入它。

Note

注意

Attribute Names are case and space sensitive.

属性名称区分大小写和空格。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Access Attributes

访问属性

Attributes

属性

Redshift supports attributes directly from X-Particles as well as attributes related to Thinking Particles (TP Data Channels). Also particles that are imported from other applications through an Alembic file (internally converted to Thinking Particles), also have there attributes imported. These can be viewed under Simulate →  Thinking Particles → Thinking Particles Settings → Channels. For more information on importing particles click here.

Redshift 支持直接来自 x 粒子的属性以及与 Thinking 粒子(TP 数据通道)相关的属性。通过 Alembic 文件(内部转换为 Thinking Particles)从其他应用程序导入的粒子也有导入的属性。这些可以在模拟→思考粒子→思考粒子设置→通道下看到。更多关于导入粒子的信息请点击这里。

Below is an example list of the imported attributes that can then be used in the Redshift Shader Graph.

下面是一个导入属性的示例列表,然后可以在红移着色器图中使用。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Thinking Particles Attributes Imported from Houdini

从 Houdini 引进的思维粒子属性

Note

注意

These above attributes are not predefined, but are dependent on the application and parameters used to export the Alembic file

以上这些属性不是预定义的,而是依赖于用于导出 Alembic 文件的应用程序和参数

Important

重要事项

The name of imported attributes must match exactly what is shown in the Data Channels list. In the above example the correct attribute name for life is life(Real) not life

导入属性的名称必须与“数据通道”列表中显示的名称完全匹配。在上面的例子中,生命的正确属性名是 life (Real)而不是 life

Particle Attribute Reference

粒子属性引用

Redshift exposes the following built-in particle attributes

红移公开以下内置粒子属性

RSPID

  • Meaning: The particle ID

    意义: 粒子 ID

  • Type: Integer

    类型: Integer

  • Availability: Emitter / Thinking Particles / X-Particles

    可用性: 发射器/思考粒子/x 粒子

RSPAge

  • Meaning: The particle current age 意义: 粒子流时代
  • Type: Scalar 类型: Scalar
  • Availability: Emitter / Thinking Particles / X-Particles 可用性: 发射器/思考粒子/x 粒子

RSPLife

  • Meaning: The particle total life span 意义: 粒子总寿命
  • Type: Scalar

    类型: Scalar

  • Availability: Emitter / Thinking Particles / X-Particles

    可用性: 发射器/思考粒子/x 粒子

RSPAgeNormalized

Rspagenorized

  • Meaning: The particle age remapped as a 0.0 to 1.0 value

    意思是: 颗粒的年龄被重新定义为0.0到1.0之间的值

  • Type: Scalar 类型: Scalar
  • Availability: Emitter / Thinking Particles / X-Particles

    可用性: 发射器/思考粒子/x 粒子

RSPColor

  • Meaning: The color of the particle

    意义: 粒子的颜色

  • Type: Color

    类型: 颜色

  • Availability: Thinking Particles / X-Particles

    可用性: 思考粒子/x 粒子

RSPVelocity

  • Meaning: The particle velocity

    意义: 粒子速度

  • Type: Scalar 类型: Scalar
  • Availability: Thinking Particles / X-Particles 可用性: 思考粒子/x 粒子

RSPMass

  • Meaning: The particle mass

    意义: 粒子质量

  • Type: Scalar 类型: Scalar
  • Availability: Thinking Particles / X-Particles 可用性: 思考粒子/x 粒子

RSPSpinAxis

旋转轴

  • Meaning: The particle rotation axis 意义: 粒子的旋转轴
  • Type: Vector 类型: Vector
  • Availability: Thinking Particles 可用性: 思考粒子

RSPSpinSpeed

  • Meaning: The particle rotation speed 意义: 粒子的转速
  • Type: Scalar 类型: Scalar
  • Availability: Thinking Particles 可用性: 思考粒子

RSPSize

  • Meaning: The particle size 意义: 颗粒大小
  • Type: Scalar 类型: Scalar
  • Availability: Thinking Particles / X-Particles 可用性: 思考粒子/x 粒子

RSPScale

  • Meaning: The particle scale 意义: 粒子尺度
  • Type: Vector 类型: Vector
  • Availability: Thinking Particles 可用性: 思考粒子

RSPAlignmentX

  • Meaning: The X-Axis of the particle alignment matrix 意义: 粒子排列矩阵的 x 轴
  • Type: Vector 类型: Vector
  • Availability: Thinking Particles

    可用性: 思考粒子

RSPAlignmentY

  • Meaning: The Y-Axis of the particle alignment matrix

    意义: 粒子排列矩阵的 y 轴

  • Type: Vector

    类型: Vector

  • Availability: Thinking Particles

    可用性: 思考粒子

RSPAlignmentZ

  • Meaning: The Z-Axis of the particle alignment matrix

    意义: 粒子排列矩阵的 z 轴

  • Type: Vector

    类型: Vector

  • Availability: Thinking Particles

    可用性: 思考粒子

RSPRandomSeed

  • Meaning: The particle random seed

    意义: 粒子的随机种子

  • Type: Integer

    类型: Integer

  • Availability: Thinking Particles

    可用性: 思考粒子

RSPGroupID

  • Meaning: The particle group ID

    意义: 粒子群 ID

  • Type: Integer

    类型: Integer

  • Availability: X-Particles

    可用性: x 粒子

RSPDensity

  • Meaning: The particle density during fluid simulations

    意义: 流体模拟过程中的粒子密度

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPRotation

突变

  • Meaning: The particle rotation vector

    意义: 粒子旋转矢量

  • Type: Vector

    类型: Vector

  • Availability: X-Particles

    可用性: x 粒子

RSPDistanceTravelled

旅行

  • Meaning: The distance traveled by the particle 意义: 粒子所经过的距离
  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPSpin

  • Meaning: The particle spin vector

    意义: 粒子自旋矢量

  • Type: Vector

    类型: Vector

  • Availability: X-Particles

    可用性: x 粒子

RSPTemperature

  • Meaning: The temperature of the particle

    意义: 粒子的温度

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPFuel

  • Meaning: The particle's fuel amount

    意义: 粒子的燃料量

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPFire

  • Meaning: The particle's fire amount

    意义: 粒子的燃烧量

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPSmoke

  • Meaning: The particle's smoke density

    意义: 粒子的烟密度

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPExpansion

  • Meaning: the particle's expansion amount

    意义: 粒子的膨胀量

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

RSPUVW

  • Meaning: The UVW coordinates of the particle

    意义: 粒子的 UVW 坐标

  • Type: Vector

    类型: Vector

  • Availability: X-Particles

    可用性: x 粒子

RSPTransparency

  • Meaning: The particle's transparency value

    意义: 粒子的透明度值

  • Type: Scalar

    类型: Scalar

  • Availability: X-Particles

    可用性: x 粒子

Particle Material

粒子材料

The Redshift Particle Material is a preset material with a Color user data set to RSPColor (Particle Color Attribute) that is connected to the Diffuse channel. This will take your Particles default color and use it as the diffuse color of your Redshift Material.

红移粒子材质是一个预设的材质,颜色用户数据设置为 RSPColor (粒子颜色属性) ,连接到漫射通道。这将采取您的粒子默认颜色,并使用它作为漫反射颜色的红移材质。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Particle Material

粒子材料

You can shade particles with a regualr Redshift Material, the Particle Material is just a preset to save you a few clicks not a special material for only particles.

你可以阴影粒子与一个调整红移材料,粒子材料只是一个预设,以节省您点击不是一个特殊的材料只为粒子。

X-Particles

X 粒子

Here is an example of our X-Particles in the viewport then with the Particle Material applied. As you can see we are getting that same grayscale gradient as our viewport now in our Renderview. Because we are working in our regular Redshift Shader Graph we can use any nodes we want in our shading process. As you can see below we can remap our grayscale gradient with a Ramp to any colors we want. To do this we connect a Ramp Node in between our User Data color node and our RS material that came connected in our default Particle Material. We set the ramp source to Alt mode (which would be our user data node using our RSPColor attribute) and change the colors to a purple and gold color in our ramp gradient.

这里是一个例子,我们的 x 粒子的视图然后与粒子材料应用。正如你所看到的,我们现在在渲染视图中得到了同样的灰度渐变效果。因为我们工作在我们的常规红移着色图,我们可以使用任何节点,我们想要在我们的阴影过程。正如你在下面看到的,我们可以用 Ramp 重新映射我们的灰度梯度到任何我们想要的颜色。为了做到这一点,我们连接一个坡道节点之间的用户数据颜色节点和我们的 RS 材料来连接在我们的默认粒子材质。我们将斜坡源设置为 Alt 模式(使用 RSPColor 属性的用户数据节点) ,并在斜坡渐变中将颜色更改为紫色和金色。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Viewport X-Particles Viewport x 粒子 Defualt Particle Material applied 应用脱盐粒子材料 Remapped Particle Material applied 应用重塑颗粒材料

 

Another attribute we can use to shade our X-Particles is the RSPAgeNormalized. To use this we need a Scalar Data Node and set the attribute to Age Normalized. This will allow us to control our particle colors based on there age (How long the particle stays alive).

另一个我们可以用来遮蔽 x 粒子的属性是 rspagennorized。要使用这个属性,我们需要一个标量数据节点并将属性设置为 Age Normalized。这将允许我们控制我们的粒子颜色的基础上有年龄(多久的粒子保持活着)。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Scalar User Data Node

标量用户数据节点

Add a Ramp node in between our Scalar User Data and Diffuse color and add a couple of colors to our ramp node. Make sure the ramp source is set to alt.

在标量用户数据和漫反射颜色之间添加一个 Ramp 节点,并向 Ramp 节点添加一对颜色。确保斜坡源设置为 alt。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君
RS Ramp

遥感坡道

As you can see now as we progress through our time line the particles are changing colors based off there age going from left to right on our ramp gradient.

正如你现在可以看到的,当我们在时间线上前进的时候,粒子会随着时间的推移而改变颜色,在我们的斜坡梯度上从左到右。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Timeline at 5 seconds 时间线5秒 Timeline at 10 seconds 10秒的时间线 Timeline at 15 seconds 15秒的时间线

 

Alembic Particles / Thinking Particles

粒子/思考粒子

Whether you are working with Thinking Particles inside of Cinema 4D or have imported particles through an Alembic file (more information here), Redshift supports a number of different attributes that can be used for shading. To look at all the attributes available for you to use, you can go to your Thinking Particles settings and look at the channels. Below is a particle system imported through an Alembic file from Houdini.

不管你是使用 Cinema 4D 内部的 Thinking Particles 还是通过 Alembic 文件导入粒子(更多信息在这里) ,Redshift 支持许多不同的属性,可用于阴影。要查看可供使用的所有属性,您可以进入 Thinking Particles 设置并查看通道。下面是一个粒子系统,通过一个 Alembic 文件从 Houdini 导入。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Thinking Partciles Data Channels

数据通道的思考

To shade these particles we are going to use the pScale attribute inside our shader graph. So let's create a new Particle Material and bring a Scalar user data node and set the attribute to pScale.

为了给这些粒子加阴影,我们将在着色器图中使用 pScale 属性。因此,让我们创建一个新的粒子材质,带来一个 Scalar 用户数据节点,并将属性设置为 pScale。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Scalar User Data

标量用户数据

Next we bring in a Ramp node to remap our Scalar User Data. We want to connect this in between our Scalar User Data and our RS material and set the source mode to Alt. Then we are going to choose two different colors.

接下来,我们引入 Ramp 节点来重新映射标量用户数据。我们希望在标量用户数据和 RS 材料之间连接这个,并将源模式设置为 Alt。然后我们要选择两种不同的颜色。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Remapping Scalar data

重新映射标量数据


As you can see now the color is changing based on the size of our particles. The bigger particles in the middle stay green and the particles that are flying away and getting smaller are turning purple.

正如你现在可以看到的颜色正在改变基于我们的粒子的大小。中间较大的粒子保持绿色,而那些飞走变小的粒子则变成紫色。

C4D周练作业-Shading 阴影—RS渲染粒子—Redshift红移中文帮助文档手册-苦七君

Particles shaded based on pScale

基于 pScale 的粒子阴影

Any scalar value can be fed into a Ramp node to remap the colors from left (0.0) to right to (1.0). You can also use a change range to scale a real number to a scalar, for example a value from 0-300 can be remapped to 0-1.

任何标量值都可以输入 Ramp 节点,以将颜色从左(0.0)重新映射到右(1.0)。您还可以使用更改范围将实数扩展为标量,例如,可以将0-300的值重新映射为0-1。

1

赶快留个言打破零评论!~

返回顶部

显示

忘记密码?

显示

显示

获取验证码

Close