

OSStatus decodeStatus = VTDecompressionSessionDecodeFrame ( decodeSession, sampleBuffer, flags, &outputPixelBuffer, &flagOut ) ĭBG ( "decode failed status=" + String ( decodeStatus) ) The rationale behind creating the toolkit is to. Call didDecompress and call back after returning. Concerns such as involvement in drugs, drug addiction and violence are discussed in a real life based format. VTDecodeFrameFlags flags = 0 VTDecodeInfoFlags flagOut = 0 If (status = kCMBlockBufferNoErr & sampleBuffer) Status = CMSampleBufferCreateReady(kCFAllocatorDefault,blockBuffer,formatDescription,1, 0, NULL, 1, sampleSizeArray,&sampleBuffer) *outputPixelBuffer = CVPixelBufferRetain(pixelBuffer) Ĭonst uint8_t* parameterSetPointers = The "guts" of the decoding part looks like this (modified from a demo on GitHub) void didDecompress(void *decompressionOutputRefCon, void *sourceFrameRefCon, OSStatus status, VTDecodeInfoFlags infoFlags, CVImageBufferRef pixelBuffer, CMTime presentationTimeStamp, CMTime presentationDuration )ĬVPixelBufferRef *outputPixelBuffer = (CVPixelBufferRef *)sourceFrameRefCon One thing that I did notice is that the decode call returns with no error code but a NULL pixel buffer about 70% of the time. I suspect that this has something to do with temporal processing, but really don't understand H264 well enough to work it out. I have a similar problem when receiving from an OpenH264 encoder on a slower Windows machine. Doing the same on the Macbook (same image of test program) give 3/4 green again.

#Video toolkit software
If I capture the frames on the MacBook and then run exactly the same decoding software in a test program on the iMac then it decodes fine. If I scale the image down to about 1/8 of original before encoding then it works fine. On the receiver the decoded image is about 3/4 green.
#Video toolkit pro
When the source uses video Toolbox on a 2011 iMac running MacOS High Sierra and the receiver is a MacBook pro running Big Sur. There is one use-case that doesn't work and I can't find any solution. I am trying to get an H264 streaming app working on various platforms using a combination of Apple Video Toolbox and OpenH264.
