Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to remove triangle reference duplication #4

Open
pshriwise opened this issue Jan 4, 2024 · 1 comment
Open

Upgrade to remove triangle reference duplication #4

pshriwise opened this issue Jan 4, 2024 · 1 comment

Comments

@pshriwise
Copy link
Owner

Right now there are two triangle references per triangle: one with a forward sense in its scene (volume) and another for the reverse sense in its scene (another volume).

We may be able to avoid the need to duplicate these references by storing the forward and reverse sense scenes on the GeometryData object -- it should be available to us as part of the intersection arguments. The remaining need is to know what scene the ray is being fired on. This information can be stored on the RTCDRay if needed, but it may also be available as part of the intersection arguments. TBD.

@pshriwise
Copy link
Owner Author

pshriwise commented Jan 4, 2024

Doesn't look like the scene information is part of the RTCIntersectionArgs struct:

struct RTCIntersectFunctionNArguments
{
int* valid;
void* geometryUserPtr;
unsigned int primID;
struct RTCRayQueryContext* context;
struct RTCRayHitN* rayhit;
unsigned int N;
unsigned int geomID;
};

so it will need to go on the ray.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant