Sending captured images to udp stream

I have tested your solution. but unfortunately it does not work as I expected. I dont want to disply video stream on local machine. by the way the object detection process is necessary to be done.