How to set MaxH264SliceBytes property of VTCompressionSession

点点圈 提交于 2019-12-06 09:22:11

问题


iOS VTCompressionSession has a property which is kVTCompressionPropertyKey_MaxH264SliceBytes. However, I cannot set the kVTCompressionPropertyKey_MaxH264SliceBytes property of VTCompressionSession. It returns a -12900 error code (kVTPropertyNotSupportedErr) and the description in VTCompressionProperties.h file says "If supported by an H.264 encoder, the value limits the size in bytes of slices produced by the encoder, where possible."

So I understand that usage of this property is supported for some encoder settings. Does anybody know what that settings are?

Thanks.


回答1:


As Apple Developer Technical Support answered us: The VTCompressionSession only supports configuring the maximum slice size if the dictionary returned by VTSessionCopySupportedPropertyDictionary contains the kVTCompressionPropertyKey_MaxH264SliceBytes key.

Turns out that it is not supported by iOS 8.4 on any of the devices I've tested (iPhone 5, 6s) -> it's probably not implemented, at least not on iOS.

The technical support suggested we file an enhancement request using the Apple Bug Reporter. I filed one, and I suggest you file one as well, as Apple priorities bug reports based on the number of duplicates filed.



来源:https://stackoverflow.com/questions/29510311/how-to-set-maxh264slicebytes-property-of-vtcompressionsession

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!