<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 14.0.0 -",
    "tvOS: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AVFoundation",
  "identifier" : "/documentation/AVFoundation/AVCaptureMovieFileOutput/setRecordsVideoOrientationAndMirroringChangesAsMetadataTrack(_:for:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AVFoundation"
    ],
    "preciseIdentifier" : "c:objc(cs)AVCaptureMovieFileOutput(im)setRecordsVideoOrientationAndMirroringChanges:asMetadataTrackForConnection:"
  },
  "title" : "setRecordsVideoOrientationAndMirroringChangesAsMetadataTrack(_:for:)"
}
-->

# setRecordsVideoOrientationAndMirroringChangesAsMetadataTrack(_:for:)

Sets whether the movie file output creates a timed metadata track to capture changes to the connection’s video orientation and mirroring.

```
func setRecordsVideoOrientationAndMirroringChangesAsMetadataTrack(_ doRecordChanges: Bool, for connection: AVCaptureConnection)
```

## Parameters

`doRecordChanges`

A Boolean value that indicates whether to capture orientation and mirroring information. The system observes this value only at the start of recording. Setting a different value has no effect until you start a new recording.

`connection`

A connection that delivers video media to the movie file output. This method throws an invalid argument exception if the value isn’t a video connection or if the connection doesn’t terminate at the movie file output.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)