Video encoding in the cloud