参考 stackoverflow
setting the AVPlayerLayer's bounds to the AVPlayerLayer's bound seemed to do the trick. although i don't really get why.
self.displayLayer.videoGravity = gravity;
//通过改变bounds, 触发gravity 生效
CGRect bounds = self.displayLayer.bounds;
self.displayLayer.bounds = CGRectZero;
self.displayLayer.bounds = bounds;
网友评论