Skip to content

VideoToolbox tvOS xcode9 beta1

Vincent Dondain edited this page Jun 5, 2017 · 1 revision

#VideoToolbox.framework

diff -ruN /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTBase.h /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTBase.h
--- /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTBase.h	2017-02-28 01:06:17.000000000 -0500
+++ /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTBase.h	2017-05-30 01:31:34.000000000 -0400
@@ -26,6 +26,16 @@
 #define VT_AVAILABLE_STARTING(_ver) __OSX_AVAILABLE_STARTING(__MAC_##_ver, __IPHONE_NA)
 #endif
 
+typedef struct VTInt32Point {
+	int32_t x;
+	int32_t y;
+} VTInt32Point;
+
+typedef struct VTInt32Size {
+	int32_t width;
+	int32_t height;
+} VTInt32Size;
+
 
 #pragma pack(pop)
 
diff -ruN /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTCompressionProperties.h /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTCompressionProperties.h
--- /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTCompressionProperties.h	2017-03-02 01:51:11.000000000 -0500
+++ /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTCompressionProperties.h	2017-05-30 01:31:34.000000000 -0400
@@ -3,7 +3,7 @@
 	
 	Framework:  VideoToolbox
 	
-	Copyright 2007-2013 Apple Inc. All rights reserved.
+	Copyright 2007-2017 Apple Inc. All rights reserved.
 	
 	Standard Video Toolbox compression properties.
 */
@@ -234,6 +234,9 @@
 		Video encoders should use standard keys where available, and follow standard patterns where not.
 */
 VT_EXPORT const CFStringRef kVTCompressionPropertyKey_ProfileLevel API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2)); // Read/write, CFString (enumeration), Optional
+	
+VT_EXPORT const CFStringRef kVTProfileLevel_HEVC_Main_AutoLevel API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0));
+VT_EXPORT const CFStringRef kVTProfileLevel_HEVC_Main10_AutoLevel API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0));
 
 VT_EXPORT const CFStringRef kVTProfileLevel_H264_Baseline_1_3 API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2));
 VT_EXPORT const CFStringRef kVTProfileLevel_H264_Baseline_3_0 API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2));
@@ -396,6 +399,16 @@
 */
 VT_EXPORT const CFStringRef kVTCompressionPropertyKey_ExpectedDuration API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2)); // Read/write, CFNumber(seconds), Optional
 
+/*!
+	@constant	kVTCompressionPropertyKey_BaseLayerFrameRate
+	@abstract
+		This property indicates the desired frame rate for the base temporal layer used in hierarchical video encoding.
+	@discussion
+		The frame rate is measured in frames per second.
+		This property is only implemented by encoders which support hierarchical frame encoding, and requests that this encoding feature be enabled.
+*/
+VT_EXPORT const CFStringRef kVTCompressionPropertyKey_BaseLayerFrameRate API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0)); // Read/write, CFNumber, Optional
+
 
 #pragma mark Hardware acceleration
 // hardware acceleration is default behavior on iOS.  no opt-in required.
@@ -412,7 +425,7 @@
 		This is useful for clients doing realtime encode operations to allow the VideoToolbox
 		to choose the optimal encode path.
 */
-VT_EXPORT const CFStringRef kVTVideoEncoderSpecification_EnableHardwareAcceleratedVideoEncoder API_AVAILABLE(macosx(10.9), ios(8.0)); // CFBoolean, Optional
+VT_EXPORT const CFStringRef kVTVideoEncoderSpecification_EnableHardwareAcceleratedVideoEncoder API_AVAILABLE(macosx(10.9), ios(8.0), tvos(10.2)); // CFBoolean, Optional
 
 /*!
 	@constant	kVTVideoEncoderSpecification_RequireHardwareAcceleratedVideoEncoder
@@ -431,7 +444,7 @@
 			- the requested encoding format or encoding configuration is not supported
 			- the hardware encoding resources on the machine are busy
 */
-VT_EXPORT const CFStringRef kVTVideoEncoderSpecification_RequireHardwareAcceleratedVideoEncoder API_AVAILABLE(macosx(10.9), ios(8.0)); // CFBoolean, Optional
+VT_EXPORT const CFStringRef kVTVideoEncoderSpecification_RequireHardwareAcceleratedVideoEncoder API_AVAILABLE(macosx(10.9), ios(8.0), tvos(10.2)); // CFBoolean, Optional
 
 /*!
 	@constant	kVTCompressionPropertyKey_UsingHardwareAcceleratedVideoEncoder
@@ -442,7 +455,7 @@
 		accelerated encode using kVTVideoEncoderSpecification_EnableHardwareAcceleratedVideoEncoder
 		to see if a hardware accelerated encoder was selected.
 */
