Post

Replies

Boosts

Views

Activity

Reply to VideoToolbox regression with iOS 15.4
Hello, I want a 4 Mbs bitrate, before 15.4, this code used to work, now it doesn't : status = VTSessionSetProperty( compressionSession, kVTCompressionPropertyKey_RealTime, kCFBooleanTrue ); status = VTSessionSetProperty( compressionSession, kVTCompressionPropertyKey_AllowFrameReordering, kCFBooleanFalse ); int compressionBitrate = 4 * 1024 * 1024; float kLimitToAverageBitRateFactor = 1.5f; status = VTSessionSetProperty( compressionSession, kVTCompressionPropertyKey_AverageBitRate, (__bridge CFTypeRef)@( compressionBitrate ) ); int64_t dataLimitBytesPerSecondValue = compressionBitrate * kLimitToAverageBitRateFactor / 8; CFNumberRef bytesPerSecond = CFNumberCreate( kCFAllocatorDefault, kCFNumberSInt64Type, &dataLimitBytesPerSecondValue ); int64_t oneSecondValue = 1; CFNumberRef oneSecond = CFNumberCreate( kCFAllocatorDefault, kCFNumberSInt64Type, &oneSecondValue ); const void *nums[2] = { bytesPerSecond, oneSecond }; CFArrayRef dataRateLimits = CFArrayCreate( nil, nums, 2, &kCFTypeArrayCallBacks ); status = VTSessionSetProperty( processObjC->compressionSession, kVTCompressionPropertyKey_DataRateLimits, dataRateLimits );
Mar ’22