I have a UIView
which contains an AVPlayer
to show a video. When changing orientation, I need to change the size and location of the video.
First step: check out UIView's autoresizing property in UIVIew.h
@property(nonatomic) UIViewAutoresizing autoresizingMask; // simple resize. default is UIViewAutoresizingNone
This property correspondents to the "springs and struts" controls in IB, though it will take you some experimentation to get the results you want.