1RTCRay(3)                Embree Ray Tracing Kernels 4                RTCRay(3)
2
3
4
5   NAME
6              RTCRay - single ray structure
7
8   SYNOPSIS
9              #include <embree4/rtcore_ray.h>
10
11              struct RTC_ALIGN(16) RTCRay
12              {
13                float org_x;        // x coordinate of ray origin
14                float org_y;        // y coordinate of ray origin
15                float org_z;        // z coordinate of ray origin
16                float tnear;        // start of ray segment
17
18                float dir_x;        // x coordinate of ray direction
19                float dir_y;        // y coordinate of ray direction
20                float dir_z;        // z coordinate of ray direction
21                float time;         // time of this ray for motion blur
22
23                float tfar;         // end of ray segment (set to hit distance)
24                unsigned int mask;  // ray mask
25                unsigned int id;    // ray ID
26                unsigned int flags; // ray flags
27              };
28
29   DESCRIPTION
30       The  RTCRay structure defines the ray layout for a single ray.  The ray
31       contains the origin (org_x, org_y,  org_z  members),  direction  vector
32       (dir_x,  dir_y,  dir_z  members),  and ray segment (tnear and tfar mem‐
33       bers).  The ray direction does not have to be normalized, and only  the
34       parameter  range  specified  by  the  tnear/tfar interval is considered
35       valid.
36
37       The ray segment must be in the range [0, ∞], thus ranges that start be‐
38       hind the ray origin are not allowed, but ranges can reach to infinity.
39
40       The  ray  further contains a motion blur time in the range [0, 1] (time
41       member), a ray mask (mask member), a ray ID (id member), and ray  flags
42       (flags  member).   The ray mask can be used to mask out some geometries
43       for some rays (see rtcSetGeometryMask for more details).   The  ray  ID
44       can  be  used to identify a ray inside a callback function, even if the
45       order of rays inside a ray packet has changed.
46
47       The embree4/rtcore_ray.h  header  additionally  defines  the  same  ray
48       structure  in structure of array (SOA) layout for API functions accept‐
49       ing ray packets of size 4 (RTCRay4 type), size 8  (RTCRay8  type),  and
50       size  16  (RTCRay16 type).  The header additionally defines an RTCRayNt
51       template for ray packets of an arbitrary compile-time size.
52
53   EXIT STATUS
54   SEE ALSO
55       [RTCHit]
56
57
58
59                                                                     RTCRay(3)
Impressum