Stream Probe introduces iOS 18 AVMetrics support in this update, enabling detailed per-segment video playback metrics from AVPlayer.
TL;DR
Stream Probe can now capture per-segment playback data on iOS 18 using Apple's AVMetrics API. A new Swift adapter feeds raw AVMetrics objects into the KMP layer, where a Kotlin mapper converts them into internal SegmentMetric models consumed by AVPlayerProbe.
What's New
- AVMetricsSegmentAdapter (Swift): Hooks into iOS 18 AVMetrics to capture per-segment playback events directly from AVPlayer
- AVMetricsSegmentMapper (Kotlin): Maps raw AVMetrics data to the shared
SegmentMetricmodel used across the KMP layer - AVPlayerProbe update: Now ingests per-segment metrics from the new adapter, giving you segment-level visibility into buffering, stalls, and timing data
How to Use
No API changes required on the call site. If your app runs on iOS 18+, AVPlayerProbe automatically picks up per-segment metrics. The data surfaces through the same diagnostics output you already consume.
// iOS 18+ only , AVPlayerProbe handles the AVMetrics hookup internally
let probe = AVPlayerProbe(player: avPlayer)
probe.startMonitoring()
// SegmentMetric data is now included in diagnostics output