I’ve queried to EGLDevice that can support CUDA device and it seemed available.
I’ve also written producer and consumer codes. Producer creates EGLStream object, extracts a fd from it, and shares that with CUDA consumer process. To connect stream with consumer, the consumer calls cudaEGLStreamConsumerConnect() and the stream state is changed to EGL_STREAM_STATE_CONNECTING_KHR. Producer calls eglCreateStreamProducerSurfaceKHR() but EGL_NO_SURFACE is returned with EGL_BAD_ALLOC error. I can’t find the error case in an extension EGL_KHR_stream_producer_eglsurface.
It has worked well when the consumer is GL texture. so I just guess that there are additional processes to connect EGL with CUDA. If then, how can I connect?
I’ve tried this on 390.48 driver and cuda 9.1.85