I’m working in Optix 4.0.0 PathTracer SDK sample. I added textures to the path tracer and works absolutely fine with the parallelogram geometry. I added a sphere geometry and it was working fine until I tried to add textures. I’m getting this error as follows.
OptiX Error: ‘Invalid context (Details: Function “_rtContextValidate” caught exception: Validation error: Attribute “_attribute_texcoord” is referenced in a hit program but is not produced in attached intersection program, file:C:\u\workspace\rel4.0-win64-build-Release\sw\wsapps\raytracing\rtsdk\rel4.0\src\Context\ValidationManager.cpp, line: 103)’
I have declared texcoord and assigned value similar to as it is in the parallelogram intersection routine, but for some reason the error says it is not produced in intersection program. The other common attributes like shading normal and geometry normal works the same way without any issues. I also tried separately compiling the sphere cuda file using nvcc.exe but to no good. Please let me know what could be causing this.
Thanks in advance.