I would like to understand how to use API ffmpeg to capture a vnc stream and create the output video file.