Function

CMSampleBufferDataIsReady(_:)

Determines if the sample buffer's data is ready.

Declaration

func CMSampleBufferDataIsReady(_ sbuf: CMSampleBuffer) -> Bool

Parameters

sbuf

The CMSampleBuffer being interrogated.

Return Value

A Boolean indicating whether or not the sample buffer's data is ready. True is returned for special marker buffers, even though they have no data. False is returned if there is an error.

See Also

Inspecting Sample Buffers

func CMSampleBufferGetDataBuffer(CMSampleBuffer) -> CMBlockBuffer?

Returns a CMSampleBuffer's CMBlockBuffer of media data.

func CMSampleBufferGetDecodeTimeStamp(CMSampleBuffer) -> CMTime

Returns the numerically earliest decode timestamp of all the samples in a CMSampleBuffer.

func CMSampleBufferGetDuration(CMSampleBuffer) -> CMTime

Returns the total duration of a CMSampleBuffer.

func CMSampleBufferGetFormatDescription(CMSampleBuffer) -> CMFormatDescription?

Returns the format description of the samples in a CMSampleBuffer.

func CMSampleBufferGetImageBuffer(CMSampleBuffer) -> CVImageBuffer?

Returns a sample buffer's CVImageBuffer of media data.

func CMSampleBufferGetNumSamples(CMSampleBuffer) -> CMItemCount

Returns the number of media samples in a CMSampleBuffer.

func CMSampleBufferGetOutputDecodeTimeStamp(CMSampleBuffer) -> CMTime

Returns the output decode timestamp of the CMSampleBuffer.

func CMSampleBufferGetOutputDuration(CMSampleBuffer) -> CMTime

Returns the output duration of a CMSampleBuffer.

func CMSampleBufferGetOutputPresentationTimeStamp(CMSampleBuffer) -> CMTime

Returns the output presentation timestamp of the CMSampleBuffer.

func CMSampleBufferGetPresentationTimeStamp(CMSampleBuffer) -> CMTime

Returns the numerically earliest presentation timestamp of all the samples in a CMSampleBuffer.

func CMSampleBufferGetSampleAttachmentsArray(CMSampleBuffer, createIfNecessary: Bool) -> CFArray?

Returns a reference to a CMSampleBuffer's immutable array of mutable sample attachments dictionaries (one dictionary per sample in the CMSampleBuffer).

func CMSampleBufferGetSampleSize(CMSampleBuffer, at: CMItemIndex) -> Int

Returns the size in bytes of a specified sample in a CMSampleBuffer.

func CMSampleBufferGetTotalSampleSize(CMSampleBuffer) -> Int

Returns the total size in bytes of sample data in a CMSampleBuffer.

func CMSampleBufferIsValid(CMSampleBuffer) -> Bool

Queries whether a sample buffer is still valid.

func CMSampleBufferGetTypeID() -> CFTypeID

Returns the CFTypeID of CMSampleBuffer objects.