RayObject Struct Reference

#include <c4d_raytrace.h>

Public Attributes

Char   type
Char   flag_phong
Char   flag_castshadow
Char   flag_receiveshadow
Char   flag_seenbycamera
Char   flag_compositing
Char   flag_selfshadow
Char   flag_seenbygi
Char   flag_matteobject
Char   flag_seenbydetails
Char   flag_instanced
向量   v2
向量   mp
向量   rad
Float   visibility
Float   phong_angle
向量 padr
Int32   pcnt
const RayPolygon vadr
Int32   vcnt
TexList *  texadr
Int32   texcnt
const void **  uvwadr
Int32   uvwcnt
UInt32 **  rsadr
Int32   rscnt
BaseObject link
Matrix64   mg
Matrix64   mg_inverse
矩阵   motion_delta
Float   oblurlen
Char   aa_minlevel
Char   aa_maxlevel
Float   aa_threshold
Int16   channelid [12]
BaseObject texture_link
向量   default_color
Int32   restriction_index
UChar edges
Int16 psum
Int32   spd_displacement
Float   spd_height
Char   spd_keepedges
Char   spd_distribution
Char   spd_round
Char   spd_roundcontour
Char   spd_hqremapping
Char   spd_mapresult
void *  userdata
ObjectRestriction   rr
RayObjectInstanceData instance
Int16 **  tex_tsum
Char   flag_compositing_gi
Bool   forceDefaultColor

Protected Member Functions

  RayObject ()

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

◆  RayObject()

RayObject ( )
protected

Member Data Documentation

◆  type

Char type

Object type: RayObjectTypes
Special types such as O_SPHERE have no polygonal geometry, thus all values like padr and vadr are nullptr .

◆  flag_phong

Char flag_phong

Phong flag.

◆  flag_castshadow

Char flag_castshadow

Cast shadow flag.

◆  flag_receiveshadow

Char flag_receiveshadow

Receive shadow flag.

◆  flag_seenbycamera

Char flag_seenbycamera

Seen by camera flag.

◆  flag_compositing

Char flag_compositing

Compositing flag. Catches shadows.

◆  flag_selfshadow

Char flag_selfshadow

Self shadowing flag.

◆  flag_seenbygi

Char flag_seenbygi

Seen by GI flag.

◆  flag_matteobject

Char flag_matteobject

Object is matte object flag.

◆  flag_seenbydetails

Char flag_seenbydetails

Seen by details flag: OBJECTRESTRICTION .

◆  flag_instanced

Char flag_instanced

Object instanced flag.

◆  v2

向量 v2

Normal in Y direction.

◆  mp

向量 mp

Center of bounding box.

◆  rad

向量 rad

Radius of bounding box.

◆  visibility

Float visibility

Object visibility. This is the information about the object dissolve (see the Timeline and the Visibility track) in the range from 0.0 to 1.0 .

◆  phong_angle

Float phong_angle

Phong angle.

◆  padr

向量 * padr

Address of the point array for the object. Can be nullptr for non O_POLYGON 元素。

◆  pcnt

Int32 pcnt

Number of points for this object.

◆  vadr

const RayPolygon * vadr

Address of the polygons array. Can be nullptr for non O_POLYGON 元素。

◆  vcnt

Int32 vcnt

Number of polygons for this object.

◆  texadr

TexList* texadr

Address of the texture array. Can be nullptr , always check.

注意
It is not possible to access textures directly. Use VolumeData::GetTexData() instead.

◆  texcnt

Int32 texcnt

Number of textures.

◆  uvwadr

const void** uvwadr

Address of the UVW coordinate sets. Can be nullptr , always check.

注意
It is not possible to access UVWs directly. Use VolumeData::GetUVW() instead.
The UVW sets range from 1 to uvwcnt-1 .

◆  uvwcnt

Int32 uvwcnt

Number of UVW coordinate sets.

◆  rsadr

UInt32 ** rsadr

Address of the object's restriction. Can be nullptr , always check.

注意
It is possible to access the restriction directly. The restriction sets range from 1 to rscnt-1 .

◆  rscnt

Int32 rscnt

Number of object's restriction.

◆  link

BaseObject * link

Link to real Cinema 4D object. Can be nullptr , always check.

◆  mg

Matrix64 mg

World matrix for the object.

◆  mg_inverse

Matrix64 mg_inverse

Inverse object matrix.

◆  motion_delta

矩阵 motion_delta

Motion transformation matrix. This is oldmg * !newmg . The delta time is always 1/fps.

注意
The VIDEOPOSTINFO::REQUEST_MOTIONMATRIX flag must be set for this value to be calculated.

◆  oblurlen

Float oblurlen

Object blur strength.

◆  aa_minlevel

Char aa_minlevel

Minimum antialiasing level.

◆  aa_maxlevel

Char aa_maxlevel

Maximum antialiasing level.

◆  aa_threshold

Float aa_threshold

Antialiasing threshold.

◆  channelid

Int16 channelid[12]

Object buffer IDs.

◆  texture_link

BaseObject * texture_link

Link to the real object that inherited the texture tag. Can be nullptr , always check.

◆  default_color

向量 default_color

Object default color.

◆  restriction_index

Int32 restriction_index

Index to light/object restriction table.

◆  edges

UChar * edges

Address of the edges array, one per polygon. Can be nullptr , always check.
Bits 0 to 3 indicate hiding of edge A to D, bits 4 to 7 indicate the broken phong property.

◆  psum

Int16 * psum

Private . Phong normals. Access depends on mode.

◆  spd_displacement

Int32 spd_displacement

Sub-pixel displacement subdivision.

◆  spd_height

Float spd_height

Maximum displacement height, taking the strength into account.

◆  spd_keepedges

Char spd_keepedges

Sub-pixel displacement keep edge setting.

◆  spd_distribution

Char spd_distribution

Sub-pixel displacement best distribution setting.

◆  spd_round

Char spd_round

Sub-pixel displacement round setting.

◆  spd_roundcontour

Char spd_roundcontour

Sub-pixel displacement round contour setting.

◆  spd_hqremapping

Char spd_hqremapping

Sub-pixel displacement high quality remapping setting.

◆  spd_mapresult

Char spd_mapresult

Sub-pixel displacement map geometry setting.

◆  userdata

void* userdata

Only to be used by plugin renderers.

◆  rr

ObjectRestriction rr

Compositing tag restriction.

◆  instance

RayObjectInstanceData * instance

The render instance data. If not nullptr the object is a render instance.

◆  tex_tsum

Int16 ** tex_tsum

Address of the precomputed tangents for each UV channel used in VolumeData::GetDUDV() .
Just like the smooth normals, the way the data is stored depends on the mode (in same way as it does for phong). Can be nullptr , always check.
Only one tangent vector is stored. The second can be easily computed by cross product with the normal vector.

◆  flag_compositing_gi

Char flag_compositing_gi

New compositing flag for Sky mode as seen in the Compositing Tag.

◆  forceDefaultColor

Bool forceDefaultColor

force the use of default color. added for R20.