Thanks a lot for your inputs. As I am new to this thing, just want your help to validate my approach.
In my usecase, I will get a RAW image from an image sensor and then I need to do some processing on this RAW image for which the code will be written in CUDA and then I need to render the processed image onto a display.
Given this is my usecase, I am thinking I should use NvMediaImageProducer and connect it to CUDA consumer using interop and then render the CUDA processed buffer on to a display over HDMI.
I found nvmipp_bayerdgpu sample closest to my usecase. In the cuda_consumer.c file, I need to place my code in cudaprocThreadFunc and as per your suggestion change the output currently being written to the file and use OpenGL-EGL API for rendering. I will study more about this rendering part.
Let me know if my thinking is ok for the usecase.