ChannelData Struct Reference

#include <c4d_shader.h>

公共成员函数

  ChannelData ()
  ChannelData ( BaseVolumeData *t_vd)
Int32   GetCurrentCPU ()

Public Attributes

向量   p
向量   n
向量   d
Float   t
Int32   texflag
VolumeData vd
Float   off
Float   scale

构造函数 & 析构函数文档编制

◆  ChannelData() [1/2]

ChannelData ( )

Default constructor.

◆  ChannelData() [2/2]

ChannelData ( BaseVolumeData t_vd )
explicit

Constructs a ChannelData that matches the current state of a BaseVolumeData .

参数
[in] t_vd The volume data to take p , n and d from. The caller owns the pointed volume data.

成员函数文档编制

◆  GetCurrentCPU()

Int32 GetCurrentCPU ( )

Retrieves the current thread index on which the shader is executed.

由于
R16.038
注意
GetCurrentCPU() exists as a member of ChannelData and VolumeData , both yielding the same results.
However if no VolumeData is present (and only then!) a channel shader calculation can also be called with ChannelData::vd 设为 nullptr .
In that case (or generally) use ChannelData::GetCurrentCPU() .
返回
The running thread index, which is guaranteed to be >= 0 and smaller than the thread count that was passed during InitRender() .

Member Data Documentation

◆  p

向量 p

[READ ONLY] The texture position in UVW coordinates.

◆  n

向量 n

[READ ONLY] The surface normal.

◆  d

向量 d

[READ ONLY] The MIP sample radius in UVW coordinates.

◆  t

Float t

[READ ONLY] The current time in seconds.

◆  texflag

Int32 texflag

[READ ONLY] The texture flags: TEX

◆  vd

VolumeData * vd

[READ ONLY] The volume information, can be nullptr .

◆  off

Float off

◆  scale

Float scale

[READ ONLY] The MIP blur offset.