improve mjpeg streamer script