---
title: "segmentBoundaryGuidelinesForVideo(codecType:encoderSpecification:)"
framework: avfoundation
role: symbol
role_heading: Type Method
platforms: [iOS 27.0+, iPadOS 27.0+, Mac Catalyst 27.0+, macOS 27.0+, tvOS 27.0+, visionOS 27.0+]
path: "avfoundation/avassetwritingplanner/segmentboundaryguidelinesforvideo(codectype:encoderspecification:)"
---

# segmentBoundaryGuidelinesForVideo(codecType:encoderSpecification:)

Returns segment boundary guidelines that help clients determine how to segment compression video tracks with best results.

## Declaration

```swift
static func segmentBoundaryGuidelinesForVideo(codecType: AVVideoCodecType, encoderSpecification: [String : any Sendable]) -> AVAssetWritingPlanner.SegmentBoundaryGuidelines
```

## Parameters

- `codecType`: The output video codec type for the video track.
- `encoderSpecification`: A dictionary of kVTVideoEncoderSpecification_* keys describing the video encoder. This is the same specification the client uses to compress the video track.

## Return Value

Return Value An AVAssetWritingPlanner.SegmentBoundaryGuidelines with the minimum frame count and duration for the given codec and encoder.

## Discussion

Discussion The encoderSpecification parameter here is the same encoder specification the client uses to compress the video track.

## See Also

### Getting segment boundary guidance

- [segmentBoundaryRecommendations(forVideoTrack:minimumSegmentDuration:minimumSegmentFrameCount:)](avfoundation/avassetwritingplanner/segmentboundaryrecommendations(forvideotrack:minimumsegmentduration:minimumsegmentframecount:).md)
