@kolegs Thank you so much. I created this code and the performance was very better. I'm reading two IP cameras now with it.
Of course that the delay is existing (each 2 seconds the image is updated). I think that I need to improve my code. I'm using 98% of my CPU, but I need to do many routines :(