kVTVideoDecoderSpecification_RequireHardwareAcceleratedVideoDecoder
A Boolean value indicating whether to require hardware-accelerated decoding.
Declaration
let kVTVideoDecoderSpecification_RequireHardwareAcceleratedVideoDecoder: CFStringDiscussion
This key is set in the decoderSpecification passed in to VTDecompressionSessionCreate(allocator:formatDescription:decoderSpecification:imageBufferAttributes:outputCallback:decompressionSessionOut:). If set to kCFBooleanTrue, VideoToolbox tries to allocate a hardware-accelerated decoder. If it cannot, it returns an error and the session creation fails.
Setting this key automatically implies kVTVideoDecoderSpecification_EnableHardwareAcceleratedVideoDecoder–there is no need to set both and the Enable key does nothing if the Require key is set. This key is useful for clients that have their own software decoding implementation or those that may want to configure software and hardware decode sessions differently.
Hardware acceleration may be unavailable for a number of reasons:
The machine doesn’t have hardware acceleration capabilities.
The requested decoding format or configuration isn’t supported.
The hardware decoding resources on the machine are busy.