.\" Automatically generated by Pandoc 2.9.2.1
.\"
.TH "rtcOccluded1" "3" "" "" "Embree Ray Tracing Kernels 4"
.hy
.SS NAME
.IP
.nf
\f[C]
rtcOccluded1 - finds any hit for a single ray
\f[R]
.fi
.SS SYNOPSIS
.IP
.nf
\f[C]
#include <embree4/rtcore.h>

void rtcOccluded1(
  RTCScene scene,
  struct RTCRay* ray,
  struct RTCOccludedArguments* args = NULL
);
\f[R]
.fi
.SS DESCRIPTION
.PP
The \f[C]rtcOccluded1\f[R] function checks for a single ray
(\f[C]ray\f[R] argument) whether there is any hit with the scene
(\f[C]scene\f[R] argument).
The passed optional arguments struct (\f[C]args\f[R] argument) can get
used for advanced use cases, see section [rtcInitOccludedArguments] for
more details.
.PP
To trace a ray, the user must initialize the ray origin (\f[C]org\f[R]
ray member), ray direction (\f[C]dir\f[R] ray member), ray segment
(\f[C]tnear\f[R], \f[C]tfar\f[R] ray members), ray mask (\f[C]mask\f[R]
ray member), and must set the ray flags to \f[C]0\f[R] (\f[C]flags\f[R]
ray member).
The ray time (\f[C]time\f[R] ray member) must be initialized to a value
in the range [0,\[u2006]1].
The ray segment must be in the range [0,\[u2006]\[if]], thus ranges that
start behind the ray origin are not valid, but ranges can reach to
infinity.
See Section [RTCRay] for the ray layout description.
.PP
When no intersection is found, the ray data is not updated.
In case a hit was found, the \f[C]tfar\f[R] component of the ray is set
to \f[C]-inf\f[R].
.PP
The implementation makes no guarantees that primitives whose hit
distance is exactly at (or very close to) \f[C]tnear\f[R] or
\f[C]tfar\f[R] are hit or missed.
If you want to exclude intersections at \f[C]tnear\f[R] just pass a
slightly enlarged \f[C]tnear\f[R], and if you want to include
intersections at \f[C]tfar\f[R] pass a slightly enlarged \f[C]tfar\f[R].
.IP
.nf
\f[C]
\f[R]
.fi
.PP
The ray must be aligned to 16 bytes.
.SS EXIT STATUS
.PP
For performance reasons this function does not do any error checks, thus
will not set any error flags on failure.
.SS SEE ALSO
.PP
[rtcIntersect1], [rtcOccluded4/8/16], [RTCRay],
[rtcInitOccludedArguments]
