Changed code to use mjpeg