set pix_fmt properly depending on version