kCMSampleBufferAttachmentKey_TrimDurationAtStart
The duration that should be removed at the beginning of the sample buffer, after decoding.
Declaration
let kCMSampleBufferAttachmentKey_TrimDurationAtStart: CFStringDiscussion
If this attachment is not present, the trim duration is zero (nothing removed). This is a CMTime in Core Foundation dictionary format as made by CMTimeCopyAsDictionary(_:allocator:); use CMTimeMakeFromDictionary(_:) to convert to CMTime. In cases where all the output after decoding the sample buffer is to be discarded (for example, the samples are only being decoded to prime the decoder) the usual convention is to set kCMSampleBufferAttachmentKey_TrimDurationAtStart to the whole duration and not to set a kCMSampleBufferAttachmentKey_TrimDurationAtEnd attachment.
See Also
Sample Buffer Keys
kCMSampleBufferAttachmentKey_DisplayEmptyMediaImmediatelykCMSampleBufferAttachmentKey_DrainAfterDecodingkCMSampleBufferAttachmentKey_DroppedFrameReasonkCMSampleBufferDroppedFrameReason_FrameWasLatekCMSampleBufferDroppedFrameReason_OutOfBufferskCMSampleBufferDroppedFrameReason_DiscontinuitykCMSampleBufferAttachmentKey_DroppedFrameReasonInfokCMSampleBufferDroppedFrameReasonInfo_CameraModeSwitchkCMSampleBufferAttachmentKey_EmptyMediakCMSampleBufferAttachmentKey_EndsPreviousSampleDurationkCMSampleBufferAttachmentKey_FillDiscontinuitiesWithSilencekCMSampleBufferAttachmentKey_ForceKeyFramekCMSampleBufferAttachmentKey_GradualDecoderRefreshkCMSampleBufferAttachmentKey_PermanentEmptyMediakCMSampleBufferAttachmentKey_PostNotificationWhenConsumed