Azure Kinect Sensor SDK  refs/heads/master
Documentation for https://github.com/Microsoft/Azure-Kinect-Sensor-SDK

◆ k4a_playback_get_next_data_block()

k4a_stream_result_t k4a_playback_get_next_data_block ( k4a_playback_t  playback_handle,
const char *  track_name,
k4a_playback_data_block_t data_block_handle 
)
related

Read the next data block for a particular track.

Parameters
playback_handleHandle obtained by k4a_playback_open().
track_nameThe name of the track to read the next data block from.
data_block_handleThe location to write the data block handle.
Returns
K4A_STREAM_RESULT_SUCCEEDED if a data block is returned, or K4A_STREAM_RESULT_EOF if the end of the recording is reached. All other failures will return K4A_STREAM_RESULT_FAILED.
Remarks
k4a_playback_get_next_data_block() always returns the data block after the most recently returned data block for a particular track.
If a call was made to k4a_playback_get_previous_data_block() which returned K4A_STREAM_RESULT_EOF, then the playback position is at the beginning of the recording and calling k4a_playback_get_next_data_block() with the same track will return the first data block in the track.
The first call to k4a_playback_get_next_data_block() after k4a_playback_seek_timestamp() will return the data block in the recording closest to the seek time with a timestamp greater than or equal to the seek time.
k4a_playback_get_next_data_block() cannot be used with the built-in tracks: "COLOR", "DEPTH", etc... k4a_playback_track_is_builtin() can be used to determine if a track is a built-in track.
If the call is successful, callers must call k4a_playback_data_block_release() to return the allocated memory for data_block_handle.