-VT_EXPORT const CFStringRef kVTCompressionPropertyKey_UsingHardwareAcceleratedVideoEncoder API_AVAILABLE(macosx(10.9), ios(8.0)); // CFBoolean, Read; assumed false by default
+VT_EXPORT const CFStringRef kVTCompressionPropertyKey_UsingHardwareAcceleratedVideoEncoder API_AVAILABLE(macosx(10.9), ios(8.0), tvos(10.2)); // CFBoolean, Read; assumed false by default
 #endif // !TARGET_OS_IPHONE
 	
 #pragma mark Per-frame configuration
@@ -586,6 +599,27 @@
 */
 VT_EXPORT const CFStringRef kVTCompressionPropertyKey_ICCProfile API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2)); // Read/write, CFData (see kCMFormatDescriptionExtension_ICCProfile), Optional
 
+/*!
+	@constant	kVTCompressionPropertyKey_MasteringDisplayColorVolume
+	@abstract
+		The value is 24 bytes containing a big-endian structure as defined in ISO/IEC 23008-2:2015(E), D.2.28 Mastering display colour volume SEI message.
+	@discussion
+		The value will be set on the format description for output sample buffers,
+		and incorporated into the appropriate SEI NAL unit where supported by the encoder.
+*/
+VT_EXPORT const CFStringRef kVTCompressionPropertyKey_MasteringDisplayColorVolume API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0)); // Read/write, CFData(24 bytes) (see kCMFormatDescriptionExtension_MasteringDisplayColorVolume), Optional
+
+/*!
+	@constant	kVTCompressionPropertyKey_ContentLightLevelInfo
+	@abstract
+		The value is 4 bytes containing a big-endian structure as defined in the Content Light Level Info SEI message.
+	@discussion
+		The value will be set on the format description for output sample buffers,
+		and incorporated into the appropriate SEI NAL unit where supported by the encoder.
+*/
+VT_EXPORT const CFStringRef kVTCompressionPropertyKey_ContentLightLevelInfo API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0)); // Read/write, CFData(4 bytes) (see kCMFormatDescriptionExtension_ContentLightLevelInfo), Optional
+
+
 #pragma mark Pre-compression processing
 
 // Standard properties about processing to be performed before compression.
@@ -622,6 +656,17 @@
 */
 VT_EXPORT const CFStringRef kVTCompressionPropertyKey_MultiPassStorage API_AVAILABLE(macosx(10.10), ios(8.0), tvos(10.2)); // VTMultiPassStorage, optional, default is NULL
 
+#pragma mark Encoder information
+	
+/*!
+	@constant	kVTCompressionPropertyKey_EncoderID
+	@abstract
+		Specifies a particular video encoder by its ID string.
+	@discussion
+		Matches the value specified in kVTVideoEncoderSpecification_EncoderID, and the kVTVideoEncoderList_EncoderID value returned from VTCopyVideoEncoderList.
+*/
+VT_EXPORT const CFStringRef kVTCompressionPropertyKey_EncoderID API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0)); // CFStringRef
+
 	
 CM_ASSUME_NONNULL_END
 
diff -ruN /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionProperties.h /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionProperties.h
--- /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionProperties.h	2017-02-28 01:06:17.000000000 -0500
+++ /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionProperties.h	2017-05-28 01:21:07.000000000 -0400
@@ -151,7 +151,7 @@
 		This is useful for clients doing realtime decode operations to allow the VideoToolbox
 		to choose the optimal decode path.
 */
-VT_EXPORT const CFStringRef kVTVideoDecoderSpecification_EnableHardwareAcceleratedVideoDecoder API_AVAILABLE(macosx(10.9), ios(8.0)); // CFBoolean, Optional
+VT_EXPORT const CFStringRef kVTVideoDecoderSpecification_EnableHardwareAcceleratedVideoDecoder API_AVAILABLE(macosx(10.9), ios(8.0), tvos(10.2)); // CFBoolean, Optional
 
 /*!
 	@constant	kVTVideoDecoderSpecification_RequireHardwareAcceleratedVideoDecoder
@@ -171,7 +171,7 @@
 			- the requested decoding format or configuration is not supported
 			- the hardware decode resources on the machine are busy
 */
