<!--
{
  "availability" : [
    "iOS: 27.0.0 -",
    "iPadOS: 27.0.0 -",
    "macCatalyst: 27.0.0 -",
    "macOS: 27.0.0 -",
    "tvOS: 27.0.0 -",
    "visionOS: 27.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "VideoToolbox",
  "identifier" : "/documentation/VideoToolbox/VTLowLatencyFrameInterpolationConfiguration/maximumDimension(forSpatialScaleFactor:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "Video Toolbox",
      "VideoToolbox"
    ],
    "preciseIdentifier" : "s:So43VTLowLatencyFrameInterpolationConfigurationC12VideoToolboxE16maximumDimension21forSpatialScaleFactorSiSgSi_tFZ"
  },
  "title" : "maximumDimension(forSpatialScaleFactor:)"
}
-->

# maximumDimension(forSpatialScaleFactor:)

The maximum value for either dimension of the source frame, in pixels, for a given spatial scale factor.

```
class func maximumDimension(forSpatialScaleFactor spatialScaleFactor: Int) -> Int?
```

## Discussion

Both `frameWidth` and `frameHeight` must be less than or equal to this value.
Use in conjunction with [`maximumPixelCountForSpatialScaleFactor:`](/documentation/VideoToolbox/VTLowLatencyFrameInterpolationConfiguration/maximumPixelCountForSpatialScaleFactor:) to determine valid frame dimensions.
For example, if [`maximumDimensionForSpatialScaleFactor:`](/documentation/VideoToolbox/VTLowLatencyFrameInterpolationConfiguration/maximumDimensionForSpatialScaleFactor:) is 1920 and [`maximumPixelCountForSpatialScaleFactor:`](/documentation/VideoToolbox/VTLowLatencyFrameInterpolationConfiguration/maximumPixelCountForSpatialScaleFactor:)
corresponds to 1920×1080, then 1920×1080, 1080×1920, and 1440×1440 are all valid, but 1920×1920 is not.
Pass `1` for `spatialScaleFactor` when using the processor for temporal interpolation without spatial scaling.
Optional return value.  Returns nil for unsupported spatialScaleFactor or if processor is unsupported.

---

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)