rtPrintf in OPTIX with rtPrintf I get no output

Hello,

sorry for this stupid question! But I am completely new at CUDA and Optix.

I want to debug my Cuda Code with rtPrintf.

I did:

rtDeclareVariable(uint2, launch_index, rtLaunchIndex, );

...

RT_PROGRAM void pinhole_camera()

{

...

rtPrintf("Hello from index %u, %u!\n", launch_index.x, launch_index.y);

}

and in the host code:

int main(int argc, char* argv[])

{

...

RTcontext print;

rtContextCreate( &print);

rtContextSetPrintEnabled(print, 1);

rtContextSetPrintBufferSize(print, 4096);

...

}

I get no error but I get no output neither. Where can I find the output? Or what is missing?

I will be very happy about any answers!

Thank you!

Have you solved your problem?

You should post this on the OptiX forum https://devtalk.nvidia.com/default/board/90/optix/.

Anyway, since you enable print it should be working.

I got the same problem as you did. I used printf instead.