-VT_EXPORT const CFStringRef kVTVideoDecoderSpecification_RequireHardwareAcceleratedVideoDecoder API_AVAILABLE(macosx(10.9), ios(8.0)); // CFBoolean, Optional
+VT_EXPORT const CFStringRef kVTVideoDecoderSpecification_RequireHardwareAcceleratedVideoDecoder API_AVAILABLE(macosx(10.9), ios(8.0), tvos(10.2)); // CFBoolean, Optional
 
 /*!
 	@constant	kVTDecompressionPropertyKey_UsingHardwareAcceleratedVideoDecoder
@@ -182,7 +182,7 @@
 		accelerated decode using kVTVideoDecoderSpecification_EnableHardwareAcceleratedVideoDecoder
 		to see if a hardware accelerated decoder was selected.
 */
-VT_EXPORT const CFStringRef kVTDecompressionPropertyKey_UsingHardwareAcceleratedVideoDecoder API_AVAILABLE(macosx(10.9), ios(8.0)); // CFBoolean, Read; assumed false by default
+VT_EXPORT const CFStringRef kVTDecompressionPropertyKey_UsingHardwareAcceleratedVideoDecoder API_AVAILABLE(macosx(10.9), ios(8.0), tvos(10.2)) ; // CFBoolean, Read; assumed false by default
 #endif // !TARGET_OS_IPHONE
 	
 #pragma mark Decoder behavior
diff -ruN /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionSession.h /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionSession.h
--- /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionSession.h	2017-02-28 01:05:47.000000000 -0500
+++ /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTDecompressionSession.h	2017-05-21 19:05:05.000000000 -0400
@@ -308,6 +308,19 @@
    CM_NONNULL VTDecompressionSessionRef			session,
    CM_RETURNS_RETAINED_PARAMETER CM_NULLABLE CVPixelBufferRef * CM_NONNULL pixelBufferOut ) API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2));
 	
+/*!
+	@function VTIsHardwareDecodeSupported
+	@abstract Indicates whether the current system supports hardware decode for a given codec
+	@discussion
+		This routine reports whether the current system supports hardware decode.  Using
+		this information, clients can make informed decisions regarding remote assets to load,
+		favoring alternate encodings when hardware decode is not supported.
+		This call returning true does not guarantee that hardware decode resources will be
+		available at all times.
+ */
+VT_EXPORT Boolean
+VTIsHardwareDecodeSupported( CMVideoCodecType codecType ) API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0));
+	
 // See VTSession.h for property access APIs on VTDecompressionSessions.
 // See VTDecompressionProperties.h for standard property keys and values for decompression sessions.
 
diff -ruN /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTSession.h /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTSession.h
--- /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTSession.h	2017-02-20 22:48:11.000000000 -0500
+++ /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTSession.h	2017-05-28 01:21:07.000000000 -0400
@@ -83,7 +83,7 @@
 VTSessionSetProperty(
   CM_NONNULL VTSessionRef       session,
   CM_NONNULL CFStringRef        propertyKey,
-  CM_NONNULL CFTypeRef          propertyValue ) API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2));
+  CM_NULLABLE CFTypeRef         propertyValue ) API_AVAILABLE(macosx(10.8), ios(8.0), tvos(10.2));
 	
 CF_IMPLICIT_BRIDGING_DISABLED
 
diff -ruN /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTVideoEncoderList.h /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTVideoEncoderList.h
--- /Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTVideoEncoderList.h	2017-02-28 01:06:17.000000000 -0500
+++ /Applications/Xcode9-beta1.app/Contents/Developer/Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS.sdk/System/Library/Frameworks/VideoToolbox.framework/Headers/VTVideoEncoderList.h	2017-05-30 01:31:34.000000000 -0400
@@ -42,6 +42,20 @@
 
 CM_ASSUME_NONNULL_END
 
+/*!
+	@function	VTCopySupportedPropertyDictionaryForEncoder
+	@abstract	Builds a list of supported properties and encoder ID for an encoder
+	@discussion
+		The caller must CFRelease the returned supported properties and encoder ID.
+*/
+VT_EXPORT OSStatus VTCopySupportedPropertyDictionaryForEncoder(
+		int32_t						width,
+		int32_t						height,
+		CMVideoCodecType			codecType,
+		CM_NULLABLE CFDictionaryRef	encoderSpecification,
+		CM_RETURNS_RETAINED_PARAMETER CM_NULLABLE CFStringRef		* CM_NULLABLE outEncoderID,
+		CM_RETURNS_RETAINED_PARAMETER CM_NULLABLE CFDictionaryRef	* CM_NULLABLE outSupportedProperties ) API_AVAILABLE(macosx(10.13), ios(11.0), tvos(11.0));
+	
 #pragma pack(pop)
 
 #if defined(__cplusplus)
Clone this wiki locally