Opencv - capturing frames from video and then storing it 90 degree counter clockwise

sorry!! this is my first post. Hope the edited post was more clear. Any suggestions are highly appreciated. Thanks