CMSampleBufferTrackDataReadiness(_:sampleBufferToTrack:)
Associates a sample buffer’s data readiness with that of another sample buffer.
Declaration
func CMSampleBufferTrackDataReadiness(_ sbuf: CMSampleBuffer, sampleBufferToTrack: CMSampleBuffer) -> OSStatusParameters
- sbuf:
The sample buffer being modified.
- sampleBufferToTrack:
The sample buffer being tracked.
Return Value
A result code. See Sample Buffer Error Codes.
Discussion
After calling this API, if CMSampleBufferDataIsReady is called, it will return sampleBufferToTrack’s data readiness. If CMSampleBufferMakeDataReady is called, it will make sampleBufferToTrack data ready.
Example of use: This allows bursting a multi-sample CMSampleBuffer into single-sample CMSampleBuffers before the data is ready. The single-sample CMSampleBuffers will all track the multi-sample CMSampleBuffer’s data readiness.