Post

Replies

Boosts

Views

Activity

AVSampleBufferDisplayLayer fails to decode with error -8969
I'm writing a player app that will play back HLS live streams, and ran into a curious error when trying to enqueue CMSampleBuffers into an AVSampleBufferDisplayLayer.What I am doing:1. Take NALUs from the stream and strip out the SPS, PPS information to construct a CMFormatDescription2. For VCL type NALUs, replace the starter bytes with a 4-byte length.3. Wrap the NALUs into CMBlockBuffer4. Wrap the CMBlockBuffer, along with the CMFormatDescription, into CMSampleBuffers( What I had done originally:5. Use a VTDecompressionSession to decompress the CMSampleBuffers into CVImageBuffers6. Display CVImageBuffers using CAEAGLayer rendering code found here.)When I had the player written to use the entire video processing pipeline above (steps #1 through #6), it worked just fine playing HLS live streams. Now, what I'm trying to do now is to enqueue the CMSampleBuffers generated in step #4 directly into an AVSampleBufferDisplay layer to decompress and display (replacing steps #5 and #6).When I enqueue each CMSampleBuffer, AVSampleBufferDisplayLayerStatus = Rendering, but it also generated a notification that it failed to decode:Error Domain=AVFoundationErrorDomain Code=-11800 "The operation could not be completed" UserInfo={AVErrorMediaSubTypeKey=( 1635148593 ), NSLocalizedFailureReason=An unknown error occurred (-8969), NSUnderlyingError=0x600000046870 {Error Domain=NSOSStatusErrorDomain Code=-8969 "(null)"}, AVErrorMediaTypeKey=vide, AVErrorPresentationTimeStampKey=CMTime: {642749/90000 = 7.142}, NSLocalizedDescription=The operation could not be completed}What could cause an error code -11800 / -8969?
3
1
2.4k
Mar ’23
AVSampleBufferDisplayLayer fails to decode with error -8969
I'm writing a player app that will play back HLS live streams, and ran into a curious error when trying to enqueue CMSampleBuffers into an AVSampleBufferDisplayLayer.What I am doing:1. Take NALUs from the stream and strip out the SPS, PPS information to construct a CMFormatDescription2. For VCL type NALUs, replace the starter bytes with a 4-byte length.3. Wrap the NALUs into CMBlockBuffer4. Wrap the CMBlockBuffer, along with the CMFormatDescription, into CMSampleBuffers( What I had done originally:5. Use a VTDecompressionSession to decompress the CMSampleBuffers into CVImageBuffers6. Display CVImageBuffers using CAEAGLayer rendering code found here.)When I had the player written to use the entire video processing pipeline above (steps #1 through #6), it worked just fine playing HLS live streams. Now, what I'm trying to do now is to enqueue the CMSampleBuffers generated in step #4 directly into an AVSampleBufferDisplay layer to decompress and display (replacing steps #5 and #6).When I enqueue each CMSampleBuffer, AVSampleBufferDisplayLayerStatus = Rendering, but it also generated a notification that it failed to decode:Error Domain=AVFoundationErrorDomain Code=-11800 "The operation could not be completed" UserInfo={AVErrorMediaSubTypeKey=( 1635148593 ), NSLocalizedFailureReason=An unknown error occurred (-8969), NSUnderlyingError=0x600000046870 {Error Domain=NSOSStatusErrorDomain Code=-8969 "(null)"}, AVErrorMediaTypeKey=vide, AVErrorPresentationTimeStampKey=CMTime: {642749/90000 = 7.142}, NSLocalizedDescription=The operation could not be completed}What could cause an error code -11800 / -8969?
Replies
3
Boosts
1
Views
2.4k
Activity
Mar ’23