Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.
6712 Discussions

Clarification on parameter for IntersectMO function in the Realistic Rendering and 3D Data Processing Library.

gkbee
Beginner
418 Views
Hello All,

I have been trying to understand what the parameter pTrngl ( a Ipp32s*) input value represents. The parameter is defined as: Pointer to the triangle index if the intersection is found, if not it is set to -1, and then further in the description: Only rays for which value pTrngl is greater than -1 are considered.

I understand the output. If a scene triangle was intersected, pTrngl represents the index in the array of triangle indices and this has been working for me fine. What I do not understand is why pTrngl is also an input parameter, how is it used?

Any help here would be greatly appreciated!

Thankfully,

George.
0 Kudos
1 Solution
Chao_Y_Intel
Moderator
418 Views
George,

please find some comments from the function expert:

ipprIntersectMO are used to process secondary rays. Not all rays in the bunch of rays are valid after intersection primary rays with scene geometry or because of shadows. Parameter pTrngl is used as the mask which masks invalid rays in the bunch and it can speedup calculation secondary rays.

Thanks,
Chao

View solution in original post

0 Kudos
2 Replies
Chao_Y_Intel
Moderator
419 Views
George,

please find some comments from the function expert:

ipprIntersectMO are used to process secondary rays. Not all rays in the bunch of rays are valid after intersection primary rays with scene geometry or because of shadows. Parameter pTrngl is used as the mask which masks invalid rays in the bunch and it can speedup calculation secondary rays.

Thanks,
Chao

0 Kudos
gkbee
Beginner
418 Views
Thank you Chao, that is just what I needed to know!
0 Kudos
Reply