---
title: kCMSampleBufferAttachmentKey_TrimDurationAtEnd
framework: coremedia
role: symbol
role_heading: Global Variable
path: coremedia/kcmsamplebufferattachmentkey_trimdurationatend
---

# kCMSampleBufferAttachmentKey_TrimDurationAtEnd

The duration that should be removed at the end of the sample buffer, after decoding.

## Declaration

```swift
let kCMSampleBufferAttachmentKey_TrimDurationAtEnd: CFString
```

## Discussion

Discussion 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.

## See Also

### Sample Buffer Keys

- [kCMSampleBufferAttachmentKey_DisplayEmptyMediaImmediately](coremedia/kcmsamplebufferattachmentkey_displayemptymediaimmediately.md)
- [kCMSampleBufferAttachmentKey_DrainAfterDecoding](coremedia/kcmsamplebufferattachmentkey_drainafterdecoding.md)
- [kCMSampleBufferAttachmentKey_DroppedFrameReason](coremedia/kcmsamplebufferattachmentkey_droppedframereason.md)
- [kCMSampleBufferDroppedFrameReason_FrameWasLate](coremedia/kcmsamplebufferdroppedframereason_framewaslate.md)
- [kCMSampleBufferDroppedFrameReason_OutOfBuffers](coremedia/kcmsamplebufferdroppedframereason_outofbuffers.md)
- [kCMSampleBufferDroppedFrameReason_Discontinuity](coremedia/kcmsamplebufferdroppedframereason_discontinuity.md)
- [kCMSampleBufferAttachmentKey_DroppedFrameReasonInfo](coremedia/kcmsamplebufferattachmentkey_droppedframereasoninfo.md)
- [kCMSampleBufferDroppedFrameReasonInfo_CameraModeSwitch](coremedia/kcmsamplebufferdroppedframereasoninfo_cameramodeswitch.md)
- [kCMSampleBufferAttachmentKey_EmptyMedia](coremedia/kcmsamplebufferattachmentkey_emptymedia.md)
- [kCMSampleBufferAttachmentKey_EndsPreviousSampleDuration](coremedia/kcmsamplebufferattachmentkey_endsprevioussampleduration.md)
- [kCMSampleBufferAttachmentKey_FillDiscontinuitiesWithSilence](coremedia/kcmsamplebufferattachmentkey_filldiscontinuitieswithsilence.md)
- [kCMSampleBufferAttachmentKey_ForceKeyFrame](coremedia/kcmsamplebufferattachmentkey_forcekeyframe.md)
- [kCMSampleBufferAttachmentKey_GradualDecoderRefresh](coremedia/kcmsamplebufferattachmentkey_gradualdecoderrefresh.md)
- [kCMSampleBufferAttachmentKey_PermanentEmptyMedia](coremedia/kcmsamplebufferattachmentkey_permanentemptymedia.md)
- [kCMSampleBufferAttachmentKey_PostNotificationWhenConsumed](coremedia/kcmsamplebufferattachmentkey_postnotificationwhenconsumed.md)
