title: Video Full Screen not Working in ios Swift AVPlayer?
body: <p>This is my code:</p>
  <pre><code>self.playerView?.transform = CGAffineTransformMakeRotation(CGFloat(M_PI_2));
  self.playerView?.setVideoGravity(AVLayerVideoGravityResizeAspectFill)
  self.playerView?.setMovieToPlayer(mp)
  </code></pre>
  <p>First line to transform from portrait to landscape...
  mp is AVPlayer..</p>
  <p>Storyboard pic and black color is the <code>playerView</code> inside <code>ViewController MainView</code></p>
  <p><a href="https://i.stack.imgur.com/JpuZ8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/JpuZ8.png" alt="enter image description here" /></a></p>
  <p>and the constraints are</p>
  <pre><code>trailing = Player View.trailing
  Player View.bottom = Bottom Layout Guide.top
  Player View.top = top
  Player View.leading = leading
  </code></pre>
  <p>The output is: View is not Occupying the full screen but leaving some space at left and right</p>
  <p><a href="https://i.stack.imgur.com/ImlQ6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ImlQ6.png" alt="enter image description here" /></a></p>
  <p>Somebody help please?
  Atleast Provide some tutorial...</p>