add capture from memory and decode into cv::Mat