Adding support for video rotation