1rtcSetGeometryOccludedFiltEemrbFruenectRiaoyn(T3r)acritncgSeKteGrenoemlestr4yOccludedFilterFunction(3)
2
3
4
5 NAME
6 rtcSetGeometryOccludedFilterFunction - sets the occlusion filter
7 for the geometry
8
9 SYNOPSIS
10 #include <embree4/rtcore.h>
11
12 void rtcSetGeometryOccludedFilterFunction(
13 RTCGeometry geometry,
14 RTCFilterFunctionN filter
15 );
16
17 DESCRIPTION
18 The rtcSetGeometryOccludedFilterFunction function registers an occlu‐
19 sion filter callback function (filter argument) for the specified geom‐
20 etry (geometry argument).
21
22 Only a single callback function can be registered per geometry, and
23 further invocations overwrite the previously set callback function.
24 Passing NULL as function pointer disables the registered callback func‐
25 tion.
26
27 The registered occlusion filter function is invoked for every hit en‐
28 countered during the rtcOccluded-type ray queries and can accept or re‐
29 ject that hit. The feature can be used to define a silhouette for a
30 primitive and reject hits that are outside the silhouette. E.g. a
31 tree leaf could be modeled with an alpha texture that decides whether
32 hit points lie inside or outside the leaf.
33
34 Please see the description of the rtcSetGeometryIntersectFilterFunction
35 for a description of the filter callback function.
36
37 The rtcOccluded-type functions terminate traversal when a hit got com‐
38 mitted. As filter functions can only set the tfar distance of the ray
39 for a committed hit, the occlusion filter cannot influence the tfar
40 value of subsequent traversal, as that directly ends. For that reason
41 rtcOccluded and occlusion filters cannot get used to gather the next n-
42 hits, and rtcIntersect and intersection filters should get used in‐
43 stead.
44
45 EXIT STATUS
46 On failure an error code is set that can be queried using rtcGetDe‐
47 viceError.
48
49 SEE ALSO
50 [rtcSetGeometryIntersectFilterFunction]
51
52
53
54 rtcSetGeometryOccludedFilterFunction(3)